oms业务单修改
This commit is contained in:
+1
-1
@@ -41,7 +41,7 @@ public class ExecuteOrderApplicationService {
|
||||
/**
|
||||
* 新增【请填写功能名称】
|
||||
*/
|
||||
public Boolean insert(ExecuteOrderDO executeOrderDO) {
|
||||
public Long insert(ExecuteOrderDO executeOrderDO) {
|
||||
|
||||
return executeOrderDomainService.insert(executeOrderDO);
|
||||
}
|
||||
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package com.mhd.oms.domain.businessDocumentCargoInfo.repository;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mhd.oms.interfaces.assembler.businessDocumentCargoInfo.BusinessDocumentCargoInfo;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author: brb
|
||||
* @description:
|
||||
* @create: 2026-03-30 17:38
|
||||
*/
|
||||
public interface BusinessDocumentCargoInfoMapper extends BaseMapper<BusinessDocumentCargoInfo> {
|
||||
void insertBatch(@Param("list") List<BusinessDocumentCargoInfo> businessDocumentCargoInfoList);
|
||||
}
|
||||
+37
@@ -694,4 +694,41 @@ public class BusinessDocumentOrder extends BaseVOEntity{
|
||||
|
||||
@ApiModelProperty("预约单号")
|
||||
private String reservationOrderNumber;
|
||||
|
||||
|
||||
@ApiModelProperty("执行单id")
|
||||
private String executeOrderId;
|
||||
|
||||
@ApiModelProperty("执行单号")
|
||||
private String executeOrderNumber;
|
||||
|
||||
@ApiModelProperty("收款账户id")
|
||||
private String paymentAccountId;
|
||||
|
||||
@ApiModelProperty("收款账户信息")
|
||||
private String accountInformation;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
private Integer businessCategory;
|
||||
|
||||
@ApiModelProperty(value = "组织地址")
|
||||
private String companyAddress;
|
||||
|
||||
@ApiModelProperty(value = "组织公司名称")
|
||||
private String companyName;
|
||||
|
||||
// @ApiModelProperty(value = "组织公司名称英文")
|
||||
// private String companyNameEn;
|
||||
//
|
||||
// @ApiModelProperty(value = "负责人姓名")
|
||||
// private String contact;
|
||||
//
|
||||
// @ApiModelProperty(value = "组织负责人id")
|
||||
// private String contactPhone;
|
||||
//
|
||||
@ApiModelProperty(value = "账户名称")
|
||||
private String accountName;
|
||||
//
|
||||
// @ApiModelProperty(value = "开户银行")
|
||||
// private String accountBank;
|
||||
}
|
||||
|
||||
+42
-22
@@ -1,6 +1,7 @@
|
||||
package com.mhd.oms.domain.businessDocumentOrder.repository.persistence;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
@@ -17,6 +18,7 @@ import com.mhd.system.api.model.LoginUser;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.rmi.ServerException;
|
||||
import java.util.ArrayList;
|
||||
@@ -120,33 +122,51 @@ public class BusinessDocumentOrderImpl extends ServiceImpl<BusinessDocumentOrder
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean execute(Long[] ids) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();//获取登录人
|
||||
for (Long id:ids){
|
||||
BusinessDocumentOrder businessDocumentOrder=businessDocumentOrderMapper.selectById(id);
|
||||
if (ObjectUtil.isNotNull(businessDocumentOrder)){
|
||||
businessDocumentOrder.setExecuteId(loginUser.getUserid());
|
||||
businessDocumentOrder.setExecuteStatus(2L);
|
||||
businessDocumentOrder.setExecuteTime(new Date());
|
||||
businessDocumentOrder.setExecutor(loginUser.getUsername());
|
||||
businessDocumentOrder.setOrderStatus(2L);
|
||||
businessDocumentOrderMapper.updateById(businessDocumentOrder);
|
||||
ExecuteOrderDO executeOrderDO=new ExecuteOrderDO();
|
||||
executeOrderDO.setBusinessDocumentId(id);
|
||||
executeOrderDO.setBusinessDocumentNumber(businessDocumentOrder.getGoodsNumber());
|
||||
executeOrderDO.setGoodsNumber(businessDocumentOrder.getGoodsNumber());
|
||||
executeOrderDO.setCreateBy(loginUser.getUserid());
|
||||
executeOrderDO.setCreateTime(new Date());
|
||||
executeOrderDO.setDelFlag(1);
|
||||
executeOrderDO.setOrganizationId(businessDocumentOrder.getOrganizationId());
|
||||
executeOrderDO.setOrgName(businessDocumentOrder.getOrgName());
|
||||
executeOrderDO.setTopOrganizationId(businessDocumentOrder.getTopOrganizationId());
|
||||
executeOrderDomainService.insert(executeOrderDO);
|
||||
try {
|
||||
for (Long id:ids){
|
||||
BusinessDocumentOrder businessDocumentOrder=businessDocumentOrderMapper.selectById(id);
|
||||
|
||||
if (ObjectUtil.isNotNull(businessDocumentOrder)){
|
||||
ExecuteOrder objects = executeOrderMapper.selectOne(new LambdaQueryWrapper<ExecuteOrder>().eq(ExecuteOrder::getBusinessDocumentId, id).eq(ExecuteOrder::getDelFlag,1) .last("LIMIT 1")
|
||||
);
|
||||
if (ObjectUtil.isNotNull(objects)) {
|
||||
throw new ServerException("业务单已生成执行单,请先取消执行单");
|
||||
}
|
||||
|
||||
// 先创建执行单
|
||||
ExecuteOrderDO executeOrderDO=new ExecuteOrderDO();
|
||||
executeOrderDO.setBusinessDocumentId(id);
|
||||
executeOrderDO.setBusinessDocumentNumber(businessDocumentOrder.getGoodsNumber());
|
||||
executeOrderDO.setGoodsNumber(businessDocumentOrder.getGoodsNumber());
|
||||
executeOrderDO.setCreateBy(loginUser.getUserid());
|
||||
executeOrderDO.setCreateTime(new Date());
|
||||
executeOrderDO.setDelFlag(1);
|
||||
executeOrderDO.setOrganizationId(businessDocumentOrder.getOrganizationId());
|
||||
executeOrderDO.setOrgName(businessDocumentOrder.getOrgName());
|
||||
executeOrderDO.setTopOrganizationId(businessDocumentOrder.getTopOrganizationId());
|
||||
|
||||
Long executeOrderId = executeOrderDomainService.insert(executeOrderDO);
|
||||
|
||||
// 更新业务单状态和执行单信息(只保存一次)
|
||||
businessDocumentOrder.setExecuteId(loginUser.getUserid());
|
||||
businessDocumentOrder.setExecuteStatus(2L);
|
||||
businessDocumentOrder.setExecuteTime(new Date());
|
||||
businessDocumentOrder.setExecutor(loginUser.getUsername());
|
||||
businessDocumentOrder.setOrderStatus(2L);
|
||||
businessDocumentOrder.setExecuteOrderId(String.valueOf(executeOrderId));
|
||||
businessDocumentOrder.setExecuteOrderNumber(businessDocumentOrder.getGoodsNumber());
|
||||
businessDocumentOrderMapper.updateById(businessDocumentOrder);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return true;
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
throw new RuntimeException("执行失败:" + e.getMessage());
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
+36
@@ -706,4 +706,40 @@ public class BusinessDocumentOrderPO extends BaseVOEntity{
|
||||
|
||||
@ApiModelProperty("预约单号")
|
||||
private String reservationOrderNumber;
|
||||
|
||||
@ApiModelProperty("执行单id")
|
||||
private String executeOrderId;
|
||||
|
||||
@ApiModelProperty("执行单号")
|
||||
private String executeOrderNumber;
|
||||
|
||||
@ApiModelProperty("收款账户id")
|
||||
private String paymentAccountId;
|
||||
|
||||
@ApiModelProperty("收款账户信息")
|
||||
private String accountInformation;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
private Integer businessCategory;
|
||||
|
||||
@ApiModelProperty(value = "组织地址")
|
||||
private String companyAddress;
|
||||
|
||||
@ApiModelProperty(value = "组织公司名称")
|
||||
private String companyName;
|
||||
|
||||
@ApiModelProperty(value = "组织公司名称英文")
|
||||
private String companyNameEn;
|
||||
|
||||
@ApiModelProperty(value = "负责人姓名")
|
||||
private String contact;
|
||||
|
||||
@ApiModelProperty(value = "组织负责人id")
|
||||
private String contactPhone;
|
||||
|
||||
@ApiModelProperty(value = "账户名称")
|
||||
private String accountName;
|
||||
|
||||
@ApiModelProperty(value = "开户银行")
|
||||
private String accountBank;
|
||||
}
|
||||
|
||||
+40
@@ -2,6 +2,7 @@ package com.mhd.oms.domain.businessDocumentOrder.repository.todo;
|
||||
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.oms.domain.businessDocumentCargoMulti.entity.BusinessDocumentCargoMulti;
|
||||
import com.mhd.oms.interfaces.assembler.businessDocumentCargoInfo.BusinessDocumentCargoInfo;
|
||||
import com.mhd.oms.interfaces.dto.businessDocumentAddressMulti.BusinessDocumentAddressMultiDTO;
|
||||
import com.mhd.oms.interfaces.dto.businessDocumentCargoMulti.BusinessDocumentCargoMultiDTO;
|
||||
import lombok.Data;
|
||||
@@ -728,12 +729,51 @@ public class BusinessDocumentOrderDO extends BaseVOEntity{
|
||||
@ApiModelProperty("预约单号")
|
||||
private String reservationOrderNumber;
|
||||
|
||||
@ApiModelProperty("执行单id")
|
||||
private String executeOrderId;
|
||||
|
||||
@ApiModelProperty("执行单号")
|
||||
private String executeOrderNumber;
|
||||
|
||||
@ApiModelProperty("收款账户id")
|
||||
private String paymentAccountId;
|
||||
|
||||
@ApiModelProperty("收款账户信息")
|
||||
private String accountInformation;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
private Integer businessCategory;
|
||||
|
||||
@ApiModelProperty(value = "组织地址")
|
||||
private String companyAddress;
|
||||
|
||||
@ApiModelProperty(value = "组织公司名称")
|
||||
private String companyName;
|
||||
|
||||
@ApiModelProperty(value = "组织公司名称英文")
|
||||
private String companyNameEn;
|
||||
|
||||
@ApiModelProperty(value = "负责人姓名")
|
||||
private String contact;
|
||||
|
||||
@ApiModelProperty(value = "组织负责人id")
|
||||
private String contactPhone;
|
||||
|
||||
@ApiModelProperty(value = "账户名称")
|
||||
private String accountName;
|
||||
|
||||
@ApiModelProperty(value = "开户银行")
|
||||
private String accountBank;
|
||||
|
||||
@ApiModelProperty("业务单地址集合")
|
||||
private List<BusinessDocumentAddressMultiDTO> businessDocumentAddressMultiDTOList;
|
||||
|
||||
@ApiModelProperty("业务单货物集合")
|
||||
private List<BusinessDocumentCargoMultiDTO> businessDocumentCargoMultiList;
|
||||
|
||||
@ApiModelProperty("业务单货物详情集合")
|
||||
private List<BusinessDocumentCargoInfo> cargoInfoList;
|
||||
|
||||
@ApiModelProperty(value = "装货地址集合")
|
||||
private List<BusinessDocumentAddressMultiDTO> loadingAddressList;
|
||||
@ApiModelProperty(value = "卸货地址集合")
|
||||
|
||||
+8
-1
@@ -15,6 +15,7 @@ import com.mhd.oms.domain.businessDocumentCargoMulti.entity.BusinessDocumentCarg
|
||||
import com.mhd.oms.domain.businessDocumentCargoMulti.repository.mapper.BusinessDocumentCargoMultiMapper;
|
||||
import com.mhd.oms.domain.businessDocumentOrder.entity.BusinessDocumentOrder;
|
||||
import com.mhd.oms.domain.businessDocumentOrder.repository.facade.IBusinessDocumentOrderService;
|
||||
import com.mhd.oms.domain.businessDocumentOrder.repository.mapper.BusinessDocumentOrderMapper;
|
||||
import com.mhd.oms.domain.businessDocumentOrder.repository.po.BusinessDocumentOrderPO;
|
||||
import com.mhd.oms.domain.businessDocumentOrder.repository.todo.BusinessDocumentOrderDO;
|
||||
import com.mhd.oms.domain.orderType.entity.OrderType;
|
||||
@@ -57,6 +58,9 @@ public class BusinessDocumentOrderDomainService {
|
||||
|
||||
@Resource
|
||||
private BusinessDocumentAddressMultiMapper businessDocumentAddressMultiMapper;
|
||||
|
||||
@Resource
|
||||
private BusinessDocumentOrderMapper businessDocumentOrderMapper;
|
||||
/**
|
||||
* 分页查询【请填写功能名称】列表
|
||||
*/
|
||||
@@ -210,6 +214,8 @@ public class BusinessDocumentOrderDomainService {
|
||||
tmsOrder.setFreighterName(firstAddress.getContactName());
|
||||
tmsOrder.setLoadingPhone(firstAddress.getContactPhone());
|
||||
tmsOrder.setLoadingDate(firstAddress.getLayDate());
|
||||
tmsOrder.setAppointShipper(businessDocumentOrderDO.getAppointShipper());
|
||||
tmsOrder.setAppointShipperId(businessDocumentOrderDO.getAppointShipperId());
|
||||
|
||||
tmsOrder.setUnloadAreaId(lastAddress.getAreaCode());
|
||||
tmsOrder.setUnloadName(lastAddress.getAreaCode());
|
||||
@@ -300,7 +306,8 @@ public class BusinessDocumentOrderDomainService {
|
||||
if (businessDocumentOrderDO.getTopOrganizationId() != null) {
|
||||
tmsOrder.setTopOrganizationId(businessDocumentOrderDO.getTopOrganizationId());
|
||||
}
|
||||
boolean istrue=businessDocumentOrderService.insert(businessDocumentOrderDO);
|
||||
// boolean istrue=businessDocumentOrderService.insert(businessDocumentOrderDO);
|
||||
boolean istrue = businessDocumentOrderMapper.insert(tmsOrder) > 0;
|
||||
//保存货物信息及地址信息
|
||||
|
||||
saveAddress2CargoInfo(tmsOrder.getId(), allCargoList, loadingAddressList, unloadAddressList);
|
||||
|
||||
+1
-1
@@ -23,7 +23,7 @@ public interface IExecuteOrderService extends IService<ExecuteOrder>
|
||||
/**
|
||||
* 新增【请填写功能名称】
|
||||
*/
|
||||
public Boolean insert(ExecuteOrderDO executeOrderDO);
|
||||
public Long insert(ExecuteOrderDO executeOrderDO);
|
||||
|
||||
/**
|
||||
* 修改【请填写功能名称】
|
||||
|
||||
+3
-2
@@ -67,10 +67,11 @@ public class ExecuteOrderImpl extends ServiceImpl<ExecuteOrderMapper, ExecuteOrd
|
||||
* 新增【请填写功能名称】
|
||||
*/
|
||||
@Override
|
||||
public Boolean insert(ExecuteOrderDO executeOrderDO) {
|
||||
public Long insert(ExecuteOrderDO executeOrderDO) {
|
||||
ExecuteOrder executeOrder = new ExecuteOrder();
|
||||
BeanUtils.copyProperties(executeOrderDO,executeOrder);
|
||||
return this.save(executeOrder);
|
||||
this.save(executeOrder);
|
||||
return executeOrder.getId();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+1
-1
@@ -33,7 +33,7 @@ public class ExecuteOrderDomainService {
|
||||
/**
|
||||
* 新增【请填写功能名称】
|
||||
*/
|
||||
public Boolean insert(ExecuteOrderDO executeOrderDO) {
|
||||
public Long insert(ExecuteOrderDO executeOrderDO) {
|
||||
|
||||
return executeOrderService.insert(executeOrderDO);
|
||||
}
|
||||
|
||||
+98
@@ -0,0 +1,98 @@
|
||||
package com.mhd.oms.interfaces.assembler.businessDocumentCargoInfo;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @author: brb
|
||||
* @description:
|
||||
* @create: 2026-03-30 17:15
|
||||
*/
|
||||
@Data
|
||||
public class BusinessDocumentCargoInfo {
|
||||
|
||||
@ApiModelProperty(value = "ID")
|
||||
private String id;
|
||||
@ApiModelProperty(value = "组织表ID")
|
||||
private Long organizationId;
|
||||
@ApiModelProperty(value = "组织名称")
|
||||
private String organizationName;
|
||||
@ApiModelProperty(value = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
private Date createTime;
|
||||
@ApiModelProperty(value = "创建人用户ID")
|
||||
private Long createBy;
|
||||
@ApiModelProperty(value = "创建人姓名")
|
||||
private String createByName;
|
||||
@ApiModelProperty(value = "修改时间")
|
||||
private Date updateTime;
|
||||
// @ApiModelProperty(value = "修改人用户ID")
|
||||
// private Long updateBy;
|
||||
@ApiModelProperty(value = "修改人姓名")
|
||||
private String updateByName;
|
||||
@ApiModelProperty(value = "删除标记:0-无状态,1-正常,2-已删除")
|
||||
private Integer delFlag;
|
||||
@ApiModelProperty(value = "货单号")
|
||||
private String orderId;
|
||||
@ApiModelProperty(value = "货物类型ID")
|
||||
private String goodsTypeId;
|
||||
@ApiModelProperty(value = "货物类型")
|
||||
private String goodsType;
|
||||
@ApiModelProperty(value = "货物名称ID")
|
||||
private String goodsNameId;
|
||||
@ApiModelProperty(value = "货物名称")
|
||||
private String goodsName;
|
||||
@ApiModelProperty(value = "货物数量")
|
||||
private BigDecimal cargoNum;
|
||||
@ApiModelProperty(value = "货物重量")
|
||||
private BigDecimal cargoWeight;
|
||||
|
||||
@ApiModelProperty("体积")
|
||||
private BigDecimal cargoVolume;
|
||||
|
||||
@ApiModelProperty("内容")
|
||||
private String cargoContent;
|
||||
@ApiModelProperty(value = "重量单位ID")
|
||||
private String weightUnitId;
|
||||
@ApiModelProperty(value = "重量单位名称")
|
||||
private String weightUnit;
|
||||
@ApiModelProperty(value = "数量单位ID")
|
||||
private String quantityUnitId;
|
||||
@ApiModelProperty(value = "数量单位名称")
|
||||
private String quantityUnit;
|
||||
|
||||
@ApiModelProperty("货物名称")
|
||||
private String cargoName;
|
||||
|
||||
@ApiModelProperty("货物单位ID")
|
||||
private String cargoUnitId;
|
||||
|
||||
@ApiModelProperty("货物单位名字")
|
||||
private String cargoUnitName;
|
||||
|
||||
@ApiModelProperty("整机表编号")
|
||||
private String machineCode;
|
||||
|
||||
@ApiModelProperty("是否为库存")
|
||||
private boolean stockFlag;
|
||||
|
||||
@ApiModelProperty("货物重量 罐车运输专有字段")
|
||||
private BigDecimal cargoTonnage;
|
||||
|
||||
@ApiModelProperty("价格")
|
||||
private BigDecimal unitPrice;
|
||||
|
||||
@ApiModelProperty("货物类型标识:STOCK-库存,MATERIAL-物料,MANUAL-手动输入")
|
||||
private String cargoType;
|
||||
|
||||
@ApiModelProperty(value = "删除标记:0-无状态,1-正常,2-已删除")
|
||||
private Integer inventoryStatus;
|
||||
|
||||
@ApiModelProperty("货物备注")
|
||||
private String remark;
|
||||
|
||||
}
|
||||
+1
@@ -59,6 +59,7 @@ public class BusinessDocumentOrderAssembler {
|
||||
businessDocumentOrderDO.setUpdateTime(new Date());
|
||||
businessDocumentOrderDO.setDelFlag(1);
|
||||
}
|
||||
// businessDocumentOrderDO.setBusinessDocumentCargoMultiList(businessDocumentOrderDTO.getBusinessDocumentCargoMultiDTOList());
|
||||
return businessDocumentOrderDO;
|
||||
}
|
||||
|
||||
|
||||
+53
-1
@@ -5,6 +5,7 @@ import com.mhd.oms.domain.businessDocumentAddressMulti.entity.BusinessDocumentAd
|
||||
import com.mhd.oms.domain.businessDocumentAddressMulti.repository.todo.BusinessDocumentAddressMultiDO;
|
||||
import com.mhd.oms.domain.businessDocumentCargoMulti.entity.BusinessDocumentCargoMulti;
|
||||
import com.mhd.oms.interfaces.dto.businessDocumentAddressMulti.BusinessDocumentAddressMultiDTO;
|
||||
import com.mhd.oms.interfaces.dto.businessDocumentCargoMulti.BusinessDocumentCargoMultiDTO;
|
||||
import lombok.Data;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
@@ -42,6 +43,16 @@ public class BusinessDocumentOrderDTO extends BaseVOEntity{
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String createCompanyId;
|
||||
|
||||
@ApiModelProperty(value = "创建开始日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date createStartTime;
|
||||
|
||||
@ApiModelProperty(value = "创建结束日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date createEndTime;
|
||||
|
||||
@ApiModelProperty("$column.columnComment")
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String goodsNumber;
|
||||
@@ -706,11 +717,52 @@ public class BusinessDocumentOrderDTO extends BaseVOEntity{
|
||||
@ApiModelProperty("预约单号")
|
||||
private String reservationOrderNumber;
|
||||
|
||||
@ApiModelProperty("执行单id")
|
||||
private String executeOrderId;
|
||||
|
||||
@ApiModelProperty("执行单号")
|
||||
private String executeOrderNumber;
|
||||
|
||||
@ApiModelProperty("收款账户id")
|
||||
private String paymentAccountId;
|
||||
|
||||
@ApiModelProperty("收款账户信息")
|
||||
private String accountInformation;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
private Integer businessCategory;
|
||||
|
||||
@ApiModelProperty(value = "组织地址")
|
||||
private String companyAddress;
|
||||
|
||||
@ApiModelProperty(value = "组织公司名称")
|
||||
private String companyName;
|
||||
|
||||
@ApiModelProperty(value = "组织公司名称英文")
|
||||
private String companyNameEn;
|
||||
|
||||
@ApiModelProperty(value = "负责人姓名")
|
||||
private String contact;
|
||||
|
||||
@ApiModelProperty(value = "组织负责人id")
|
||||
private String contactPhone;
|
||||
|
||||
@ApiModelProperty(value = "账户名称")
|
||||
private String accountName;
|
||||
|
||||
@ApiModelProperty(value = "开户银行")
|
||||
private String accountBank;
|
||||
|
||||
@ApiModelProperty("业务单地址集合")
|
||||
private List<BusinessDocumentAddressMultiDTO> businessDocumentAddressMultiDTOList;
|
||||
|
||||
|
||||
@ApiModelProperty("业务单货物集合")
|
||||
private List<BusinessDocumentCargoMulti> businessDocumentCargoMultiList;
|
||||
private List<BusinessDocumentCargoMulti> businessDocumentCargoMultiList1;
|
||||
|
||||
@ApiModelProperty("业务单货物集合")
|
||||
private List<BusinessDocumentCargoMultiDTO> businessDocumentCargoMultiList;
|
||||
|
||||
|
||||
@ApiModelProperty(value = "装货地址集合")
|
||||
private List<BusinessDocumentAddressMultiDTO> loadingAddressList;
|
||||
|
||||
+6
-2
@@ -10,6 +10,7 @@ import com.mhd.oms.domain.businessDocumentOrder.repository.todo.BusinessDocument
|
||||
import com.mhd.oms.domain.businessDocumentOrder.repository.po.BusinessDocumentOrderPO;
|
||||
import com.mhd.oms.application.service.businessDocumentOrder.BusinessDocumentOrderApplicationService;
|
||||
import com.mhd.oms.interfaces.assembler.businessDocumentOrder.BusinessDocumentOrderAssembler;
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import javax.annotation.Resource;
|
||||
import com.mhd.common.core.web.controller.BaseController;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
@@ -35,11 +36,14 @@ public class BusinessDocumentOrderApi extends BaseController{
|
||||
*/
|
||||
@ApiOperation("查询【业务单】列表")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(BusinessDocumentOrderDTO businessDocumentOrderDTO)
|
||||
public TableDataInfo list(BusinessDocumentOrderDTO businessDocumentOrderDTO,
|
||||
@RequestParam(value = "pageNo", required = false, defaultValue = "1") Integer pageNo,
|
||||
@RequestParam(value = "pageSize", required = false, defaultValue = "20") Integer pageSize)
|
||||
{
|
||||
//转换实体
|
||||
BusinessDocumentOrderDO businessDocumentOrderDO = businessDocumentOrderAssembler.toDO(businessDocumentOrderDTO);
|
||||
startPage();
|
||||
// 使用 PageHelper 手动分页,支持 pageNo 参数
|
||||
PageHelper.startPage(pageNo, pageSize);
|
||||
List<BusinessDocumentOrderPO> list = businessDocumentOrderApplicationService.queryList(businessDocumentOrderDO);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
+2
-1
@@ -56,7 +56,8 @@ public class ExecuteOrderApi extends BaseController{
|
||||
if(executeOrderDTO.getId() != null){
|
||||
return toAjax(executeOrderApplicationService.update(executeOrderDO));
|
||||
}else {
|
||||
return toAjax(executeOrderApplicationService.insert(executeOrderDO));
|
||||
Long executeOrderId = executeOrderApplicationService.insert(executeOrderDO);
|
||||
return executeOrderId != null ? success() : error();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.mhd.oms.domain.businessDocumentCargoInfo.repository.BusinessDocumentCargoInfoMapper">
|
||||
|
||||
<insert id="insertBatch"></insert>
|
||||
</mapper>
|
||||
+2
-1
@@ -194,7 +194,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
and CREATE_TIME >= #{createStartTime}
|
||||
</if>
|
||||
<if test="createEndTime != null">
|
||||
and CREATE_TIME <= DATE_ADD(#{createEndTime}, INTERVAL 1 DAY - 1 SECOND)
|
||||
and CREATE_TIME <= #{createEndTime} + 1 - 1/86400
|
||||
</if>
|
||||
|
||||
<!-- <if test="updateTime != null ">-->
|
||||
@@ -669,6 +669,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<select id="queryList" parameterType="com.mhd.oms.domain.businessDocumentOrder.repository.todo.BusinessDocumentOrderDO" resultMap="BusinessDocumentOrderResult">
|
||||
<include refid="selectBusinessDocumentOrderPo"/>
|
||||
<include refid="selectBusinessDocumentOrderPo1"/>
|
||||
order by create_time desc
|
||||
</select>
|
||||
<select id="selectByMakerCodeNc" parameterType="java.lang.String" resultType="java.lang.String">
|
||||
select DOCUMENT_PREPARER_NC_code from NGWL_TEST_USER."USER" where USER_ID = #{salesmanCodeNc}</select>
|
||||
|
||||
Reference in New Issue
Block a user