修复 管理员回复后工单状态不改变的问题

This commit is contained in:
iVampireSP.com 2023-01-10 22:27:19 +08:00
parent 56dffd297f
commit 9e1b85697e
No known key found for this signature in database
GPG Key ID: 2F7B001CA27A8132

View File

@ -46,6 +46,8 @@ protected static function boot()
// change work order status // change work order status
if (auth('admin')->check()) { if (auth('admin')->check()) {
$model->role = 'admin'; $model->role = 'admin';
$model->workOrder->status = 'replied';
} else if (auth('sanctum')->check()) { } else if (auth('sanctum')->check()) {
$model->user_id = auth('sanctum')->id(); $model->user_id = auth('sanctum')->id();
$model->role = 'user'; $model->role = 'user';