代码提交

This commit is contained in:
huangzj
2023-10-26 10:03:06 +08:00
parent e069b440b8
commit 27783fe396
6 changed files with 29 additions and 4 deletions

View File

@@ -16,6 +16,7 @@ import com.njcn.csdevice.pojo.po.CsEquipmentDeliveryPO;
import com.njcn.csdevice.pojo.vo.CsEquipmentDeliveryVO;
import com.njcn.csdevice.pojo.vo.DeviceManagerVO;
import com.njcn.csdevice.pojo.vo.ProjectEquipmentVO;
import com.njcn.csdevice.service.CsDevModelRelationService;
import com.njcn.csdevice.service.CsEquipmentDeliveryService;
import com.njcn.csdevice.service.IMqttUserService;
import com.njcn.csdevice.utils.ExcelStyleUtil;
@@ -57,6 +58,7 @@ public class EquipmentDeliveryController extends BaseController {
private final CsEquipmentDeliveryService csEquipmentDeliveryService;
private final IMqttUserService mqttUserService;
private final CsDevModelRelationService csDevModelRelationService;
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
@PostMapping("/addEquipmentDelivery")
@@ -141,6 +143,8 @@ public class EquipmentDeliveryController extends BaseController {
List<CsEquipmentDeliveryDTO> collect = csEquipmentDeliveryPOS.stream().map(temp -> {
CsEquipmentDeliveryDTO csEquipmentDeliveryDTO = new CsEquipmentDeliveryDTO();
BeanUtils.copyProperties(temp, csEquipmentDeliveryDTO);
String versionByDevId = csDevModelRelationService.getVersionByDevId(temp.getId());
csEquipmentDeliveryDTO.setProgramVersionName(versionByDevId);
return csEquipmentDeliveryDTO;
}).collect(Collectors.toList());
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, collect, methodDescribe);