作者 lyh

gx

... ... @@ -60,10 +60,10 @@ class KeywordLogic extends BaseLogic
$this->param['created_at'] = date('Y-m-d H:i:s');
$this->param['updated_at'] = $this->param['created_at'];
$id = $this->model->insertGetId($this->param);
}
//路由映射
$route = RouteMap::setRoute($this->param['title'], RouteMap::SOURCE_PRODUCT_KEYWORD, $id, $this->user['project_id']);
$this->model->edit(['route'=>$route],['id'=>$id]);
}
//清除缓存
Common::del_user_cache('product_keyword',$this->user['project_id']);
DB::commit();
... ...
... ... @@ -49,7 +49,6 @@ class ProductLogic extends BaseLogic
}
//路由映射
$route = RouteMap::setRoute($this->param['route'], RouteMap::SOURCE_PRODUCT, $id, $this->user['project_id']);
//更新路由
$this->model->edit(['route'=>$route],['id'=>$id]);
DB::commit();
}catch (\Exception $e){
... ...