功能完善
This commit is contained in:
parent
c956bca3af
commit
867070cd6b
|
|
@ -223,7 +223,7 @@ public class BackApplyController extends BaseController {
|
||||||
return AjaxResult.error("退料设备明细为空,请重新选择后上传!");
|
return AjaxResult.error("退料设备明细为空,请重新选择后上传!");
|
||||||
}
|
}
|
||||||
for (BackApplyInfo backApplyInfo : record.getBackApplyDetails()){
|
for (BackApplyInfo backApplyInfo : record.getBackApplyDetails()){
|
||||||
backApplyInfo.setId(record.getTaskId());
|
backApplyInfo.setParentId(record.getParentId());
|
||||||
boolean re =backApplyService.upload(backApplyInfo)>0;
|
boolean re =backApplyService.upload(backApplyInfo)>0;
|
||||||
if (!re){
|
if (!re){
|
||||||
return AjaxResult.error("退料任务明细插入失败");
|
return AjaxResult.error("退料任务明细插入失败");
|
||||||
|
|
@ -233,25 +233,6 @@ public class BackApplyController extends BaseController {
|
||||||
}catch (Exception e){
|
}catch (Exception e){
|
||||||
return AjaxResult.error("创建任务失败," + e.getCause().toString() + "," + e.getMessage());
|
return AjaxResult.error("创建任务失败," + e.getCause().toString() + "," + e.getMessage());
|
||||||
}
|
}
|
||||||
// try {
|
|
||||||
// if (!StringUtils.isEmpty(record.getTypeId()) && !StringUtils.isEmpty(record.getNum())){
|
|
||||||
// String[] typeId = record.getTypeId().split(",");
|
|
||||||
// String[] num = record.getNum().split(",");
|
|
||||||
// for (int i=0;i< typeId.length;i++){
|
|
||||||
// String typeIdStr=typeId[i];
|
|
||||||
// String numStr=num[i];
|
|
||||||
// record.setTypeId(typeIdStr);
|
|
||||||
// record.setNum(numStr);
|
|
||||||
// int re =backApplyService.upload(record);
|
|
||||||
// if (re<1){
|
|
||||||
// return AjaxResult.error("提交失败");
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// return AjaxResult.success("提交成功");
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// throw new RuntimeException(e);
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 退料编号生成规则
|
// 退料编号生成规则
|
||||||
|
|
|
||||||
|
|
@ -283,7 +283,21 @@
|
||||||
bai.id = #{id}
|
bai.id = #{id}
|
||||||
</update>
|
</update>
|
||||||
<delete id="del">
|
<delete id="del">
|
||||||
DELETE FROM back_apply_info WHERE id = #{id}
|
DELETE
|
||||||
|
FROM tm_task_agreement
|
||||||
|
WHERE task_id IN (SELECT task_id FROM back_apply_info WHERE id = #{id});
|
||||||
|
|
||||||
|
DELETE
|
||||||
|
FROM tm_task
|
||||||
|
WHERE task_id IN (SELECT task_id FROM back_apply_info WHERE id = #{id});
|
||||||
|
|
||||||
|
DELETE
|
||||||
|
FROM back_apply_details
|
||||||
|
WHERE parent_id IN (SELECT id FROM back_apply_info WHERE id = #{id});
|
||||||
|
|
||||||
|
DELETE
|
||||||
|
FROM back_apply_info
|
||||||
|
WHERE id = #{id};
|
||||||
</delete>
|
</delete>
|
||||||
|
|
||||||
<select id="getbackUnit" resultType="com.bonus.sgzb.app.domain.BmAgreementInfo">
|
<select id="getbackUnit" resultType="com.bonus.sgzb.app.domain.BmAgreementInfo">
|
||||||
|
|
@ -327,7 +341,7 @@
|
||||||
tt.task_status as taskStatus,
|
tt.task_status as taskStatus,
|
||||||
tta.agreement_id as agreementId,
|
tta.agreement_id as agreementId,
|
||||||
GROUP_CONCAT(DISTINCT bad.type_id) as typeId,
|
GROUP_CONCAT(DISTINCT bad.type_id) as typeId,
|
||||||
GROUP_CONCAT(CONCAT_WS('/', IFNULL(mt3.type_name, ''))) AS typeName
|
GROUP_CONCAT(CONCAT_WS('/', IFNULL(mt2.type_name, ''))) AS typeName
|
||||||
FROM
|
FROM
|
||||||
back_apply_info bai
|
back_apply_info bai
|
||||||
LEFT JOIN back_apply_details bad on bad.parent_id=bai.id
|
LEFT JOIN back_apply_details bad on bad.parent_id=bai.id
|
||||||
|
|
@ -339,8 +353,6 @@
|
||||||
LEFT JOIN sys_user us on us.user_id=bai.create_by
|
LEFT JOIN sys_user us on us.user_id=bai.create_by
|
||||||
LEFT JOIN ma_type mt1 ON mt1.type_id=bad.type_id
|
LEFT JOIN ma_type mt1 ON mt1.type_id=bad.type_id
|
||||||
LEFT JOIN ma_type mt2 ON mt2.type_id=mt1.parent_id
|
LEFT JOIN ma_type mt2 ON mt2.type_id=mt1.parent_id
|
||||||
LEFT JOIN ma_type mt3 ON mt3.type_id=mt2.parent_id
|
|
||||||
LEFT JOIN ma_type mt4 ON mt4.type_id=mt3.parent_id
|
|
||||||
GROUP BY bai.id, us.user_name, bai.phone, bpl.lot_name, bui.unit_name, bagi.plan_start_time
|
GROUP BY bai.id, us.user_name, bai.phone, bpl.lot_name, bui.unit_name, bagi.plan_start_time
|
||||||
ORDER BY bai.create_time desc
|
ORDER BY bai.create_time desc
|
||||||
</select>
|
</select>
|
||||||
|
|
@ -422,14 +434,14 @@
|
||||||
<select id="examineList" resultType="com.bonus.sgzb.app.domain.BackApplyInfo">
|
<select id="examineList" resultType="com.bonus.sgzb.app.domain.BackApplyInfo">
|
||||||
SELECT
|
SELECT
|
||||||
bai.id,
|
bai.id,
|
||||||
us.user_name as userName,
|
bai.back_person as backPerson,
|
||||||
bai.phone,
|
bai.phone,
|
||||||
bpl.lot_name as lotName,
|
bpl.lot_name as lotName,
|
||||||
bui.unit_name as unitName,
|
bui.unit_name as unitName,
|
||||||
bagi.plan_start_time as planStartTime,
|
bagi.plan_start_time as planStartTime,
|
||||||
tt.task_status as taskStatus,
|
tt.task_status as taskStatus,
|
||||||
GROUP_CONCAT(DISTINCT bad.type_id) as typeId,
|
GROUP_CONCAT(DISTINCT bad.type_id) as typeId,
|
||||||
GROUP_CONCAT(CONCAT_WS('/', IFNULL(mt3.type_name, ''))) AS typeName,
|
GROUP_CONCAT(CONCAT_WS('/', IFNULL(mt2.type_name, ''))) AS typeName,
|
||||||
SUM(DISTINCT bad.pre_num) AS num,
|
SUM(DISTINCT bad.pre_num) AS num,
|
||||||
bai.direct_audit_remark as directAuditRemark
|
bai.direct_audit_remark as directAuditRemark
|
||||||
FROM
|
FROM
|
||||||
|
|
@ -443,18 +455,14 @@
|
||||||
LEFT JOIN sys_user us on us.user_id=bai.create_by
|
LEFT JOIN sys_user us on us.user_id=bai.create_by
|
||||||
LEFT JOIN ma_type mt1 ON mt1.type_id=bad.type_id
|
LEFT JOIN ma_type mt1 ON mt1.type_id=bad.type_id
|
||||||
LEFT JOIN ma_type mt2 ON mt2.type_id=mt1.parent_id
|
LEFT JOIN ma_type mt2 ON mt2.type_id=mt1.parent_id
|
||||||
LEFT JOIN ma_type mt3 ON mt3.type_id=mt2.parent_id
|
|
||||||
LEFT JOIN ma_type mt4 ON mt4.type_id=mt3.parent_id
|
|
||||||
WHERE
|
WHERE
|
||||||
# bai.company_id=#{companyId}
|
|
||||||
# and
|
|
||||||
bad.type_id is not null
|
bad.type_id is not null
|
||||||
GROUP BY bai.id, us.user_name, bai.phone, bpl.lot_name, bui.unit_name, bagi.plan_start_time
|
GROUP BY bai.id, us.user_name, bai.phone, bpl.lot_name, bui.unit_name, bagi.plan_start_time
|
||||||
</select>
|
</select>
|
||||||
<select id="examineView" resultType="com.bonus.sgzb.app.domain.BackApplyInfo">
|
<select id="examineView" resultType="com.bonus.sgzb.app.domain.BackApplyInfo">
|
||||||
SELECT
|
SELECT
|
||||||
mt.type_name typeCode,
|
mt.type_name typeCode,
|
||||||
CONCAT_WS('/', IFNULL(mt3.type_name, '')) AS typeName,
|
CONCAT_WS('/', IFNULL(mt2.type_name, '')) AS typeName,
|
||||||
bad.pre_num as num,
|
bad.pre_num as num,
|
||||||
mm.ma_code as maCode
|
mm.ma_code as maCode
|
||||||
FROM
|
FROM
|
||||||
|
|
@ -463,8 +471,6 @@
|
||||||
LEFT JOIN ma_type mt on mt.type_id=bad.type_id
|
LEFT JOIN ma_type mt on mt.type_id=bad.type_id
|
||||||
LEFT JOIN ma_type mt1 ON mt1.type_id=bad.type_id
|
LEFT JOIN ma_type mt1 ON mt1.type_id=bad.type_id
|
||||||
LEFT JOIN ma_type mt2 ON mt2.type_id=mt1.parent_id
|
LEFT JOIN ma_type mt2 ON mt2.type_id=mt1.parent_id
|
||||||
LEFT JOIN ma_type mt3 ON mt3.type_id=mt2.parent_id
|
|
||||||
LEFT JOIN ma_type mt4 ON mt4.type_id=mt3.parent_id
|
|
||||||
LEFT JOIN ma_machine mm on mm.type_id=bad.type_id
|
LEFT JOIN ma_machine mm on mm.type_id=bad.type_id
|
||||||
WHERE
|
WHERE
|
||||||
bai.id=#{id}
|
bai.id=#{id}
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,12 @@
|
||||||
package com.bonus.sgzb.material.controller;
|
package com.bonus.sgzb.material.controller;
|
||||||
|
|
||||||
|
import com.bonus.sgzb.common.core.utils.poi.ExcelUtil;
|
||||||
import com.bonus.sgzb.common.core.web.controller.BaseController;
|
import com.bonus.sgzb.common.core.web.controller.BaseController;
|
||||||
import com.bonus.sgzb.common.core.web.domain.AjaxResult;
|
import com.bonus.sgzb.common.core.web.domain.AjaxResult;
|
||||||
import com.bonus.sgzb.common.core.web.page.TableDataInfo;
|
import com.bonus.sgzb.common.core.web.page.TableDataInfo;
|
||||||
|
import com.bonus.sgzb.common.log.annotation.Log;
|
||||||
|
import com.bonus.sgzb.common.log.enums.BusinessType;
|
||||||
|
import com.bonus.sgzb.material.domain.BackApplyInfo;
|
||||||
import com.bonus.sgzb.material.domain.RepairTestInputDetailVo;
|
import com.bonus.sgzb.material.domain.RepairTestInputDetailVo;
|
||||||
import com.bonus.sgzb.material.domain.RepairTestInputDto;
|
import com.bonus.sgzb.material.domain.RepairTestInputDto;
|
||||||
import com.bonus.sgzb.material.domain.RepairTestInputVo;
|
import com.bonus.sgzb.material.domain.RepairTestInputVo;
|
||||||
|
|
@ -12,6 +16,7 @@ import org.springframework.validation.annotation.Validated;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -60,4 +65,17 @@ public class RepairTestInputController extends BaseController {
|
||||||
public AjaxResult inputByType(@RequestBody RepairTestInputDto dto){
|
public AjaxResult inputByType(@RequestBody RepairTestInputDto dto){
|
||||||
return service.inputByType(dto);
|
return service.inputByType(dto);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修试入库导出
|
||||||
|
*/
|
||||||
|
@ApiOperation("修试入库导出")
|
||||||
|
@Log(title = "修试入库导出", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("export")
|
||||||
|
public void export(HttpServletResponse response, RepairTestInputDto bean)
|
||||||
|
{
|
||||||
|
List<RepairTestInputDetailVo> list = service.exportList(bean);
|
||||||
|
ExcelUtil<RepairTestInputDetailVo> util = new ExcelUtil<RepairTestInputDetailVo>(RepairTestInputDetailVo.class);
|
||||||
|
util.exportExcel(response, list, "修试入库数据");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,17 +1,23 @@
|
||||||
package com.bonus.sgzb.material.controller;
|
package com.bonus.sgzb.material.controller;
|
||||||
|
|
||||||
|
import com.bonus.sgzb.common.core.utils.poi.ExcelUtil;
|
||||||
import com.bonus.sgzb.common.core.web.controller.BaseController;
|
import com.bonus.sgzb.common.core.web.controller.BaseController;
|
||||||
import com.bonus.sgzb.common.core.web.domain.AjaxResult;
|
import com.bonus.sgzb.common.core.web.domain.AjaxResult;
|
||||||
import com.bonus.sgzb.common.core.web.page.TableDataInfo;
|
import com.bonus.sgzb.common.core.web.page.TableDataInfo;
|
||||||
|
import com.bonus.sgzb.common.log.annotation.Log;
|
||||||
|
import com.bonus.sgzb.common.log.enums.BusinessType;
|
||||||
|
import com.bonus.sgzb.material.domain.BackApplyInfo;
|
||||||
import com.bonus.sgzb.material.domain.ReturnOfMaterialsInfo;
|
import com.bonus.sgzb.material.domain.ReturnOfMaterialsInfo;
|
||||||
import com.bonus.sgzb.material.service.ReturnOfMaterialsInfoService;
|
import com.bonus.sgzb.material.service.ReturnOfMaterialsInfoService;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -47,4 +53,17 @@ public class ReturnOfMaterialsInfoController extends BaseController {
|
||||||
return AjaxResult.success(list);
|
return AjaxResult.success(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 退料入库导出
|
||||||
|
*/
|
||||||
|
@ApiOperation("退料入库导出")
|
||||||
|
@Log(title = "退料入库导出", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
public void export(HttpServletResponse response, ReturnOfMaterialsInfo bean)
|
||||||
|
{
|
||||||
|
List<ReturnOfMaterialsInfo> list = returnOfMaterialsInfoService.exportList(bean);
|
||||||
|
ExcelUtil<ReturnOfMaterialsInfo> util = new ExcelUtil<ReturnOfMaterialsInfo>(ReturnOfMaterialsInfo.class);
|
||||||
|
util.exportExcel(response, list, "退料入库数据");
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
package com.bonus.sgzb.material.domain;
|
package com.bonus.sgzb.material.domain;
|
||||||
|
|
||||||
|
import com.bonus.sgzb.common.core.annotation.Excel;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -15,33 +16,53 @@ public class RepairTestInputDetailVo {
|
||||||
/** 机具id*/
|
/** 机具id*/
|
||||||
private Integer maId;
|
private Integer maId;
|
||||||
|
|
||||||
|
/** 维修单号*/
|
||||||
|
@Excel(name = "维修单号")
|
||||||
|
private String repairCode;
|
||||||
|
|
||||||
/** 规格ID*/
|
/** 规格ID*/
|
||||||
private Integer typeId;
|
private Integer typeId;
|
||||||
|
|
||||||
/** 设备类型*/
|
/** 设备类型*/
|
||||||
private String typeName;
|
@Excel(name = "工机具类型")
|
||||||
|
private String typeName2;
|
||||||
|
|
||||||
/** 规格型号*/
|
/** 规格型号*/
|
||||||
private String typeName2;
|
@Excel(name = "规格型号")
|
||||||
|
private String typeName;
|
||||||
|
|
||||||
|
/** 维修人员*/
|
||||||
|
@Excel(name = "维修人员")
|
||||||
|
private String wxName;
|
||||||
|
|
||||||
|
/** 维修时间*/
|
||||||
|
@Excel(name = "维修时间")
|
||||||
|
private String wxTime;
|
||||||
|
|
||||||
/** 管理方式(0编号 1计数)*/
|
/** 管理方式(0编号 1计数)*/
|
||||||
private String manageType;
|
private String manageType;
|
||||||
|
|
||||||
/** 数量*/
|
/** 数量*/
|
||||||
|
@Excel(name = "数量")
|
||||||
private double repairNum;
|
private double repairNum;
|
||||||
|
|
||||||
/** 编号*/
|
/** 编号*/
|
||||||
|
@Excel(name = "编号")
|
||||||
private String maCode;
|
private String maCode;
|
||||||
|
|
||||||
/** 提交入库人员*/
|
/** 提交入库人员*/
|
||||||
|
@Excel(name = "提交入库人员")
|
||||||
private String updateBy;
|
private String updateBy;
|
||||||
|
|
||||||
/** 提交入库时间*/
|
/** 提交入库时间*/
|
||||||
|
@Excel(name = "提交入库时间")
|
||||||
private String updateTime;
|
private String updateTime;
|
||||||
|
|
||||||
/** 不通过原因*/
|
/** 不通过原因*/
|
||||||
|
@Excel(name = "不通过原因")
|
||||||
private String remark;
|
private String remark;
|
||||||
|
|
||||||
/** 状态*/
|
/** 状态*/
|
||||||
|
@Excel(name = "状态")
|
||||||
private String status;
|
private String status;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
package com.bonus.sgzb.material.domain;
|
package com.bonus.sgzb.material.domain;
|
||||||
|
|
||||||
|
import com.bonus.sgzb.common.core.annotation.Excel;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
|
|
@ -16,30 +17,42 @@ public class ReturnOfMaterialsInfo {
|
||||||
|
|
||||||
/** 退料单号 */
|
/** 退料单号 */
|
||||||
@ApiModelProperty(value = "退料单号")
|
@ApiModelProperty(value = "退料单号")
|
||||||
|
@Excel(name = "退料单号")
|
||||||
private String code;
|
private String code;
|
||||||
|
|
||||||
/** 退料单位 */
|
/** 退料单位 */
|
||||||
@ApiModelProperty(value = "退料单位")
|
@ApiModelProperty(value = "退料单位")
|
||||||
|
@Excel(name = "退料单位")
|
||||||
private String unitName;
|
private String unitName;
|
||||||
|
|
||||||
/** 退料工程 */
|
/** 退料工程 */
|
||||||
@ApiModelProperty(value = "退料工程")
|
@ApiModelProperty(value = "退料工程")
|
||||||
|
@Excel(name = "退料工程")
|
||||||
private String lotName;
|
private String lotName;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "类型名称")
|
||||||
|
@Excel(name = "退料机具类型")
|
||||||
|
private String typeName;
|
||||||
|
|
||||||
|
|
||||||
@ApiModelProperty(value = "机具id")
|
@ApiModelProperty(value = "机具id")
|
||||||
private Long kindId;
|
private Long kindId;
|
||||||
|
|
||||||
@ApiModelProperty(value = "机具名称")
|
@ApiModelProperty(value = "机具名称")
|
||||||
|
@Excel(name = "退料设备类型")
|
||||||
private String kindName;
|
private String kindName;
|
||||||
|
|
||||||
@ApiModelProperty(value = "类型id")
|
@ApiModelProperty(value = "类型id")
|
||||||
private Long typeId;
|
private Long typeId;
|
||||||
|
|
||||||
@ApiModelProperty(value = "类型ids")
|
@ApiModelProperty(value = "类型ids")
|
||||||
private String typeIds;
|
private String typeIds;
|
||||||
@ApiModelProperty(value = "类型名称")
|
|
||||||
private String typeName;
|
|
||||||
@ApiModelProperty(value = "规格型号id")
|
@ApiModelProperty(value = "规格型号id")
|
||||||
private Long modelId;
|
private Long modelId;
|
||||||
|
|
||||||
@ApiModelProperty(value = "规格型号")
|
@ApiModelProperty(value = "规格型号")
|
||||||
|
@Excel(name = "退料规格型号")
|
||||||
private String modelName;
|
private String modelName;
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -50,15 +63,19 @@ public class ReturnOfMaterialsInfo {
|
||||||
private String maCode;
|
private String maCode;
|
||||||
|
|
||||||
@ApiModelProperty(value = "退料时间")
|
@ApiModelProperty(value = "退料时间")
|
||||||
|
@Excel(name = "退料时间")
|
||||||
private String returnTime;
|
private String returnTime;
|
||||||
|
|
||||||
@ApiModelProperty(value = "提交入库时间")
|
|
||||||
private String submitStorageTime;
|
|
||||||
|
|
||||||
@ApiModelProperty(value = "提交入库人员")
|
@ApiModelProperty(value = "提交入库人员")
|
||||||
|
@Excel(name = "提交入库人员")
|
||||||
private String submitToStoragePersonnel;
|
private String submitToStoragePersonnel;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "提交入库时间")
|
||||||
|
@Excel(name = "提交入库时间")
|
||||||
|
private String submitStorageTime;
|
||||||
|
|
||||||
@ApiModelProperty(value = "备注")
|
@ApiModelProperty(value = "备注")
|
||||||
|
@Excel(name = "备注")
|
||||||
private String remark;
|
private String remark;
|
||||||
|
|
||||||
@ApiModelProperty(value = "关键字")
|
@ApiModelProperty(value = "关键字")
|
||||||
|
|
|
||||||
|
|
@ -104,4 +104,13 @@ public interface RepairTestInputMapper {
|
||||||
void updateTmTaskStatus(@Param("params") RepairTestWarehousingDto dto, @Param("dictId") int dicId);
|
void updateTmTaskStatus(@Param("params") RepairTestWarehousingDto dto, @Param("dictId") int dicId);
|
||||||
|
|
||||||
int insertRepairInputDetails(RepairInputDetails repairTestWarehousingDto);
|
int insertRepairInputDetails(RepairInputDetails repairTestWarehousingDto);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param bean
|
||||||
|
* @return List<RepairTestInputDetailVo>
|
||||||
|
* @description 修试入库--导出
|
||||||
|
* @author hay
|
||||||
|
* @date 2024/1/9 15:14
|
||||||
|
*/
|
||||||
|
List<RepairTestInputDetailVo> exportList(RepairTestInputDto bean);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -16,4 +16,5 @@ public interface ReturnOfMaterialsInfoMapper {
|
||||||
List<ReturnOfMaterialsInfo> getReturnOfMaterialsInfoAll(ReturnOfMaterialsInfo bean);
|
List<ReturnOfMaterialsInfo> getReturnOfMaterialsInfoAll(ReturnOfMaterialsInfo bean);
|
||||||
|
|
||||||
List<ReturnOfMaterialsInfo> getTypeList(String level);
|
List<ReturnOfMaterialsInfo> getTypeList(String level);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -31,11 +31,20 @@ public interface RepairTestInputService {
|
||||||
List<RepairTestInputDetailVo> getRepairedDetailList(RepairTestInputDto dto);
|
List<RepairTestInputDetailVo> getRepairedDetailList(RepairTestInputDto dto);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param params
|
* @param dto
|
||||||
* @return AjaxResult
|
* @return AjaxResult
|
||||||
* @description 修试后入库-入库操作
|
* @description 修试后入库-入库操作
|
||||||
* @author cwchen
|
* @author cwchen
|
||||||
* @date 2023/12/16 18:35
|
* @date 2023/12/16 18:35
|
||||||
*/
|
*/
|
||||||
AjaxResult inputByType(RepairTestInputDto dto);
|
AjaxResult inputByType(RepairTestInputDto dto);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param bean
|
||||||
|
* @return List<RepairTestInputDetailVo>
|
||||||
|
* @description 修试入库-导出
|
||||||
|
* @author hay
|
||||||
|
* @date 2024/1/9 15:13
|
||||||
|
*/
|
||||||
|
List<RepairTestInputDetailVo> exportList(RepairTestInputDto bean);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,4 +13,9 @@ public interface ReturnOfMaterialsInfoService {
|
||||||
List<ReturnOfMaterialsInfo> getReturnOfMaterialsInfoAll(ReturnOfMaterialsInfo bean);
|
List<ReturnOfMaterialsInfo> getReturnOfMaterialsInfoAll(ReturnOfMaterialsInfo bean);
|
||||||
|
|
||||||
List<ReturnOfMaterialsInfo> getTypeList(String level);
|
List<ReturnOfMaterialsInfo> getTypeList(String level);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 退料入库导出
|
||||||
|
*/
|
||||||
|
List<ReturnOfMaterialsInfo> exportList(ReturnOfMaterialsInfo bean);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -109,6 +109,11 @@ public class RepairTestInputServiceImpl implements RepairTestInputService {
|
||||||
return AjaxResult.success();
|
return AjaxResult.success();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<RepairTestInputDetailVo> exportList(RepairTestInputDto bean) {
|
||||||
|
return mapper.exportList(bean);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param num
|
* @param num
|
||||||
* @param repairNum
|
* @param repairNum
|
||||||
|
|
|
||||||
|
|
@ -26,4 +26,9 @@ public class ReturnOfMaterialsInfoServiceImpl implements ReturnOfMaterialsInfoSe
|
||||||
public List<ReturnOfMaterialsInfo> getTypeList(String level) {
|
public List<ReturnOfMaterialsInfo> getTypeList(String level) {
|
||||||
return returnOfMaterialsInfoMapper.getTypeList(level);
|
return returnOfMaterialsInfoMapper.getTypeList(level);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<ReturnOfMaterialsInfo> exportList(ReturnOfMaterialsInfo bean) {
|
||||||
|
return returnOfMaterialsInfoMapper.getReturnOfMaterialsInfoAll(bean);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -164,6 +164,49 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
COUNT(*) AS totalNum
|
COUNT(*) AS totalNum
|
||||||
FROM repair_input_details WHERE task_id = #{taskId}
|
FROM repair_input_details WHERE task_id = #{taskId}
|
||||||
</select>
|
</select>
|
||||||
|
<select id="exportList" resultType="com.bonus.sgzb.material.domain.RepairTestInputDetailVo">
|
||||||
|
SELECT rid.id,
|
||||||
|
tt2.`code` as repairCode,
|
||||||
|
tt2.create_by as wxName,
|
||||||
|
tt2.create_time as wxTime,
|
||||||
|
rid.ma_id AS maId,
|
||||||
|
rid.type_id AS typeId,
|
||||||
|
a.typeName,
|
||||||
|
a.typeName2,
|
||||||
|
rid.repair_num AS repairNum,
|
||||||
|
a.manage_type AS manageType,
|
||||||
|
mm.ma_code AS maCode,
|
||||||
|
rid.update_by AS updateBy,
|
||||||
|
rid.update_time AS updateTime,
|
||||||
|
rid.remark,
|
||||||
|
CASE rid.`status` WHEN '0' THEN '进行中' WHEN '1' THEN '已入库' WHEN '2' THEN '驳回' ELSE '进行中' END AS `status`
|
||||||
|
FROM repair_input_details rid
|
||||||
|
LEFT JOIN tm_task tt2 ON rid.repair_id = tt2.task_id
|
||||||
|
LEFT JOIN ma_machine mm ON rid.ma_id = mm.ma_id
|
||||||
|
LEFT JOIN (
|
||||||
|
SELECT mt.type_id AS typeId,mt2.type_id AS typeId2,mt.type_name AS typeName,mt2.type_name AS
|
||||||
|
typeName2,mt.manage_type
|
||||||
|
FROM ma_type mt
|
||||||
|
LEFT JOIN ma_type mt2 ON mt2.type_id = mt.parent_id AND mt2.`level` = '3'
|
||||||
|
WHERE mt.`level` = '4'
|
||||||
|
)a ON rid.type_id = a.typeId
|
||||||
|
<where>
|
||||||
|
<if test="deviceTypeId!=null and deviceTypeId!=''">
|
||||||
|
INSTR(b.typeId2,#{deviceTypeId}) > 0
|
||||||
|
</if>
|
||||||
|
<if test="wxTime!=null and wxTime!=''">
|
||||||
|
AND b.wxTime BETWEEN CONCAT(#{wxTime},' 00:00:00') AND CONCAT(#{wxTime},' 23:59:59')
|
||||||
|
</if>
|
||||||
|
<if test="keyWord!=null and keyWord!=''">
|
||||||
|
AND (
|
||||||
|
INSTR(b.repairCode,#{keyWord}) > 0 OR
|
||||||
|
INSTR(b.wxName,#{keyWord}) > 0
|
||||||
|
)
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
ORDER BY rid.create_time DESC
|
||||||
|
|
||||||
|
</select>
|
||||||
|
|
||||||
<insert id="insertRepairInputDetails" parameterType="com.bonus.sgzb.material.domain.RepairInputDetails">
|
<insert id="insertRepairInputDetails" parameterType="com.bonus.sgzb.material.domain.RepairInputDetails">
|
||||||
insert into repair_input_details
|
insert into repair_input_details
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
iad.input_num as inputNum,mm.ma_code as maCode,
|
iad.input_num as inputNum,mm.ma_code as maCode,
|
||||||
tt.create_time as returnTime,
|
tt.create_time as returnTime,
|
||||||
iad.create_time as submitStorageTime,
|
iad.create_time as submitStorageTime,
|
||||||
iad.create_by as submitToStoragePersonnel,iad.remark as remark
|
us.user_name as submitToStoragePersonnel,iad.remark as remark
|
||||||
FROM input_apply_details iad
|
FROM input_apply_details iad
|
||||||
LEFT JOIN tm_task tt ON iad.task_id = tt.task_id
|
LEFT JOIN tm_task tt ON iad.task_id = tt.task_id
|
||||||
LEFT JOIN tm_task_agreement tta on tta.task_id = tt.task_id
|
LEFT JOIN tm_task_agreement tta on tta.task_id = tt.task_id
|
||||||
|
|
@ -21,9 +21,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
LEFT JOIN ma_type mt on mt.type_id = iad.type_id
|
LEFT JOIN ma_type mt on mt.type_id = iad.type_id
|
||||||
LEFT JOIN ma_type mt2 ON mt2.type_id = mt.parent_id AND mt2.`level` = '3'
|
LEFT JOIN ma_type mt2 ON mt2.type_id = mt.parent_id AND mt2.`level` = '3'
|
||||||
LEFT JOIN ma_type mt3 ON mt2.parent_id = mt3.type_id AND mt3.`level` = '2'
|
LEFT JOIN ma_type mt3 ON mt2.parent_id = mt3.type_id AND mt3.`level` = '2'
|
||||||
LEFT JOIN ma_type mt4 ON mt3.parent_id = mt4.type_id AND mt4.`level` = '1'
|
LEFT JOIN sys_user us on us.user_id=iad.create_by
|
||||||
LEFT JOIN ma_machine mm ON mm.ma_id = iad.ma_id
|
LEFT JOIN ma_machine mm ON mm.ma_id = iad.ma_id
|
||||||
WHERE tt.task_status = '38' and mt.`level` = '4' and input_type ='2'
|
WHERE tt.task_status = '40' and mt.`level` = '4' and input_type ='2'
|
||||||
<if test="keyWord != null and keyWord != ''">
|
<if test="keyWord != null and keyWord != ''">
|
||||||
and tt.`code` like concat('%', #{keyWord}, '%')
|
and tt.`code` like concat('%', #{keyWord}, '%')
|
||||||
</if>
|
</if>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue