commit
e1d4ae7be4
|
@ -53,7 +53,7 @@ class EditSettingsController extends Controller {
|
|||
];
|
||||
|
||||
foreach($settings as $setting) {
|
||||
if(Controller::request($setting)) {
|
||||
if(Controller::request($setting)!==null) {
|
||||
$settingInstance = Setting::getSetting($setting);
|
||||
$settingInstance->value = Controller::request($setting);
|
||||
$settingInstance->store();
|
||||
|
@ -68,7 +68,7 @@ class EditSettingsController extends Controller {
|
|||
|
||||
Response::respondSuccess();
|
||||
}
|
||||
|
||||
|
||||
public function handleLanguages() {
|
||||
$allowed = json_decode(Controller::request('allowedLanguages'));
|
||||
$supported = json_decode(Controller::request('supportedLanguages'));
|
||||
|
@ -83,4 +83,4 @@ class EditSettingsController extends Controller {
|
|||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -66,10 +66,13 @@ class ChangeDepartmentController extends Controller {
|
|||
$ticket->addEvent($event);
|
||||
$ticket->department = $department;
|
||||
$ticket->unread = true;
|
||||
if(!Controller::getLoggedUser()->sharedDepartmentList->includesId($department->id)) {
|
||||
$ticket->owner = null;
|
||||
}
|
||||
$ticket->store();
|
||||
|
||||
Log::createLog('DEPARTMENT_CHANGED', $ticket->ticketNumber);
|
||||
|
||||
Response::respondSuccess();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -6,7 +6,7 @@ describe'system/edit-settings' do
|
|||
result= request('/system/edit-settings', {
|
||||
"csrf_userid" => $csrf_userid,
|
||||
"csrf_token" => $csrf_token,
|
||||
"maintenance-mode" => false,
|
||||
"maintenance-mode" => 0,
|
||||
"time-zone" => -3,
|
||||
"layout" => 'full-width',
|
||||
"allow-attachments" => 1,
|
||||
|
@ -82,4 +82,4 @@ describe'system/edit-settings' do
|
|||
|
||||
request('/user/logout')
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue