问题修改
This commit is contained in:
parent
f277c297ea
commit
dcc5132ff0
|
|
@ -2,6 +2,8 @@ package com.bonus.material.ma.controller;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.bonus.common.biz.domain.lease.LeaseApplyInfo;
|
||||||
import com.bonus.common.log.enums.OperaType;
|
import com.bonus.common.log.enums.OperaType;
|
||||||
import com.bonus.material.common.annotation.PreventRepeatSubmit;
|
import com.bonus.material.common.annotation.PreventRepeatSubmit;
|
||||||
import com.bonus.material.ma.domain.Type;
|
import com.bonus.material.ma.domain.Type;
|
||||||
|
|
@ -141,4 +143,18 @@ public class MachineController extends BaseController {
|
||||||
{
|
{
|
||||||
return machineService.deleteMachineByMaId(maId);
|
return machineService.deleteMachineByMaId(maId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 电子标签查询
|
||||||
|
*/
|
||||||
|
@ApiOperation(value = "电子标签查询")
|
||||||
|
@GetMapping("/getElectronicLabel")
|
||||||
|
public AjaxResult getElectronicLabel(Machine machine) {
|
||||||
|
try {
|
||||||
|
return success(machineService.getElectronicLabel(machine));
|
||||||
|
} catch (Exception e) {
|
||||||
|
return error("系统错误, " + e.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -173,4 +173,12 @@ public class Machine extends BaseEntity
|
||||||
@ApiModelProperty("后缀")
|
@ApiModelProperty("后缀")
|
||||||
private Integer suffix;
|
private Integer suffix;
|
||||||
|
|
||||||
|
@ApiModelProperty("检测报告编号")
|
||||||
|
private String exCode;
|
||||||
|
|
||||||
|
@ApiModelProperty("检测报告地址")
|
||||||
|
private String exUrl;
|
||||||
|
|
||||||
|
@ApiModelProperty("是否为机具")
|
||||||
|
private Integer isJj;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -105,4 +105,11 @@ public interface MachineMapper
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
List<Machine> getMachineList(Type type);
|
List<Machine> getMachineList(Type type);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询电子标签
|
||||||
|
* @param machine
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<Machine> getElectronicLabel(Machine machine);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -76,4 +76,11 @@ public interface IMachineService
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
AjaxResult getMachineList(Type type);
|
AjaxResult getMachineList(Type type);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* todo 查询电子标签
|
||||||
|
* @param machine
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<Machine> getElectronicLabel(Machine machine);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -182,4 +182,9 @@ public class MachineServiceImpl implements IMachineService
|
||||||
}
|
}
|
||||||
return AjaxResult.success(typeList);
|
return AjaxResult.success(typeList);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Machine> getElectronicLabel(Machine machine) {
|
||||||
|
return machineMapper.getElectronicLabel(machine);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -67,7 +67,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
ma.erp_code as erpCode,
|
ma.erp_code as erpCode,
|
||||||
ma.transfer_code as transferCode,
|
ma.transfer_code as transferCode,
|
||||||
ma.in_out_num as inOutNum,
|
ma.in_out_num as inOutNum,
|
||||||
ma.buy_task as buyTask,
|
tt.code as buyTask,
|
||||||
ma.own_house as ownHouse,
|
ma.own_house as ownHouse,
|
||||||
ma.company_id as companyId,
|
ma.company_id as companyId,
|
||||||
ma.create_time as createTime,
|
ma.create_time as createTime,
|
||||||
|
|
@ -93,6 +93,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
LEFT JOIN ma_type mt4 ON mt3.parent_id = mt4.type_id
|
LEFT JOIN ma_type mt4 ON mt3.parent_id = mt4.type_id
|
||||||
and mt4.`level` = '1' and mt4.del_flag = '0'
|
and mt4.`level` = '1' and mt4.del_flag = '0'
|
||||||
LEFT JOIN ma_supplier_info msi ON msi.supplier_id = ma.ma_vender
|
LEFT JOIN ma_supplier_info msi ON msi.supplier_id = ma.ma_vender
|
||||||
|
LEFT JOIN tm_task tt on tt.task_id=ma.buy_task
|
||||||
where
|
where
|
||||||
1 = 1
|
1 = 1
|
||||||
<if test="keyWord != null and keyWord != ''">
|
<if test="keyWord != null and keyWord != ''">
|
||||||
|
|
@ -409,6 +410,30 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
mm.ma_status = '1' and mt.type_id = #{typeId}
|
mm.ma_status = '1' and mt.type_id = #{typeId}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="getElectronicLabel" resultType="com.bonus.material.ma.domain.Machine">
|
||||||
|
SELECT
|
||||||
|
mm.ma_id as maId,
|
||||||
|
mt2.type_name as materialName,
|
||||||
|
mt.type_name as materialModel,
|
||||||
|
mm.ma_code as maCode,
|
||||||
|
mm.this_check_time as thisCheckTime,
|
||||||
|
mm.next_check_time as nextCheckTime,
|
||||||
|
mm.check_man as checkMan,
|
||||||
|
mm.inspect_man as inspectMan,
|
||||||
|
mm.phone,
|
||||||
|
mm.inspect_status as inspectStatus,
|
||||||
|
mm.ma_vender as maVender,
|
||||||
|
mm.ex_code as exCode,
|
||||||
|
mm.ex_url as exUrl,
|
||||||
|
mm.is_jj as isJj
|
||||||
|
FROM
|
||||||
|
ma_machine mm
|
||||||
|
LEFT JOIN ma_type mt on mt.type_id=mm.type_id
|
||||||
|
LEFT JOIN ma_type mt2 on mt2.type_id=mt.parent_id
|
||||||
|
WHERE
|
||||||
|
mm.ma_code like concat('%', #{maCode}, '%')
|
||||||
|
</select>
|
||||||
|
|
||||||
<delete id="deleteMachineByMaCodeAndTypeId">
|
<delete id="deleteMachineByMaCodeAndTypeId">
|
||||||
delete from ma_machine where ma_code = #{maCode} and type_id = #{typeId}
|
delete from ma_machine where ma_code = #{maCode} and type_id = #{typeId}
|
||||||
and ma_status = '0'
|
and ma_status = '0'
|
||||||
|
|
|
||||||
|
|
@ -190,6 +190,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
LEFT JOIN ma_type mt1 ON mt.parent_id = mt1.type_id
|
LEFT JOIN ma_type mt1 ON mt.parent_id = mt1.type_id
|
||||||
WHERE
|
WHERE
|
||||||
pm.qr_code IS NULL
|
pm.qr_code IS NULL
|
||||||
|
and pm.ma_code is not null
|
||||||
<if test="taskId != null">
|
<if test="taskId != null">
|
||||||
AND pm.task_id = #{taskId}
|
AND pm.task_id = #{taskId}
|
||||||
</if>
|
</if>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue