diff --git a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/BaseTrailerFeign.java b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/BaseTrailerFeign.java index 65d0cb1763..9885b1b62e 100644 --- a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/BaseTrailerFeign.java +++ b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/BaseTrailerFeign.java @@ -142,4 +142,8 @@ public interface BaseTrailerFeign { @ApiOperation("根据挂车车架号和车辆sid获取一条记录") @PostMapping("/fetchByGcVinNoAndVehSid") ResultBean fetchByGcVinNoAndVehSid(@RequestParam("gcVinNo") String gcVinNo,@RequestParam("vehSid") String vehSid); + + @ApiOperation("付款申请选择挂车") + @PostMapping("/payApply") + public ResultBean> payApply(@RequestBody PagerQuery query); } \ No newline at end of file diff --git a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/BaseTrailerFeignFallback.java b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/BaseTrailerFeignFallback.java index f2155fa2be..868f33c3a5 100644 --- a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/BaseTrailerFeignFallback.java +++ b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/BaseTrailerFeignFallback.java @@ -108,4 +108,9 @@ public class BaseTrailerFeignFallback implements BaseTrailerFeign { public ResultBean fetchByGcVinNoAndVehSid(String gcVinNo, String vehSid) { return null; } + + @Override + public ResultBean> payApply(PagerQuery query) { + return null; + } } \ No newline at end of file diff --git a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/PayApplyTrailerQuery.java b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/PayApplyTrailerQuery.java new file mode 100644 index 0000000000..aba423ec66 --- /dev/null +++ b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/PayApplyTrailerQuery.java @@ -0,0 +1,48 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.base.api.basetrailer; + +import com.yxt.common.core.query.Query; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.util.List; + +@Data +public class PayApplyTrailerQuery implements Query { + + @ApiModelProperty("挂车名称") + private String trailerTypeValue; + @ApiModelProperty("车架号") + private String vinNo; + @ApiModelProperty("主车车架号") + private String zcVinNo; + @ApiModelProperty("客户名称") + private String customerName; + + private String useOrgSid; + private List sids; +} diff --git a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/PayApplyTrailerVo.java b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/PayApplyTrailerVo.java new file mode 100644 index 0000000000..870d0dba66 --- /dev/null +++ b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basetrailer/PayApplyTrailerVo.java @@ -0,0 +1,63 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.base.api.basetrailer; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; + +@Data +public class PayApplyTrailerVo implements Vo { + + @ApiModelProperty("挂车名称") + private String trailerTypeValue; // 挂车名称 + @ApiModelProperty("外观尺寸") + private String size; // 外观尺寸 + @ApiModelProperty("车架号") + private String vinNo; // 车架号 + @ApiModelProperty("挂车sid") + private String trailerSid; // 挂车sid + @ApiModelProperty("箱体颜色") + private String color; // 箱体颜色 + @ApiModelProperty("厂家结算价") + private BigDecimal costPrice; // 厂家结算价 + @ApiModelProperty("品牌名称") + private String brandName; // 品牌名称 + @ApiModelProperty("车型别名") + private String vehModel; // 车型别名 + @ApiModelProperty("主车车架号") + private String zcVinNo; // 主车车架号 + @ApiModelProperty("合同编号") + private String contractNo; // 合同编号 + @ApiModelProperty("销售订单号") + private String saleOrderNo; // 销售订单号 + @ApiModelProperty("客户名称") + private String customerName; // 客户名称 + @ApiModelProperty("销售类型") + private String payType; // 销售类型 +} diff --git a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/BaseVehinstallFeign.java b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/BaseVehinstallFeign.java index 65b65521ff..446d1a23ef 100644 --- a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/BaseVehinstallFeign.java +++ b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/BaseVehinstallFeign.java @@ -25,6 +25,8 @@ *********************************************************/ package com.yxt.anrui.base.api.basevehinstall; +import com.yxt.anrui.base.api.basetrailer.PayApplyTrailerQuery; +import com.yxt.anrui.base.api.basetrailer.PayApplyTrailerVo; import com.yxt.common.core.query.PagerQuery; import com.yxt.common.core.result.ResultBean; import com.yxt.common.core.vo.PagerVo; @@ -33,6 +35,8 @@ import io.swagger.annotations.ApiOperation; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.*; +import java.util.List; + /** * Project: anrui-base(上装配置管理)
* File: BaseVehinstallFeign.java
@@ -68,12 +72,12 @@ public interface BaseVehinstallFeign { @PostMapping("/save") @ResponseBody public ResultBean save(@RequestBody BaseVehinstallDto dto); - + @ApiOperation("根据sid删除记录") @DeleteMapping("/delBySids") @ResponseBody public ResultBean delBySids(@RequestBody String[] sids); - + @ApiOperation("根据SID获取一条记录") @GetMapping("/fetchDetailsBySid/{sid}") @ResponseBody @@ -82,7 +86,7 @@ public interface BaseVehinstallFeign { @ApiOperation("获取车辆的上装信息") @GetMapping("/selectOne") @ResponseBody - ResultBean selectOne(@RequestParam("vinNo")String vinNo,@RequestParam("useOrgSid")String useOrgSid); + ResultBean selectOne(@RequestParam("vinNo") String vinNo, @RequestParam("useOrgSid") String useOrgSid); @ApiOperation("上装出库") @PostMapping("/vehinstallOut/{sid}") @@ -91,4 +95,8 @@ public interface BaseVehinstallFeign { @ApiOperation("上装单独出库(新)") @PostMapping("/vehinstallOutNew/{sid}") ResultBean vehinstallOutNew(@PathVariable("sid") String sid); + + @ApiOperation("付款申请选择上装") + @PostMapping("/payApply") + public ResultBean> payApply(@RequestBody PagerQuery query); } \ No newline at end of file diff --git a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/BaseVehinstallFeignFallback.java b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/BaseVehinstallFeignFallback.java index 42860e8a52..21e61322db 100644 --- a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/BaseVehinstallFeignFallback.java +++ b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/BaseVehinstallFeignFallback.java @@ -89,4 +89,9 @@ public class BaseVehinstallFeignFallback implements BaseVehinstallFeign { public ResultBean vehinstallOutNew(String sid) { return null; } + + @Override + public ResultBean> payApply(PagerQuery query) { + return null; + } } \ No newline at end of file diff --git a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/PayApplyTopQuery.java b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/PayApplyTopQuery.java new file mode 100644 index 0000000000..9158552f64 --- /dev/null +++ b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/PayApplyTopQuery.java @@ -0,0 +1,46 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.base.api.basevehinstall; + +import com.yxt.common.core.query.Query; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.util.List; + +@Data +public class PayApplyTopQuery implements Query { + + @ApiModelProperty("上装名称") + private String installNameValue; + @ApiModelProperty("车架号") + private String vinNo; + @ApiModelProperty("客户名称") + private String customerName; + + private String useOrgSid; + private List sids; +} diff --git a/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/PayApplyTopVo.java b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/PayApplyTopVo.java new file mode 100644 index 0000000000..f88965bbee --- /dev/null +++ b/anrui-base/anrui-base-api/src/main/java/com/yxt/anrui/base/api/basevehinstall/PayApplyTopVo.java @@ -0,0 +1,63 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.base.api.basevehinstall; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; + +@Data +public class PayApplyTopVo implements Vo { + + @ApiModelProperty("付款申请sid") + private String applySid; + @ApiModelProperty("上装名称") + private String installNameValue; + @ApiModelProperty("货箱内部尺寸") + private String size; + @ApiModelProperty("车架号") + private String vinNo; + @ApiModelProperty("上装sid") + private String topSid; + @ApiModelProperty("箱体颜色") + private String color; + @ApiModelProperty("厂家结算价") + private BigDecimal costPrice; + @ApiModelProperty("品牌名称") + private String brandName; + @ApiModelProperty("车型别名") + private String vehModel; + @ApiModelProperty("合同编号") + private String contractNo; + @ApiModelProperty("销售订单号") + private String saleOrderNo; + @ApiModelProperty("客户名称") + private String customerName; + @ApiModelProperty("销售类型") + private String payType; +} diff --git a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerMapper.java b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerMapper.java index a3fa20ddcf..561a8ba515 100644 --- a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerMapper.java +++ b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerMapper.java @@ -106,7 +106,9 @@ public interface BaseTrailerMapper extends BaseMapper { List getByVehSid(@Param("vehSid") String vehSid); @Select("select * from base_trailer where vinNo = #{gcVinNo} and vehSid = #{vehSid} order by id desc limit 1") - BaseTrailerDetailsVo fetchByGcVinNoAndVehSid(@Param("gcVinNo") String gcVinNo,@Param("vehSid") String vehSid); + BaseTrailerDetailsVo fetchByGcVinNoAndVehSid(@Param("gcVinNo") String gcVinNo, @Param("vehSid") String vehSid); List fetchTypeAndMan(String materialSid); + + IPage payApply(IPage page, @Param(Constants.WRAPPER) Wrapper qw); } \ No newline at end of file diff --git a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerMapper.xml b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerMapper.xml index 842cdffe7c..e30af2a1b6 100644 --- a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerMapper.xml +++ b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerMapper.xml @@ -8,7 +8,7 @@ btm.* FROM base_trailer bt LEFT JOIN base_trailer_model btm - ON bt.`trailerModelSid` = btm.`sid` + ON bt.trailerModelSid = btm.sid ${ew.sqlSegment} @@ -59,7 +59,7 @@ from base_vehicle_out_apply where billNo LIKE concat(#{billNo}, '%') order by billNo desc - limit 1 + limit 1 @@ -103,8 +103,52 @@ SELECT btm.trailerTypeValue, btm.manufacturerName FROM base_trailer bt - LEFT JOIN base_trailer_model btm - ON bt.`trailerModelSid` = btm.`sid` + LEFT JOIN base_trailer_model btm + ON bt.trailerModelSid = btm.sid WHERE bt.vehSid = #{materialSid} + + \ No newline at end of file diff --git a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerRest.java b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerRest.java index 43b115e081..731bd502b4 100644 --- a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerRest.java +++ b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerRest.java @@ -52,88 +52,93 @@ import java.util.List; * @since 1.0 */ @Api(tags = "挂车 base_trailer") -@RestController("com.yxt.anrui.base.biz.basetrailer.BaseTrailerRest") +@RestController @RequestMapping("v1/basetrailer") public class BaseTrailerRest implements BaseTrailerFeign { - @Autowired - private BaseTrailerService baseTrailerService; - - @Override - @ApiOperation("根据条件分页查询数据的列表") - @PostMapping("/listPage") - public ResultBean> listPage(@RequestBody PagerQuery pq){ - ResultBean rb = ResultBean.fireFail(); - PagerVo pv = baseTrailerService.listPageVo(pq); - return rb.success().setData(pv); - } - - @Override - @ApiOperation("新增保存") - @PostMapping("/save") - public ResultBean save(@RequestBody BaseTrailerDto dto){ - return baseTrailerService.saveTrailer(dto); - } - - @Override - @ApiOperation("修改保存") - @PostMapping("/update/{sid}") - public ResultBean update(@RequestBody BaseTrailerDto dto, @PathVariable("sid") String sid){ - return baseTrailerService.updateTrailer(dto,sid); - } - - @Override - @ApiOperation("根据sid批量删除") + @Autowired + private BaseTrailerService baseTrailerService; + + @Override + @ApiOperation("根据条件分页查询数据的列表") + @PostMapping("/listPage") + public ResultBean> listPage(@RequestBody PagerQuery pq) { + ResultBean rb = ResultBean.fireFail(); + PagerVo pv = baseTrailerService.listPageVo(pq); + return rb.success().setData(pv); + } + + @Override + @ApiOperation("新增保存") + @PostMapping("/save") + public ResultBean save(@RequestBody BaseTrailerDto dto) { + return baseTrailerService.saveTrailer(dto); + } + + @Override + @ApiOperation("修改保存") + @PostMapping("/update/{sid}") + public ResultBean update(@RequestBody BaseTrailerDto dto, @PathVariable("sid") String sid) { + return baseTrailerService.updateTrailer(dto, sid); + } + + @Override + @ApiOperation("根据sid批量删除") @DeleteMapping("/delBySids") - public ResultBean delBySids(@RequestBody String[] sids){ - ResultBean rb = ResultBean.fireFail(); - baseTrailerService.delBySids(sids); - return rb.success(); - } - - @Override - @ApiOperation("根据SID获取一条记录") - @GetMapping("/fetchBySid/{sid}") - public ResultBean fetchBySid(@PathVariable("sid") String sid) { - return baseTrailerService.fetchDetailsBySid(sid); - } - - @Override - public ResultBean> getByVehSid(String vehSid) { - return baseTrailerService.getByVehSid(vehSid); - } - - @Override - public ResultBean> searchPage(PagerQuery pagerQuery) { - ResultBean> rb = ResultBean.fireFail(); - IPage page = baseTrailerService.searchPage(pagerQuery); - PagerVo pv = new PagerVo<>(); - PagerVo pv1 = PagerUtil.pageToVo(page, pv); - return rb.success().setData(pv1); - } - - @Override - public ResultBean trailerOut(String sid) { - return baseTrailerService.trailerOut(sid); - } - - @Override - public ResultBean trailerOutNew(String sid) { - return baseTrailerService.trailerOutNew(sid); - } - - @Override - public ResultBean trailerList(String vinSid,String contractNo) { - return baseTrailerService.trailerList(vinSid,contractNo); - } - - @Override - public ResultBean fetchByGcVinNo(String gcVinNo) { - return baseTrailerService.fetchByGcVinNo(gcVinNo); - } - - @Override - public ResultBean fetchByGcVinNoAndVehSid(String gcVinNo, String vehSid) { - return baseTrailerService.fetchByGcVinNoAndVehSid(gcVinNo,vehSid); - } + public ResultBean delBySids(@RequestBody String[] sids) { + ResultBean rb = ResultBean.fireFail(); + baseTrailerService.delBySids(sids); + return rb.success(); + } + + @Override + @ApiOperation("根据SID获取一条记录") + @GetMapping("/fetchBySid/{sid}") + public ResultBean fetchBySid(@PathVariable("sid") String sid) { + return baseTrailerService.fetchDetailsBySid(sid); + } + + @Override + public ResultBean> getByVehSid(String vehSid) { + return baseTrailerService.getByVehSid(vehSid); + } + + @Override + public ResultBean> searchPage(PagerQuery pagerQuery) { + ResultBean> rb = ResultBean.fireFail(); + IPage page = baseTrailerService.searchPage(pagerQuery); + PagerVo pv = new PagerVo<>(); + PagerVo pv1 = PagerUtil.pageToVo(page, pv); + return rb.success().setData(pv1); + } + + @Override + public ResultBean trailerOut(String sid) { + return baseTrailerService.trailerOut(sid); + } + + @Override + public ResultBean trailerOutNew(String sid) { + return baseTrailerService.trailerOutNew(sid); + } + + @Override + public ResultBean trailerList(String vinSid, String contractNo) { + return baseTrailerService.trailerList(vinSid, contractNo); + } + + @Override + public ResultBean fetchByGcVinNo(String gcVinNo) { + return baseTrailerService.fetchByGcVinNo(gcVinNo); + } + + @Override + public ResultBean fetchByGcVinNoAndVehSid(String gcVinNo, String vehSid) { + return baseTrailerService.fetchByGcVinNoAndVehSid(gcVinNo, vehSid); + } + + @Override + public ResultBean> payApply(PagerQuery query) { + return baseTrailerService.payApply(query); + } } diff --git a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerService.java b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerService.java index 5f23dfc9f5..e27a0b27d4 100644 --- a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerService.java +++ b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basetrailer/BaseTrailerService.java @@ -302,17 +302,17 @@ public class BaseTrailerService extends MybatisBaseService data = busSalesOrderTrailerFeign.fetchDetailsByOrderSid(orderSid).getData(); - if (data != null && data.size() > 0){ + if (data != null && data.size() > 0) { Boolean tg = false; for (BusSalesOrderTrailerDetailsVo datum : data) { - if (datum.getAppearanceSizeLong().compareTo(appearanceSizeLong) == 0 && datum.getTrailerTypeKey().equals(trailerTypeKey)){ + if (datum.getAppearanceSizeLong().compareTo(appearanceSizeLong) == 0 && datum.getTrailerTypeKey().equals(trailerTypeKey)) { tg = true; break; } } - if (!tg){ + if (!tg) { return rb.setMsg("该挂车类型和外廓长与绑定的主车销售订单中挂车类型和外廓长不一致,无法入库"); } } @@ -928,7 +928,7 @@ public class BaseTrailerService extends MybatisBaseService fetchByGcVinNoAndVehSid(String gcVinNo, String vehSid) { ResultBean rb = ResultBean.fireFail(); - BaseTrailerDetailsVo baseTrailerDetailsVo = baseMapper.fetchByGcVinNoAndVehSid(gcVinNo,vehSid); + BaseTrailerDetailsVo baseTrailerDetailsVo = baseMapper.fetchByGcVinNoAndVehSid(gcVinNo, vehSid); return rb.success().setData(baseTrailerDetailsVo); } public List fetchTypeAndMan(String vehSid) { return baseMapper.fetchTypeAndMan(vehSid); } + + public ResultBean> payApply(PagerQuery pq) { + ResultBean rb = ResultBean.fireFail(); + PayApplyTrailerQuery query = pq.getParams(); + QueryWrapper qw = new QueryWrapper<>(); + qw.eq("bt.useOrgSid", query.getUseOrgSid()); + if (StringUtils.isNotBlank(query.getVinNo())) { + qw.like("bt.vinNo", query.getVinNo()); + } + if (StringUtils.isNotBlank(query.getZcVinNo())) { + qw.eq("bt.zcvinNo", query.getZcVinNo()); + } + if (StringUtils.isNotBlank(query.getCustomerName())) { + qw.eq("bso.customerName", query.getCustomerName()); + } + if (StringUtils.isNotBlank(query.getTrailerTypeValue())) { + qw.like("btm.trailerTypeValue", query.getTrailerTypeValue()); + } + if (query.getSids().size() > 0) { + qw.notIn("bt.sid", query.getSids()); + } + IPage page = PagerUtil.queryToPage(pq); + IPage pagging = baseMapper.payApply(page, qw); + PagerVo p = PagerUtil.pageToVo(pagging, null); + return rb.success().setData(p); + } } \ No newline at end of file diff --git a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallMapper.java b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallMapper.java index 6f17151102..9554b27387 100644 --- a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallMapper.java +++ b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallMapper.java @@ -26,10 +26,12 @@ package com.yxt.anrui.base.biz.basevehinstall; import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.toolkit.Constants; import com.yxt.anrui.base.api.basevehinstall.BaseVehinstallDetailsVo; +import com.yxt.anrui.base.api.basevehinstall.PayApplyTopVo; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Select; @@ -54,24 +56,26 @@ import java.util.List; @Mapper public interface BaseVehinstallMapper extends BaseMapper { - //@Update("update base_vehinstall set name=#{msg} where id=#{id}") - //IPage voPage(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw); - - IPage selectPageVo(IPage page, @Param(Constants.WRAPPER) Wrapper qw); - - List selectListAllVo(@Param(Constants.WRAPPER) Wrapper qw); - - @Select("select vinNo from base_vehinstall where createOrg = #{createOrgSid}") - List selectListVo(String createOrgSid); + //@Update("update base_vehinstall set name=#{msg} where id=#{id}") + //IPage voPage(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw); + + IPage selectPageVo(IPage page, @Param(Constants.WRAPPER) Wrapper qw); + + List selectListAllVo(@Param(Constants.WRAPPER) Wrapper qw); + + @Select("select vinNo from base_vehinstall where createOrg = #{createOrgSid}") + List selectListVo(String createOrgSid); List selectByOrgSidAndVin(@Param("useOrgSid") String orgSid, @Param("vinNo") String vin); - @Select("select * from base_vehinstall where createOrg = #{createOrgSid} and vinNo = #{vinNo}") - BaseVehinstallDetailsVo fetchByVinNoAndOrgSid(@Param("vinNo") String vinNo,@Param("createOrgSid") String createOrgSid); + @Select("select * from base_vehinstall where createOrg = #{createOrgSid} and vinNo = #{vinNo}") + BaseVehinstallDetailsVo fetchByVinNoAndOrgSid(@Param("vinNo") String vinNo, @Param("createOrgSid") String createOrgSid); BaseVehinstall seletByVinAndUseOrg(@Param("vinNo") String vinNo, @Param("useOrgSid") String useOrgSid); int selectNumGCRK(String bill); String selectNum(String billNo); + + IPage payApply(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw); } \ No newline at end of file diff --git a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallMapper.xml b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallMapper.xml index b8adc8baab..bf2c11f54c 100644 --- a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallMapper.xml +++ b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallMapper.xml @@ -65,4 +65,44 @@ order by billNo desc limit 1 + + \ No newline at end of file diff --git a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallRest.java b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallRest.java index 499556f56a..5aa777e381 100644 --- a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallRest.java +++ b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallRest.java @@ -79,7 +79,7 @@ import java.util.List; * @since 1.0 */ @Api(tags = "上装表") -@RestController("com.yxt.anrui.base.biz.basevehinstall.BaseVehinstallRest") +@RestController @RequestMapping("v1/basevehinstall") public class BaseVehinstallRest implements BaseVehinstallFeign { @@ -297,4 +297,9 @@ public class BaseVehinstallRest implements BaseVehinstallFeign { public ResultBean vehinstallOutNew(String sid) { return baseVehinstallService.vehinstallOutNew(sid); } + + @Override + public ResultBean> payApply(PagerQuery query) { + return baseVehinstallService.payApply(query); + } } diff --git a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallService.java b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallService.java index 147b08967d..97e19471f7 100644 --- a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallService.java +++ b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basevehinstall/BaseVehinstallService.java @@ -31,11 +31,13 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.yxt.anrui.base.api.basepurchasesystem.BasePurchaseSystemDetailsVo; import com.yxt.anrui.base.api.basetrailer.BaseTrailer; +import com.yxt.anrui.base.api.basetrailer.PayApplyTrailerVo; import com.yxt.anrui.base.api.basetrailermodel.BaseTrailerModel; import com.yxt.anrui.base.api.basevehicle.BaseVehicle; import com.yxt.anrui.base.api.basevehicleout.BaseVehicleOut; import com.yxt.anrui.base.api.basevehicleout.BaseVehicleOutDetailsVo; import com.yxt.anrui.base.api.basevehicleoutapply.BaseVehicleOutApply; +import com.yxt.anrui.base.api.basevehinstall.*; import com.yxt.anrui.base.api.basevehinstallmodel.BaseVehinstallmodel; import com.yxt.anrui.base.api.basevehinstallmodel.BaseVehinstallmodelDetailsVo; import com.yxt.anrui.base.api.basevehmodelconfig.BaseVehmodelVo; @@ -57,12 +59,6 @@ import com.yxt.common.base.utils.PagerUtil; import com.yxt.common.core.query.PagerQuery; import com.yxt.common.core.result.ResultBean; import com.yxt.common.core.vo.PagerVo; -import com.yxt.anrui.base.api.basevehinstall.BaseVehinstall; -import com.yxt.anrui.base.api.basevehinstall.BaseVehinstallQuery; -import com.yxt.anrui.base.api.basevehinstall.BaseVehinstallVo; -import com.yxt.anrui.base.api.basevehinstall.BaseVehinstallDetailsVo; -import com.yxt.anrui.base.api.basevehinstall.BaseVehinstallDto; -import com.yxt.anrui.base.api.basevehinstall.BaseVehinstallFeign; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; @@ -524,4 +520,27 @@ public class BaseVehinstallService extends MybatisBaseService> payApply(PagerQuery pq) { + ResultBean rb = ResultBean.fireFail(); + PayApplyTopQuery query = pq.getParams(); + QueryWrapper qw = new QueryWrapper<>(); + qw.eq("bv.useOrgSid", query.getUseOrgSid()); + if (StringUtils.isNotBlank(query.getVinNo())) { + qw.like("bv.vinNo", query.getVinNo()); + } + if (StringUtils.isNotBlank(query.getCustomerName())) { + qw.eq("bso.customerName", query.getCustomerName()); + } + if (StringUtils.isNotBlank(query.getInstallNameValue())) { + qw.like("bvm.installNameValue", query.getInstallNameValue()); + } + if (query.getSids().size() > 0) { + qw.notIn("bv.sid", query.getSids()); + } + IPage page = PagerUtil.queryToPage(pq); + IPage pagging = baseMapper.payApply(page, qw); + PagerVo p = PagerUtil.pageToVo(pagging, null); + return rb.success().setData(p); + } } \ No newline at end of file diff --git a/anrui-buscenter/anrui-finmanage-ui/src/api/anruifinmanagement/payment.js b/anrui-buscenter/anrui-finmanage-ui/src/api/anruifinmanagement/payment.js index ce8d6c7900..1ea697e64b 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/api/anruifinmanagement/payment.js +++ b/anrui-buscenter/anrui-finmanage-ui/src/api/anruifinmanagement/payment.js @@ -10,12 +10,30 @@ export default { headers: { 'Content-Type': 'application/json' } }) }, - // 查询分页列表 - pageList: function(params) { + // 查询分页列表 -- 选择主车车辆 + pageList: function(data) { return request({ url: '/base/v1/basevehicle/selectPayVehicleList', method: 'post', - data: params, + data: data, + headers: { 'Content-Type': 'application/json' } + }) + }, + // 查询分页列表 -- 选择挂车 + trailerApply: function(data) { + return request({ + url: '/base/v1/basetrailer/payApply', + method: 'post', + data: data, + headers: { 'Content-Type': 'application/json' } + }) + }, + // 查询分页列表 -- 选择上装 + topApply: function(data) { + return request({ + url: '/base/v1/basevehinstall/payApply', + method: 'post', + data: data, headers: { 'Content-Type': 'application/json' } }) }, diff --git a/anrui-buscenter/anrui-finmanage-ui/src/router/modules/codemenu.js b/anrui-buscenter/anrui-finmanage-ui/src/router/modules/codemenu.js index 8a70444d61..2d14fc25c7 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/router/modules/codemenu.js +++ b/anrui-buscenter/anrui-finmanage-ui/src/router/modules/codemenu.js @@ -130,7 +130,7 @@ const codemenu = [ component: Layout, redirect: '/anruifinmanagement', meta: { - title: '款项结转申请' + title: '付款信息管理' }, children: [{ path: '/anruifinmanagement/paymentInformation', diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentAdd.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentAdd.vue index d78cbb1a89..350c8d6f05 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentAdd.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentAdd.vue @@ -54,7 +54,7 @@
*是否涉及车辆
- + @@ -204,12 +204,67 @@ +
+
+
挂车列表
+ 选择 +
+ + + + + + + + + + + + + + + + + + + +
+
+
+
上装列表
+ 选择 +
+ + + + + + + + + + + + + + + + + + +
- - @@ -244,6 +299,12 @@ 关闭 + + + + + + @@ -257,6 +318,8 @@ import req from '@/api/anruifinmanagement/payment' import { typeValues, getOrgSidByPath, getInvoicingList, brandDown, selectNameByOrg, getTypeValueList } from '@/api/jichuxinxi/dictcommons' import vehcile from './relation/vehcile' +import trailerCar from './relation/trailerCar' +import top from './relation/top' import paymentInformationAdd from './relation/paymentInformationAdd' import paymentInformationInfo from './relation/paymentInformationInfo' import tops from '@/components/publicPage/tops' @@ -265,6 +328,8 @@ export default { name: 'PaymentAdd', components: { vehcile, + trailerCar, + top, paymentInformationAdd, paymentInformationInfo, tops @@ -277,6 +342,8 @@ export default { tableKey: 0, vehicleKey: 1, paymentKey: 2, + trailerKey: 3, + topKey: 4, index: 0, carBrand_list: [], costRange_list: [], @@ -312,8 +379,10 @@ export default { carBrandSid: '', // 品牌sid carBrandName: '', // 品牌名称 orgSidPath: '', - detailsList: [], - vehicleList: [] + detailsList: [], // 付款信息列表 + vehicleList: [], // 主车车辆列表 + trailerList: [], // 挂车列表 + topList: [] // 上装列表 }, rules: { carBrandName: [{ required: true, message: '品牌不能为空', trigger: 'change' }], @@ -452,8 +521,12 @@ export default { const choose = this.costType_list.filter((item) => item.dictValue === value) if (choose.length > 0 && choose !== null) { this.formobj.costTypeKey = choose[0].dictKey + if (this.formobj.costTypeKey !== '001') { + this.formobj.isVeh = '0' + } } else { this.formobj.costTypeKey = '' + this.formobj.isVeh = '' } }, changePayCompany(value) { @@ -489,6 +562,35 @@ export default { handleDelete(index) { this.formobj.detailsList.splice(index, 1) }, + changeCostTitle(value, row) { + const choose = this.costTitle_list.filter((item) => item.dictValue === value) + if (choose.length > 0 && choose !== null) { + row.costTitleKey = choose[0].dictKey + } else { + row.costTitleKey = '' + } + }, + changePaymentType(value, row) { + const choose = this.payment_list.filter((item) => item.dictValue === value) + if (choose.length > 0 && choose !== null) { + row.paymentTypeKey = choose[0].dictKey + } else { + row.paymentTypeKey = '' + } + }, + changeActualPay(value, row) { + const choose = this.actualPay_list.filter((item) => item.actualPay === value) + if (choose.length > 0 && choose !== null) { + row.actualPay = choose[0].actualPay + row.receiveCompany = choose[0].accountName + row.bank = choose[0].depositBank + row.receivingAccount = choose[0].bankAccount + } else { + row.actualPay = '' + row.bank = '' + row.receivingAccount = '' + } + }, handleAddPayment(row, index) { if (row.paymentType === '') { this.$message({ showClose: true, type: 'error', message: '付款方式不能为空' }) @@ -620,33 +722,64 @@ export default { this.viewState = 5 this.$refs['divTops'].showInfo({ sid: row.topSid }) }, - changeCostTitle(value, row) { - const choose = this.costTitle_list.filter((item) => item.dictValue === value) - if (choose.length > 0 && choose !== null) { - row.costTitleKey = choose[0].dictKey - } else { - row.costTitleKey = '' - } + trailerSelect() { + this.viewState = 6 + this.$refs['divTrailer'].showData(this.formobj.trailerList, this.formobj.useOrgSid) }, - changePaymentType(value, row) { - const choose = this.payment_list.filter((item) => item.dictValue === value) - if (choose.length > 0 && choose !== null) { - row.paymentTypeKey = choose[0].dictKey - } else { - row.paymentTypeKey = '' + trailerDelete(index) { + this.formobj.trailerList.splice(index, 1) + }, + backTrailer(value) { + this.viewState = 1 + value = JSON.parse(JSON.stringify(value)) + if (value.length > 0) { + value.forEach((e) => { + this.formobj.trailerList.push({ + trailerTypeValue: e.trailerTypeValue, // 挂车名称 + size: e.size, // 外观尺寸 + vinNo: e.vinNo, // 挂车车架号 + trailerSid: e.trailerSid, // 挂车sid + color: e.color, // 箱体颜色 + costPrice: e.costPrice, // 厂家结算价 + brandName: e.brandName, // 品牌名称 + vehModel: e.vehModel, // 车型别名 + zcVinNo: e.zcVinNo, // 主车车架号 + contractNo: e.contractNo, // 合同编号 + saleOrderNo: e.saleOrderNo, // 销售订单号 + customerName: e.customerName, // 客户名称 + payType: e.payType // 销售类型 + }) + }) } }, - changeActualPay(value, row) { - const choose = this.actualPay_list.filter((item) => item.actualPay === value) - if (choose.length > 0 && choose !== null) { - row.actualPay = choose[0].actualPay - row.receiveCompany = choose[0].accountName - row.bank = choose[0].depositBank - row.receivingAccount = choose[0].bankAccount - } else { - row.actualPay = '' - row.bank = '' - row.receivingAccount = '' + topSelect() { + this.viewState = 7 + this.$refs['divTop'].showData(this.formobj.topList, this.formobj.useOrgSid) + }, + topDelete(index) { + this.formobj.topList.splice(index, 1) + }, + backTop(value) { + this.viewState = 1 + value = JSON.parse(JSON.stringify(value)) + if (value.length > 0) { + value.forEach((e) => { + this.formobj.topList.push({ + installNameValue: e.installNameValue, // 上装名称 + topSid: e.topSid, // 上装sid + size: e.size, // 外观尺寸 + vinNo: e.vinNo, // 车架号 + vehiSid: e.vehiSid, // 车辆sid + color: e.color, // 箱体颜色 + costPrice: e.costPrice, // 厂家结算价 + brandName: e.brandName, // 品牌名称 + vehModel: e.vehModel, // 车型别名 + contractNo: e.contractNo, // 合同编号 + saleOrderNo: e.saleOrderNo, // 销售订单号 + customerName: e.customerName, // 客户名称 + payType: e.payType // 销售类型 + }) + }) } }, saveOrUpdate() { @@ -745,6 +878,16 @@ export default { }, 0) sums[index] += '' this.formobj.carTotal = sums[index] += '' + } else if (column.property === 'costPrice') { + sums[index] = values.reduce((prev, curr) => { + const value = Number(curr) + if (!isNaN(value)) { + return prev + curr + } else { + return prev + } + }, 0) + sums[index] += '' } }) return sums @@ -781,8 +924,10 @@ export default { carBrandSid: '', // 品牌sid carBrandName: '', // 品牌名称 orgSidPath: '', - detailsList: [], - vehicleList: [] + detailsList: [], // 付款信息列表 + vehicleList: [], // 主车车辆列表 + trailerList: [], // 挂车列表 + topList: [] // 上装列表 } this.submitdisabled = false this.$refs['form_obj'].resetFields() diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentInfo.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentInfo.vue index df53e5987f..832a84512d 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentInfo.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentInfo.vue @@ -121,6 +121,47 @@ +
+
挂车列表
+ + + + + + + + + + + + + + + + +
+
+
上装列表
+ + + + + + + + + + + + + + + +
@@ -179,6 +220,8 @@ export default { tableKey: 0, vehicleKey: 1, paymentKey: 2, + trailerKey: 3, + topKey: 4, index: 0, formobj: { billNo: '', // 申请编号 @@ -207,8 +250,10 @@ export default { carBrandSid: '', // 品牌sid carBrandName: '', // 品牌名称 orgSidPath: '', - detailsList: [], - vehicleList: [] + detailsList: [], // 付款信息列表 + vehicleList: [], // 主车车辆列表 + trailerList: [], // 挂车列表 + topList: [] // 上装列表 }, rules: {}, paymentVisible: false, // 付款明细表 -- 新增付款信息弹框 @@ -300,6 +345,16 @@ export default { }, 0) sums[index] += '' this.formobj.carTotal = sums[index] += '' + } else if (column.property === 'costPrice') { + sums[index] = values.reduce((prev, curr) => { + const value = Number(curr) + if (!isNaN(value)) { + return prev + curr + } else { + return prev + } + }, 0) + sums[index] += '' } }) return sums @@ -335,8 +390,10 @@ export default { carBrandSid: '', // 品牌sid carBrandName: '', // 品牌名称 orgSidPath: '', - detailsList: [], - vehicleList: [] + detailsList: [], // 付款信息列表 + vehicleList: [], // 主车车辆列表 + trailerList: [], // 挂车列表 + topList: [] // 上装列表 } this.$refs['form_obj'].resetFields() this.$emit('doback') diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/relation/top.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/relation/top.vue new file mode 100644 index 0000000000..db1859bf22 --- /dev/null +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/relation/top.vue @@ -0,0 +1,168 @@ + + + + + diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/relation/trailerCar.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/relation/trailerCar.vue new file mode 100644 index 0000000000..50277d3700 --- /dev/null +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/relation/trailerCar.vue @@ -0,0 +1,174 @@ + + + + + diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanDaiBanInfo.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanDaiBanInfo.vue index a89cd035c4..0fc373a07e 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanDaiBanInfo.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanDaiBanInfo.vue @@ -123,6 +123,47 @@ +
+
挂车列表
+ + + + + + + + + + + + + + + + +
+
+
上装列表
+ + + + + + + + + + + + + + + +
@@ -203,6 +244,8 @@ export default { tableKey: 0, vehicleKey: 1, paymentKey: 2, + trailerKey: 3, + topKey: 4, index: 0, formobj: { billNo: '', // 申请编号 @@ -231,8 +274,10 @@ export default { carBrandSid: '', // 品牌sid carBrandName: '', // 品牌名称 orgSidPath: '', - detailsList: [], - vehicleList: [] + detailsList: [], // 付款信息列表 + vehicleList: [], // 主车车辆列表 + trailerList: [], // 挂车列表 + topList: [] // 上装列表 }, rules: {}, paymentVisible: false, // 付款明细表 -- 新增付款信息弹框 @@ -377,6 +422,16 @@ export default { }, 0) sums[index] += '' this.formobj.carTotal = sums[index] += '' + } else if (column.property === 'costPrice') { + sums[index] = values.reduce((prev, curr) => { + const value = Number(curr) + if (!isNaN(value)) { + return prev + curr + } else { + return prev + } + }, 0) + sums[index] += '' } }) return sums @@ -389,7 +444,7 @@ export default { this.operation = val this.currentLink = true this.dialogList.comment = '同意' - req.getNextNodesForSubmit({ taskDefKey: this.current.taskDefKe, businessSid: this.linkByParameter.businessSid }).then((resp) => { + req.getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => { if (resp.success) { var arr = resp.data this.nextNode = arr[0] diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanEdit.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanEdit.vue index ffce22ff96..e7bc30cd7b 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanEdit.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanEdit.vue @@ -53,7 +53,7 @@
*是否涉及车辆
- + @@ -203,12 +203,67 @@ +
+
+
挂车列表
+ 选择 +
+ + + + + + + + + + + + + + + + + + + +
+
+
+
上装列表
+ 选择 +
+ + + + + + + + + + + + + + + + + + +
- - @@ -243,6 +298,12 @@ 关闭 + + + + + + @@ -256,6 +317,8 @@ import req from '@/api/anruifinmanagement/payment' import { typeValues, brandDown, selectNameByOrg, getInvoicingList, getTypeValueList } from '@/api/jichuxinxi/dictcommons' import vehcile from './relation/vehcile' +import trailerCar from './relation/trailerCar' +import top from './relation/top' import paymentInformationAdd from './relation/paymentInformationAdd' import paymentInformationInfo from './relation/paymentInformationInfo' import tops from '@/views/workFlow/publicPage/tops' @@ -264,6 +327,8 @@ export default { name: 'FuKuanEdit', components: { vehcile, + trailerCar, + top, paymentInformationAdd, paymentInformationInfo, tops @@ -276,6 +341,8 @@ export default { tableKey: 0, vehicleKey: 1, paymentKey: 2, + trailerKey: 3, + topKey: 4, index: 0, carBrand_list: [], costRange_list: [], @@ -311,8 +378,10 @@ export default { carBrandSid: '', // 品牌sid carBrandName: '', // 品牌名称 orgSidPath: '', - detailsList: [], - vehicleList: [] + detailsList: [], // 付款信息列表 + vehicleList: [], // 主车车辆列表 + trailerList: [], // 挂车列表 + topList: [] // 上装列表 }, rules: { carBrandName: [{ required: true, message: '品牌不能为空', trigger: 'change' }], @@ -443,8 +512,12 @@ export default { const choose = this.costType_list.filter((item) => item.dictValue === value) if (choose.length > 0 && choose !== null) { this.formobj.costTypeKey = choose[0].dictKey + if (this.formobj.costTypeKey !== '001') { + this.formobj.isVeh = '0' + } } else { this.formobj.costTypeKey = '' + this.formobj.isVeh = '' } }, changePayCompany(value) { @@ -480,6 +553,35 @@ export default { handleDelete(index) { this.formobj.detailsList.splice(index, 1) }, + changeCostTitle(value, row) { + const choose = this.costTitle_list.filter((item) => item.dictValue === value) + if (choose.length > 0 && choose !== null) { + row.costTitleKey = choose[0].dictKey + } else { + row.costTitleKey = '' + } + }, + changePaymentType(value, row) { + const choose = this.payment_list.filter((item) => item.dictValue === value) + if (choose.length > 0 && choose !== null) { + row.paymentTypeKey = choose[0].dictKey + } else { + row.paymentTypeKey = '' + } + }, + changeActualPay(value, row) { + const choose = this.actualPay_list.filter((item) => item.actualPay === value) + if (choose.length > 0 && choose !== null) { + row.actualPay = choose[0].actualPay + row.receiveCompany = choose[0].accountName + row.bank = choose[0].depositBank + row.receivingAccount = choose[0].bankAccount + } else { + row.actualPay = '' + row.bank = '' + row.receivingAccount = '' + } + }, handleAddPayment(row, index) { if (row.paymentType === '') { this.$message({ showClose: true, type: 'error', message: '付款方式不能为空' }) @@ -611,33 +713,64 @@ export default { this.viewState = 5 this.$refs['divTops'].showInfo({ sid: row.topSid }) }, - changeCostTitle(value, row) { - const choose = this.costTitle_list.filter((item) => item.dictValue === value) - if (choose.length > 0 && choose !== null) { - row.costTitleKey = choose[0].dictKey - } else { - row.costTitleKey = '' - } + trailerSelect() { + this.viewState = 6 + this.$refs['divTrailer'].showData(this.formobj.trailerList, this.formobj.useOrgSid) }, - changePaymentType(value, row) { - const choose = this.payment_list.filter((item) => item.dictValue === value) - if (choose.length > 0 && choose !== null) { - row.paymentTypeKey = choose[0].dictKey - } else { - row.paymentTypeKey = '' + trailerDelete(index) { + this.formobj.trailerList.splice(index, 1) + }, + backTrailer(value) { + this.viewState = 1 + value = JSON.parse(JSON.stringify(value)) + if (value.length > 0) { + value.forEach((e) => { + this.formobj.trailerList.push({ + trailerTypeValue: e.trailerTypeValue, // 挂车名称 + size: e.size, // 外观尺寸 + vinNo: e.vinNo, // 挂车车架号 + trailerSid: e.trailerSid, // 挂车sid + color: e.color, // 箱体颜色 + costPrice: e.costPrice, // 厂家结算价 + brandName: e.brandName, // 品牌名称 + vehModel: e.vehModel, // 车型别名 + zcVinNo: e.zcVinNo, // 主车车架号 + contractNo: e.contractNo, // 合同编号 + saleOrderNo: e.saleOrderNo, // 销售订单号 + customerName: e.customerName, // 客户名称 + payType: e.payType // 销售类型 + }) + }) } }, - changeActualPay(value, row) { - const choose = this.actualPay_list.filter((item) => item.actualPay === value) - if (choose.length > 0 && choose !== null) { - row.actualPay = choose[0].actualPay - row.receiveCompany = choose[0].accountName - row.bank = choose[0].depositBank - row.receivingAccount = choose[0].bankAccount - } else { - row.actualPay = '' - row.bank = '' - row.receivingAccount = '' + topSelect() { + this.viewState = 7 + this.$refs['divTop'].showData(this.formobj.topList, this.formobj.useOrgSid) + }, + topDelete(index) { + this.formobj.topList.splice(index, 1) + }, + backTop(value) { + this.viewState = 1 + value = JSON.parse(JSON.stringify(value)) + if (value.length > 0) { + value.forEach((e) => { + this.formobj.topList.push({ + installNameValue: e.installNameValue, // 上装名称 + topSid: e.topSid, // 上装sid + size: e.size, // 外观尺寸 + vinNo: e.vinNo, // 车架号 + vehiSid: e.vehiSid, // 车辆sid + color: e.color, // 箱体颜色 + costPrice: e.costPrice, // 厂家结算价 + brandName: e.brandName, // 品牌名称 + vehModel: e.vehModel, // 车型别名 + contractNo: e.contractNo, // 合同编号 + saleOrderNo: e.saleOrderNo, // 销售订单号 + customerName: e.customerName, // 客户名称 + payType: e.payType // 销售类型 + }) + }) } }, saveOrUpdate() { @@ -750,6 +883,16 @@ export default { }, 0) sums[index] += '' this.formobj.carTotal = sums[index] += '' + } else if (column.property === 'costPrice') { + sums[index] = values.reduce((prev, curr) => { + const value = Number(curr) + if (!isNaN(value)) { + return prev + curr + } else { + return prev + } + }, 0) + sums[index] += '' } }) return sums diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanYiBanInfo.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanYiBanInfo.vue index c57a1fdf5e..b47b0fb266 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanYiBanInfo.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanYiBanInfo.vue @@ -121,6 +121,47 @@ +
+
挂车列表
+ + + + + + + + + + + + + + + + +
+
+
上装列表
+ + + + + + + + + + + + + + + +
@@ -178,6 +219,8 @@ export default { tableKey: 0, vehicleKey: 1, paymentKey: 2, + trailerKey: 3, + topKey: 4, index: 0, formobj: { billNo: '', // 申请编号 @@ -206,8 +249,10 @@ export default { carBrandSid: '', // 品牌sid carBrandName: '', // 品牌名称 orgSidPath: '', - detailsList: [], - vehicleList: [] + detailsList: [], // 付款信息列表 + vehicleList: [], // 主车车辆列表 + trailerList: [], // 挂车列表 + topList: [] // 上装列表 }, rules: {}, paymentVisible: false, // 付款明细表 -- 新增付款信息弹框 @@ -335,6 +380,16 @@ export default { }, 0) sums[index] += '' this.formobj.carTotal = sums[index] += '' + } else if (column.property === 'costPrice') { + sums[index] = values.reduce((prev, curr) => { + const value = Number(curr) + if (!isNaN(value)) { + return prev + curr + } else { + return prev + } + }, 0) + sums[index] += '' } }) return sums diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/relation/top.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/relation/top.vue new file mode 100644 index 0000000000..91eb9b19f5 --- /dev/null +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/relation/top.vue @@ -0,0 +1,168 @@ + + + + + diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/relation/trailerCar.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/relation/trailerCar.vue new file mode 100644 index 0000000000..bc647f6ae3 --- /dev/null +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/relation/trailerCar.vue @@ -0,0 +1,174 @@ + + + + + diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapply/FinPaymentapplyDetailsVo.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapply/FinPaymentapplyDetailsVo.java index 3d9cbe5cd4..7bde24f907 100644 --- a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapply/FinPaymentapplyDetailsVo.java +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapply/FinPaymentapplyDetailsVo.java @@ -27,6 +27,10 @@ package com.yxt.anrui.fin.api.finpaymentapply; import com.yxt.anrui.fin.api.finpaymentapplydetails.FinPaymentapplyDetailVo; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopDetailsVo; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopDto; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerDetailsVo; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerDto; import com.yxt.anrui.fin.api.finpaymentapplyvehicle.FinPaymentapplyVehicleVo; import com.yxt.common.core.vo.Vo; import io.swagger.annotations.ApiModel; @@ -83,6 +87,10 @@ public class FinPaymentapplyDetailsVo implements Vo { private List detailsList = new ArrayList<>(); private List vehicleList = new ArrayList<>(); + + private List trailerList; + private List topList; + private String isVeh; @ApiModelProperty(value = "品牌sid") diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapply/FinPaymentapplyDto.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapply/FinPaymentapplyDto.java index 7b0bb6816a..6992ecd5fd 100644 --- a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapply/FinPaymentapplyDto.java +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapply/FinPaymentapplyDto.java @@ -27,6 +27,8 @@ package com.yxt.anrui.fin.api.finpaymentapply; import com.yxt.anrui.fin.api.finpaymentapplydetails.FinPaymentapplyDetailDto; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopDto; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerDto; import com.yxt.anrui.fin.api.finpaymentapplyvehicle.FinPaymentapplyVehicleDto; import com.yxt.common.core.dto.Dto; import io.swagger.annotations.ApiModel; @@ -78,6 +80,10 @@ public class FinPaymentapplyDto implements Dto { private List detailsList; private List vehicleList; + + private List trailerList; + private List topList; + @ApiModelProperty("是否涉及车辆,1是,0否") @NotBlank(message = "请选择是否涉及车辆") private String isVeh; diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTop.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTop.java new file mode 100644 index 0000000000..d472cc477f --- /dev/null +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTop.java @@ -0,0 +1,82 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.api.finpaymentapplytop; + +import com.baomidou.mybatisplus.annotation.TableName; +import com.yxt.common.core.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * Project: anrui-fin(付款申请)
+ * File: FinPaymentapplyTop.java
+ * Class: com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTop
+ * Description: 付款申请上装.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2025-01-14 10:55:50
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "付款申请上装", description = "付款申请上装") +@TableName("fin_paymentapply_top") +public class FinPaymentapplyTop extends BaseEntity { + private static final long serialVersionUID = 1L; + + @ApiModelProperty("付款申请sid") + private String applySid; // 付款申请sid + @ApiModelProperty("上装名称") + private String installNameValue; // 上装名称 + @ApiModelProperty("货箱内部尺寸") + private String size; // 货箱内部尺寸 + @ApiModelProperty("车架号") + private String vinNo; // 车架号 + @ApiModelProperty("上装sid") + private String topSid; // 上装sid + @ApiModelProperty("箱体颜色") + private String color; // 箱体颜色 + @ApiModelProperty("厂家结算价") + private BigDecimal costPrice; // 厂家结算价 + @ApiModelProperty("品牌名称") + private String brandName; // 品牌名称 + @ApiModelProperty("车型别名") + private String vehModel; // 车型别名 + @ApiModelProperty("合同编号") + private String contractNo; // 合同编号 + @ApiModelProperty("销售订单号") + private String saleOrderNo; // 销售订单号 + @ApiModelProperty("客户名称") + private String customerName; // 客户名称 + @ApiModelProperty("销售类型") + private String payType; // 销售类型 + +} diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTopDetailsVo.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTopDetailsVo.java new file mode 100644 index 0000000000..e28d88d47d --- /dev/null +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTopDetailsVo.java @@ -0,0 +1,83 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.api.finpaymentapplytop; + + +import com.yxt.common.core.vo.Vo; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * Project: anrui-fin(付款申请)
+ * File: FinPaymentapplyTopVo.java
+ * Class: com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopVo
+ * Description: 付款申请上装 视图数据对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2025-01-14 10:55:50
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "付款申请上装 视图数据详情", description = "付款申请上装 视图数据详情") +public class FinPaymentapplyTopDetailsVo implements Vo { + + private String sid; // sid + + @ApiModelProperty("付款申请sid") + private String applySid; // 付款申请sid + @ApiModelProperty("上装名称") + private String installNameValue; // 上装名称 + @ApiModelProperty("货箱内部尺寸") + private String size; // 货箱内部尺寸 + @ApiModelProperty("车架号") + private String vinNo; // 车架号 + @ApiModelProperty("上装sid") + private String topSid; // 上装sid + @ApiModelProperty("箱体颜色") + private String color; // 箱体颜色 + @ApiModelProperty("厂家结算价") + private BigDecimal costPrice; // 厂家结算价 + @ApiModelProperty("品牌名称") + private String brandName; // 品牌名称 + @ApiModelProperty("车型别名") + private String vehModel; // 车型别名 + @ApiModelProperty("合同编号") + private String contractNo; // 合同编号 + @ApiModelProperty("销售订单号") + private String saleOrderNo; // 销售订单号 + @ApiModelProperty("客户名称") + private String customerName; // 客户名称 + @ApiModelProperty("销售类型") + private String payType; // 销售类型 + +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTopDto.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTopDto.java new file mode 100644 index 0000000000..9377253dde --- /dev/null +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTopDto.java @@ -0,0 +1,83 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.api.finpaymentapplytop; + + +import com.yxt.common.core.dto.Dto; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * Project: anrui-fin(付款申请)
+ * File: FinPaymentapplyTopDto.java
+ * Class: com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopDto
+ * Description: 付款申请上装 数据传输对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2025-01-14 10:55:50
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "付款申请上装 数据传输对象", description = "付款申请上装 数据传输对象") +public class FinPaymentapplyTopDto implements Dto { + + private String sid; // sid + + @ApiModelProperty("付款申请sid") + private String applySid; // 付款申请sid + @ApiModelProperty("上装名称") + private String installNameValue; // 上装名称 + @ApiModelProperty("货箱内部尺寸") + private String size; // 货箱内部尺寸 + @ApiModelProperty("车架号") + private String vinNo; // 车架号 + @ApiModelProperty("上装sid") + private String topSid; // 上装sid + @ApiModelProperty("箱体颜色") + private String color; // 箱体颜色 + @ApiModelProperty("厂家结算价") + private BigDecimal costPrice; // 厂家结算价 + @ApiModelProperty("品牌名称") + private String brandName; // 品牌名称 + @ApiModelProperty("车型别名") + private String vehModel; // 车型别名 + @ApiModelProperty("合同编号") + private String contractNo; // 合同编号 + @ApiModelProperty("销售订单号") + private String saleOrderNo; // 销售订单号 + @ApiModelProperty("客户名称") + private String customerName; // 客户名称 + @ApiModelProperty("销售类型") + private String payType; // 销售类型 + +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTopFeign.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTopFeign.java new file mode 100644 index 0000000000..d9f3f493e1 --- /dev/null +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytop/FinPaymentapplyTopFeign.java @@ -0,0 +1,38 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.api.finpaymentapplytop; + +import io.swagger.annotations.Api; +import org.springframework.cloud.openfeign.FeignClient; + +@Api(tags = "付款申请上装") +@FeignClient( + contextId = "anrui-fin-FinPaymentapplyTop", + name = "anrui-fin", + path = "v1/finpaymentapplytop") +public interface FinPaymentapplyTopFeign { + +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailer.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailer.java new file mode 100644 index 0000000000..ad747ba2f5 --- /dev/null +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailer.java @@ -0,0 +1,84 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.api.finpaymentapplytrailer; + +import com.baomidou.mybatisplus.annotation.TableName; +import com.yxt.common.core.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * Project: anrui-fin(付款申请)
+ * File: FinPaymentapplyTrailer.java
+ * Class: com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailer
+ * Description: 付款申请挂车.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2025-01-14 10:55:50
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "付款申请挂车", description = "付款申请挂车") +@TableName("fin_paymentapply_trailer") +public class FinPaymentapplyTrailer extends BaseEntity { + private static final long serialVersionUID = 1L; + + @ApiModelProperty("付款申请sid") + private String applySid; // 付款申请sid + @ApiModelProperty("挂车名称") + private String trailerTypeValue; // 挂车名称 + @ApiModelProperty("外观尺寸") + private String size; // 外观尺寸 + @ApiModelProperty("车架号") + private String vinNo; // 车架号 + @ApiModelProperty("挂车sid") + private String trailerSid; // 挂车sid + @ApiModelProperty("箱体颜色") + private String color; // 箱体颜色 + @ApiModelProperty("厂家结算价") + private BigDecimal costPrice; // 厂家结算价 + @ApiModelProperty("品牌名称") + private String brandName; // 品牌名称 + @ApiModelProperty("车型别名") + private String vehModel; // 车型别名 + @ApiModelProperty("主车车架号") + private String zcVinNo; // 主车车架号 + @ApiModelProperty("合同编号") + private String contractNo; // 合同编号 + @ApiModelProperty("销售订单号") + private String saleOrderNo; // 销售订单号 + @ApiModelProperty("客户名称") + private String customerName; // 客户名称 + @ApiModelProperty("销售类型") + private String payType; // 销售类型 + +} diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailerDetailsVo.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailerDetailsVo.java new file mode 100644 index 0000000000..11af968f6f --- /dev/null +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailerDetailsVo.java @@ -0,0 +1,85 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.api.finpaymentapplytrailer; + + +import com.yxt.common.core.vo.Vo; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * Project: anrui-fin(付款申请)
+ * File: FinPaymentapplyTrailerVo.java
+ * Class: com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerVo
+ * Description: 付款申请挂车 视图数据对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2025-01-14 10:55:50
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "付款申请挂车 视图数据详情", description = "付款申请挂车 视图数据详情") +public class FinPaymentapplyTrailerDetailsVo implements Vo { + + private String sid; // sid + + @ApiModelProperty("付款申请sid") + private String applySid; // 付款申请sid + @ApiModelProperty("挂车名称") + private String trailerTypeValue; // 挂车名称 + @ApiModelProperty("外观尺寸") + private String size; // 外观尺寸 + @ApiModelProperty("车架号") + private String vinNo; // 车架号 + @ApiModelProperty("挂车sid") + private String trailerSid; // 挂车sid + @ApiModelProperty("箱体颜色") + private String color; // 箱体颜色 + @ApiModelProperty("厂家结算价") + private BigDecimal costPrice; // 厂家结算价 + @ApiModelProperty("品牌名称") + private String brandName; // 品牌名称 + @ApiModelProperty("车型别名") + private String vehModel; // 车型别名 + @ApiModelProperty("主车车架号") + private String zcVinNo; // 主车车架号 + @ApiModelProperty("合同编号") + private String contractNo; // 合同编号 + @ApiModelProperty("销售订单号") + private String saleOrderNo; // 销售订单号 + @ApiModelProperty("客户名称") + private String customerName; // 客户名称 + @ApiModelProperty("销售类型") + private String payType; // 销售类型 + +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailerDto.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailerDto.java new file mode 100644 index 0000000000..fa58d65f7a --- /dev/null +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailerDto.java @@ -0,0 +1,85 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.api.finpaymentapplytrailer; + + +import com.yxt.common.core.dto.Dto; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * Project: anrui-fin(付款申请)
+ * File: FinPaymentapplyTrailerDto.java
+ * Class: com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerDto
+ * Description: 付款申请挂车 数据传输对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2025-01-14 10:55:50
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "付款申请挂车 数据传输对象", description = "付款申请挂车 数据传输对象") +public class FinPaymentapplyTrailerDto implements Dto { + + private String sid; // sid + + @ApiModelProperty("付款申请sid") + private String applySid; // 付款申请sid + @ApiModelProperty("挂车名称") + private String trailerTypeValue; // 挂车名称 + @ApiModelProperty("外观尺寸") + private String size; // 外观尺寸 + @ApiModelProperty("车架号") + private String vinNo; // 车架号 + @ApiModelProperty("挂车sid") + private String trailerSid; // 挂车sid + @ApiModelProperty("箱体颜色") + private String color; // 箱体颜色 + @ApiModelProperty("厂家结算价") + private BigDecimal costPrice; // 厂家结算价 + @ApiModelProperty("品牌名称") + private String brandName; // 品牌名称 + @ApiModelProperty("车型别名") + private String vehModel; // 车型别名 + @ApiModelProperty("主车车架号") + private String zcVinNo; // 主车车架号 + @ApiModelProperty("合同编号") + private String contractNo; // 合同编号 + @ApiModelProperty("销售订单号") + private String saleOrderNo; // 销售订单号 + @ApiModelProperty("客户名称") + private String customerName; // 客户名称 + @ApiModelProperty("销售类型") + private String payType; // 销售类型 + +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailerFeign.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailerFeign.java new file mode 100644 index 0000000000..9a1b1fedb6 --- /dev/null +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/finpaymentapplytrailer/FinPaymentapplyTrailerFeign.java @@ -0,0 +1,38 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.api.finpaymentapplytrailer; + +import io.swagger.annotations.Api; +import org.springframework.cloud.openfeign.FeignClient; + +@Api(tags = "付款申请挂车") +@FeignClient( + contextId = "anrui-fin-FinPaymentapplyTrailer", + name = "anrui-fin", + path = "v1/finpaymentapplytrailer") +public interface FinPaymentapplyTrailerFeign { + +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/kingdee/voucher/GeneralVoucher.java b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/kingdee/voucher/GeneralVoucher.java index 107a51d067..54302d8981 100644 --- a/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/kingdee/voucher/GeneralVoucher.java +++ b/anrui-fin/anrui-fin-api/src/main/java/com/yxt/anrui/fin/api/kingdee/voucher/GeneralVoucher.java @@ -56,5 +56,7 @@ public class GeneralVoucher { public String material; @ApiModelProperty("备注") public String remarks; + @ApiModelProperty("采购系统sid") + public String purchaseSystemSid; } } diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapply/FinPaymentapplyService.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapply/FinPaymentapplyService.java index 6b88a8ad52..ecd019ec91 100644 --- a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapply/FinPaymentapplyService.java +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapply/FinPaymentapplyService.java @@ -48,6 +48,10 @@ import com.yxt.anrui.fin.api.finpaymentapplydetails.FinPaymentapplyDetailDto; import com.yxt.anrui.fin.api.finpaymentapplydetails.FinPaymentapplyDetailVo; import com.yxt.anrui.fin.api.finpaymentapplydetailsbelow.FinPaymentapplyDetailsBelowDetailsVo; import com.yxt.anrui.fin.api.finpaymentapplydetailsbeloweve.FinPaymentapplyDetailsBelowEveDetailsVo; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopDetailsVo; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopDto; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerDetailsVo; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerDto; import com.yxt.anrui.fin.api.finpaymentapplyvehicle.AppFinPaymentapplyVehicleVo; import com.yxt.anrui.fin.api.finpaymentapplyvehicle.FinPaymentapplyVehicleDto; import com.yxt.anrui.fin.api.finpaymentapplyvehicle.FinPaymentapplyVehicleVo; @@ -57,6 +61,8 @@ import com.yxt.anrui.fin.biz.fincompanyinvoicing.FinCompanyInvoicingService; import com.yxt.anrui.fin.biz.finpaymentapplydetails.FinPaymentapplyDetailsService; import com.yxt.anrui.fin.biz.finpaymentapplydetailsbelow.FinPaymentapplyDetailsBelowService; import com.yxt.anrui.fin.biz.finpaymentapplydetailsbeloweve.FinPaymentapplyDetailsBelowEveService; +import com.yxt.anrui.fin.biz.finpaymentapplytop.FinPaymentapplyTopService; +import com.yxt.anrui.fin.biz.finpaymentapplytrailer.FinPaymentapplyTrailerService; import com.yxt.anrui.fin.biz.finpaymentapplyvehicle.FinPaymentapplyVehicleService; import com.yxt.anrui.fin.biz.finpaymentrecord.FinPaymentrecordService; import com.yxt.anrui.flowable.api.flow.FlowableFeign; @@ -128,10 +134,9 @@ public class FinPaymentapplyService extends MybatisBaseService listPageVo(PagerQuery pq) { FinPaymentapplyQuery query = pq.getParams(); @@ -285,6 +286,22 @@ public class FinPaymentapplyService extends MybatisBaseService trailerList = dto.getTrailerList(); + for (FinPaymentapplyTrailerDto finPaymentapplyTrailerDto : trailerList) { + finPaymentapplyTrailerDto.setApplySid(finPaymentapply.getSid()); + finPaymentapplyTrailerService.insertByDto(finPaymentapplyTrailerDto); + } + } + + if ("003".equals(dto.getCostTypeKey())){//上装采购 + List topList = dto.getTopList(); + for (FinPaymentapplyTopDto finPaymentapplyTopDto : topList) { + finPaymentapplyTopDto.setApplySid(finPaymentapply.getSid()); + finPaymentapplyTopService.insertByDto(finPaymentapplyTopDto); + } + } + baseMapper.insert(finPaymentapply); dtoSid = finPaymentapply.getSid(); } else { @@ -309,6 +326,26 @@ public class FinPaymentapplyService extends MybatisBaseService trailerList = dto.getTrailerList(); + for (FinPaymentapplyTrailerDto finPaymentapplyTrailerDto : trailerList) { + finPaymentapplyTrailerDto.setApplySid(dtoSid); + finPaymentapplyTrailerService.insertByDto(finPaymentapplyTrailerDto); + } + } + + if ("003".equals(dto.getCostTypeKey())){//上装采购 + List topList = dto.getTopList(); + for (FinPaymentapplyTopDto finPaymentapplyTopDto : topList) { + finPaymentapplyTopDto.setApplySid(dtoSid); + finPaymentapplyTopService.insertByDto(finPaymentapplyTopDto); + } + } + baseMapper.updateById(finPaymentapply); } return rb.success().setData(dtoSid); @@ -320,7 +357,7 @@ public class FinPaymentapplyService extends MybatisBaseService vehicleList = finPaymentapplyVehicleService.getVehicleList(sid); vo.setDetailsList(detailsList); vo.setVehicleList(vehicleList); + List finPaymentapplyTrailerDetailsVos = finPaymentapplyTrailerService.fetchByMainSid(sid); + List finPaymentapplyTopDetailsVos = finPaymentapplyTopService.fetchByMainSid(sid); + vo.setTrailerList(finPaymentapplyTrailerDetailsVos); + vo.setTopList(finPaymentapplyTopDetailsVos); return vo; } diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopMapper.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopMapper.java new file mode 100644 index 0000000000..3414ef5c1a --- /dev/null +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopMapper.java @@ -0,0 +1,45 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.biz.finpaymentapplytop; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopDetailsVo; +import org.apache.ibatis.annotations.Delete; +import org.apache.ibatis.annotations.Mapper; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTop; +import org.apache.ibatis.annotations.Select; + +import java.util.List; + +@Mapper +public interface FinPaymentapplyTopMapper extends BaseMapper { + + @Delete("delete from fin_paymentapply_top where applySid = #{dtoSid}") + void delByMainSid(String dtoSid); + + @Select("select * from fin_paymentapply_top where applySid = #{mainSid}") + List fetchByMainSid(String mainSid); +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopMapper.xml b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopMapper.xml new file mode 100644 index 0000000000..7c5bc9797d --- /dev/null +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopMapper.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopRest.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopRest.java new file mode 100644 index 0000000000..33c30cd172 --- /dev/null +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopRest.java @@ -0,0 +1,38 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.biz.finpaymentapplytop; + +import io.swagger.annotations.Api; +import org.springframework.web.bind.annotation.*; + +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopFeign; + +@Api(tags = "付款申请上装") +@RestController +@RequestMapping("v1/finpaymentapplytop") +public class FinPaymentapplyTopRest implements FinPaymentapplyTopFeign { + +} diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopService.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopService.java new file mode 100644 index 0000000000..277de88a55 --- /dev/null +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytop/FinPaymentapplyTopService.java @@ -0,0 +1,73 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.biz.finpaymentapplytop; + +import cn.hutool.core.bean.BeanUtil; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import org.apache.commons.lang3.StringUtils; +import com.yxt.common.base.service.MybatisBaseService; +import com.yxt.common.base.utils.PagerUtil; +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.vo.PagerVo; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTop; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopDetailsVo; +import com.yxt.anrui.fin.api.finpaymentapplytop.FinPaymentapplyTopDto; + +import org.springframework.stereotype.Service; + +import java.util.List; + +/** + * Project: anrui-fin(付款申请)
+ * File: FinPaymentapplyTopService.java
+ * Class: com.yxt.anrui.fin.biz.finpaymentapplytop.FinPaymentapplyTopService
+ * Description: 付款申请上装 业务逻辑.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2025-01-14 10:55:50
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Service +public class FinPaymentapplyTopService extends MybatisBaseService { + + public void insertByDto(FinPaymentapplyTopDto dto){ + FinPaymentapplyTop entity = new FinPaymentapplyTop(); + BeanUtil.copyProperties(dto, entity, "id", "sid"); + baseMapper.insert(entity); + } + + public void delByMainSid(String dtoSid) { + baseMapper.delByMainSid(dtoSid); + } + + public List fetchByMainSid(String mainSid) { + return baseMapper.fetchByMainSid(mainSid); + } +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerMapper.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerMapper.java new file mode 100644 index 0000000000..aac8315e08 --- /dev/null +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerMapper.java @@ -0,0 +1,45 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.biz.finpaymentapplytrailer; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerDetailsVo; +import org.apache.ibatis.annotations.Delete; +import org.apache.ibatis.annotations.Mapper; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailer; +import org.apache.ibatis.annotations.Select; + +import java.util.List; + +@Mapper +public interface FinPaymentapplyTrailerMapper extends BaseMapper { + + @Delete("delete from fin_paymentapply_trailer where applySid = #{dtoSid}") + void delByMainSid(String dtoSid); + + @Select("select * from fin_paymentapply_trailer where applySid = #{mainSid}") + List fetchByMainSid(String mainSid); +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerMapper.xml b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerMapper.xml new file mode 100644 index 0000000000..557cfea410 --- /dev/null +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerMapper.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerRest.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerRest.java new file mode 100644 index 0000000000..775cde4c32 --- /dev/null +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerRest.java @@ -0,0 +1,38 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.biz.finpaymentapplytrailer; + +import io.swagger.annotations.Api; +import org.springframework.web.bind.annotation.*; + +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerFeign; + +@Api(tags = "付款申请挂车") +@RestController +@RequestMapping("v1/finpaymentapplytrailer") +public class FinPaymentapplyTrailerRest implements FinPaymentapplyTrailerFeign { + +} diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerService.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerService.java new file mode 100644 index 0000000000..967328bd51 --- /dev/null +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentapplytrailer/FinPaymentapplyTrailerService.java @@ -0,0 +1,73 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.fin.biz.finpaymentapplytrailer; + +import cn.hutool.core.bean.BeanUtil; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import org.apache.commons.lang3.StringUtils; +import com.yxt.common.base.service.MybatisBaseService; +import com.yxt.common.base.utils.PagerUtil; +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.vo.PagerVo; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailer; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerDetailsVo; +import com.yxt.anrui.fin.api.finpaymentapplytrailer.FinPaymentapplyTrailerDto; + +import org.springframework.stereotype.Service; + +import java.util.List; + +/** + * Project: anrui-fin(付款申请)
+ * File: FinPaymentapplyTrailerService.java
+ * Class: com.yxt.anrui.fin.biz.finpaymentapplytrailer.FinPaymentapplyTrailerService
+ * Description: 付款申请挂车 业务逻辑.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2025-01-14 10:55:50
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Service +public class FinPaymentapplyTrailerService extends MybatisBaseService { + + public void insertByDto(FinPaymentapplyTrailerDto dto){ + FinPaymentapplyTrailer entity = new FinPaymentapplyTrailer(); + BeanUtil.copyProperties(dto, entity, "id", "sid"); + baseMapper.insert(entity); + } + + public void delByMainSid(String dtoSid) { + baseMapper.delByMainSid(dtoSid); + } + + public List fetchByMainSid(String mainSid) { + return baseMapper.fetchByMainSid(mainSid); + } +} \ No newline at end of file diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentrecord/FinPaymentrecordService.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentrecord/FinPaymentrecordService.java index 7e0ba504fe..3c1d6edec8 100644 --- a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentrecord/FinPaymentrecordService.java +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finpaymentrecord/FinPaymentrecordService.java @@ -986,7 +986,7 @@ public class FinPaymentrecordService extends MybatisBaseService voucherDetails = voucher.getVoucherDetails(); + BigDecimal shangnian = BigDecimal.ZERO;//上年 + BigDecimal bennian = BigDecimal.ZERO;//本年 + BigDecimal total = BigDecimal.ZERO;//合计 + String deptNo = ""; + String manufacturer = ""; + String timeFlag = ""; if (!voucherDetails.isEmpty()) { for (GeneralVoucher.GeneralVoucherDetail voucherDetail : voucherDetails) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); //借方 - Voucher.VoucherResultDetailDto dto2 = new Voucher.VoucherResultDetailDto(); //贷方 - dto1.setSummary(voucherDetail.getTimeFlag() + "单车返利预提预留费用"); - dto2.setSummary(voucherDetail.getTimeFlag() + "单车返利预提预留费用"); + BigDecimal amount = voucherDetail.getAmount(); if (voucherDetail.getSceneCode().equals("上年")) { - dto1.setSubjectNo("1161.02.15"); + shangnian = shangnian.add(amount); } else if (voucherDetail.getSceneCode().equals("本年")) { - dto1.setSubjectNo("1161.01.15"); + bennian = bennian.add(amount); } - dto2.setSubjectNo("2181.07.00"); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto2.setDimensionCustom(voucherDetail.getCustomerCode()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - dto2.setCredit(String.valueOf(voucherDetail.getAmount())); + total = total.add(amount); + deptNo = voucherDetail.getDeptCode(); + manufacturer = voucherDetail.getManufacturer(); + timeFlag = voucherDetail.getTimeFlag(); + } + if (shangnian.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); //借方 + dto1.setSummary(timeFlag + "单车返利预提预留费用"); + dto1.setSubjectNo("1161.02.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(shangnian)); resultDetails.add(dto1); - resultDetails.add(dto2); } + if (bennian.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); //借方 + dto1.setSummary(timeFlag + "单车返利预提预留费用"); + dto1.setSubjectNo("1161.01.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(bennian)); + resultDetails.add(dto1); + } + Voucher.VoucherResultDetailDto dto2 = new Voucher.VoucherResultDetailDto(); //贷方 + dto2.setSummary(timeFlag + "单车返利预提预留费用"); + dto2.setSubjectNo("2181.07.00"); + dto2.setDimensionCustom("DZFCJFL"); + dto2.setCredit(String.valueOf(total)); + resultDetails.add(dto2); newVoucher.setResultDetails(resultDetails); } log.info("FinKingDeeFeignRest-saveVoucher:{}", JSONObject.toJSONString(newVoucher)); @@ -366,18 +389,26 @@ public class FinKingDeeFeignRest implements FinKingDeeFeign { if (StringUtils.isNotBlank(voucher.getBussDate())) { newVoucher.setBussDate(voucher.getBussDate()); } + BigDecimal cjwdx = BigDecimal.ZERO;// 单车厂家未兑现返利 + BigDecimal shangnian = BigDecimal.ZERO;// 单车上年返利 + BigDecimal bennian = BigDecimal.ZERO;// 单车本年返利 + BigDecimal qtdk = BigDecimal.ZERO;// 单车应收厂家返利其他垫款 + BigDecimal sntz = BigDecimal.ZERO;// 上年返利调整 + BigDecimal bntz = BigDecimal.ZERO;// 本年返利调整 + BigDecimal qttz = BigDecimal.ZERO;// 其他应付调整 + BigDecimal cjwdxJR = BigDecimal.ZERO;// 厂家未兑现返利金融 + String deptNo = ""; + String manufacturer = ""; + String timeFlag = ""; List voucherDetails = voucher.getVoucherDetails(); if (!voucherDetails.isEmpty()) { for (GeneralVoucher.GeneralVoucherDetail voucherDetail : voucherDetails) { + timeFlag = voucherDetail.getTimeFlag(); + deptNo = voucherDetail.getDeptCode(); + manufacturer = voucherDetail.getManufacturer(); if (voucherDetail.getRemarks().equals("金融贴息")) { if (voucherDetail.getSceneCode().equals("1161.01.16")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "金融贴息上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + cjwdxJR = cjwdxJR.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("1161.02.19") || voucherDetail.getSceneCode().equals("1161.01.19")) { Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); @@ -393,48 +424,100 @@ public class FinKingDeeFeignRest implements FinKingDeeFeign { } if (voucherDetail.getRemarks().equals("返利上传")) { if (voucherDetail.getSceneCode().equals("1161.01.16")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "单车返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + cjwdx = cjwdx.add(voucherDetail.getAmount()); } - if (voucherDetail.getSceneCode().equals("1161.02.15") || - voucherDetail.getSceneCode().equals("1161.01.15") || - voucherDetail.getSceneCode().equals("1161.04.00")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "单车返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setCredit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + if (voucherDetail.getSceneCode().equals("1161.02.15")) { + shangnian = shangnian.add(voucherDetail.getAmount()); + } + if (voucherDetail.getSceneCode().equals("1161.01.15")) { + bennian = bennian.add(voucherDetail.getAmount()); + } + if (voucherDetail.getSceneCode().equals("1161.04.00")) { + qtdk = qtdk.add(voucherDetail.getAmount()); } } - if (voucherDetail.getRemarks().equals("预留费用调整")) { - if (voucherDetail.getSceneCode().equals("1161.02.15") || voucherDetail.getSceneCode().equals("1161.01.15")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "返利上传预留费用调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + if (voucherDetail.getSceneCode().equals("1161.02.15")) { + sntz = sntz.add(voucherDetail.getAmount()); + } + if (voucherDetail.getSceneCode().equals("1161.01.15")) { + bntz = bntz.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("2181.07.00")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "返利上传预留费用调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionCustom(voucherDetail.getCustomerCode()); - dto1.setCredit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + qttz = qttz.add(voucherDetail.getAmount()); } } - - + } + if (cjwdxJR.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "金融贴息上传"); + dto1.setSubjectNo("1161.01.16"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(cjwdxJR)); + resultDetails.add(dto1); + } + if (cjwdx.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "单车返利上传"); + dto1.setSubjectNo("1161.01.16"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(cjwdx)); + resultDetails.add(dto1); + } + if (shangnian.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "单车返利上传"); + dto1.setSubjectNo("1161.02.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(shangnian)); + resultDetails.add(dto1); + } + if (bennian.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "单车返利上传"); + dto1.setSubjectNo("1161.01.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(bennian)); + resultDetails.add(dto1); + } + if (qtdk.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "单车返利上传"); + dto1.setSubjectNo("1161.04.00"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(qtdk)); + resultDetails.add(dto1); + } + if (sntz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "返利上传预留费用调整"); + dto1.setSubjectNo("1161.02.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(sntz)); + resultDetails.add(dto1); + } + if (bntz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "返利上传预留费用调整"); + dto1.setSubjectNo("1161.01.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(bntz)); + resultDetails.add(dto1); + } + if (qttz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "返利上传预留费用调整"); + dto1.setSubjectNo("2181.07.00"); + dto1.setDimensionCustom("DZFCJFL"); + dto1.setCredit(String.valueOf(qttz)); + resultDetails.add(dto1); } newVoucher.setResultDetails(resultDetails); } @@ -454,35 +537,65 @@ public class FinKingDeeFeignRest implements FinKingDeeFeign { if (StringUtils.isNotBlank(voucher.getBussDate())) { newVoucher.setBussDate(voucher.getBussDate()); } + BigDecimal snfl = BigDecimal.ZERO;//上年返利 + BigDecimal bnfl = BigDecimal.ZERO;//本年返利 + BigDecimal cjfl = BigDecimal.ZERO;//厂家返利 + BigDecimal qtfl = BigDecimal.ZERO;//其他应付款 + String deptNo = ""; + String manufacturer = ""; + String timeFlag = ""; List voucherDetails = voucher.getVoucherDetails(); if (!voucherDetails.isEmpty()) { for (GeneralVoucher.GeneralVoucherDetail voucherDetail : voucherDetails) { - if (voucherDetail.getSceneCode().equals("1161.02.15") || voucherDetail.getSceneCode().equals("1161.01.15")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利预提"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + deptNo = voucherDetail.getDeptCode(); + manufacturer = voucherDetail.getManufacturer(); + timeFlag = voucherDetail.getTimeFlag(); + if (voucherDetail.getSceneCode().equals("1161.02.15")) { + snfl = snfl.add(voucherDetail.getAmount()); + } + if (voucherDetail.getSceneCode().equals("1161.01.15")) { + bnfl = bnfl.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("6401.13")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利预提"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setDebit(voucherDetail.getAmount().negate().toString());//转负数 - resultDetails.add(dto1); + cjfl = cjfl.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("2181.07.00")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利预提"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionCustom(voucherDetail.getCustomerCode()); - dto1.setCredit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + qtfl = qtfl.add(voucherDetail.getAmount()); } - + } + if (snfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利预提"); + dto1.setSubjectNo("1161.02.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(snfl)); + resultDetails.add(dto1); + } + if (bnfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利预提"); + dto1.setSubjectNo("1161.01.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(bnfl)); + resultDetails.add(dto1); + } + if (cjfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利预提"); + dto1.setSubjectNo("6401.13"); + dto1.setDimensionDept(deptNo); + dto1.setDebit(cjfl.negate().toString());//转负数 + resultDetails.add(dto1); + } + if (qtfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利预提"); + dto1.setSubjectNo("2181.07.00"); + dto1.setDimensionCustom("DZFCJFL"); + dto1.setCredit(String.valueOf(qtfl)); + resultDetails.add(dto1); } newVoucher.setResultDetails(resultDetails); } @@ -502,118 +615,217 @@ public class FinKingDeeFeignRest implements FinKingDeeFeign { if (StringUtils.isNotBlank(voucher.getBussDate())) { newVoucher.setBussDate(voucher.getBussDate()); } + BigDecimal cjflxx = BigDecimal.ZERO;//厂家未兑现行销 + BigDecimal qtyfxx = BigDecimal.ZERO;//其他应付行销 + BigDecimal dkxx = BigDecimal.ZERO;//垫款行销 + BigDecimal qtdkxx = BigDecimal.ZERO;//其他垫款行销 + BigDecimal srlxx = BigDecimal.ZERO;//收入行销 + BigDecimal dkxxtz = BigDecimal.ZERO;//垫款行销调整 + BigDecimal srxxtz = BigDecimal.ZERO;//收入行销调整 + BigDecimal cjfl = BigDecimal.ZERO;//厂家未兑现 + BigDecimal snfl = BigDecimal.ZERO;//上年返利 + BigDecimal bnfl = BigDecimal.ZERO;//本年返利 + BigDecimal qtdk = BigDecimal.ZERO;//其他垫款 + BigDecimal snfltz = BigDecimal.ZERO;//上年返利调整 + BigDecimal bnfltz = BigDecimal.ZERO;//本年返利调整 + BigDecimal cjfltz = BigDecimal.ZERO;//厂家返利调整 + BigDecimal qtyftz = BigDecimal.ZERO;//其他应付调整 + String timeFlag = ""; + String deptNo = ""; + String manufacturer = ""; List voucherDetails = voucher.getVoucherDetails(); if (!voucherDetails.isEmpty()) { for (GeneralVoucher.GeneralVoucherDetail voucherDetail : voucherDetails) { + timeFlag = voucherDetail.getTimeFlag(); + deptNo = voucherDetail.getDeptCode(); + manufacturer = voucherDetail.getManufacturer(); if (!voucherDetail.getType().equals("行销活动")) { if (voucherDetail.getRemarks().equals("返利上传")) { if (voucherDetail.getSceneCode().equals("1161.01.16")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + cjfl = cjfl.add(voucherDetail.getAmount()); + } + if (voucherDetail.getSceneCode().equals("1161.02.15")) { + snfl = snfl.add(voucherDetail.getAmount()); + } + if (voucherDetail.getSceneCode().equals("1161.01.15")) { + bnfl = bnfl.add(voucherDetail.getAmount()); } - if (voucherDetail.getSceneCode().equals("1161.02.15") || - voucherDetail.getSceneCode().equals("1161.01.15") || - voucherDetail.getSceneCode().equals("1161.04.00")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setCredit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + if (voucherDetail.getSceneCode().equals("1161.04.00")) { + qtdk = qtdk.add(voucherDetail.getAmount()); } } if (voucherDetail.getRemarks().equals("返利调整")) { - if (voucherDetail.getSceneCode().equals("1161.02.15") || voucherDetail.getSceneCode().equals("1161.01.15")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + if (voucherDetail.getSceneCode().equals("1161.02.15")) { + snfltz = snfltz.add(voucherDetail.getAmount()); + } + if (voucherDetail.getSceneCode().equals("1161.01.15")) { + bnfltz = bnfltz.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("6401.13")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setDebit(voucherDetail.getAmount().negate().toString()); - resultDetails.add(dto1); + cjfltz = cjfltz.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("2181.07.00")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionCustom(voucherDetail.getCustomerCode()); - dto1.setCredit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + qtyftz = qtyftz.add(voucherDetail.getAmount()); } } } else { if (voucherDetail.getRemarks().equals("返利上传")) { if (voucherDetail.getSceneCode().equals("1161.01.16")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "行销返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + cjflxx = cjflxx.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("2181.07.00")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "行销返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionCustom(voucherDetail.getCustomerCode()); - dto1.setCredit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + qtyfxx = qtyfxx.add(voucherDetail.getAmount()); + } + if (voucherDetail.getSceneCode().equals("1161.03.00")) { + dkxx = dkxx.add(voucherDetail.getAmount()); } - if (voucherDetail.getSceneCode().equals("1161.03.00") || - voucherDetail.getSceneCode().equals("1161.04.00")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "行销返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setCredit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + if (voucherDetail.getSceneCode().equals("1161.04.00")) { + qtdkxx = qtdkxx.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("6401.14")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "行销返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setCredit(voucherDetail.getAmount().negate().toString()); - resultDetails.add(dto1); + srlxx = srlxx.add(voucherDetail.getAmount()); } } if (voucherDetail.getRemarks().equals("返利调整")) { if (voucherDetail.getSceneCode().equals("1161.03.00")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + dkxxtz = dkxxtz.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("6401.14")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "专项返利调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setDebit(voucherDetail.getAmount().negate().toString()); - resultDetails.add(dto1); + srxxtz = srxxtz.add(voucherDetail.getAmount()); } } } } + if (cjfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利上传"); + dto1.setSubjectNo("1161.01.16"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(cjfl)); + resultDetails.add(dto1); + } + if (snfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利上传"); + dto1.setSubjectNo("1161.02.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(snfl)); + resultDetails.add(dto1); + } + if (bnfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利上传"); + dto1.setSubjectNo("1161.01.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(bnfl)); + resultDetails.add(dto1); + } + if (qtdk.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利上传"); + dto1.setSubjectNo("1161.04.00"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(qtdk)); + resultDetails.add(dto1); + } + if (snfltz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利调整"); + dto1.setSubjectNo("1161.02.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(snfltz)); + resultDetails.add(dto1); + } + if (bnfltz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利调整"); + dto1.setSubjectNo("1161.01.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(bnfltz)); + resultDetails.add(dto1); + } + if (cjfltz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利调整"); + dto1.setSubjectNo("6401.13"); + dto1.setDimensionDept(deptNo); + dto1.setDebit(cjfltz.negate().toString()); + resultDetails.add(dto1); + } + if (qtyftz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利调整"); + dto1.setSubjectNo("2181.07.00"); + dto1.setDimensionCustom("DZFCJFL"); + dto1.setCredit(String.valueOf(qtyftz)); + resultDetails.add(dto1); + } + if (cjflxx.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "行销返利上传"); + dto1.setSubjectNo("1161.01.16"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(cjflxx)); + resultDetails.add(dto1); + } + if (qtyfxx.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "行销返利上传"); + dto1.setSubjectNo("2181.07.00"); + dto1.setDimensionCustom("DZFCJFL"); + dto1.setCredit(String.valueOf(qtyfxx)); + resultDetails.add(dto1); + } + if (dkxx.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "行销返利上传"); + dto1.setSubjectNo("1161.03.00"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(dkxx)); + resultDetails.add(dto1); + } + if (qtdkxx.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "行销返利上传"); + dto1.setSubjectNo("1161.04.00"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(qtdkxx)); + resultDetails.add(dto1); + } + if (srlxx.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "行销返利上传"); + dto1.setSubjectNo("6401.14"); + dto1.setDimensionDept(deptNo); + dto1.setCredit(srlxx.negate().toString()); + resultDetails.add(dto1); + } + if (dkxxtz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利调整"); + dto1.setSubjectNo("1161.03.00"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(dkxxtz)); + resultDetails.add(dto1); + } + if (srxxtz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "专项返利调整"); + dto1.setSubjectNo("6401.14"); + dto1.setDimensionDept(deptNo); + dto1.setDebit(srxxtz.negate().toString()); + resultDetails.add(dto1); + } newVoucher.setResultDetails(resultDetails); } log.info("FinKingDeeFeignRest-saveVoucher:{}", JSONObject.toJSONString(newVoucher)); @@ -632,27 +844,54 @@ public class FinKingDeeFeignRest implements FinKingDeeFeign { if (StringUtils.isNotBlank(voucher.getBussDate())) { newVoucher.setBussDate(voucher.getBussDate()); } + BigDecimal sn = BigDecimal.ZERO; //上年返利 + BigDecimal bn = BigDecimal.ZERO;//本年返利 + BigDecimal cd = BigDecimal.ZERO;//承兑贴息 + String timeFlag = ""; + String deptNo = ""; + String manufacturer = ""; List voucherDetails = voucher.getVoucherDetails(); if (!voucherDetails.isEmpty()) { for (GeneralVoucher.GeneralVoucherDetail voucherDetail : voucherDetails) { - if (voucherDetail.getSceneCode().equals("1161.02.15") || voucherDetail.getSceneCode().equals("1161.01.15")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "回款返利预提"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); + timeFlag = voucherDetail.getTimeFlag(); + deptNo = voucherDetail.getDeptCode(); + manufacturer = voucherDetail.getManufacturer(); + if (voucherDetail.getSceneCode().equals("1161.02.15")) { + sn = sn.add(voucherDetail.getAmount()); + } + if (voucherDetail.getSceneCode().equals("1161.01.15")) { + bn = bn.add(voucherDetail.getAmount()); } if (voucherDetail.getSceneCode().equals("2191.03")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "回款返利预提"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setCredit(voucherDetail.getAmount().toString()); - resultDetails.add(dto1); + cd = cd.add(voucherDetail.getAmount()); } } + if (sn.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利预提"); + dto1.setSubjectNo("1161.02.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(sn)); + resultDetails.add(dto1); + } + if (bn.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利预提"); + dto1.setSubjectNo("1161.01.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(bn)); + resultDetails.add(dto1); + } + if (cd.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利预提"); + dto1.setSubjectNo("2191.03"); + dto1.setDimensionDept(deptNo); + dto1.setCredit(cd.toString()); + resultDetails.add(dto1); + } newVoucher.setResultDetails(resultDetails); } log.info("FinKingDeeFeignRest-saveVoucher:{}", JSONObject.toJSONString(newVoucher)); @@ -671,59 +910,110 @@ public class FinKingDeeFeignRest implements FinKingDeeFeign { if (StringUtils.isNotBlank(voucher.getBussDate())) { newVoucher.setBussDate(voucher.getBussDate()); } + BigDecimal cjfl = BigDecimal.ZERO;//厂家未兑现 + BigDecimal snfl = BigDecimal.ZERO;//上年返利 + BigDecimal bnfl = BigDecimal.ZERO;//本年返利 + BigDecimal cjfltz = BigDecimal.ZERO;//厂家返利调整 + BigDecimal snfltz = BigDecimal.ZERO;//上年返利调整 + BigDecimal bnfltz = BigDecimal.ZERO;//本年返利调整 + BigDecimal ndsy = BigDecimal.ZERO;//以前年度损益 + String timeFlag = ""; + String deptNo = ""; + String manufacturer = ""; List voucherDetails = voucher.getVoucherDetails(); if (!voucherDetails.isEmpty()) { for (GeneralVoucher.GeneralVoucherDetail voucherDetail : voucherDetails) { - if (voucherDetail.getRemarks().equals("返利上传")) { - if (voucherDetail.getSceneCode().equals("1161.01.16")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "回款返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); - } - if (voucherDetail.getSceneCode().equals("1161.02.15") || - voucherDetail.getSceneCode().equals("1161.01.15")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "回款返利上传"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setCredit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); - } + timeFlag = voucherDetail.getTimeFlag(); + deptNo = voucherDetail.getDeptCode(); + manufacturer = voucherDetail.getManufacturer(); + BigDecimal amount = voucherDetail.getAmount(); + if (voucherDetail.getRemarks().equals("返利上传")) { + if (voucherDetail.getSceneCode().equals("1161.01.16")) { + cjfl = cjfl.add(amount); } - if (voucherDetail.getRemarks().equals("返利调整")) { - if (voucherDetail.getSceneCode().equals("6401.13")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "回款返利上传调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setDebit(voucherDetail.getAmount().negate().toString()); - resultDetails.add(dto1); - } - if (voucherDetail.getSceneCode().equals("1161.01.15") || voucherDetail.getSceneCode().equals("1161.02.15")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "回款返利上传调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setDimensionDept(voucherDetail.getDeptCode()); - dto1.setManufacturer(voucherDetail.getManufacturer()); - dto1.setDebit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); - } - if (voucherDetail.getSceneCode().equals("6801")) { - Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); - dto1.setSummary(voucherDetail.getTimeFlag() + "回款返利上传调整"); - dto1.setSubjectNo(voucherDetail.getSceneCode()); - dto1.setCredit(String.valueOf(voucherDetail.getAmount())); - resultDetails.add(dto1); - } + if (voucherDetail.getSceneCode().equals("1161.02.15")) { + snfl = snfl.add(amount); } - + if (voucherDetail.getSceneCode().equals("1161.01.15")) { + bnfl = bnfl.add(amount); + } + } + if (voucherDetail.getRemarks().equals("返利调整")) { + if (voucherDetail.getSceneCode().equals("6401.13")) { + cjfltz = cjfltz.add(amount); + } + if (voucherDetail.getSceneCode().equals("1161.01.15")) { + bnfltz = bnfltz.add(amount); + } + if (voucherDetail.getSceneCode().equals("1161.02.15")) { + snfltz = snfltz.add(amount); + } + if (voucherDetail.getSceneCode().equals("6801")) { + ndsy = ndsy.add(amount); + } + } + } + if (cjfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利上传"); + dto1.setSubjectNo("1161.01.16"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(cjfl)); + resultDetails.add(dto1); + } + if (snfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利上传"); + dto1.setSubjectNo("1161.02.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(snfl)); + resultDetails.add(dto1); + } + if (bnfl.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利上传"); + dto1.setSubjectNo("1161.01.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setCredit(String.valueOf(bnfl)); + resultDetails.add(dto1); + } + if (cjfltz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利上传调整"); + dto1.setSubjectNo("6401.13"); + dto1.setDimensionDept(deptNo); + dto1.setDebit(cjfltz.negate().toString()); + resultDetails.add(dto1); + } + if (bnfltz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利上传调整"); + dto1.setSubjectNo("1161.01.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(bnfltz)); + resultDetails.add(dto1); + } + if (snfltz.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利上传调整"); + dto1.setSubjectNo("1161.02.15"); + dto1.setDimensionDept(deptNo); + dto1.setManufacturer(manufacturer); + dto1.setDebit(String.valueOf(snfltz)); + resultDetails.add(dto1); + newVoucher.setResultDetails(resultDetails); + } + if (ndsy.compareTo(BigDecimal.ZERO) != 0) { + Voucher.VoucherResultDetailDto dto1 = new Voucher.VoucherResultDetailDto(); + dto1.setSummary(timeFlag + "回款返利上传调整"); + dto1.setSubjectNo("6801"); + dto1.setCredit(String.valueOf(ndsy)); + resultDetails.add(dto1); } - newVoucher.setResultDetails(resultDetails); } log.info("FinKingDeeFeignRest-saveVoucher:{}", JSONObject.toJSONString(newVoucher)); return voucherService.saveVoucher(newVoucher); diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/kingdee/costadjustmentsbill/data_model.json b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/kingdee/costadjustmentsbill/data_model.json index a8946395d2..9d9d85ada3 100644 --- a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/kingdee/costadjustmentsbill/data_model.json +++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/kingdee/costadjustmentsbill/data_model.json @@ -18,10 +18,6 @@ "FACCTPOLICYID": { "FNumber": "KJZC01_SYS" }, - "FCurrencyID": { - "FNumber": "" - }, - "FAdjustmentReason": "", "FAcctgId": "0", "FDocumentStatus": "Z", "FCreateDate": "@KD_FDATE", diff --git a/anrui-fin/anrui-fin-biz/src/main/resources/ftl/prePaymentApply.ftl b/anrui-fin/anrui-fin-biz/src/main/resources/ftl/prePaymentApply.ftl index 31666accb7..fc6a555a5d 100644 --- a/anrui-fin/anrui-fin-biz/src/main/resources/ftl/prePaymentApply.ftl +++ b/anrui-fin/anrui-fin-biz/src/main/resources/ftl/prePaymentApply.ftl @@ -118,57 +118,35 @@ - - - - - - - + + + + + + - - - - - - - + - - + + - - - - - - - - - - - - - - - - - + - + - - + - + @@ -181,26 +159,38 @@ - - + + ${applyCode!} + + + + + + - - + - - + + + + + + + @@ -212,10 +202,15 @@ - - + + + + + + @@ -919,39 +914,6 @@ - - - - - - - - - - - - 下载人: - - - - - - ${downName!} - - - - - - 下载时间: - - - - - - ${downTime!} - - @@ -1046,6 +1008,46 @@ + + + + + + + + + + + + 下载人: + + + + + + ${downName!} + + + + + + + + + + + + + 下载时间: + + + + + + ${downTime!} + + diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanbecollectionapply/LoanBeCollectionApplyService.java b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanbecollectionapply/LoanBeCollectionApplyService.java index 1c3fd77063..dab39047a3 100644 --- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanbecollectionapply/LoanBeCollectionApplyService.java +++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanbecollectionapply/LoanBeCollectionApplyService.java @@ -522,7 +522,7 @@ public class LoanBeCollectionApplyService extends MybatisBaseService loanBeCollectionVehDetails = dto.getLoanBeCollectionVehDetails(); if (collMeasures.contains("远程控制")) { for (LoanBeCollectionVehDto loanBeCollectionVehDetail : loanBeCollectionVehDetails) { - int i = loanBeCollectionVehService.selKzStateBySaleVehSid(loanBeCollectionVehDetail.getSaleVehSid()); + int i = loanBeCollectionVehService.selKzStateBySaleVehSid(loanBeCollectionVehDetail.getSaleVehSid(),dto.getSid()); if (i > 0) { return rb.setMsg("车架号" + loanBeCollectionVehDetail.getVinNo() + "已存在审批中(待控制/控制成功),不可再次勾选远程控制措施。"); } diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanbecollectionveh/LoanBeCollectionVehMapper.java b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanbecollectionveh/LoanBeCollectionVehMapper.java index 89ea0dc890..cc6a5b2841 100644 --- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanbecollectionveh/LoanBeCollectionVehMapper.java +++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanbecollectionveh/LoanBeCollectionVehMapper.java @@ -73,7 +73,7 @@ public interface LoanBeCollectionVehMapper extends BaseMapper