提交 8088d43e authored 作者: 邓砥奕's avatar 邓砥奕

更新

上级 65b29b24
...@@ -236,7 +236,7 @@ public class PackingLibraryController { ...@@ -236,7 +236,7 @@ public class PackingLibraryController {
} }
@ApiOperation(value = "查询多个列装详情", notes = "可以通过这个接口查询多个列装详情") @ApiOperation(value = "查询多个列装详情", notes = "可以通过这个接口查询多个列装详情")
@GetMapping("/selectMoreDetail/") @PostMapping("/selectMoreDetail")
public ResponseEntity selectMorePackingDetail(@RequestBody List<Integer> ids) { public ResponseEntity selectMorePackingDetail(@RequestBody List<Integer> ids) {
List<PackingLibrary> packingLibraries = new ArrayList<>(); List<PackingLibrary> packingLibraries = new ArrayList<>();
ids.forEach(integer -> packingLibraries.add(packingLibraryService.getOne(integer))); ids.forEach(integer -> packingLibraries.add(packingLibraryService.getOne(integer)));
......
...@@ -10,7 +10,14 @@ import com.tykj.dev.device.repair.subject.domin.RepairBill; ...@@ -10,7 +10,14 @@ import com.tykj.dev.device.repair.subject.domin.RepairBill;
import com.tykj.dev.device.repair.subject.domin.RepairDetail; import com.tykj.dev.device.repair.subject.domin.RepairDetail;
import com.tykj.dev.device.repair.subject.domin.RepairSendBill; import com.tykj.dev.device.repair.subject.domin.RepairSendBill;
import com.tykj.dev.device.repair.subject.vo.RepairBillSelectVo; import com.tykj.dev.device.repair.subject.vo.RepairBillSelectVo;
import com.tykj.dev.device.repair.subject.vo.TaskRemark;
import com.tykj.dev.device.task.service.TaskService;
import com.tykj.dev.device.task.subject.bto.TaskBto;
import com.tykj.dev.device.task.subject.vo.TaskSelectVo;
import com.tykj.dev.device.task.subject.vo.TaskUserVo;
import com.tykj.dev.device.task.utils.TaskUtils;
import com.tykj.dev.misc.base.RepairStatusEnum; import com.tykj.dev.misc.base.RepairStatusEnum;
import com.tykj.dev.misc.utils.PageUtil;
import com.tykj.dev.misc.utils.ResultUtil; import com.tykj.dev.misc.utils.ResultUtil;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
...@@ -20,6 +27,7 @@ import org.springframework.web.bind.annotation.*; ...@@ -20,6 +27,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.stream.Collectors;
/** /**
* @author dengdiyi * @author dengdiyi
...@@ -42,6 +50,27 @@ public class RepairBillSelectController { ...@@ -42,6 +50,27 @@ public class RepairBillSelectController {
@Autowired @Autowired
private RepairDetailService repairDetailService; private RepairDetailService repairDetailService;
@Autowired
private TaskService taskService;
@Autowired
private TaskUtils taskUtils;
@ApiOperation(value = "查询维修管理任务", notes = "可以通过这个接口查询查询维修管理任务")
@PostMapping(value = "/repair")
public ResponseEntity selectRepairTasks(@RequestBody TaskSelectVo taskSelectVo){
List<TaskUserVo> taskUserVos = taskService.getManageList(taskSelectVo).stream().filter(taskUserVo -> taskUserVo.getBillStatus()==704||taskUserVo.getBillStatus()==804).collect(Collectors.toList());
return ResultUtil.success(PageUtil.getPerPage(taskSelectVo.getPage(), taskSelectVo.getSize(), taskUtils.orderByTopDesc(taskUserVos), taskSelectVo.getPageable()));
}
@ApiOperation(value = "上传任务备注", notes = "可以通过这个接口上传任务备注")
@PostMapping(value = "/remark")
public ResponseEntity selectRepairTasks(@RequestBody TaskRemark taskRemark){
TaskBto taskBto = taskService.get(taskRemark.getId());
taskBto.setRemark(taskRemark.getRemark());
taskService.update(taskBto);
return ResponseEntity.ok("更新成功");
}
@ApiOperation(value = "查询维修单", notes = "可以通过这个接口查询维修单") @ApiOperation(value = "查询维修单", notes = "可以通过这个接口查询维修单")
@PostMapping(value = "/archives/repair/summary") @PostMapping(value = "/archives/repair/summary")
......
...@@ -659,15 +659,16 @@ public class RepairController { ...@@ -659,15 +659,16 @@ public class RepairController {
repairBackBill.setSendTime(new Date()); repairBackBill.setSendTime(new Date());
repairBackBill.setTitle("维修退回业务"); repairBackBill.setTitle("维修退回业务");
repairBackBill.setAgent(repairBackBillSaveVo.getAgent()); repairBackBill.setAgent(repairBackBillSaveVo.getAgent());
Calendar calendar = Calendar.getInstance();
String s1 = "NO:第" + calendar.get(Calendar.YEAR) + "LQ" + repairBackBill.getId() + "号";
repairBackBill.setDocNum(s1);
//生成单位签章id //生成单位签章id
Long signId = snowflake.creatNextId(); Long signId = snowflake.creatNextId();
Long signId2 = snowflake.creatNextId(); Long signId2 = snowflake.creatNextId();
repairBackBill.setLeftSignatureId(signId.toString()); repairBackBill.setLeftSignatureId(signId.toString());
repairBackBill.setRightSignatureId(signId2.toString()); repairBackBill.setRightSignatureId(signId2.toString());
RepairBackBill deviceRepairBackBillEntity1 = deviceRepairBackBillService.save(repairBackBill); RepairBackBill deviceRepairBackBillEntity1 = deviceRepairBackBillService.save(repairBackBill);
Calendar calendar = Calendar.getInstance();
String s1 = "NO:第" + calendar.get(Calendar.YEAR) + "LQ" + repairBackBill.getId() + "号";
deviceRepairBackBillEntity1.setDocNum(s1);
deviceRepairBackBillService.update(deviceRepairBackBillEntity1);
//发起维修退回子业务 //发起维修退回子业务
List<Integer> userIds = new ArrayList<>(); List<Integer> userIds = new ArrayList<>();
userIds.add(userId); userIds.add(userId);
......
package com.tykj.dev.device.repair.subject.vo;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
/**
* @author dengdiyi
*/
@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel("业务备注类")
public class TaskRemark {
@Min(value = 1,message = "id不能小于1")
@ApiModelProperty(value = "任务ID", example = "1")
private Integer id;
@NotNull
@ApiModelProperty(value = "备注")
private String remark;
}
...@@ -36,6 +36,10 @@ ...@@ -36,6 +36,10 @@
<groupId>com.tykj.dev</groupId> <groupId>com.tykj.dev</groupId>
<artifactId>blockcha</artifactId> <artifactId>blockcha</artifactId>
</dependency> </dependency>
<dependency>
<groupId>com.tykj</groupId>
<artifactId>dev-file</artifactId>
</dependency>
</dependencies> </dependencies>
</project> </project>
\ No newline at end of file
...@@ -2,6 +2,7 @@ package com.tykj.dev.device.storage.controller; ...@@ -2,6 +2,7 @@ package com.tykj.dev.device.storage.controller;
import com.fasterxml.jackson.core.type.TypeReference; import com.fasterxml.jackson.core.type.TypeReference;
import com.tykj.dev.config.swagger.AutoDocument; import com.tykj.dev.config.swagger.AutoDocument;
import com.tykj.dev.device.file.service.FilesUtil;
import com.tykj.dev.device.library.repository.DeviceLibraryDao; import com.tykj.dev.device.library.repository.DeviceLibraryDao;
import com.tykj.dev.device.library.service.DeviceLibraryService; import com.tykj.dev.device.library.service.DeviceLibraryService;
import com.tykj.dev.device.library.service.DeviceLogService; import com.tykj.dev.device.library.service.DeviceLogService;
...@@ -374,6 +375,7 @@ public class StorageBillController { ...@@ -374,6 +375,7 @@ public class StorageBillController {
StorageBill storageBillEntity = storageBillService.getOne(taskBto.getBillId()); StorageBill storageBillEntity = storageBillService.getOne(taskBto.getBillId());
storageBillEntity.setReceiveUserA(userPublicService.getOne(storageBillEntity.getReceiveUseraId()).getName()); storageBillEntity.setReceiveUserA(userPublicService.getOne(storageBillEntity.getReceiveUseraId()).getName());
storageBillEntity.setReceiveUserB(userPublicService.getOne(storageBillEntity.getReceiveUserbId()).getName()); storageBillEntity.setReceiveUserB(userPublicService.getOne(storageBillEntity.getReceiveUserbId()).getName());
storageBillEntity.setReplyFileList(FilesUtil.stringFileToList(storageBillEntity.getReplyFiles()));
List<StorageBillDetailVo> storageBillDetailVos = JacksonUtil.readValue(storageBillEntity.getPackingDetail(), new TypeReference<List<StorageBillDetailVo>>() { List<StorageBillDetailVo> storageBillDetailVos = JacksonUtil.readValue(storageBillEntity.getPackingDetail(), new TypeReference<List<StorageBillDetailVo>>() {
}); });
setPackingLibrary(storageBillDetailVos); setPackingLibrary(storageBillDetailVos);
......
package com.tykj.dev.device.storage.subject.domin; package com.tykj.dev.device.storage.subject.domin;
import com.tykj.dev.device.file.entity.FileRet;
import com.tykj.dev.device.storage.subject.vo.StorageBillDetailVo; import com.tykj.dev.device.storage.subject.vo.StorageBillDetailVo;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
...@@ -163,4 +164,10 @@ public class StorageBill { ...@@ -163,4 +164,10 @@ public class StorageBill {
@ApiModelProperty(value = "StorageBillDetailVo to json") @ApiModelProperty(value = "StorageBillDetailVo to json")
@Column(name = "packing_detail",columnDefinition = "TEXT") @Column(name = "packing_detail",columnDefinition = "TEXT")
private String packingDetail; private String packingDetail;
@Column(name = "reply_files",columnDefinition = "TEXT")
private String replyFiles;
@Transient
private List<FileRet> replyFileList = new ArrayList<>();
} }
package com.tykj.dev.device.storage.subject.vo; package com.tykj.dev.device.storage.subject.vo;
import com.tykj.dev.device.file.entity.FileRet;
import com.tykj.dev.device.file.service.FilesUtil;
import com.tykj.dev.device.library.subject.vo.DeviceLibrarySaveVo; import com.tykj.dev.device.library.subject.vo.DeviceLibrarySaveVo;
import com.tykj.dev.device.storage.subject.domin.StorageBill; import com.tykj.dev.device.storage.subject.domin.StorageBill;
import com.tykj.dev.misc.utils.JacksonUtil; import com.tykj.dev.misc.utils.JacksonUtil;
...@@ -67,6 +69,10 @@ public class StorageBillSaveVo { ...@@ -67,6 +69,10 @@ public class StorageBillSaveVo {
@ApiModelProperty(value = "配发单附件url") @ApiModelProperty(value = "配发单附件url")
private String fileUrl; private String fileUrl;
// @NotNull(message = "fileName不能为空")
@ApiModelProperty(value = "批复文号附件名")
private List<FileRet> replyFiles;
// @NotNull(message = "receiveFileName不能为空") // @NotNull(message = "receiveFileName不能为空")
@ApiModelProperty(value = "入库单附件名") @ApiModelProperty(value = "入库单附件名")
private String receiveFileName; private String receiveFileName;
...@@ -99,6 +105,9 @@ public class StorageBillSaveVo { ...@@ -99,6 +105,9 @@ public class StorageBillSaveVo {
storageBillEntity.setStorageStatus(2); storageBillEntity.setStorageStatus(2);
storageBillEntity.setStorageDetail("x"); storageBillEntity.setStorageDetail("x");
storageBillEntity.setPackingDetail(JacksonUtil.toJSon(storageBillDetailVos)); storageBillEntity.setPackingDetail(JacksonUtil.toJSon(storageBillDetailVos));
if(this.replyFiles!=null&&this.replyFiles.size()>0){
storageBillEntity.setReplyFiles(FilesUtil.stringFileToList(this.replyFiles));
}
return storageBillEntity; return storageBillEntity;
} }
} }
...@@ -77,6 +77,9 @@ public class TaskBto { ...@@ -77,6 +77,9 @@ public class TaskBto {
@ApiModelProperty(value = "区块链记录id") @ApiModelProperty(value = "区块链记录id")
private String recordId; private String recordId;
@ApiModelProperty(value = "备注")
private String remark;
public TaskBto(Integer billStatus, String title, Integer parentTaskId, String nodeIdDetail, Integer billId, Integer businessType, Integer ownUnit, Integer currentPoint, String customInfo, List<Integer> involveUserIdList) { public TaskBto(Integer billStatus, String title, Integer parentTaskId, String nodeIdDetail, Integer billId, Integer businessType, Integer ownUnit, Integer currentPoint, String customInfo, List<Integer> involveUserIdList) {
this.billStatus = billStatus; this.billStatus = billStatus;
this.title = title; this.title = title;
......
...@@ -97,6 +97,9 @@ public class Task { ...@@ -97,6 +97,9 @@ public class Task {
@ApiModelProperty(value = "区块链记录id") @ApiModelProperty(value = "区块链记录id")
private String recordId; private String recordId;
@ApiModelProperty(value = "备注")
private String remark;
public Task(String title, Integer parentTaskId, String nodeIdDetail, Integer businessType, Integer billId, Integer ownUnit) { public Task(String title, Integer parentTaskId, String nodeIdDetail, Integer businessType, Integer billId, Integer ownUnit) {
this.title = title; this.title = title;
this.parentTaskId = parentTaskId; this.parentTaskId = parentTaskId;
......
...@@ -96,4 +96,7 @@ public class TaskUserVo { ...@@ -96,4 +96,7 @@ public class TaskUserVo {
@ApiModelProperty(value = "区块链记录id") @ApiModelProperty(value = "区块链记录id")
private String recordId; private String recordId;
@ApiModelProperty(value = "备注")
private String remark;
} }
...@@ -7,6 +7,7 @@ import com.tykj.dev.device.allot.subject.domin.AllotBackBill; ...@@ -7,6 +7,7 @@ import com.tykj.dev.device.allot.subject.domin.AllotBackBill;
import com.tykj.dev.device.allot.subject.domin.AllotBill; import com.tykj.dev.device.allot.subject.domin.AllotBill;
import com.tykj.dev.device.apply.service.DeviceApplyBillService; import com.tykj.dev.device.apply.service.DeviceApplyBillService;
import com.tykj.dev.device.apply.subject.domin.DeviceApplyBill; import com.tykj.dev.device.apply.subject.domin.DeviceApplyBill;
import com.tykj.dev.device.file.service.FilesUtil;
import com.tykj.dev.device.library.service.DeviceLibraryService; import com.tykj.dev.device.library.service.DeviceLibraryService;
import com.tykj.dev.device.library.subject.domin.DeviceLibrary; import com.tykj.dev.device.library.subject.domin.DeviceLibrary;
import com.tykj.dev.device.library.subject.vo.DeviceLibrarySelectVo; import com.tykj.dev.device.library.subject.vo.DeviceLibrarySelectVo;
...@@ -131,6 +132,7 @@ public class TaskSelectController { ...@@ -131,6 +132,7 @@ public class TaskSelectController {
StorageBill storageBillEntity = storageBillService.getOne(billId); StorageBill storageBillEntity = storageBillService.getOne(billId);
storageBillEntity.setReceiveUserA(userPublicService.getOne(storageBillEntity.getReceiveUseraId()).getName()); storageBillEntity.setReceiveUserA(userPublicService.getOne(storageBillEntity.getReceiveUseraId()).getName());
storageBillEntity.setReceiveUserB(userPublicService.getOne(storageBillEntity.getReceiveUserbId()).getName()); storageBillEntity.setReceiveUserB(userPublicService.getOne(storageBillEntity.getReceiveUserbId()).getName());
storageBillEntity.setReplyFileList(FilesUtil.stringFileToList(storageBillEntity.getReplyFiles()));
list.add(storageBillEntity); list.add(storageBillEntity);
String str = storageBillEntity.getStorageDetail(); String str = storageBillEntity.getStorageDetail();
List<Integer> list1 = StringSplitUtil.userIdSplit(str); List<Integer> list1 = StringSplitUtil.userIdSplit(str);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论