重庆领料申请代码提交
This commit is contained in:
parent
85a1fe9cfb
commit
270d3ae2f8
|
|
@ -70,24 +70,47 @@ public class TmTaskController extends BaseController {
|
||||||
* @param task 审核信息
|
* @param task 审核信息
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
@Log(title = "领料审核通过", businessType = BusinessType.UPDATE)
|
@Log(title = "宁夏领料审核通过", businessType = BusinessType.UPDATE)
|
||||||
@PostMapping("auditLeaseByCompany")
|
@PostMapping("auditLeaseByCompany")
|
||||||
public AjaxResult auditLeaseByCompany(@RequestBody TmTask task) {
|
public AjaxResult auditLeaseByCompany(@RequestBody TmTask task) {
|
||||||
return toAjax(tmTaskService.updateLeaseTaskAuditInfo(task));
|
return toAjax(tmTaskService.updateLeaseTaskAuditInfo(task));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 领料审核通过,分公司,分管,机具分公司统一接口
|
||||||
|
*
|
||||||
|
* @param task 审核信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Log(title = "重庆领料审核通过", businessType = BusinessType.UPDATE)
|
||||||
|
@PostMapping("auditLeaseByCompanyCq")
|
||||||
|
public AjaxResult auditLeaseByCompanyCq(@RequestBody TmTask task) {
|
||||||
|
return toAjax(tmTaskService.updateLeaseTaskAuditInfoCq(task));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 领料审核驳回,分公司,分管,机具分公司统一接口
|
* 领料审核驳回,分公司,分管,机具分公司统一接口
|
||||||
*
|
*
|
||||||
* @param task
|
* @param task
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@Log(title = "领料审核驳回", businessType = BusinessType.UPDATE)
|
@Log(title = "宁夏领料审核驳回", businessType = BusinessType.UPDATE)
|
||||||
@PostMapping("rejectLeaseByCompany")
|
@PostMapping("rejectLeaseByCompany")
|
||||||
public AjaxResult rejectLeaseByCompany(@RequestBody TmTask task) {
|
public AjaxResult rejectLeaseByCompany(@RequestBody TmTask task) {
|
||||||
return toAjax(tmTaskService.updateLeaseTaskRejectInfo(task));
|
return toAjax(tmTaskService.updateLeaseTaskRejectInfo(task));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 领料审核驳回,分公司,分管,机具分公司统一接口
|
||||||
|
*
|
||||||
|
* @param task
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@Log(title = "重庆领料审核驳回", businessType = BusinessType.UPDATE)
|
||||||
|
@PostMapping("rejectLeaseByCompanyCq")
|
||||||
|
public AjaxResult rejectLeaseByCompanyCq(@RequestBody TmTask task) {
|
||||||
|
return toAjax(tmTaskService.updateLeaseTaskRejectInfoCq(task));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据任务id删除任务表及任务信息
|
* 根据任务id删除任务表及任务信息
|
||||||
|
|
@ -162,6 +185,7 @@ public class TmTaskController extends BaseController {
|
||||||
leaseApplyInfo.setTaskId(Integer.valueOf(taskId)); // 设置任务ID
|
leaseApplyInfo.setTaskId(Integer.valueOf(taskId)); // 设置任务ID
|
||||||
leaseApplyInfo.setCompanyId(leaseApplyDetailsList.get(0).getCompanyId()); // 设置设备所属分公司,用于交给哪家审核
|
leaseApplyInfo.setCompanyId(leaseApplyDetailsList.get(0).getCompanyId()); // 设置设备所属分公司,用于交给哪家审核
|
||||||
leaseApplyInfo.setType("2"); // 设置审批层级,先固定2层,后期根据接口传入Type区分来源设定
|
leaseApplyInfo.setType("2"); // 设置审批层级,先固定2层,后期根据接口传入Type区分来源设定
|
||||||
|
leaseApplyInfo.setLeaseType(task.getLeaseType());
|
||||||
|
|
||||||
// 创建领料任务,返回领料任务编号
|
// 创建领料任务,返回领料任务编号
|
||||||
boolean addLeaseTaskResult = leaseApplyInfoService.genderLeaseCode(leaseApplyInfo) > 0;
|
boolean addLeaseTaskResult = leaseApplyInfoService.genderLeaseCode(leaseApplyInfo) > 0;
|
||||||
|
|
@ -319,7 +343,7 @@ public class TmTaskController extends BaseController {
|
||||||
* @param souceBy app为1 web为0
|
* @param souceBy app为1 web为0
|
||||||
* @return 列表
|
* @return 列表
|
||||||
*/
|
*/
|
||||||
@Log(title = "查询机具领料管理列表", businessType = BusinessType.QUERY)
|
@Log(title = "宁夏查询机具领料管理列表", businessType = BusinessType.QUERY)
|
||||||
@GetMapping(value = "getLeaseManageListAll")
|
@GetMapping(value = "getLeaseManageListAll")
|
||||||
public AjaxResult getLeaseManageListAll(TmTask task, Integer souceBy) {
|
public AjaxResult getLeaseManageListAll(TmTask task, Integer souceBy) {
|
||||||
if (StringUtils.isNull(task)) {
|
if (StringUtils.isNull(task)) {
|
||||||
|
|
@ -336,6 +360,31 @@ public class TmTaskController extends BaseController {
|
||||||
Integer pageSize = Convert.toInt(ServletUtils.getParameter(PAGE_SIZE), 10);
|
Integer pageSize = Convert.toInt(ServletUtils.getParameter(PAGE_SIZE), 10);
|
||||||
return AjaxResult.success(ListPagingUtil.paging(pageIndex, pageSize, leaseAuditList));
|
return AjaxResult.success(ListPagingUtil.paging(pageIndex, pageSize, leaseAuditList));
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* 查询机具领料管理列表
|
||||||
|
*
|
||||||
|
* @param task 筛选条件
|
||||||
|
* @param souceBy app为1 web为0
|
||||||
|
* @return 列表
|
||||||
|
*/
|
||||||
|
@Log(title = "重庆查询机具领料管理列表", businessType = BusinessType.QUERY)
|
||||||
|
@GetMapping(value = "getLeaseManageListAllCq")
|
||||||
|
public AjaxResult getLeaseManageListAllCq(TmTask task, Integer souceBy) {
|
||||||
|
if (StringUtils.isNull(task)) {
|
||||||
|
return AjaxResult.error("参数错误");
|
||||||
|
}
|
||||||
|
List<TmTask> leaseAuditList;
|
||||||
|
if (souceBy != null && souceBy == 1) {
|
||||||
|
leaseAuditList = tmTaskService.getLeaseAuditManageListCq(task);
|
||||||
|
return AjaxResult.success(leaseAuditList);
|
||||||
|
}
|
||||||
|
// startPage();
|
||||||
|
leaseAuditList = tmTaskService.getLeaseAuditManageListCq(task);
|
||||||
|
Integer pageIndex = Convert.toInt(ServletUtils.getParameter(PAGE_NUM), 1);
|
||||||
|
Integer pageSize = Convert.toInt(ServletUtils.getParameter(PAGE_SIZE), 10);
|
||||||
|
return AjaxResult.success(ListPagingUtil.paging(pageIndex, pageSize, leaseAuditList));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 领料申请导出
|
* 领料申请导出
|
||||||
|
|
@ -472,7 +521,7 @@ public class TmTaskController extends BaseController {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Log(title = "获取领料管理-详情列表", businessType = BusinessType.QUERY)
|
@Log(title = "宁夏获取领料管理-详情列表", businessType = BusinessType.QUERY)
|
||||||
@GetMapping("/getLeaseListAll")
|
@GetMapping("/getLeaseListAll")
|
||||||
public TableDataInfo getLeaseListAll(@RequestParam(value = "taskId", required = false, defaultValue = "") String taskId) {
|
public TableDataInfo getLeaseListAll(@RequestParam(value = "taskId", required = false, defaultValue = "") String taskId) {
|
||||||
TmTask task = new TmTask();
|
TmTask task = new TmTask();
|
||||||
|
|
@ -481,7 +530,16 @@ public class TmTaskController extends BaseController {
|
||||||
return getDataTable(leaseAuditList);
|
return getDataTable(leaseAuditList);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Log(title = "获取领料申请-查看列表", businessType = BusinessType.QUERY)
|
@Log(title = "重庆获取领料管理-详情列表", businessType = BusinessType.QUERY)
|
||||||
|
@GetMapping("/getLeaseListAllCq")
|
||||||
|
public TableDataInfo getLeaseListAllCq(@RequestParam(value = "taskId", required = false, defaultValue = "") String taskId) {
|
||||||
|
TmTask task = new TmTask();
|
||||||
|
task.setTaskId(Long.parseLong(taskId));
|
||||||
|
List<TmTask> leaseAuditList = tmTaskService.getLeaseListAllCq(task);
|
||||||
|
return getDataTable(leaseAuditList);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Log(title = "获取领料申请-查看/编辑列表", businessType = BusinessType.QUERY)
|
||||||
@GetMapping("/getLeaseApplyListAll")
|
@GetMapping("/getLeaseApplyListAll")
|
||||||
public TableDataInfo getLeaseApplyListAll(@RequestParam(value = "taskId", required = false, defaultValue = "") String taskId) {
|
public TableDataInfo getLeaseApplyListAll(@RequestParam(value = "taskId", required = false, defaultValue = "") String taskId) {
|
||||||
TmTask task = new TmTask();
|
TmTask task = new TmTask();
|
||||||
|
|
|
||||||
|
|
@ -159,5 +159,7 @@ public class LeaseApplyInfo implements Serializable {
|
||||||
|
|
||||||
@ApiModelProperty(value="审核状态")
|
@ApiModelProperty(value="审核状态")
|
||||||
private String status;
|
private String status;
|
||||||
|
@ApiModelProperty(value="领用类型:0 短期租赁 1长期领用")
|
||||||
|
private String leaseType;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -229,4 +229,8 @@ public class TmTask implements Serializable {
|
||||||
@ApiModelProperty(value="分管审批备注")
|
@ApiModelProperty(value="分管审批备注")
|
||||||
private String deptAuditRemark;
|
private String deptAuditRemark;
|
||||||
|
|
||||||
|
@ApiModelProperty(value="领用类型:0 短期租赁 1长期领用")
|
||||||
|
private String leaseType;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -108,4 +108,6 @@ public interface TmTaskMapper {
|
||||||
LeaseApplyInfo getListSomeol(LeaseApplyInfo info);
|
LeaseApplyInfo getListSomeol(LeaseApplyInfo info);
|
||||||
|
|
||||||
Integer getKgByMaType(Integer typeId);
|
Integer getKgByMaType(Integer typeId);
|
||||||
|
|
||||||
|
List<LeaseApplyDetails> getLeaseApplyDetailsCq(@Param("record") LeaseApplyInfo leaseApplyInfo);
|
||||||
}
|
}
|
||||||
|
|
@ -28,8 +28,10 @@ public interface TmTaskService{
|
||||||
|
|
||||||
/** 领料任务审核通过状态修改 */
|
/** 领料任务审核通过状态修改 */
|
||||||
int updateLeaseTaskAuditInfo(TmTask record);
|
int updateLeaseTaskAuditInfo(TmTask record);
|
||||||
|
int updateLeaseTaskAuditInfoCq(TmTask record);
|
||||||
/** 领料任务审核驳回状态修改 */
|
/** 领料任务审核驳回状态修改 */
|
||||||
int updateLeaseTaskRejectInfo(TmTask record);
|
int updateLeaseTaskRejectInfo(TmTask record);
|
||||||
|
int updateLeaseTaskRejectInfoCq(TmTask record);
|
||||||
|
|
||||||
String genderLeaseCode();
|
String genderLeaseCode();
|
||||||
|
|
||||||
|
|
@ -81,4 +83,8 @@ public interface TmTaskService{
|
||||||
LeaseApplyInfo getListSomeol(LeaseApplyInfo info);
|
LeaseApplyInfo getListSomeol(LeaseApplyInfo info);
|
||||||
|
|
||||||
List<TmTask> getLeaseAuditListByPeople(TmTask task);
|
List<TmTask> getLeaseAuditListByPeople(TmTask task);
|
||||||
|
|
||||||
|
List<TmTask> getLeaseAuditManageListCq(TmTask task);
|
||||||
|
|
||||||
|
List<TmTask> getLeaseListAllCq(TmTask task);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -170,6 +170,37 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int updateLeaseTaskAuditInfoCq(TmTask record) {
|
||||||
|
int result = 0;
|
||||||
|
if (StringUtils.isNotNull(record)) {
|
||||||
|
// 内部审核
|
||||||
|
// 管理员登录时审核
|
||||||
|
result += tmTaskMapper.updateTmTaskAuditStatus(record);
|
||||||
|
// 分公司审核
|
||||||
|
// 再审核领料任务信息表
|
||||||
|
List<LeaseApplyInfo> leaseApplyInfoList = record.getLeaseApplyInfoList();
|
||||||
|
if (CollUtil.isNotEmpty(leaseApplyInfoList)) {
|
||||||
|
for (LeaseApplyInfo leaseApplyInfo : leaseApplyInfoList) {
|
||||||
|
if (leaseApplyInfo != null) {
|
||||||
|
//leaseApplyInfo.setExamineStatusId(record.getExamineStatusId());
|
||||||
|
result += tmTaskMapper.updateLeaseApplyInfoAuditInfo(leaseApplyInfo);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 再审核领料任务详情表
|
||||||
|
List<LeaseApplyDetails> leaseApplyDetails = record.getLeaseApplyDetails();
|
||||||
|
if (CollUtil.isNotEmpty(leaseApplyDetails)) {
|
||||||
|
for (LeaseApplyDetails details : leaseApplyDetails) {
|
||||||
|
if (StringUtils.isNotNull(details)) {
|
||||||
|
result += tmTaskMapper.updateLeaseApplyDetailsAuditInfo(details);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取领料申请列表
|
* 获取领料申请列表
|
||||||
*/
|
*/
|
||||||
|
|
@ -292,6 +323,65 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
return tmTaskList;
|
return tmTaskList;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<TmTask> getLeaseAuditManageListCq(TmTask record) {
|
||||||
|
List<TmTask> tmTaskList = tmTaskMapper.getAuditManageListByLeaseTmTask(record);
|
||||||
|
for (TmTask tmTask : tmTaskList) {
|
||||||
|
int count = 0;
|
||||||
|
if (tmTask != null) {
|
||||||
|
// 去查询任务分单表
|
||||||
|
List<LeaseApplyInfo> collect = tmTaskMapper.getAuditManageListByLeaseInfo(tmTask);
|
||||||
|
// 对领料任务集合查询具体详情
|
||||||
|
for (LeaseApplyInfo leaseApplyInfo : collect) {
|
||||||
|
if (leaseApplyInfo != null) {
|
||||||
|
// 去查询领料任务详情表
|
||||||
|
List<LeaseApplyDetails> leaseApplyDetails = tmTaskMapper.getLeaseApplyManageDetails(leaseApplyInfo);
|
||||||
|
if (leaseApplyDetails != null && !leaseApplyDetails.isEmpty()) {
|
||||||
|
for (LeaseApplyDetails leaseApplyDetail : leaseApplyDetails) {
|
||||||
|
if (leaseApplyDetail != null && leaseApplyDetail.getPreNum() != null) {
|
||||||
|
// 统计预领数量
|
||||||
|
count += leaseApplyDetail.getPreNum();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 塞入领料任务详情的集合中
|
||||||
|
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 存入领料任务实体集合
|
||||||
|
tmTask.setLeaseApplyInfoList(collect);
|
||||||
|
tmTask.setPreCountNum(count);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
List<TmTask> tmTasks = tmTaskList.stream().filter(t -> t.getLeaseApplyInfoList() != null).collect(Collectors.toList());
|
||||||
|
return tmTasks;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<TmTask> getLeaseListAllCq(TmTask task) {
|
||||||
|
List<TmTask> tmTaskList = new ArrayList<>();
|
||||||
|
TmTask tmTask = tmTaskMapper.getLeaseListTmTask(task);
|
||||||
|
if (tmTask != null) {
|
||||||
|
List<LeaseApplyInfo> leaseApplyInfoList = tmTaskMapper.getLeaseListByLeaseInfo(task);
|
||||||
|
tmTask.setLeaseApplyInfoList(leaseApplyInfoList);
|
||||||
|
|
||||||
|
List<LeaseApplyDetails> listLeaseDetails = new ArrayList<>();
|
||||||
|
for (LeaseApplyInfo leaseApplyInfo : leaseApplyInfoList) {
|
||||||
|
if (leaseApplyInfo != null) {
|
||||||
|
// 去查询领料任务详情表
|
||||||
|
List<LeaseApplyDetails> leaseApplyDetails = tmTaskMapper.getLeaseApplyDetailsCq(leaseApplyInfo);
|
||||||
|
if (leaseApplyDetails != null && !leaseApplyDetails.isEmpty()) {
|
||||||
|
listLeaseDetails.addAll(leaseApplyDetails);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 塞入领料任务详情的集合中
|
||||||
|
tmTask.setLeaseApplyDetails(listLeaseDetails);
|
||||||
|
}
|
||||||
|
tmTaskList.add(tmTask);
|
||||||
|
return tmTaskList;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取领料申请列表
|
* 获取领料申请列表
|
||||||
|
|
@ -595,7 +685,40 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
return 0;
|
return result;
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int updateLeaseTaskRejectInfoCq(TmTask record) {
|
||||||
|
int result = 0;
|
||||||
|
if (StringUtils.isNotNull(record)) {
|
||||||
|
// 先审核任务表
|
||||||
|
result += tmTaskMapper.updateTmTaskAuditStatus(record);
|
||||||
|
// 分公司驳回
|
||||||
|
// 再审核领料任务信息表
|
||||||
|
List<LeaseApplyInfo> leaseApplyInfoList = record.getLeaseApplyInfoList();
|
||||||
|
if (CollUtil.isNotEmpty(leaseApplyInfoList)) {
|
||||||
|
for (LeaseApplyInfo leaseApplyInfo : leaseApplyInfoList) {
|
||||||
|
if (leaseApplyInfo != null) {
|
||||||
|
//leaseApplyInfo.setExamineStatusId(record.getExamineStatusId());
|
||||||
|
result += tmTaskMapper.updateLeaseApplyInfoRejectInfo(leaseApplyInfo);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 再审核领料任务详情表
|
||||||
|
List<LeaseApplyDetails> leaseApplyDetails = record.getLeaseApplyDetails();
|
||||||
|
if (CollUtil.isNotEmpty(leaseApplyDetails)) {
|
||||||
|
for (LeaseApplyDetails details : leaseApplyDetails) {
|
||||||
|
if (StringUtils.isNotNull(details)) {
|
||||||
|
result += tmTaskMapper.updateLeaseApplyDetailsRejectInfo(details);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
@ -899,7 +1022,7 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
List<LeaseApplyInfo> leaseApplyInfoList = tmTaskMapper.getLeaseListByLeaseInfo(task);
|
List<LeaseApplyInfo> leaseApplyInfoList = tmTaskMapper.getLeaseListByLeaseInfo(task);
|
||||||
if (task.getFlag() == 0) {
|
if (task.getFlag() == 0) {
|
||||||
for (LeaseApplyInfo applyInfo : leaseApplyInfoList) {
|
for (LeaseApplyInfo applyInfo : leaseApplyInfoList) {
|
||||||
if ("2".equals(applyInfo.getStatus()) || "4".equals(applyInfo.getStatus()) || "6".equals(applyInfo.getStatus()) || "8".equals(applyInfo.getStatus())) {
|
if ("2".equals(applyInfo.getStatus()) || "4".equals(applyInfo.getStatus()) || "6".equals(applyInfo.getStatus()) || "8".equals(applyInfo.getStatus()) || "10".equals(applyInfo.getStatus())) {
|
||||||
leaseApplyInfos.add(applyInfo);
|
leaseApplyInfos.add(applyInfo);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -122,6 +122,9 @@
|
||||||
<if test="companyId != null">
|
<if test="companyId != null">
|
||||||
company_id,
|
company_id,
|
||||||
</if>
|
</if>
|
||||||
|
<if test="leaseType != null and leaseType != ''">
|
||||||
|
lease_type,
|
||||||
|
</if>
|
||||||
</trim>
|
</trim>
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
<if test="code != null">
|
<if test="code != null">
|
||||||
|
|
@ -175,6 +178,9 @@
|
||||||
<if test="companyId != null">
|
<if test="companyId != null">
|
||||||
#{companyId,jdbcType=INTEGER},
|
#{companyId,jdbcType=INTEGER},
|
||||||
</if>
|
</if>
|
||||||
|
<if test="leaseType != null and leaseType != ''">
|
||||||
|
#{leaseType,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
</trim>
|
</trim>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -458,7 +458,7 @@
|
||||||
tt.*, su.phonenumber AS phoneNumber, sd.dept_name as deptName,
|
tt.*, su.phonenumber AS phoneNumber, sd.dept_name as deptName,
|
||||||
bpl.lot_id as proId,bpl.lot_name as proName,
|
bpl.lot_id as proId,bpl.lot_name as proName,
|
||||||
bui.unit_id as unitId,bui.unit_name as unitName,
|
bui.unit_id as unitId,bui.unit_name as unitName,
|
||||||
lai.lease_person as leasePerson, lai.phone as leasePhone, tt.create_by as applyFor,d.`name` as taskName,
|
lai.lease_person as leasePerson, lai.phone as leasePhone, tt.create_by as applyFor,d.`name` as taskName,lai.lease_type as leaseType,
|
||||||
case when d.id = '30' then lai.company_audit_remark
|
case when d.id = '30' then lai.company_audit_remark
|
||||||
when d.id = '31' then lai.dept_audit_remark
|
when d.id = '31' then lai.dept_audit_remark
|
||||||
when d.id = '32' then lai.direct_audit_remark
|
when d.id = '32' then lai.direct_audit_remark
|
||||||
|
|
@ -625,6 +625,7 @@
|
||||||
su4.user_name as directAuditBy,
|
su4.user_name as directAuditBy,
|
||||||
lai.direct_audit_time as directAuditTime,
|
lai.direct_audit_time as directAuditTime,
|
||||||
lai.direct_audit_remark as directAuditRemark,
|
lai.direct_audit_remark as directAuditRemark,
|
||||||
|
lai.lease_type as leaseType,
|
||||||
|
|
||||||
d.id as examineStatusId,
|
d.id as examineStatusId,
|
||||||
bai.agreement_code as agreementCode,
|
bai.agreement_code as agreementCode,
|
||||||
|
|
@ -807,7 +808,7 @@
|
||||||
tt.*, su.phonenumber AS phoneNumber, sd.dept_name as deptName,
|
tt.*, su.phonenumber AS phoneNumber, sd.dept_name as deptName,
|
||||||
bpl.lot_id as proId,bpl.lot_name as proName,
|
bpl.lot_id as proId,bpl.lot_name as proName,
|
||||||
bui.unit_id as unitId,bui.unit_name as unitName,
|
bui.unit_id as unitId,bui.unit_name as unitName,
|
||||||
lai.lease_person as leasePerson, lai.phone as leasePhone, tt.create_by as applyFor,d.`name` as taskName,
|
lai.lease_person as leasePerson, lai.phone as leasePhone, tt.create_by as applyFor,d.`name` as taskName,lai.lease_type as leaseType,
|
||||||
case when d.id = '30' then lai.company_audit_remark
|
case when d.id = '30' then lai.company_audit_remark
|
||||||
when d.id = '31' then lai.dept_audit_remark
|
when d.id = '31' then lai.dept_audit_remark
|
||||||
when d.id = '32' then lai.direct_audit_remark
|
when d.id = '32' then lai.direct_audit_remark
|
||||||
|
|
@ -866,6 +867,21 @@
|
||||||
GROUP BY
|
GROUP BY
|
||||||
lad.id
|
lad.id
|
||||||
</select>
|
</select>
|
||||||
|
<select id="getLeaseApplyDetailsCq" resultType="com.bonus.sgzb.app.domain.LeaseApplyDetails">
|
||||||
|
SELECT
|
||||||
|
lad.*, mt.type_name AS typeModelName, mt1.type_name AS typeName,mt.unit_name as unitName, mt.manage_type as manageType,
|
||||||
|
case WHEN mt.manage_type = '0' then '编号' else '计数' end manageTypeName,
|
||||||
|
mt.num, (lad.pre_num - IF(lad.al_num IS NULL,'0',lad.al_num)) AS outNum,mm.ma_code as maCode
|
||||||
|
FROM
|
||||||
|
lease_apply_details lad
|
||||||
|
LEFT JOIN ma_type mt ON lad.type_id = mt.type_id
|
||||||
|
LEFT JOIN ma_type mt1 ON mt.parent_id = mt1.type_id
|
||||||
|
LEFT JOIN ma_machine mm ON lad.type_id = mm.type_id
|
||||||
|
WHERE
|
||||||
|
lad.parennt_id = #{record.id}
|
||||||
|
GROUP BY
|
||||||
|
lad.id
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
|
||||||
|
|
@ -149,7 +149,7 @@ public class WorkSiteDirectManageController extends BaseController {
|
||||||
if (CollUtil.isEmpty(leaseApplyDetails)) {
|
if (CollUtil.isEmpty(leaseApplyDetails)) {
|
||||||
return AjaxResult.error("领料出库信息为空");
|
return AjaxResult.error("领料出库信息为空");
|
||||||
}
|
}
|
||||||
List<LeaseApplyInfo> leaseApplyInfoList = applyInfoService.selectIdByTaskId(task.getTaskId().intValue());
|
List<LeaseApplyInfo> leaseApplyInfoList = applyInfoService.selectIdByTaskId(Integer.parseInt(task.getId()));
|
||||||
List<LeaseOutDetails> list = new ArrayList();
|
List<LeaseOutDetails> list = new ArrayList();
|
||||||
for (LeaseApplyDetails leaseApplyDetail : leaseApplyDetails) {
|
for (LeaseApplyDetails leaseApplyDetail : leaseApplyDetails) {
|
||||||
LeaseOutDetails leaseOutDetails = new LeaseOutDetails();
|
LeaseOutDetails leaseOutDetails = new LeaseOutDetails();
|
||||||
|
|
|
||||||
|
|
@ -70,6 +70,14 @@ export function getLeaseManageListAll(query) {
|
||||||
params: query
|
params: query
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
// 机具领料-申请列表
|
||||||
|
export function getLeaseManageListAllCq(query) {
|
||||||
|
return request({
|
||||||
|
url: '/base/tm_task/getLeaseManageListAllCq',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
|
}
|
||||||
// 机具领料-管理列表
|
// 机具领料-管理列表
|
||||||
export function getLeaseAuditListAll(query) {
|
export function getLeaseAuditListAll(query) {
|
||||||
return request({
|
return request({
|
||||||
|
|
@ -142,13 +150,21 @@ export function deleteTask( taskId ){
|
||||||
}
|
}
|
||||||
|
|
||||||
// 根据 领料任务id 获取详情数据
|
// 根据 领料任务id 获取详情数据
|
||||||
export function getTaskDetail( params = {} ){
|
export function getLeaseListAll( params = {} ){
|
||||||
return request({
|
return request({
|
||||||
url: '/base/tm_task/getLeaseListAll',
|
url: '/base/tm_task/getLeaseListAll',
|
||||||
method:'get',
|
method:'get',
|
||||||
params:params
|
params:params
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
// 根据 领料任务id 获取详情数据
|
||||||
|
export function getLeaseListAllCq( params = {} ){
|
||||||
|
return request({
|
||||||
|
url: '/base/tm_task/getLeaseListAllCq',
|
||||||
|
method:'get',
|
||||||
|
params:params
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
// 领料审核 同意
|
// 领料审核 同意
|
||||||
export function auditLeaseByCompany(params = {} ){
|
export function auditLeaseByCompany(params = {} ){
|
||||||
|
|
|
||||||
|
|
@ -146,7 +146,7 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { listType, getType, delType, addType, updateType, refreshCache } from "@/api/system/dict/type";
|
import { listType, getType, delType, addType, updateType, refreshCache } from "@/api/system/dict/type";
|
||||||
import { auditLeaseByCompanyCq, getTaskDetail,rejectLeaseByCompanyCq } from '@/api/claimAndRefund/receive'
|
import { auditLeaseByCompanyCq, getLeaseListAllCq,rejectLeaseByCompanyCq } from '@/api/claimAndRefund/receive'
|
||||||
import {mapState} from 'vuex'
|
import {mapState} from 'vuex'
|
||||||
export default {
|
export default {
|
||||||
name: "ReceiveExamine",
|
name: "ReceiveExamine",
|
||||||
|
|
@ -323,7 +323,7 @@ export default {
|
||||||
},
|
},
|
||||||
/** 查询 */
|
/** 查询 */
|
||||||
async getData(taskId) {
|
async getData(taskId) {
|
||||||
const res = await getTaskDetail({
|
const res = await getLeaseListAllCq({
|
||||||
taskId
|
taskId
|
||||||
})
|
})
|
||||||
this.queryParams = {...this.queryParams,...res.rows[0]}
|
this.queryParams = {...this.queryParams,...res.rows[0]}
|
||||||
|
|
|
||||||
|
|
@ -196,7 +196,7 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { listType, getType, delType, addType, updateType, refreshCache } from "@/api/system/dict/type";
|
import { listType, getType, delType, addType, updateType, refreshCache } from "@/api/system/dict/type";
|
||||||
import { getLeaseManageListAll, getUnitData, getProData, getTaskDetail } from '@/api/claimAndRefund/receive'
|
import { getLeaseManageListAllCq, getUnitData, getProData, getTaskDetail } from '@/api/claimAndRefund/receive'
|
||||||
import { getInfo } from '@/api/login'
|
import { getInfo } from '@/api/login'
|
||||||
import vueEasyPrint from 'vue-easy-print';
|
import vueEasyPrint from 'vue-easy-print';
|
||||||
export default {
|
export default {
|
||||||
|
|
@ -304,7 +304,7 @@ export default {
|
||||||
pageNum: this.queryParams.pageNum
|
pageNum: this.queryParams.pageNum
|
||||||
}
|
}
|
||||||
|
|
||||||
const res = await getLeaseManageListAll(params)
|
const res = await getLeaseManageListAllCq(params)
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
console.log('getList ============',res)
|
console.log('getList ============',res)
|
||||||
this.leaseAuditList = res.data.rows;
|
this.leaseAuditList = res.data.rows;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue