wesmiler 2 weeks ago
parent
commit
03cc874218
1 changed files with 2 additions and 1 deletions
  1. 2 1
      app/Services/Common/StoreCategoryService.php

+ 2 - 1
app/Services/Common/StoreCategoryService.php

@@ -130,7 +130,8 @@ class StoreCategoryService extends BaseService
         $id = isset($param['id'])?$param['id']:0;
         $id = isset($param['id'])?$param['id']:0;
         $checkId = $this->model->where(['name' => $param['name'], 'mark' => 1])->value('id');
         $checkId = $this->model->where(['name' => $param['name'], 'mark' => 1])->value('id');
         if ($checkId && ($id != $checkId)) {
         if ($checkId && ($id != $checkId)) {
-            return message('该商户分类已存在', false);
+            $this->error = '该商户分类已存在';
+            return false;
         }
         }
 
 
         // 保存数据
         // 保存数据