Skip to content

Commit b3cc8d2

Browse files
committed
fix(formansswer): keep tickets on delete
1 parent 08d3871 commit b3cc8d2

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

inc/formanswer.class.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -940,12 +940,16 @@ public function prepareInputForUpdate($input) {
940940
* @return boolean true if pre_delete actions succeeded, false if not
941941
*/
942942
public function pre_deleteItem() {
943+
global $CFG_GLPI;
944+
943945
$issue = new PluginFormcreatorIssue();
944946
$issue->deleteByCriteria([
945947
'items_id' => $this->getID(),
946948
'itemtype' => self::getType(),
947949
]);
948950

951+
$CFG_GLPI['keep_tickets_on_delete'] = '1';
952+
949953
return true;
950954
}
951955

0 commit comments

Comments
 (0)