Browse Source

印版库

unknown 9 months ago
parent
commit
dfbeb7a4dd
1 changed files with 2 additions and 1 deletions
  1. 2 1
      application/api/controller/PrintingPlate.php

+ 2 - 1
application/api/controller/PrintingPlate.php

@@ -214,6 +214,7 @@ class PrintingPlate extends Api
             '报废日期'   => $param['Scrappe_date']?:'1900-01-01 00:00:00',
             'Sys_id'    => $param['sys_id']
         ];
+        $UniqID = $param['UniqID'];
         //查询数据是否存在,存在则修改,不存在则增加
         $res = db('产品_印版库')
             ->where('存货编码',$param['code'])
@@ -224,7 +225,7 @@ class PrintingPlate extends Api
             $sql = db('产品_印版库')->fetchSql(true)->insert($data);
         }else{
             $data['Mod_rq'] = date('Y-m-d H:i:s',time());
-            $sql = db('产品_印版库')->fetchSql(true)->update($data);
+            $sql = db('产品_印版库')->where($UniqID)->fetchSql(true)->update($data);
         }
         $result = db()->query($sql);
         if ($result === false){