diff --git a/app/data/controller/NewsItem.php b/app/data/controller/NewsItem.php index f535c9137..520ee785f 100644 --- a/app/data/controller/NewsItem.php +++ b/app/data/controller/NewsItem.php @@ -94,7 +94,7 @@ class NewsItem extends Controller protected function _form_filter(array &$data) { if (empty($data['code'])) { - $data['code'] = CodeExtend::uniqidNumber(15, 'A'); + $data['code'] = CodeExtend::uniqidNumber(14, 'A'); } if ($this->request->isGet()) { $query = $this->app->db->name('DataNewsMark')->where(['deleted' => 0, 'status' => 1]); diff --git a/app/data/controller/ShopGoods.php b/app/data/controller/ShopGoods.php index 267808e9e..c8184793b 100644 --- a/app/data/controller/ShopGoods.php +++ b/app/data/controller/ShopGoods.php @@ -136,7 +136,7 @@ class ShopGoods extends Controller protected function _copy_form_filter(array &$data) { if ($this->request->isPost()) { - $data['code'] = CodeExtend::uniqidNumber(12, 'G'); + $data['code'] = CodeExtend::uniqidNumber(14, 'G'); } } @@ -150,7 +150,7 @@ class ShopGoods extends Controller protected function _form_filter(array &$data) { if (empty($data['code'])) { - $data['code'] = CodeExtend::uniqidNumber(12, 'G'); + $data['code'] = CodeExtend::uniqidNumber(14, 'G'); } if ($this->request->isGet()) { $data['mark'] = str2arr($data['mark'] ?? '');