修饰审核--查询字段、SQL调整

This commit is contained in:
syruan 2024-11-14 14:31:46 +08:00
parent 2e78385163
commit 651b9df2ab
3 changed files with 22 additions and 12 deletions

View File

@ -55,15 +55,14 @@ public class RepairAuditDetailsController extends BaseController {
@RequiresPermissions("service:auditing:list")
public TableDataInfo questList(RepairAuditDetails repairAuditDetails) {
startPage();
// Map<String, Object> params = repairAuditDetails.getParams();
Map<String, Object> params = new HashMap<>();
// if (params != null && !params.isEmpty()) {
// String beginTime = (String) params.get("beginTime");
// String endTime = (String) params.get("endTime");
// params.put("beginTime", beginTime + " 00:00:00");
// params.put("endTime", endTime + " 23:59:59");
// repairAuditDetails.setParams(params);
// }
Map<String, Object> params = repairAuditDetails.getParams();
if (params != null && !params.isEmpty()) {
String beginTime = (String) params.get("beginTime");
String endTime = (String) params.get("endTime");
params.put("beginTime", beginTime + " 00:00:00");
params.put("endTime", endTime + " 23:59:59");
repairAuditDetails.setParams(params);
}
List<ScrapApplyDetailsVO> list = repairAuditDetailsService.selectRepairQuestList(repairAuditDetails);
return getDataTable(list);
}

View File

@ -85,7 +85,18 @@ public class RepairAuditDetails extends BaseEntity {
@ApiModelProperty(value = "数据所属组织")
private Integer companyId;
/** 关键字 */
/**传入参数*/
@ApiModelProperty(value = "单位id")
private Integer backUnit;
@ApiModelProperty(value = "工程id")
private Integer backPro;
@ApiModelProperty(value = "工机具类型id")
private Integer type;
@ApiModelProperty(value = "维修单号")
private String backCode;
@ApiModelProperty(value = "关键字")
private String keyword;
@ApiModelProperty(value = "规格型号")
private String typeName;
}

View File

@ -284,7 +284,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
AND (locate(#{keyword}, su.nick_name) > 0
or locate(#{keyword}, tk.CODE) > 0
or locate(#{keyword}, bui.unit_name) > 0
or locate(#{keyword}, bpl.lot_name) > 0)
or locate(#{keyword}, bpl.pro_name) > 0)
</if>
<if test="backUnit != null and backUnit != ''">
and bui.unit_id = #{backUnit}
@ -293,7 +293,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
and tk.task_status = #{taskStatus}
</if>
<if test="backPro != null and backPro != ''">
and bpl.lot_id = #{backPro}
and bpl.pro_id = #{backPro}
</if>
<if test="type != null and type != ''">
and mt1.type_id = #{type}