This commit is contained in:
mashuai 2025-08-21 20:04:14 +08:00
parent 40bac3228a
commit 06fb0a60d1
12 changed files with 115 additions and 63 deletions

View File

@ -176,6 +176,9 @@ public class BackApplyInfo implements Serializable {
@ApiModelProperty(value="二维码") @ApiModelProperty(value="二维码")
private String qrCode; private String qrCode;
@ApiModelProperty(value = "审批人签名类型 手写0 和 图片上传1")
private int directAuditSignType;
@ApiModelProperty(value = "审批人人签名URL") @ApiModelProperty(value = "审批人人签名URL")
private String directAuditSignUrl; private String directAuditSignUrl;
@ -212,4 +215,10 @@ public class BackApplyInfo implements Serializable {
@ApiModelProperty(value = "退料方式1 直退2 数据同步)") @ApiModelProperty(value = "退料方式1 直退2 数据同步)")
private String backStyle; private String backStyle;
@ApiModelProperty(value = "制单人签名地址")
private String signUrl;
@ApiModelProperty(value = "制单人签名类型 手写0 和 图片上传1")
private int signType;
} }

View File

@ -334,7 +334,7 @@ public interface BackApplyInfoMapper {
Long getDirectAuditBy(); Long getDirectAuditBy();
/** 设置审批人签名url 防止代码冲突 **/ /** 设置审批人签名url 防止代码冲突 **/
String getDirectAuditUrl(BackApplyInfo backApplyInfo); BackApplyInfo getDirectAuditUrl(BackApplyInfo backApplyInfo);
/** /**
* 根据任务id查询是否有签名 * 根据任务id查询是否有签名

View File

@ -113,15 +113,31 @@ public class BackApplyInfoServiceImpl implements IBackApplyInfoService {
backApplyInfo.setUserId(userId == 0 ? null : userId); backApplyInfo.setUserId(userId == 0 ? null : userId);
} }
/** 设置审批人签名url 防止代码冲突 **/ // 设置审批人签名url,目前固定查询夏成刚签名信息
String directAuditUrl = backApplyInfoMapper.getDirectAuditUrl(backApplyInfo); BackApplyInfo info = backApplyInfoMapper.getDirectAuditUrl(backApplyInfo);
backApplyInfo.setDirectAuditSignUrl(directAuditUrl); if (info != null && StringUtils.isNotBlank(info.getDirectAuditSignUrl())) {
/** 设置审批人签名url 防止代码冲突 **/ backApplyInfo.setDirectAuditSignType(info.getDirectAuditSignType());
if (!info.getDirectAuditSignUrl().startsWith("http")) {
backApplyInfo.setDirectAuditSignUrl("data:image/png;base64," + info.getDirectAuditSignUrl());
} else {
backApplyInfo.setDirectAuditSignUrl(info.getDirectAuditSignUrl());
}
}
// 设置退料人签名url
if (StringUtils.isNotBlank(backApplyInfo.getBackSignUrl())) { if (StringUtils.isNotBlank(backApplyInfo.getBackSignUrl())) {
if (!backApplyInfo.getBackSignUrl().startsWith("http")) { if (!backApplyInfo.getBackSignUrl().startsWith("http")) {
backApplyInfo.setBackSignUrl("data:image/png;base64," + backApplyInfo.getBackSignUrl()); backApplyInfo.setBackSignUrl("data:image/png;base64," + backApplyInfo.getBackSignUrl());
} }
} }
// 设置制单人签名url
if (StringUtils.isNotBlank(backApplyInfo.getSignUrl())) {
if (!backApplyInfo.getSignUrl().startsWith("http")) {
backApplyInfo.setSignUrl("data:image/png;base64," + backApplyInfo.getBackSignUrl());
}
}
backApplyRequestVo.setBackApplyInfo(backApplyInfo); backApplyRequestVo.setBackApplyInfo(backApplyInfo);
//查询退料详情信息 //查询退料详情信息
@ -583,7 +599,7 @@ public class BackApplyInfoServiceImpl implements IBackApplyInfoService {
tmTask.setCreateBy(SecurityUtils.getLoginUser().getSysUser().getNickName()); tmTask.setCreateBy(SecurityUtils.getLoginUser().getSysUser().getNickName());
BackApplyInfo backApplyInfo = dto.getBackApplyInfo(); BackApplyInfo backApplyInfo = dto.getBackApplyInfo();
backApplyInfo.setCode(code); backApplyInfo.setCode(code);
backApplyInfo.setCreateBy(SecurityUtils.getLoginUser().getSysUser().getNickName()); backApplyInfo.setCreateBy(SecurityUtils.getLoginUser().getUserid().toString());
backApplyInfo.setCreateTime(DateUtils.getNowDate()); backApplyInfo.setCreateTime(DateUtils.getNowDate());
// 保存退料信息到 tm_task 表中 // 保存退料信息到 tm_task 表中
result += taskMapper.insertTmTask(tmTask); result += taskMapper.insertTmTask(tmTask);

View File

@ -63,6 +63,18 @@ public class LeaseApplyInfoController extends BaseController {
return AjaxResult.success(ListPagingUtil.paging(pageIndex, pageSize, list)); return AjaxResult.success(ListPagingUtil.paging(pageIndex, pageSize, list));
} }
/**
* 统计时间段出库总数量
* @param leaseApplyInfo
* @return
*/
@ApiOperation(value = "统计时间段出库总数量")
@GetMapping("/getOutNum")
public AjaxResult getOutNum(LeaseApplyInfo leaseApplyInfo) {
LeaseApplyInfo info = leaseApplyInfoService.getOutNum(leaseApplyInfo);
return AjaxResult.success(info);
}
/** /**
* 查询已完成出库的任务 * 查询已完成出库的任务
*/ */

View File

@ -202,4 +202,11 @@ public interface LeaseApplyInfoMapper {
LeaseApplyInfo getUserPhoneById(LeaseApplyInfo item); LeaseApplyInfo getUserPhoneById(LeaseApplyInfo item);
LeaseApplyInfo getOutList(LeaseApplyInfo applyInfo); LeaseApplyInfo getOutList(LeaseApplyInfo applyInfo);
/**
* 统计时间段出库总数量
* @param leaseApplyInfo
* @return
*/
LeaseApplyInfo getOutNum(LeaseApplyInfo leaseApplyInfo);
} }

