Selaa lähdekoodia

刘优化功能

liuhairui 3 vuotta sitten
vanhempi
commit
1b30c817b9
1 muutettua tiedostoa jossa 3 lisäystä ja 2 poistoa
  1. 3 2
      application/admin/controller/Stock.php

+ 3 - 2
application/admin/controller/Stock.php

@@ -248,9 +248,10 @@ class Stock extends Backend
      * 库存管理提示来新订单 进行处理修改状态
      */
     public function orderstu(){
+        $company_id = $_SESSION['think']['admin']['company_id'];//查询对应的公司id
         $orderstu = $this->request->request('orderstu');//2
-        $arr = ['orderstu' =>$orderstu];
-        if(Db::name('order')->where('orderstu','=',1)->update($arr)){
+        $arr = ['orderstu' =>$orderstu,'update'=>date("Y-m-d H:i:s")];
+        if(Db::name('order')->where('company_id',$company_id)->where('orderstu','=',1)->update($arr)){
             return '处理成功';
         }else{
             return '处理异常';