OMS-商业合作伙伴页面查询

This commit is contained in:
zhaoqing
2026-04-28 16:59:41 +08:00
parent 7a11d68b8f
commit 8f5bf53620
5 changed files with 155 additions and 0 deletions
@@ -0,0 +1,51 @@
package com.mhd.oms.application.service.businessPartner;
import com.mhd.common.core.web.domain.AjaxResult;
import com.mhd.common.core.web.page.TableDataInfo;
import com.mhd.oms.interfaces.dto.businessPartner.BusinessPartnerDTO;
import com.mhd.system.api.UserServiceFeign;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
@Service
@Slf4j
public class BusinessPartnerApplicationService {
@Resource
private UserServiceFeign userServiceFeign;
public TableDataInfo queryShipperPage(BusinessPartnerDTO businessPartnerDTO) {
AjaxResult<?> result = userServiceFeign.userShipperList(
businessPartnerDTO.getPageNum(),
businessPartnerDTO.getPageSize(),
businessPartnerDTO.getUserAccount(),
businessPartnerDTO.getShipperEnterpriseName(),
businessPartnerDTO.getOrganizationId(),
businessPartnerDTO.getOrganizationName(),
businessPartnerDTO.getCreateTimeFrom(),
businessPartnerDTO.getCreateTimeTo(),
businessPartnerDTO.getUpdateTimeFrom(),
businessPartnerDTO.getUpdateTimeTo(),
businessPartnerDTO.getShipperType()
);
if ("200".equals((String.valueOf(result.get("code"))))){
List<?> list = (List<?>) result.get("data");
TableDataInfo tableDataInfo = new TableDataInfo();
tableDataInfo.setData(list);
tableDataInfo.setTotal(list.size());
tableDataInfo.setCode(200);
return tableDataInfo;
}
return null;
}
}
@@ -0,0 +1,52 @@
package com.mhd.oms.interfaces.dto.businessPartner;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
@Data
@ApiModel(description = "商业合作伙伴DTO")
public class BusinessPartnerDTO {
@ApiModelProperty(value = "登录账号")
private String userAccount;
@ApiModelProperty(value = "企业名称")
private String shipperEnterpriseName;
@ApiModelProperty(value = "组织ID")
private Long organizationId;
@ApiModelProperty(value = "组织名称")
private String organizationName;
@ApiModelProperty(value = "创建时间起")
private String createTimeFrom;
@ApiModelProperty(value = "创建时间止")
private String createTimeTo;
@ApiModelProperty(value = "更新时间起")
private String updateTimeFrom;
@ApiModelProperty(value = "更新时间止")
private String updateTimeTo;
@ApiModelProperty(value = "推送时间起")
private String pushTimeFrom;
@ApiModelProperty(value = "推送时间止")
private String pushTimeTo;
@ApiModelProperty(value = "货主类型:1-个人,2-企业")
private Integer shipperType;
@ApiModelProperty(value = "页码")
private Integer pageNum = 1;
@ApiModelProperty(value = "每页数量")
private Integer pageSize = 10;
}
@@ -0,0 +1,30 @@
package com.mhd.oms.interfaces.facade.businessPartner;
import com.mhd.common.core.web.page.TableDataInfo;
import com.mhd.oms.application.service.businessPartner.BusinessPartnerApplicationService;
import com.mhd.oms.interfaces.dto.businessPartner.BusinessPartnerDTO;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.annotation.Resource;
@RestController
@RequestMapping("/businessPartnerApi")
public class BusinessPartnerApi {
@Resource
private BusinessPartnerApplicationService businessPartnerApplicationService;
@ApiOperation("商业合作伙伴-分页查询委托方列表")
@GetMapping("/shippperList")
public TableDataInfo shipperList(BusinessPartnerDTO businessPartnerDTO){
return businessPartnerApplicationService.queryShipperPage(businessPartnerDTO);
}
}