Keep In process status for new events with same extra id
This commit is contained in:
parent
23f0ffdf9e
commit
4bb88080ea
|
@ -13095,7 +13095,8 @@ function api_set_create_event($id, $trash1, $other, $returnType)
|
|||
|
||||
if ($validation) {
|
||||
foreach ($validation as $val) {
|
||||
if ((int) $val['estado'] === EVENT_STATUS_INPROCESS
|
||||
if ((bool) $config['keep_in_process_status_extra_id'] === true
|
||||
&& (int) $val['estado'] === EVENT_STATUS_INPROCESS
|
||||
&& (int) $values['status'] === 0
|
||||
) {
|
||||
$values['status'] = 2;
|
||||
|
|
|
@ -4072,7 +4072,7 @@ sub pandora_event {
|
|||
if (defined ($id_extra) && $id_extra ne '') {
|
||||
my $keep_in_process_status_extra_id = pandora_get_tconfig_token ($dbh, 'keep_in_process_status_extra_id', 0);
|
||||
|
||||
if ($keep_in_process_status_extra_id == 1) {
|
||||
if (defined ($keep_in_process_status_extra_id) && $keep_in_process_status_extra_id == 1) {
|
||||
# Keep status if the latest event was In process
|
||||
logger($pa_config, "Checking status of latest event with extended id '$id_extra'.", 10);
|
||||
my $id_extra_last_status = get_db_value_limit ($dbh, 'SELECT estado FROM tevento WHERE id_extra=? ORDER BY timestamp DESC', 1, $id_extra);
|
||||
|
|
Loading…
Reference in New Issue