From 249728dba73467af0cb03241176f34010ff475d7 Mon Sep 17 00:00:00 2001 From: Thierry Bugier Date: Thu, 4 Jun 2020 10:37:43 +0200 Subject: [PATCH] fix(exportable): implement missing method Signed-off-by: Thierry Bugier --- inc/questionparameter.class.php | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/inc/questionparameter.class.php b/inc/questionparameter.class.php index d25806cc3..8b9497ca0 100644 --- a/inc/questionparameter.class.php +++ b/inc/questionparameter.class.php @@ -80,4 +80,15 @@ public function prepareInputforAdd($input) { return $input; } + + public function deleteObsoleteItems(CommonDBTM $container, array $exclude) + { + $keepCriteria = [ + self::$items_id => $container->getID(), + ]; + if (count($exclude) > 0) { + $keepCriteria[] = ['NOT' => ['id' => $exclude]]; + } + return $this->deleteByCriteria($keepCriteria); + } }