|
|
@@ -460,7 +460,7 @@ class OrderSuperLoss extends Api
|
|
|
// $data['实际投料'] = number_format($data['投料']*$data['ls']*$data['ks']/10000,4);
|
|
|
$data['实际投料'] = number_format($data['投料'] * $data['ls'] * $data['ks'] / 10000, 4, '.', '');
|
|
|
if($data['实际投料'] == 0){
|
|
|
- $this->error('投料数据为 0');
|
|
|
+ $this->error('投料数据为 0,请点击超节损页面“修正工单投料”按钮进行修正');
|
|
|
return;
|
|
|
}
|
|
|
//查出成品数量及日期
|
|
|
@@ -578,7 +578,7 @@ class OrderSuperLoss extends Api
|
|
|
// $data['分摊废'] = '';//分摊废
|
|
|
$plan_total =db('工单_工艺资料')->where(['Gy0_gdbh' => $order,'Gy0_yjno' => $params['yjno'], 'Gy0_gxh' => ['in', $gxh_values]])->value('SUM(Gy0_计划损耗 * Gy0_ls * Gy0_ks)');
|
|
|
if($plan_total == 0){
|
|
|
- $this->error('计划损耗数据为 0');
|
|
|
+ $this->error('计划损耗数据为 0,请到工单资料管理页面修改工艺资料中选择正确的工序损耗');
|
|
|
return;
|
|
|
}
|
|
|
//单据列表最后统计
|
|
|
@@ -1159,13 +1159,13 @@ class OrderSuperLoss extends Api
|
|
|
if ($item['sczl_bh'.$i] !== '' && $item['sczl_bh'.$i] !== null){
|
|
|
$item['sczl_rate'.$i] = 1;
|
|
|
|
|
|
- $res = [
|
|
|
- 'bh' => $item['sczl_bh'.$i],
|
|
|
- 'xm' => $item['Xm'.$i],
|
|
|
- 'je' => $item['CjsJe']*$item['sczl_rate'.$i],
|
|
|
- 'cj' => rtrim($item['车间名称'])
|
|
|
- ];
|
|
|
- array_push($data,$res);
|
|
|
+ $res = [
|
|
|
+ 'bh' => $item['sczl_bh'.$i],
|
|
|
+ 'xm' => $item['Xm'.$i],
|
|
|
+ 'je' => $item['CjsJe']*$item['sczl_rate'.$i],
|
|
|
+ 'cj' => rtrim($item['车间名称'])
|
|
|
+ ];
|
|
|
+ array_push($data,$res);
|
|
|
}
|
|
|
}
|
|
|
}
|