|
@@ -56,7 +56,9 @@ class ProductLogic extends BaseLogic |
|
@@ -56,7 +56,9 @@ class ProductLogic extends BaseLogic |
|
56
|
$id = $this->param['id'];
|
56
|
$id = $this->param['id'];
|
|
57
|
}else{
|
57
|
}else{
|
|
58
|
$this->param = $this->addHandleParam($this->param);
|
58
|
$this->param = $this->addHandleParam($this->param);
|
|
59
|
- $this->param['sort'] = $this->setNewsSort();
|
59
|
+ if($this->user['project_id'] != 2059){//2059项目不处理排序
|
|
|
|
60
|
+ $this->param['sort'] = $this->setProductSort();
|
|
|
|
61
|
+ }
|
|
60
|
$id = $this->model->addReturnId($this->param);
|
62
|
$id = $this->model->addReturnId($this->param);
|
|
61
|
$route = RouteMap::setRoute($this->param['route'], RouteMap::SOURCE_PRODUCT, $id, $this->user['project_id']);
|
63
|
$route = RouteMap::setRoute($this->param['route'], RouteMap::SOURCE_PRODUCT, $id, $this->user['project_id']);
|
|
62
|
$this->model->edit(['route'=>$route],['id'=>$id]);
|
64
|
$this->model->edit(['route'=>$route],['id'=>$id]);
|
|
@@ -81,7 +83,7 @@ class ProductLogic extends BaseLogic |
|
@@ -81,7 +83,7 @@ class ProductLogic extends BaseLogic |
|
81
|
* @method :post
|
83
|
* @method :post
|
|
82
|
* @time :2023/12/25 9:27
|
84
|
* @time :2023/12/25 9:27
|
|
83
|
*/
|
85
|
*/
|
|
84
|
- public function setNewsSort(){
|
86
|
+ public function setProductSort(){
|
|
85
|
$info = $this->model->orderBy('sort','desc')->first();
|
87
|
$info = $this->model->orderBy('sort','desc')->first();
|
|
86
|
if(empty($info)){
|
88
|
if(empty($info)){
|
|
87
|
return 1;
|
89
|
return 1;
|