View File

@ -178,4 +178,11 @@ public interface ILeaseApplyInfoService {
LeaseApplyRequestVo getLeaseRequestVo(LeaseApplyDetails bean); LeaseApplyRequestVo getLeaseRequestVo(LeaseApplyDetails bean);
List<LeaseApplyInfo> getConfirmTaskList(LeaseApplyInfo leaseApplyInfo); List<LeaseApplyInfo> getConfirmTaskList(LeaseApplyInfo leaseApplyInfo);
/**
* 统计时间段出库总数量
* @param leaseApplyInfo
* @return
*/
LeaseApplyInfo getOutNum(LeaseApplyInfo leaseApplyInfo);
} }

View File

@ -725,6 +725,8 @@ public class LeaseApplyInfoServiceImpl implements ILeaseApplyInfoService {
List<LeaseApplyInfo> leaseApplyOutList = leaseApplyInfoMapper.selectPublish(leaseApplyInfo); List<LeaseApplyInfo> leaseApplyOutList = leaseApplyInfoMapper.selectPublish(leaseApplyInfo);
if (!CollectionUtils.isEmpty(leaseApplyOutList)) { if (!CollectionUtils.isEmpty(leaseApplyOutList)) {
list.addAll(leaseApplyOutList); list.addAll(leaseApplyOutList);
}
if (!CollectionUtils.isEmpty(list)) {
for (LeaseApplyInfo applyInfo : list) { for (LeaseApplyInfo applyInfo : list) {
// 根据id去查询出库数量 // 根据id去查询出库数量
LeaseApplyInfo outList = leaseApplyInfoMapper.getOutList(applyInfo); LeaseApplyInfo outList = leaseApplyInfoMapper.getOutList(applyInfo);
@ -767,38 +769,20 @@ public class LeaseApplyInfoServiceImpl implements ILeaseApplyInfoService {
.filter(item -> containsKeyword(item, keyWord)) .filter(item -> containsKeyword(item, keyWord))
.collect(Collectors.toList()); .collect(Collectors.toList());
} }
// // 判断状态
// if (!CollectionUtils.isEmpty(leaseApplyInfo.getStatusList())) {
// // 将集合sortedList中状态taskStatus包含在leaseApplyInfo.getStatusList()中的元素
// sortedList = sortedList.stream()
// .filter(item -> leaseApplyInfo.getStatusList().contains(item.getTaskStatus()))
// .collect(Collectors.toList());
// }
} }
sortedList.removeIf(Objects::isNull);
if (leaseApplyInfo.getIsConfirm() != null) {
if (leaseApplyInfo.getIsConfirm() == 1) {
for (LeaseApplyInfo item : sortedList) {
if(item.getPreCountNum().compareTo(item.getAlNum()) != 0){
item.setIsConfirm(1);
}else{
//查找签名的数量之和是否为
}
}
// sortedList.removeIf(item -> item.getIsConfirm() != null && item.getIsConfirm() == 2);
} else if (leaseApplyInfo.getIsConfirm() == 2) {
sortedList.removeIf(item -> item.getIsConfirm() == null || item.getIsConfirm() != 2);
}
}
// 再次移除可能的null值
sortedList.removeIf(Objects::isNull);
// 只有出库完成的任务才需要进行确认这里过滤掉任务状态不等于4出库已完成
// sortedList.removeIf(item -> item.getTaskStatus() != 4);
return sortedList; return sortedList;
} }
/**
* 统计时间段出库总数量
* @param leaseApplyInfo
* @return
*/
@Override
public LeaseApplyInfo getOutNum(LeaseApplyInfo leaseApplyInfo) {
return leaseApplyInfoMapper.getOutNum(leaseApplyInfo);
}
/** /**
* 关键字搜索 * 关键字搜索

View File

@ -72,7 +72,7 @@ public class PurchaseBindController extends BaseController {
*/ */
@ApiOperation(value = "编码绑定") @ApiOperation(value = "编码绑定")
@PreventRepeatSubmit @PreventRepeatSubmit
@RequiresPermissions("purchase:bind:add") //@RequiresPermissions("purchase:bind:add")
@PostMapping("/bind") @PostMapping("/bind")
public AjaxResult bind(@RequestBody @NotNull(message = "参数不能为空") PurchaseDto dto) { public AjaxResult bind(@RequestBody @NotNull(message = "参数不能为空") PurchaseDto dto) {
return purchaseBindService.bind(dto); return purchaseBindService.bind(dto);
@ -120,7 +120,7 @@ public class PurchaseBindController extends BaseController {
@ApiOperation(value = "二维码生成下载") @ApiOperation(value = "二维码生成下载")
@PostMapping(value = "/downloadQrCode") @PostMapping(value = "/downloadQrCode")
@PreventRepeatSubmit @PreventRepeatSubmit
@RequiresPermissions("purchase:bind:download") //@RequiresPermissions("purchase:bind:download")
public void downloadQrCode(HttpServletResponse response, PurchaseDto purchaseDto) { public void downloadQrCode(HttpServletResponse response, PurchaseDto purchaseDto) {
purchaseBindService.downloadQrCode(response, purchaseDto); purchaseBindService.downloadQrCode(response, purchaseDto);
} }
@ -132,7 +132,7 @@ public class PurchaseBindController extends BaseController {
*/ */
@ApiOperation(value = "驳回或批量驳回操作") @ApiOperation(value = "驳回或批量驳回操作")
@PreventRepeatSubmit @PreventRepeatSubmit
@RequiresPermissions("purchase:bind:reject") //@RequiresPermissions("purchase:bind:reject")
@PostMapping("/reject") @PostMapping("/reject")
public AjaxResult reject(@RequestBody @NotNull(message = "参数不能为空") PurchaseDto dto) { public AjaxResult reject(@RequestBody @NotNull(message = "参数不能为空") PurchaseDto dto) {
return purchaseBindService.reject(dto); return purchaseBindService.reject(dto);
@ -143,7 +143,7 @@ public class PurchaseBindController extends BaseController {
*/ */
@ApiOperation(value = "导出新购验收绑定详细列表") @ApiOperation(value = "导出新购验收绑定详细列表")
@PreventRepeatSubmit @PreventRepeatSubmit
@RequiresPermissions("purchase:bind:export") //@RequiresPermissions("purchase:bind:export")
@SysLog(title = "新购验收绑定任务", businessType = OperaType.EXPORT, module = "仓储管理->导出新购验收绑定任务") @SysLog(title = "新购验收绑定任务", businessType = OperaType.EXPORT, module = "仓储管理->导出新购验收绑定任务")
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, PurchaseDto dto) { public void export(HttpServletResponse response, PurchaseDto dto) {

View File

@ -181,11 +181,6 @@ public class RepairServiceImpl implements RepairService {
List<RepairDeviceSummaryVo> repairDeviceSummaryVoList = new ArrayList<>(); List<RepairDeviceSummaryVo> repairDeviceSummaryVoList = new ArrayList<>();
List<RepairDeviceVO> repairDeviceList = repairMapper.getRepairDeviceList(bean); List<RepairDeviceVO> repairDeviceList = repairMapper.getRepairDeviceList(bean);
if (CollectionUtil.isNotEmpty(repairDeviceList)) { if (CollectionUtil.isNotEmpty(repairDeviceList)) {
for (RepairDeviceVO repairDeviceVO : repairDeviceList) {
// 获取待修数量
repairDeviceVO.setWaitRepairNum(repairDeviceVO.getRepairNum().subtract(repairDeviceVO.getRepairedNum()
.subtract(repairDeviceVO.getScrapNum())));
}
if (CollectionUtil.isNotEmpty(typeIdList)) { if (CollectionUtil.isNotEmpty(typeIdList)) {
repairDeviceList = repairDeviceList.stream() repairDeviceList = repairDeviceList.stream()
.filter(item -> typeIdList.contains(item.getFirstId())) .filter(item -> typeIdList.contains(item.getFirstId()))
@ -216,7 +211,7 @@ public class RepairServiceImpl implements RepairService {
.filter(Objects::nonNull) .filter(Objects::nonNull)
.map(status -> "1".equals(status) ? 1 : 0) // 安全转换 .map(status -> "1".equals(status) ? 1 : 0) // 安全转换
.reduce(0, Integer::sum); .reduce(0, Integer::sum);
BigDecimal waitRepairNum = repairNumSum.subtract(repairedNumSum).subtract(scrapNumSum);
BigDecimal typeCostSum = tempList.stream().map(RepairDeviceVO::getTotalCost).reduce(BigDecimal.ZERO, BigDecimal::add); BigDecimal typeCostSum = tempList.stream().map(RepairDeviceVO::getTotalCost).reduce(BigDecimal.ZERO, BigDecimal::add);
vo.setRepairDeviceList(tempList) vo.setRepairDeviceList(tempList)
.setIds(ids).setTypeRepairNum(repairNumSum).setTypeRepairedNum(repairedNumSum) .setIds(ids).setTypeRepairNum(repairNumSum).setTypeRepairedNum(repairedNumSum)
@ -226,7 +221,7 @@ public class RepairServiceImpl implements RepairService {
.setUnitName(tempList.get(0).getUnitName()).setManageType(tempList.get(0).getManageType()) .setUnitName(tempList.get(0).getUnitName()).setManageType(tempList.get(0).getManageType())
.setDataStatusNum(dataStatusSum) .setDataStatusNum(dataStatusSum)
.setUnitValue(tempList.get(0).getUnitValue()) .setUnitValue(tempList.get(0).getUnitValue())
.setWaitRepairNum(tempList.get(0).getWaitRepairNum()) .setWaitRepairNum(waitRepairNum)
.setTypeCost(typeCostSum); .setTypeCost(typeCostSum);
repairDeviceSummaryVoList.add(vo); repairDeviceSummaryVoList.add(vo);
} }

View File

@ -8,6 +8,7 @@ import com.bonus.common.biz.constant.BmConfigItems;
import com.bonus.common.core.utils.StringUtils; import com.bonus.common.core.utils.StringUtils;
import com.bonus.common.core.utils.sms.SmsUtils; import com.bonus.common.core.utils.sms.SmsUtils;
import com.bonus.material.back.domain.BackApplyInfo; import com.bonus.material.back.domain.BackApplyInfo;
import com.bonus.material.back.mapper.BackApplyInfoMapper;
import com.bonus.material.back.service.IBackApplyInfoService; import com.bonus.material.back.service.IBackApplyInfoService;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.config.ScheduledTaskRegistrar; import org.springframework.scheduling.config.ScheduledTaskRegistrar;
@ -31,7 +32,7 @@ public class ScheduledTasks {
private static final DateTimeFormatter FORMATTER = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"); private static final DateTimeFormatter FORMATTER = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
@Resource @Resource
private IBackApplyInfoService backApplyInfoService; private BackApplyInfoMapper backApplyInfoMapper;
@Resource @Resource
private ScheduledTaskRegistrar scheduledTaskRegistrar; private ScheduledTaskRegistrar scheduledTaskRegistrar;
@ -76,8 +77,7 @@ public class ScheduledTasks {
public void taskWithFixedRate() { public void taskWithFixedRate() {
log.info("开始执行退料人未签字任务"); log.info("开始执行退料人未签字任务");
BackApplyInfo info = new BackApplyInfo(); BackApplyInfo info = new BackApplyInfo();
info.setIsExport(false); List<BackApplyInfo> list = backApplyInfoMapper.selectBackApplyInfoList(info);
List<BackApplyInfo> list = backApplyInfoService.selectBackApplyInfoList(info);
// 用于标记是否有 BackSignUrl null 的记录 // 用于标记是否有 BackSignUrl null 的记录
boolean hasNullBackSignUrl = false; boolean hasNullBackSignUrl = false;
if (CollectionUtils.isNotEmpty(list)) { if (CollectionUtils.isNotEmpty(list)) {

View File

@ -41,7 +41,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
bu.unit_name as unitName, bu.unit_name as unitName,
bai.back_time as backTime, bai.back_time as backTime,
tt.task_status as taskStatus, tt.task_status as taskStatus,
bai.create_by as createBy, CASE
WHEN bai.create_by REGEXP '^[0-9]+$' THEN su1.nick_name -- 如果是纯数字,使用昵称
ELSE bai.create_by -- 否则直接使用create_by的值
END AS createBy,
bai.create_time as createTime, bai.create_time as createTime,
bai.back_sign_url as backSignUrl, bai.back_sign_url as backSignUrl,
bai.back_sign_type as backSignType, bai.back_sign_type as backSignType,
@ -72,6 +75,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join ma_type mt3 ON mt2.parent_id = mt3.type_id and mt3.del_flag = '0' left join ma_type mt3 ON mt2.parent_id = mt3.type_id and mt3.del_flag = '0'
left join ma_type mt4 ON mt3.parent_id = mt4.type_id and mt4.del_flag = '0' left join ma_type mt4 ON mt3.parent_id = mt4.type_id and mt4.del_flag = '0'
left join sys_user su on su.user_id = bai.material_man left join sys_user su on su.user_id = bai.material_man
left join sys_user su1 on su1.user_id = bai.create_by
<if test="userId != null"> <if test="userId != null">
JOIN ma_type_repair mtr ON mtr.type_id = bad.type_id AND mtr.user_id = #{userId} JOIN ma_type_repair mtr ON mtr.type_id = bad.type_id AND mtr.user_id = #{userId}
</if> </if>
@ -157,7 +161,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
bai.task_id AS taskId, bai.task_id AS taskId,
bai.back_person AS backPerson, bai.back_person AS backPerson,
bai.phone AS phone, bai.phone AS phone,
bai.create_by AS createBy, CASE
WHEN bai.create_by REGEXP '^[0-9]+$' THEN su.nick_name -- 如果是纯数字,使用昵称
ELSE bai.create_by -- 否则直接使用create_by的值
END AS createBy,
bai.create_time AS createTime, bai.create_time AS createTime,
bai.update_by AS updateBy, bai.update_by AS updateBy,
bai.update_time AS updateTime, bai.update_time AS updateTime,
@ -171,7 +178,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
bp.pro_name AS proName, bp.pro_name AS proName,
bai.direct_audit_by AS directAuditBy, bai.direct_audit_by AS directAuditBy,
bai.back_sign_url AS backSignUrl, bai.back_sign_url AS backSignUrl,
bai.back_sign_type AS backSignType bai.back_sign_type AS backSignType,
su.sign_type AS signType,
su.sign_url AS signUrl
FROM FROM
back_apply_info bai back_apply_info bai
LEFT JOIN tm_task_agreement tta ON bai.task_id = tta.task_id LEFT JOIN tm_task_agreement tta ON bai.task_id = tta.task_id
@ -181,6 +190,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
AND bu.del_flag = '0' AND bu.del_flag = '0'
LEFT JOIN bm_project bp ON ba.project_id = bp.pro_id LEFT JOIN bm_project bp ON ba.project_id = bp.pro_id
AND bp.del_flag = '0' AND bp.del_flag = '0'
LEFT JOIN sys_user su ON su.user_id = bai.create_by
WHERE WHERE
bai.id = #{id} bai.id = #{id}
</select> </select>
@ -853,13 +863,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where sc.process_id = 1 and sc.sign_type = 0 and sc.del_flag = 0 where sc.process_id = 1 and sc.sign_type = 0 and sc.del_flag = 0
</select> </select>
<!-- 设置审批人签名url 防止代码冲突-->
<select id="getDirectAuditUrl" resultType="java.lang.String">
select
su.sign_url as directAuditSignUrl
from sys_user su
where su.user_id = #{directAuditBy} and su.del_flag = 0
</select>
<select id="selectSignByTaskId" resultType="com.bonus.material.back.domain.BackApplyInfo"> <select id="selectSignByTaskId" resultType="com.bonus.material.back.domain.BackApplyInfo">
SELECT SELECT
bai.`code`, bai.`code`,
@ -1547,4 +1550,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
AND ma_id = #{maId} AND ma_id = #{maId}
order by start_time asc order by start_time asc
</select> </select>
<select id="getDirectAuditUrl" resultType="com.bonus.material.back.domain.BackApplyInfo">
select
su.sign_type as directAuditSignType,
su.sign_url as directAuditSignUrl
from sys_user su
where su.user_id = 474 and su.del_flag = 0
</select>
</mapper> </mapper>

View File

@ -49,7 +49,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
lai.company_audit_time, lai.company_audit_remark, lai.dept_audit_by, lai.dept_audit_time, lai.company_audit_time, lai.company_audit_remark, lai.dept_audit_by, lai.dept_audit_time,
lai.dept_audit_remark, lai.direct_audit_by, lai.direct_audit_time, lai.direct_audit_remark, lai.dept_audit_remark, lai.direct_audit_by, lai.direct_audit_time, lai.direct_audit_remark,
lai.create_by, lai.create_time, lai.update_by, lai.update_time, lai.remark, lai.company_id, lai.create_by, lai.create_time, lai.update_by, lai.update_time, lai.remark, lai.company_id,
lai.direct_id, lai.lease_type, lai.estimate_lease_time, lai.cost_bearing_party, lai.lease_sign_url, lai.lease_sign_type, lai.direct_id, lai.lease_type, lai.estimate_lease_time, lai.cost_bearing_party,
lai.material_man, lai.confirm_time, lai.is_confirm, lai.confirm_remark, lai.material_man, lai.confirm_time, lai.is_confirm, lai.confirm_remark,
bai.unit_id,bai.project_id,bu.unit_name, bp.pro_name, bai.agreement_code, tt.task_status as taskStatus, bai.unit_id,bai.project_id,bu.unit_name, bp.pro_name, bai.agreement_code, tt.task_status as taskStatus,
sda.dict_label as taskStatusName, sda.dict_label as taskStatusName,
@ -472,7 +472,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
lai.company_audit_time, lai.company_audit_remark, lai.dept_audit_by as directAuditBy, lai.dept_audit_time, lai.company_audit_time, lai.company_audit_remark, lai.dept_audit_by as directAuditBy, lai.dept_audit_time,
lai.dept_audit_remark, lai.direct_audit_by, lai.direct_audit_time, lai.direct_audit_remark, lai.dept_audit_remark, lai.direct_audit_by, lai.direct_audit_time, lai.direct_audit_remark,
lai.create_by, DATE_FORMAT(lai.create_time, '%Y-%m-%d') as createTime, lai.update_by, lai.update_time, lai.remark, lai.company_id, lai.create_by, DATE_FORMAT(lai.create_time, '%Y-%m-%d') as createTime, lai.update_by, lai.update_time, lai.remark, lai.company_id,
lai.direct_id, lai.lease_type, lai.estimate_lease_time, lai.cost_bearing_party, lai.lease_sign_url as leaseSignUrl, lai.lease_sign_type as leaseSignType, lai.direct_id, lai.lease_type, lai.estimate_lease_time, lai.cost_bearing_party,
lai.material_man, lai.confirm_time, lai.is_confirm, lai.confirm_remark, lai.material_man, lai.confirm_time, lai.is_confirm, lai.confirm_remark,
bai.unit_id,bai.project_id,bu.unit_name as unitName, bp.pro_name as projectName,bp.external_id as externalId, bai.agreement_code as agreementCode, tt.task_status as taskStatus, bai.unit_id,bai.project_id,bu.unit_name as unitName, bp.pro_name as projectName,bp.external_id as externalId, bai.agreement_code as agreementCode, tt.task_status as taskStatus,
sda.dict_label as taskStatusName, sda.dict_label as taskStatusName,
@ -486,8 +486,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
bp.contract_part as contractPart, bp.contract_part as contractPart,
sd.dept_name as impUnitName, sd.dept_name as impUnitName,
tt.task_type as taskType, tt.task_type as taskType,
su.sign_type as lease_sign_type, su.sign_type as leaseSignType,
su.sign_url as lease_sign_url su.sign_url as leaseSignUrl
from from
lease_apply_info lai lease_apply_info lai
left join tm_task tt on lai.task_id = tt.task_id left join tm_task tt on lai.task_id = tt.task_id
@ -858,4 +858,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
WHERE WHERE
bai.unit_id = #{teamId} AND bai.project_id = #{projectId} bai.unit_id = #{teamId} AND bai.project_id = #{projectId}
</select> </select>
<select id="getOutNum" resultType="com.bonus.common.biz.domain.lease.LeaseApplyInfo">
SELECT
IFNULL(SUM(out_num), 0) as alNum
FROM
lease_out_details
where 1 = 1
<if test="startTime != null and startTime != '' and endTime != null and endTime != ''">
and create_time BETWEEN CONCAT(#{startTime}, ' 00:00:00') AND CONCAT(#{endTime}, ' 23:59:59')
</if>
</select>
</mapper> </mapper>