Parcourir la source

检品机每日上报产量数据修改接口

15168162575 il y a 1 an
Parent
commit
98d4c6b702
1 fichiers modifiés avec 26 ajouts et 13 suppressions
  1. 26 13
      application/api/controller/Facility.php

+ 26 - 13
application/api/controller/Facility.php

@@ -2585,7 +2585,7 @@ class Facility extends Api
                 $list[$key]['日定额'] = $row['日定额'];
                 $list[$key]['补产标准'] = $row['补产标准'];
             }
-            $list[$key]['工序'] = $list[$key]['gxmc'];
+            $list[$key]['工序'] = $list[$key]['yjno'].'-'.$list[$key]['gxh'].'-'.$list[$key]['gxmc'];
             for ($i=1;$i<11;$i++){
                 if (isset($value['sczl_bh'.$i])){
                     $name = \db('人事_基本资料')->where('员工编号',$value['sczl_bh'.$i])->field('员工姓名 as name')->find();
@@ -2603,16 +2603,29 @@ class Facility extends Api
         $this->success('成功',$list);
     }
 
-    //设备运行跟踪月度数据导出
-//    public function MouthDataOutput()
-//    {
-//        if ($this->request->isGet() === false){
-//            $this->error('参数错误');
-//        }
-//        $param = $this->request->param();
-//        if (empty($param)){
-//            $this->error('参数错误');
-//        }
-//        $filed = "工单编号,产品名称,流程单号,印件号,工序号,机台编号,日期,工序产量,工序名称,机长工号,机长名称,组员工号1,组员姓名1,";
-//    }
+    /**
+     * 检品机每日上报数据修改页面数据获取接口
+     * @return void
+     * @throws \think\db\exception\DataNotFoundException
+     * @throws \think\db\exception\ModelNotFoundException
+     * @throws \think\exception\DbException
+     */
+    public function JPchanliangDetailList()
+    {
+        if ($this->request->isGet() === false){
+            $this->error('请求错误');
+        }
+        $param = $this->request->param();
+        if (empty($param)){
+            $this->error('参数错误');
+        }
+        $list = \db('设备_产量计酬')
+            ->where('UniqId',$param['UniqId'])
+            ->find();
+        if (!empty($list)){
+            $this->success('成功',$list);
+        }else{
+            $this->error('未找到数据');
+        }
+    }
 }