Ticket System save timestamp on mass edit, new ticket with standard project

This commit is contained in:
Xenomporio 2022-08-03 17:43:45 +02:00
parent 93da199f12
commit d5a85858bd

View File

@ -181,7 +181,7 @@ class Ticket {
$status = $this->app->Secure->GetPOST('status'); $status = $this->app->Secure->GetPOST('status');
$warteschlange = $this->app->Secure->GetPOST('warteschlange'); $warteschlange = $this->app->Secure->GetPOST('warteschlange');
$sql = "UPDATE ticket SET status = '".$status."'"; $sql = "UPDATE ticket SET status = '".$status."', zeit = NOW()";
if ($warteschlange != '') { if ($warteschlange != '') {
$sql .= ", warteschlange = '".explode(" ",$warteschlange)[0]."'"; $sql .= ", warteschlange = '".explode(" ",$warteschlange)[0]."'";
} }
@ -400,6 +400,8 @@ class Ticket {
$submit = $this->app->Secure->GetPOST('submit'); $submit = $this->app->Secure->GetPOST('submit');
$input = $this->GetInput(); $input = $this->GetInput();
$projekt_id = $this->app->User->DefaultProjekt();
$projekt = $this->app->DB->Select("SELECT abkuerzung FROM projekt WHERE id = ".$projekt_id);
if ($submit != '') { if ($submit != '') {
@ -412,6 +414,8 @@ class Ticket {
exit(); exit();
} }
$this->app->Tpl->Set('PROJEKT', $projekt);
$this->app->Tpl->Set('STATUSICON', $this->ticket_status_icon('neu')." "); $this->app->Tpl->Set('STATUSICON', $this->ticket_status_icon('neu')." ");
$this->app->YUI->AutoComplete("adresse","adresse"); $this->app->YUI->AutoComplete("adresse","adresse");
$this->app->YUI->AutoComplete("projekt","projektname",1); $this->app->YUI->AutoComplete("projekt","projektname",1);