Fixed api create_event autovalidation on meta
This commit is contained in:
parent
7bd7d190c5
commit
bfa8d703e7
|
@ -12513,7 +12513,13 @@ function api_set_create_event($id, $trash1, $other, $returnType)
|
||||||
|
|
||||||
if ($other['data'][18] != '') {
|
if ($other['data'][18] != '') {
|
||||||
$values['id_extra'] = $other['data'][18];
|
$values['id_extra'] = $other['data'][18];
|
||||||
$sql_validation = 'SELECT id_evento FROM tevento where estado IN (0,2) and id_extra ="'.$other['data'][18].'";';
|
if (is_metaconsole()) {
|
||||||
|
$table_event = 'tmetaconsole_event';
|
||||||
|
} else {
|
||||||
|
$table_event = 'tevento';
|
||||||
|
}
|
||||||
|
|
||||||
|
$sql_validation = 'SELECT id_evento FROM '.$table_event.' where estado IN (0,2) and id_extra ="'.$other['data'][18].'";';
|
||||||
$validation = db_get_all_rows_sql($sql_validation);
|
$validation = db_get_all_rows_sql($sql_validation);
|
||||||
if ($validation) {
|
if ($validation) {
|
||||||
foreach ($validation as $val) {
|
foreach ($validation as $val) {
|
||||||
|
|
Loading…
Reference in New Issue