shish 2 лет назад
Родитель
Сommit
b86a7741ef

+ 4 - 4
app-ghs/controllers/CustomController.php

@@ -302,8 +302,8 @@ class CustomController extends BaseController
         if (empty($name)) {
             util::fail('名称不能为空');
         }
-        if (stringUtil::getWordNum($name) > 16) {
-            util::fail('名称不能超过16个汉字');
+        if (stringUtil::getWordNum($name) > 15) {
+            util::fail('名称不能超过15个汉字');
         }
         $has = SjClass::getByCondition(['name' => $name, 'style' => SjClass::STYLE_RETAIL]);
         if (!empty($has)) {
@@ -388,8 +388,8 @@ class CustomController extends BaseController
             if (empty($name)) {
                 util::fail('花店名称不能为空');
             }
-            if (stringUtil::getWordNum($name) > 16) {
-                util::fail('名称不能超过16个汉字');
+            if (stringUtil::getWordNum($name) > 15) {
+                util::fail('名称不能超过15个汉字');
             }
             if (empty($mobile)) {
                 //添加虚拟客户

+ 2 - 2
console/controllers/CustomController.php

@@ -172,8 +172,8 @@ class CustomController extends Controller
                     $transaction->rollBack();
                     continue;
                 }
-                if (stringUtil::getWordNum($shopName) > 16) {
-                    noticeUtil::push("花店 {$shopName} 手机号 {$mobile} 添加失败,名称超过了16个汉字", '15280215347');
+                if (stringUtil::getWordNum($shopName) > 15) {
+                    noticeUtil::push("花店 {$shopName} 手机号 {$mobile} 添加失败,名称超过了15个汉字", '15280215347');
                     $transaction->rollBack();
                     continue;
                 }