Эх сурвалжийг харах

修复自动出库时包装箱扣除库存的ID

jason 5 сар өмнө
parent
commit
3186b9cd16

+ 1 - 1
app/api/controller/Inventory.php

@@ -65,7 +65,7 @@ class Inventory extends Base
                 ->leftjoin('stock_config b', 'a.variety_id = b.id')
                 ->where('a.user_id', $this->userinfo['id'])
                 ->where($where)
-                ->whereTime('a.createtime', '-2 days')
+                //->whereTime('a.createtime', '-2 days')
                 ->field('a.*,b.title')
                 ->select();
         $this->success('ok', $list);

+ 1 - 1
app/api/service/SpecService.php

@@ -80,7 +80,7 @@ class SpecService{
                         'user_id'         => $uid, 
                         'type_id'         => StockConfig::PackingBox,
                         'type'            => 1,
-                        'variety_id'      => $item['variety_id'],
+                        'variety_id'      => $specs['box_id'],
                         'change'          => -$item['num'],
                         'after'           => $boxNum,
                         'remark'          => '录入出库'