作者 耿培杰

修改后台

... ... @@ -108,6 +108,7 @@ class Goods extends Backend
$validate = is_bool($this->modelValidate) ? ($this->modelSceneValidate ? $name . '.add' : $name) : $this->modelValidate;
$this->model->validateFailException(true)->validate($validate);
}
if (!empty($params['category_group_ids'])) $params['category_group_ids'] = ',' . $params['category_group_ids'] . ',';
$result = $this->model->allowField(true)->save($params);
Db::commit();
} catch (ValidateException $e) {
... ...