Skip to content
Snippets Groups Projects
Commit 3f2ab3ef authored by Florian Azizian's avatar Florian Azizian
Browse files

FEAT #8760 TIME 1 clean signatureBookId after retrieve doc from MP

parent b4f3d94e
No related branches found
No related tags found
No related merge requests found
...@@ -266,7 +266,7 @@ function Bt_refusedSignedMail($aArgs = []) ...@@ -266,7 +266,7 @@ function Bt_refusedSignedMail($aArgs = [])
[$aArgs['resIdMaster'], $creatorName . $aArgs['noteContent']] [$aArgs['resIdMaster'], $creatorName . $aArgs['noteContent']]
); );
} }
$GLOBALS['db']->query("UPDATE ".$aArgs['tableAttachment']." SET status = 'A_TRA' WHERE res_id = ?", [$aArgs['resIdAttachment']]); $GLOBALS['db']->query("UPDATE ".$aArgs['tableAttachment']." SET status = 'A_TRA', external_id = external_id - 'signatureBookId' WHERE res_id = ?", [$aArgs['resIdAttachment']]);
$GLOBALS['db']->query('UPDATE listinstance SET process_date = NULL WHERE res_id = ? AND difflist_type = ?', [$aArgs['resIdMaster'], 'VISA_CIRCUIT']); $GLOBALS['db']->query('UPDATE listinstance SET process_date = NULL WHERE res_id = ? AND difflist_type = ?', [$aArgs['resIdMaster'], 'VISA_CIRCUIT']);
$GLOBALS['db']->query("UPDATE res_letterbox SET status = '" . $aArgs['refusedStatus'] . "' WHERE res_id = ?", [$aArgs['resIdMaster']]); $GLOBALS['db']->query("UPDATE res_letterbox SET status = '" . $aArgs['refusedStatus'] . "' WHERE res_id = ?", [$aArgs['resIdMaster']]);
......
...@@ -335,7 +335,7 @@ foreach ($retrievedMails['isVersion'] as $resId => $value) { ...@@ -335,7 +335,7 @@ foreach ($retrievedMails['isVersion'] as $resId => $value) {
} }
$GLOBALS['logger']->write('Document validated', 'INFO'); $GLOBALS['logger']->write('Document validated', 'INFO');
$GLOBALS['db']->query("UPDATE res_version_attachments set status = 'OBS' WHERE res_id = ?", [$resId]); $GLOBALS['db']->query("UPDATE res_version_attachments set status = 'OBS', external_id = external_id - 'signatureBookId' WHERE res_id = ?", [$resId]);
if (!empty($value->onlyVisa) && $value->onlyVisa) { if (!empty($value->onlyVisa) && $value->onlyVisa) {
$status = $validatedStatusOnlyVisa; $status = $validatedStatusOnlyVisa;
} else { } else {
...@@ -450,7 +450,7 @@ foreach ($retrievedMails['noVersion'] as $resId => $value) { ...@@ -450,7 +450,7 @@ foreach ($retrievedMails['noVersion'] as $resId => $value) {
} }
$GLOBALS['logger']->write('Document validated', 'INFO'); $GLOBALS['logger']->write('Document validated', 'INFO');
$GLOBALS['db']->query("UPDATE res_attachments SET status = 'OBS' WHERE res_id = ?", [$resId]); $GLOBALS['db']->query("UPDATE res_attachments SET status = 'OBS', external_id = external_id - 'signatureBookId' WHERE res_id = ?", [$resId]);
if (!empty($value->onlyVisa) && $value->onlyVisa) { if (!empty($value->onlyVisa) && $value->onlyVisa) {
$status = $validatedStatusOnlyVisa; $status = $validatedStatusOnlyVisa;
} else { } else {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment