维修提交至修饰后审核逻辑修改
This commit is contained in:
parent
592f55515b
commit
8cf748d179
|
|
@ -42,7 +42,7 @@ public class ScrapApplyDetailsController extends BaseController {
|
||||||
/**
|
/**
|
||||||
* 查询报废任务详细列表
|
* 查询报废任务详细列表
|
||||||
*/
|
*/
|
||||||
@ApiOperation(value = "查询报废任务详细列表")
|
@ApiOperation(value = "查询报废任务列表")
|
||||||
// @RequiresPermissions("scrap:details:list")
|
// @RequiresPermissions("scrap:details:list")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
public TableDataInfo list(ScrapApplyDetails scrapApplyDetails) {
|
public TableDataInfo list(ScrapApplyDetails scrapApplyDetails) {
|
||||||
|
|
@ -51,6 +51,16 @@ public class ScrapApplyDetailsController extends BaseController {
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询报废任务详细列表--根据任务ID
|
||||||
|
*/
|
||||||
|
@ApiOperation(value = "查询报废任务详情--TaskId")
|
||||||
|
@GetMapping("/selectRepairQuestListByTaskId")
|
||||||
|
public AjaxResult selectRepairQuestListByTaskId(ScrapApplyDetails scrapApplyDetails) {
|
||||||
|
List<ScrapApplyDetails> list = scrapApplyDetailsService.selectRepairQuestListByTaskId(scrapApplyDetails);
|
||||||
|
return success(list);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 导出报废任务详细列表
|
* 导出报废任务详细列表
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -30,18 +30,7 @@ public class ScrapApplyDetails extends BaseEntity {
|
||||||
@ApiModelProperty(value = "任务ID")
|
@ApiModelProperty(value = "任务ID")
|
||||||
private Long taskId;
|
private Long taskId;
|
||||||
|
|
||||||
@Excel(name = "任务编号")
|
@ApiModelProperty(value = "状态")
|
||||||
@ApiModelProperty(value = "任务编号")
|
|
||||||
private String taskCode;
|
|
||||||
|
|
||||||
@Excel(name = "任务状态编码")
|
|
||||||
@ApiModelProperty(value = "任务状态Code")
|
|
||||||
private Byte taskStatusCode;
|
|
||||||
|
|
||||||
@Excel(name = "任务状态名称")
|
|
||||||
@ApiModelProperty(value = "任务状态名称")
|
|
||||||
private String taskStatusName;
|
|
||||||
|
|
||||||
private String status;
|
private String status;
|
||||||
|
|
||||||
/** 上级ID */
|
/** 上级ID */
|
||||||
|
|
@ -59,6 +48,26 @@ public class ScrapApplyDetails extends BaseEntity {
|
||||||
@ApiModelProperty(value = "规格ID")
|
@ApiModelProperty(value = "规格ID")
|
||||||
private Long typeId;
|
private Long typeId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "规格型号名称")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "物资类型ID")
|
||||||
|
private Long typeNameId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "物资类型名称")
|
||||||
|
private String typeName;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "管理方式")
|
||||||
|
private Byte manageType;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "单位")
|
||||||
|
private String unitName;
|
||||||
|
|
||||||
|
private String code;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "维修单号")
|
||||||
|
private String repairCode;
|
||||||
|
|
||||||
/** 报废数量 */
|
/** 报废数量 */
|
||||||
@Excel(name = "报废数量")
|
@Excel(name = "报废数量")
|
||||||
@ApiModelProperty(value = "报废数量")
|
@ApiModelProperty(value = "报废数量")
|
||||||
|
|
@ -70,12 +79,14 @@ public class ScrapApplyDetails extends BaseEntity {
|
||||||
private String scrapSource;
|
private String scrapSource;
|
||||||
|
|
||||||
/** (0自然,1人为) */
|
/** (0自然,1人为) */
|
||||||
@Excel(name = "", readConverterExp = "0=自然,1人为")
|
@Excel(name = "报废类型", readConverterExp = "0=自然,1人为")
|
||||||
private String scrapType;
|
private String scrapType;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "报废人")
|
||||||
|
private String scraper;
|
||||||
|
|
||||||
/** 审核人 */
|
/** 审核人 */
|
||||||
@Excel(name = "审核人")
|
@ApiModelProperty(value = "审核人id")
|
||||||
@ApiModelProperty(value = "审核人")
|
|
||||||
private Long auditBy;
|
private Long auditBy;
|
||||||
|
|
||||||
/** 审核时间 */
|
/** 审核时间 */
|
||||||
|
|
|
||||||
|
|
@ -25,6 +25,8 @@ public class ScrapTaskListVo {
|
||||||
@ApiModelProperty(value = "报废单号")
|
@ApiModelProperty(value = "报废单号")
|
||||||
private String scrapCode;
|
private String scrapCode;
|
||||||
|
|
||||||
|
private String repairCode;
|
||||||
|
|
||||||
@ApiModelProperty(value = "组织id")
|
@ApiModelProperty(value = "组织id")
|
||||||
private Long companyId;
|
private Long companyId;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -22,6 +22,8 @@ public interface ScrapApplyDetailsMapper {
|
||||||
*/
|
*/
|
||||||
public ScrapApplyDetails selectScrapApplyDetailsById(Long id);
|
public ScrapApplyDetails selectScrapApplyDetailsById(Long id);
|
||||||
|
|
||||||
|
List<ScrapApplyDetails> selectRepairQuestListByTaskId(ScrapApplyDetails scrapApplyDetails);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询报废任务详细列表
|
* 查询报废任务详细列表
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,16 @@ public interface IScrapApplyDetailsService {
|
||||||
* @param scrapApplyDetails 报废任务详细
|
* @param scrapApplyDetails 报废任务详细
|
||||||
* @return 报废任务详细集合
|
* @return 报废任务详细集合
|
||||||
*/
|
*/
|
||||||
public List<ScrapTaskListVo> selectScrapApplyDetailsList(ScrapApplyDetails scrapApplyDetails);
|
List<ScrapTaskListVo> selectScrapApplyDetailsList(ScrapApplyDetails scrapApplyDetails);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询报废任务详细列表
|
||||||
|
*
|
||||||
|
* @param scrapApplyDetails 报废任务详细
|
||||||
|
* @return 报废任务详细集合
|
||||||
|
*/
|
||||||
|
List<ScrapApplyDetails> selectRepairQuestListByTaskId(ScrapApplyDetails scrapApplyDetails);
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增报废任务详细
|
* 新增报废任务详细
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
package com.bonus.material.scrap.service.impl;
|
package com.bonus.material.scrap.service.impl;
|
||||||
|
|
||||||
|
import java.util.Collections;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import com.bonus.common.core.exception.ServiceException;
|
import com.bonus.common.core.exception.ServiceException;
|
||||||
import com.bonus.common.core.utils.DateUtils;
|
import com.bonus.common.core.utils.DateUtils;
|
||||||
|
|
@ -43,6 +44,17 @@ public class ScrapApplyDetailsServiceImpl implements IScrapApplyDetailsService {
|
||||||
return scrapApplyDetailsMapper.selectScrapApplyDetailsList(scrapApplyDetails);
|
return scrapApplyDetailsMapper.selectScrapApplyDetailsList(scrapApplyDetails);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询报废任务详细列表
|
||||||
|
*
|
||||||
|
* @param scrapApplyDetails 报废任务详细
|
||||||
|
* @return 报废任务详细集合
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<ScrapApplyDetails> selectRepairQuestListByTaskId(ScrapApplyDetails scrapApplyDetails) {
|
||||||
|
return scrapApplyDetailsMapper.selectRepairQuestListByTaskId(scrapApplyDetails);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增报废任务详细
|
* 新增报废任务详细
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -124,6 +124,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
rad.ma_id as maId,
|
rad.ma_id as maId,
|
||||||
rad.type_id as typeId,
|
rad.type_id as typeId,
|
||||||
rad.repair_num as repairNum,
|
rad.repair_num as repairNum,
|
||||||
|
rad.this_repaired_num,rad.this_scrap_num,
|
||||||
rad.repaired_num as repairedNum,
|
rad.repaired_num as repairedNum,
|
||||||
rad.this_repaired_num as thisRepairedNum,
|
rad.this_repaired_num as thisRepairedNum,
|
||||||
rad.scrap_num as scrapNum,
|
rad.scrap_num as scrapNum,
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<select id="selectScrapApplyDetailsList" parameterType="com.bonus.material.scrap.domain.ScrapApplyDetails" resultType="com.bonus.material.scrap.domain.vo.ScrapTaskListVo">
|
<select id="selectScrapApplyDetailsList" parameterType="com.bonus.material.scrap.domain.ScrapApplyDetails" resultType="com.bonus.material.scrap.domain.vo.ScrapTaskListVo">
|
||||||
SELECT
|
SELECT
|
||||||
sad.task_id, sad.create_by, sad.create_time,sad.update_time,sad.company_id,
|
sad.task_id, sad.create_by, sad.create_time,sad.update_time,sad.company_id,
|
||||||
tt.`code` AS scrapCode,tt.task_status AS taskStatus,tt.task_type as taskType,tt.company_id AS companyId,tt.remark,
|
tt.`code` AS scrapCode, tt2.`code` as repairCode ,tt.task_status AS taskStatus,tt.task_type as taskType,tt.company_id AS companyId,tt.remark,
|
||||||
bui.unit_name AS backUnit,
|
bui.unit_name AS backUnit,
|
||||||
bpi.pro_name AS backPro,
|
bpi.pro_name AS backPro,
|
||||||
su.nick_name AS createName,
|
su.nick_name AS createName,
|
||||||
|
|
@ -50,6 +50,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
LEFT JOIN bm_unit bui ON bai2.unit_id = bui.unit_id
|
LEFT JOIN bm_unit bui ON bai2.unit_id = bui.unit_id
|
||||||
LEFT JOIN bm_project bpi ON bai2.project_id = bpi.pro_id and bpi.del_flag = '0'
|
LEFT JOIN bm_project bpi ON bai2.project_id = bpi.pro_id and bpi.del_flag = '0'
|
||||||
left join sys_user su on sad.create_by = su.user_id
|
left join sys_user su on sad.create_by = su.user_id
|
||||||
|
left join repair_audit_details rad ON sad.parent_id = rad.id
|
||||||
|
left join tm_task tt2 ON tt2.task_id = rad.task_id
|
||||||
<!-- <where> -->
|
<!-- <where> -->
|
||||||
<!-- <if test="taskId != null "> and task_id = #{taskId}</if>-->
|
<!-- <if test="taskId != null "> and task_id = #{taskId}</if>-->
|
||||||
<!-- <if test="parentId != null "> and parent_id = #{parentId}</if>-->
|
<!-- <if test="parentId != null "> and parent_id = #{parentId}</if>-->
|
||||||
|
|
@ -69,6 +71,34 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
GROUP BY sad.task_id,bui.unit_name,bpi.pro_name,su.nick_name
|
GROUP BY sad.task_id,bui.unit_name,bpi.pro_name,su.nick_name
|
||||||
order by tt.create_time desc
|
order by tt.create_time desc
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<select id="selectRepairQuestListByTaskId" resultType="com.bonus.material.scrap.domain.ScrapApplyDetails">
|
||||||
|
select
|
||||||
|
sad.id as id,sad.task_id as taskId,sad.parent_id,sad.ma_id as maId,
|
||||||
|
sad.scrap_source,sad.scrap_type,
|
||||||
|
sad.status as status,ifnull(sad.scrap_num,0) as scrapNum,
|
||||||
|
sad.audit_by,sad.audit_remark,sad.audit_time,
|
||||||
|
sad.update_time as updateTime,sad.type_id as typeId,
|
||||||
|
sad.create_by,sad.create_time,sad.file_name,sad.file_url,
|
||||||
|
mt2.type_name as typeName,mt2.type_id as typeNameId,
|
||||||
|
mt.type_name as type,mt.unit_name as unitName,mt.manage_type as manageType,
|
||||||
|
mm.ma_code as code,
|
||||||
|
su.nick_name as scraper
|
||||||
|
from
|
||||||
|
scrap_apply_details sad
|
||||||
|
left join ma_type mt on sad.type_id = mt.type_id
|
||||||
|
left join ma_machine mm on mm.ma_id = sad.ma_id
|
||||||
|
left join sys_user su on sad.create_by = su.user_id
|
||||||
|
left join ma_type mt2 on mt.parent_id = mt2.type_id
|
||||||
|
|
||||||
|
where
|
||||||
|
sad.task_id = #{taskId}
|
||||||
|
|
||||||
|
GROUP BY sad.id
|
||||||
|
order by sad.create_time desc
|
||||||
|
</select>
|
||||||
|
|
||||||
<select id="selectScrapApplyDetailsById" parameterType="Long" resultMap="ScrapApplyDetailsResult">
|
<select id="selectScrapApplyDetailsById" parameterType="Long" resultMap="ScrapApplyDetailsResult">
|
||||||
<include refid="selectScrapApplyDetailsVo"/>
|
<include refid="selectScrapApplyDetailsVo"/>
|
||||||
|
|
@ -184,4 +214,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</if>
|
</if>
|
||||||
group by scrap_type
|
group by scrap_type
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
Loading…
Reference in New Issue