|
@@ -341,7 +341,7 @@ class GluingReport extends Api
|
|
|
->order('设备编组')
|
|
->order('设备编组')
|
|
|
->column('rtrim(使用部门) as 使用部门');
|
|
->column('rtrim(使用部门) as 使用部门');
|
|
|
if (empty($department)){
|
|
if (empty($department)){
|
|
|
- $this->success('为获取到机台数据');
|
|
|
|
|
|
|
+ $this->success('未获取到机台数据');
|
|
|
}
|
|
}
|
|
|
$list = \db('设备_糊盒报工资料')
|
|
$list = \db('设备_糊盒报工资料')
|
|
|
->field([
|
|
->field([
|
|
@@ -351,9 +351,7 @@ class GluingReport extends Api
|
|
|
->where('sczl_rq','>',$date)
|
|
->where('sczl_rq','>',$date)
|
|
|
->order('sczl_rq desc')
|
|
->order('sczl_rq desc')
|
|
|
->select();
|
|
->select();
|
|
|
- if (empty($list)){
|
|
|
|
|
- $this->success('未找到机台生产记录');
|
|
|
|
|
- }
|
|
|
|
|
|
|
+
|
|
|
foreach ($department as $value){
|
|
foreach ($department as $value){
|
|
|
$machine = \db('设备_基本资料')->where('使用部门',$value)->where('sys_sbID','<>','')->where('使用部门',$value)->field('rtrim(设备编号) as 设备编号,rtrim(设备名称) as 设备名称')->order('设备编号')->select();
|
|
$machine = \db('设备_基本资料')->where('使用部门',$value)->where('sys_sbID','<>','')->where('使用部门',$value)->field('rtrim(设备编号) as 设备编号,rtrim(设备名称) as 设备名称')->order('设备编号')->select();
|
|
|
foreach ($machine as $k=>$v){
|
|
foreach ($machine as $k=>$v){
|
|
@@ -388,6 +386,9 @@ class GluingReport extends Api
|
|
|
$machine = $params['machine'];
|
|
$machine = $params['machine'];
|
|
|
$machineCode = \db('dic_lzde')->where('适用机型',$machine)->value('sys_bh');
|
|
$machineCode = \db('dic_lzde')->where('适用机型',$machine)->value('sys_bh');
|
|
|
$data = \db('设备_糊盒报工采集')->where('sczl_jtbh',$machine)->order('UID desc')->find();
|
|
$data = \db('设备_糊盒报工采集')->where('sczl_jtbh',$machine)->order('UID desc')->find();
|
|
|
|
|
+ if (empty($data)){
|
|
|
|
|
+ $this->success('未找到数据');
|
|
|
|
|
+ }
|
|
|
$list = [];
|
|
$list = [];
|
|
|
$list['班组ID'] = $data['班组ID'];
|
|
$list['班组ID'] = $data['班组ID'];
|
|
|
$row = [];
|
|
$row = [];
|
|
@@ -510,7 +511,13 @@ class GluingReport extends Api
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- //糊盒设备运行跟踪数据页面显示
|
|
|
|
|
|
|
+ /**
|
|
|
|
|
+ * 糊盒设备运行跟踪数据页面显示
|
|
|
|
|
+ * @return void
|
|
|
|
|
+ * @throws \think\db\exception\DataNotFoundException
|
|
|
|
|
+ * @throws \think\db\exception\ModelNotFoundException
|
|
|
|
|
+ * @throws \think\exception\DbException
|
|
|
|
|
+ */
|
|
|
public function getGluingReportDataList()
|
|
public function getGluingReportDataList()
|
|
|
{
|
|
{
|
|
|
if ($this->request->isGet() === false){
|
|
if ($this->request->isGet() === false){
|