提交 ce1446bd authored 作者: huyufan's avatar huyufan

货主信息接口

上级 5b5e36c1
...@@ -2,6 +2,7 @@ package com.clx.performance.feign; ...@@ -2,6 +2,7 @@ package com.clx.performance.feign;
import com.clx.open.sdk.request.dto.OwnerCancelResidueWeightDTO; import com.clx.open.sdk.request.dto.OwnerCancelResidueWeightDTO;
import com.clx.performance.param.pc.OrderCancelParam; import com.clx.performance.param.pc.OrderCancelParam;
import com.clx.performance.vo.pc.OwnerAccountAllVO;
import com.msl.common.result.Result; import com.msl.common.result.Result;
import org.springframework.cloud.openfeign.FeignClient; import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
...@@ -20,4 +21,8 @@ public interface PerformanceSDKFeign { ...@@ -20,4 +21,8 @@ public interface PerformanceSDKFeign {
@GetMapping(value = {"clx-performance/feign/sdk/orderCancelResidueWeight"}) @GetMapping(value = {"clx-performance/feign/sdk/orderCancelResidueWeight"})
Result<OwnerCancelResidueWeightDTO> orderCancelResidueWeight(@RequestParam(value = "orderNo") String orderNo, @RequestParam(value = "optionType") String optionType); Result<OwnerCancelResidueWeightDTO> orderCancelResidueWeight(@RequestParam(value = "orderNo") String orderNo, @RequestParam(value = "optionType") String optionType);
@GetMapping(value = {"clx-performance/feign/sdk/accountAllInfo"})
Result<OwnerAccountAllVO> accountAllInfo(@RequestParam Long userNo);
} }
package com.clx.performance.vo.feign;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
/**
* @Description
* @Author aiqingguo
* @Date 2023-10-19 16:33:52
* @Version 1.0
*/
@Getter
@Setter
public class OwnerInfoVO {
@ApiModelProperty("用户编号")
private Long userNo;
@ApiModelProperty("姓名")
private String name;
@ApiModelProperty("手机号码")
private String mobile;
@ApiModelProperty("货主类型 1企业 2个人")
private Integer ownerType;
@ApiModelProperty("所属银行")
private String ownerAccountBank;
@ApiModelProperty("开户行")
private String ownerOpenBank;
@ApiModelProperty("开户行号")
private String ownerOpenBankNumber;
@ApiModelProperty("户名")
private String ownerAccountName;
@ApiModelProperty("银行账户")
private String ownerBankAccount;
@ApiModelProperty("结算账期 1拉运完成结 2月结")
private Integer settlementAccountPeriod;
@ApiModelProperty("结算方式 1装车净重 2卸车净重")
private Integer settlementWay;
@ApiModelProperty("冻结方式 1自动冻结 2手动冻结")
private Integer freezeSetting;
@ApiModelProperty("公司名称")
private String companyName;
@ApiModelProperty("法人姓名")
private String legalName;
@ApiModelProperty("法人身份证")
private String legalCardNo;
@ApiModelProperty(value = "法人手机号", example = "")
private String legalMobile;
@ApiModelProperty("营业执照图片地址")
private String companyBusinessImg;
@ApiModelProperty("营业执照编号")
private String companyBusinessNo;
@ApiModelProperty("公司税号")
private String companyTaxCode;
@ApiModelProperty("公司地址")
private String companyAddress;
@ApiModelProperty("公司联系电话")
private String companyTelephone;
@ApiModelProperty("公司银行账户")
private String companyBankAccount;
@ApiModelProperty("公司开户行")
private String companyOpenBank;
@ApiModelProperty("统一社会信用代码")
private String companyGroupCode;
@ApiModelProperty("联系人")
private String contactsName;
@ApiModelProperty("联系电话")
private String contactsTelephone;
@ApiModelProperty("联系地址")
private String contactsAddress;
@ApiModelProperty("网络货运货主编码")
private String transportOwnerCode;
@ApiModelProperty("创建时间")
private String createTime;
}
package com.clx.performance.vo.pc; package com.clx.performance.vo.pc;
import com.clx.performance.vo.feign.OwnerInfoVO;
import com.msl.common.convertor.field.Converted; import com.msl.common.convertor.field.Converted;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.Data; import lombok.Data;
...@@ -17,4 +18,10 @@ public class OwnerAccountAllVO { ...@@ -17,4 +18,10 @@ public class OwnerAccountAllVO {
@ApiModelProperty("0:没有交易密码 1:有交易密码") @ApiModelProperty("0:没有交易密码 1:有交易密码")
private Integer ownerAccountPassword; private Integer ownerAccountPassword;
@ApiModelProperty("借款账户信息")
private OwnerLoanAccountVO loanAccountVO;
@ApiModelProperty("货主信息")
private OwnerInfoVO ownerInfoVO;
} }
...@@ -45,7 +45,7 @@ public class OwnerAccountFeignController { ...@@ -45,7 +45,7 @@ public class OwnerAccountFeignController {
return Result.ok(ownerAccountService.accountInfo(userNo)); return Result.ok(ownerAccountService.accountInfo(userNo));
} }
@ApiOperation(value = "查询用户预付运费和保证金账户", notes = "<br>By:胡宇帆") @ApiOperation(value = "查询用户借款账户", notes = "<br>By:胡宇帆")
@GetMapping("/loanAccount") @GetMapping("/loanAccount")
public Result<OwnerLoanAccountVO> loanAccount(@RequestParam Long userNo) { public Result<OwnerLoanAccountVO> loanAccount(@RequestParam Long userNo) {
return Result.ok(ownerAccountService.loanAccount(userNo)); return Result.ok(ownerAccountService.loanAccount(userNo));
......
...@@ -4,6 +4,8 @@ import com.clx.open.sdk.request.dto.OwnerCancelResidueWeightDTO; ...@@ -4,6 +4,8 @@ import com.clx.open.sdk.request.dto.OwnerCancelResidueWeightDTO;
import com.clx.performance.param.pc.OrderCancelParam; import com.clx.performance.param.pc.OrderCancelParam;
import com.clx.performance.service.OrderCancelService; import com.clx.performance.service.OrderCancelService;
import com.clx.performance.service.OrderGoodsService; import com.clx.performance.service.OrderGoodsService;
import com.clx.performance.service.OwnerAccountService;
import com.clx.performance.vo.pc.OwnerAccountAllVO;
import com.msl.common.result.Result; import com.msl.common.result.Result;
import com.msl.user.utils.TokenUtil; import com.msl.user.utils.TokenUtil;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
...@@ -28,6 +30,8 @@ public class PerformanceSdkFeignController { ...@@ -28,6 +30,8 @@ public class PerformanceSdkFeignController {
private final OrderGoodsService orderGoodsService; private final OrderGoodsService orderGoodsService;
private final OwnerAccountService ownerAccountService;
@ApiOperation(value = "货主端取消订单", notes = "<br>By:胡宇帆") @ApiOperation(value = "货主端取消订单", notes = "<br>By:胡宇帆")
@PostMapping("/ownCancelOrderPre") @PostMapping("/ownCancelOrderPre")
...@@ -45,4 +49,10 @@ public class PerformanceSdkFeignController { ...@@ -45,4 +49,10 @@ public class PerformanceSdkFeignController {
dto.setWeight(orderGoodsService.orderCancelResidueWeight(orderNo, optionType).toString()); dto.setWeight(orderGoodsService.orderCancelResidueWeight(orderNo, optionType).toString());
return Result.ok(dto); return Result.ok(dto);
} }
@ApiOperation(value = "获取当前用户所有账户信息", notes = "<br>By:胡宇帆")
@GetMapping("/accountAllInfo")
public Result<OwnerAccountAllVO> accountAllInfo(@RequestParam Long userNo) {
return Result.ok(ownerAccountService.accountAllInfo(userNo));
}
} }
...@@ -104,4 +104,6 @@ public interface OwnerAccountService { ...@@ -104,4 +104,6 @@ public interface OwnerAccountService {
void resetPassword(ResetPasswordParam param); void resetPassword(ResetPasswordParam param);
OwnerLoanAccountVO loanAccount(Long userNo); OwnerLoanAccountVO loanAccount(Long userNo);
OwnerAccountAllVO accountAllInfo(Long userNo);
} }
...@@ -43,6 +43,7 @@ import com.clx.performance.utils.excel.ExcelData; ...@@ -43,6 +43,7 @@ import com.clx.performance.utils.excel.ExcelData;
import com.clx.performance.utils.excel.ExcelField; import com.clx.performance.utils.excel.ExcelField;
import com.clx.performance.utils.excel.ExcelSheet; import com.clx.performance.utils.excel.ExcelSheet;
import com.clx.performance.utils.excel.ExcelUtil; import com.clx.performance.utils.excel.ExcelUtil;
import com.clx.performance.vo.feign.OwnerInfoVO;
import com.clx.performance.vo.pc.OwnerAccountAllVO; import com.clx.performance.vo.pc.OwnerAccountAllVO;
import com.clx.performance.vo.pc.OwnerAccountRunningWaterRecordVO; import com.clx.performance.vo.pc.OwnerAccountRunningWaterRecordVO;
import com.clx.performance.vo.pc.OwnerAccountVO; import com.clx.performance.vo.pc.OwnerAccountVO;
...@@ -96,8 +97,6 @@ public class OwnerAccountServiceImpl implements OwnerAccountService { ...@@ -96,8 +97,6 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
private final OwnerCaseOutDao ownerCaseOutDao; private final OwnerCaseOutDao ownerCaseOutDao;
private final OwnerTransferInfoDao ownerTransferInfoDao;
private final OwnerInfoFeign ownerInfoFeign; private final OwnerInfoFeign ownerInfoFeign;
private final OwnerBindCardRecordDao ownerBindCardRecordDao; private final OwnerBindCardRecordDao ownerBindCardRecordDao;
...@@ -1257,4 +1256,18 @@ public class OwnerAccountServiceImpl implements OwnerAccountService { ...@@ -1257,4 +1256,18 @@ public class OwnerAccountServiceImpl implements OwnerAccountService {
return ownerLoanAccountStruct.convert(ownerLoanAccount); return ownerLoanAccountStruct.convert(ownerLoanAccount);
} }
@Override
public OwnerAccountAllVO accountAllInfo(Long userNo) {
OwnerAccountAllVO ownerAccountAllVO = this.accountInfo(userNo);
OwnerLoanAccountVO ownerLoanAccountVO = this.loanAccount(userNo);
ownerAccountAllVO.setLoanAccountVO(ownerLoanAccountVO);
Result<OwnerInfoFeignVO> ownerInfoResult = ownerFeign.getOwnerInfo(userNo);
if (ownerInfoResult.succeed()) {
OwnerInfoVO ownerInfoVO = ownerAccountStruct.convertVo(ownerInfoResult.getData());
ownerAccountAllVO.setOwnerInfoVO(ownerInfoVO);
}
return ownerAccountAllVO;
}
} }
package com.clx.performance.struct; package com.clx.performance.struct;
import com.clx.performance.model.OwnerAccount; import com.clx.performance.model.OwnerAccount;
import com.clx.performance.vo.feign.OwnerInfoVO;
import com.clx.performance.vo.pc.OwnerAccountVO; import com.clx.performance.vo.pc.OwnerAccountVO;
import com.clx.user.vo.feign.OwnerInfoFeignVO;
import com.msl.common.utils.DateStructUtil; import com.msl.common.utils.DateStructUtil;
import com.msl.common.utils.DateUtils; import com.msl.common.utils.DateUtils;
import org.mapstruct.Mapper; import org.mapstruct.Mapper;
...@@ -16,4 +18,6 @@ public interface OwnerAccountStruct { ...@@ -16,4 +18,6 @@ public interface OwnerAccountStruct {
List<OwnerAccountVO> convertList(List<OwnerAccount> orderGoods); List<OwnerAccountVO> convertList(List<OwnerAccount> orderGoods);
OwnerInfoVO convertVo(OwnerInfoFeignVO vo);
} }
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论