It's ID, not Id
This commit is contained in:
parent
663d0e3863
commit
5a25becff6
@ -645,11 +645,11 @@ function createStatus() {
|
|||||||
$my_order = $row[0]+10;
|
$my_order = $row[0]+10;
|
||||||
|
|
||||||
// Get the next status id
|
// Get the next status id
|
||||||
$res = hesk_dbQuery("SELECT `Id` FROM `".hesk_dbEscape($hesk_settings['db_pfix'])."statuses` ORDER BY `Id` DESC LIMIT 1");
|
$res = hesk_dbQuery("SELECT `ID` FROM `".hesk_dbEscape($hesk_settings['db_pfix'])."statuses` ORDER BY `Id` DESC LIMIT 1");
|
||||||
$row = hesk_dbFetchAssoc($res);
|
$row = hesk_dbFetchAssoc($res);
|
||||||
$nextId = $row['Id'] + 1;
|
$nextId = $row['ID'] + 1;
|
||||||
|
|
||||||
$insert = "INSERT INTO `".hesk_dbEscape($hesk_settings['db_pfix'])."statuses` (`Id`, `Key`, `TextColor`, `IsClosed`, `Closable`, `sort`)
|
$insert = "INSERT INTO `".hesk_dbEscape($hesk_settings['db_pfix'])."statuses` (`ID`, `Key`, `TextColor`, `IsClosed`, `Closable`, `sort`)
|
||||||
VALUES (".intval($nextId).", 'STORED IN XREF TABLE', '".hesk_dbEscape($textColor)."', ".intval($isClosed).", '".hesk_dbEscape($closable)."', ".intval($my_order).")";
|
VALUES (".intval($nextId).", 'STORED IN XREF TABLE', '".hesk_dbEscape($textColor)."', ".intval($isClosed).", '".hesk_dbEscape($closable)."', ".intval($my_order).")";
|
||||||
hesk_dbQuery($insert);
|
hesk_dbQuery($insert);
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user