优化本地商家商品添加、修改
This commit is contained in:
parent
56184f233e
commit
9d0f8aee42
@ -38,19 +38,6 @@ class LocalStoreGoods extends Api
|
||||
return JsonServer::success('提交成功', [], 1, 1);
|
||||
}
|
||||
|
||||
// 商家修改商品
|
||||
public function editGoods()
|
||||
{
|
||||
$form = $this->request->post();
|
||||
(new LocalStoreGoodsValidate())->goCheck();
|
||||
$result = LocalStoreGoodsLogic::editGoods($form, $this->user_id);
|
||||
if ($result === false) {
|
||||
$error = LocalStoreGoodsLogic::getError() ?: '提交失败';
|
||||
return JsonServer::error($error);
|
||||
}
|
||||
return JsonServer::success('提交成功', [], 1, 1);
|
||||
}
|
||||
|
||||
public function shopDetails()
|
||||
{
|
||||
$get = $this->request->get();
|
||||
|
||||
@ -103,6 +103,7 @@ class LocalStoreGoodsLogic extends Logic
|
||||
'price' => $form['price'],
|
||||
'desc' => $form['desc'] ?? '',
|
||||
'details' => $form['details'] ?? '',
|
||||
'audit_status' => self::$AUDIT_STATUS['audit_status_stay'],
|
||||
'update_time' => time(),
|
||||
]);
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user