Browse Source

Merge remote-tracking branch 'origin/master'

master
God 8 months ago
parent
commit
af1444cbab
  1. 16
      anrui-riskcenter-ui/src/views/customerrepayment/customerrepayment.vue
  2. 6
      anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanrepaymentschedule/LoanRepaymentScheduleFeign.java
  3. 5
      anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanrepaymentschedule/LoanRepaymentScheduleFeignFallback.java
  4. 14
      anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanrepaymentschedule/historyData/ImportBondAmountsUpdate.java
  5. 14
      anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanrepaymentschedule/historyData/ImportBondAmountsVo.java
  6. 6
      anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanrepaymentschedule/LoanRepaymentScheduleMapper.java
  7. 85
      anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanrepaymentschedule/LoanRepaymentScheduleMapper.xml
  8. 5
      anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanrepaymentschedule/LoanRepaymentScheduleRest.java
  9. 160
      anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanrepaymentschedule/LoanRepaymentScheduleService.java
  10. 12
      anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loansettleapply/LoanSettleApplyService.java
  11. 2
      anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatecheck/relation/yiheduidanchefanli.vue
  12. 73
      anrui-scm/anrui-scm-ui/src/views/kucunguanli/tiaojiaguanli/priceAdd.vue
  13. 13
      anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatecheck/relation/yiheduizhuanxiangfanli.vue
  14. 293
      anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatecheck/specialrebatetobechecked.vue
  15. 15
      anrui-scm/anrui-scm-ui/src/views/workFlow/danchefanliheduiFlow/relation/yiheduidanchefanli.vue
  16. 49
      anrui-scm/anrui-scm-ui/src/views/workFlow/tiaojiaguanliFlow/tiaojiaguanli/tiaojiaEdit.vue
  17. 13
      anrui-scm/anrui-scm-ui/src/views/workFlow/zhuanxiangfanliheduiFlow/relation/yiheduizhuanxiangfanli.vue

16
anrui-riskcenter-ui/src/views/customerrepayment/customerrepayment.vue

@ -216,6 +216,13 @@ export default {
btnKey: 'recordImport', btnKey: 'recordImport',
btnLabel: '生成休眠还款记录' btnLabel: '生成休眠还款记录'
}, },
{
type: 'primary',
size: 'small',
icon: 'Import',
btnKey: 'loansImport',
btnLabel: '导入贷款保证金'
},
{ {
type: 'primary', type: 'primary',
size: 'small', size: 'small',
@ -343,6 +350,9 @@ export default {
case 'recordImport': case 'recordImport':
this.recordImport() this.recordImport()
break break
case 'loansImport':
this.loansImport()
break
case 'doExport': case 'doExport':
this.doExport() this.doExport()
break break
@ -432,6 +442,12 @@ export default {
this.fileList = [] this.fileList = []
this.uploadResultMesssage = '' this.uploadResultMesssage = ''
}, },
loansImport() {
this.dialogVisible = true
this.updateAction = process.env.VUE_APP_BASE_API + '/riskcenter/v1/loanrepaymentschedule/importBondAmountsData'
this.fileList = []
this.uploadResultMesssage = ''
},
recordImport() { recordImport() {
const tip = '请确认是否生成休眠数据还款记录' const tip = '请确认是否生成休眠数据还款记录'
this.$confirm(tip, '提示', { this.$confirm(tip, '提示', {

6
anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanrepaymentschedule/LoanRepaymentScheduleFeign.java

@ -97,6 +97,12 @@ public interface LoanRepaymentScheduleFeign {
public ResultBean importSleepHistoryData(@RequestParam("userSid") String userSid); public ResultBean importSleepHistoryData(@RequestParam("userSid") String userSid);
@ApiOperation(value = "导入历史数据贷款保证金")
@PostMapping("/importBondAmountsData")
public ResultBean importBondAmountsData(
@RequestParam(value = "file") MultipartFile file, HttpServletRequest request) throws IOException;
@ApiOperation("根据还款计划明细返回资方sid") @ApiOperation("根据还款计划明细返回资方sid")
@GetMapping("/returnBankOrOtherBankByPlanSid") @GetMapping("/returnBankOrOtherBankByPlanSid")
@ResponseBody @ResponseBody

5
anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanrepaymentschedule/LoanRepaymentScheduleFeignFallback.java

@ -88,6 +88,11 @@ public class LoanRepaymentScheduleFeignFallback implements LoanRepaymentSchedule
return null; return null;
} }
@Override
public ResultBean importBondAmountsData(MultipartFile file, HttpServletRequest request) throws IOException {
return null;
}
@Override @Override
public ResultBean<String> returnBankOrOtherBankByPlanSid(String planSid) { public ResultBean<String> returnBankOrOtherBankByPlanSid(String planSid) {
return null; return null;

14
anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanrepaymentschedule/historyData/ImportBondAmountsUpdate.java

@ -0,0 +1,14 @@
package com.yxt.anrui.riskcenter.api.loanrepaymentschedule.historyData;
import lombok.Data;
/**
* @author Fan
* @description
* @date 2024/9/6 15:43
*/
@Data
public class ImportBondAmountsUpdate {
private String sid;
private String bondAmounts;
}

14
anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanrepaymentschedule/historyData/ImportBondAmountsVo.java

@ -0,0 +1,14 @@
package com.yxt.anrui.riskcenter.api.loanrepaymentschedule.historyData;
import lombok.Data;
/**
* @author Fan
* @description
* @date 2024/9/6 14:48
*/
@Data
public class ImportBondAmountsVo {
private String vinNo;
private String bondAmounts;
}

6
anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanrepaymentschedule/LoanRepaymentScheduleMapper.java

@ -7,11 +7,13 @@ import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.yxt.anrui.buscenter.api.bussalesorderloancontract.LoanRepaymentPlanDetailsExportVo; import com.yxt.anrui.buscenter.api.bussalesorderloancontract.LoanRepaymentPlanDetailsExportVo;
import com.yxt.anrui.riskcenter.api.loanrepaymenthistory.LoanRepaymentHistory; import com.yxt.anrui.riskcenter.api.loanrepaymenthistory.LoanRepaymentHistory;
import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.*; import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.*;
import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.historyData.ImportBondAmountsUpdate;
import com.yxt.anrui.riskcenter.api.loanwarrantinformation.LoanWarrantInformation; import com.yxt.anrui.riskcenter.api.loanwarrantinformation.LoanWarrantInformation;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import java.util.List; import java.util.List;
import java.util.Map;
/** /**
@ -54,4 +56,8 @@ public interface LoanRepaymentScheduleMapper extends BaseMapper<LoanRepaymentSch
LoanRepaymentSchedule selByOtherBankContractNoForSleepData(@Param("bankContractNo") String bankContractNo,@Param("vinNo") String vinNo); LoanRepaymentSchedule selByOtherBankContractNoForSleepData(@Param("bankContractNo") String bankContractNo,@Param("vinNo") String vinNo);
int updateIsEnable(@Param("list") List<String> list); int updateIsEnable(@Param("list") List<String> list);
String selSidByVinNo(@Param("vinNo") String vinNo);
void updateBoundsBySid(@Param("list") List<ImportBondAmountsUpdate> list);
} }

85
anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanrepaymentschedule/LoanRepaymentScheduleMapper.xml

@ -15,7 +15,7 @@
#{item.mainLastRepay},#{item.otherPeriod},#{item.otherBankNo},#{item.otherRepayDate},#{item.otherFirstRepay},#{item.otherMidRepay}, #{item.mainLastRepay},#{item.otherPeriod},#{item.otherBankNo},#{item.otherRepayDate},#{item.otherFirstRepay},#{item.otherMidRepay},
#{item.otherLastRepay},#{item.isOtherPolicy},#{item.sameBank},#{item.cwDeptNo},#{item.isDifferent},#{item.importTiredMoney}, #{item.otherLastRepay},#{item.isOtherPolicy},#{item.sameBank},#{item.cwDeptNo},#{item.isDifferent},#{item.importTiredMoney},
#{item.importPaymentMoney},#{item.importInterest},#{item.importFund},#{item.orgSidPath},#{item.bankSid},#{item.otherBankSid},#{item.bondAmounts} #{item.importPaymentMoney},#{item.importInterest},#{item.importFund},#{item.orgSidPath},#{item.bankSid},#{item.otherBankSid},#{item.bondAmounts}
) )
</foreach> </foreach>
</insert> </insert>
<update id="updateIsEnable"> <update id="updateIsEnable">
@ -26,6 +26,24 @@
#{item} #{item}
</foreach> </foreach>
</update> </update>
<update id="updateBoundsBySid" parameterType="java.util.List">
update loan_repayment_schedule
<trim prefix="set" suffixOverrides=",">
<trim prefix="bondAmounts =case" suffix="end,">
<foreach collection="list" item="item" index="index">
<if test="item.bondAmounts !=null and item.bondAmounts != ''">
when sid=#{item.sid} then #{item.bondAmounts}
</if>
</foreach>
</trim>
</trim>
where sid in
<foreach collection="list" index="index" item="item"
separator="," open="(" close=")">
#{item.sid}
</foreach>
</update>
<select id="selectByContractSid" <select id="selectByContractSid"
resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.LoanRepaymentSchedule"> resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.LoanRepaymentSchedule">
select * select *
@ -73,8 +91,8 @@
lrs.salesOrderSid, lrs.salesOrderSid,
lrpd.busVinSid lrpd.busVinSid
FROM loan_repayment_schedule lrs FROM loan_repayment_schedule lrs
LEFT JOIN loan_repayment_plan_details lrpd LEFT JOIN loan_repayment_plan_details lrpd
ON lrpd.scheduleSid = lrs.sid ON lrpd.scheduleSid = lrs.sid
WHERE lrpd.bankContractNo = #{bankContractNo} WHERE lrpd.bankContractNo = #{bankContractNo}
</select> </select>
<select id="selByLoanContractSid" <select id="selByLoanContractSid"
@ -102,29 +120,29 @@
</select> </select>
<select id="selPlansInfoByMainSidAndVinNo" <select id="selPlansInfoByMainSidAndVinNo"
resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.MoneyAndPeriodVo"> resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.MoneyAndPeriodVo">
SELECT SELECT period,
period, date_format(dueDate, '%Y-%m') as dueDate,
date_format(dueDate, '%Y-%m' ) as dueDate, dueMoney,
dueMoney, bankName
bankName
FROM loan_repayment_plan_details FROM loan_repayment_plan_details
WHERE WHERE scheduleSid = #{mainSid}
scheduleSid = #{mainSid} AND policyOrOther = #{mainOrOther} AND vinNo LIKE CONCAT( '%', #{vinNo}, '%' ) AND policyOrOther = #{mainOrOther}
AND vinNo LIKE CONCAT('%', #{vinNo}, '%')
ORDER BY period ASC ORDER BY period ASC
</select> </select>
<select id="selSumAmountDueMoney" resultType="java.lang.String"> <select id="selSumAmountDueMoney" resultType="java.lang.String">
SELECT SELECT IFNULL(SUM(dueMoney), 0)
IFNULL(SUM(dueMoney),0)
FROM loan_repayment_plan_details FROM loan_repayment_plan_details
WHERE WHERE scheduleSid = #{mainSid}
scheduleSid = #{mainSid} AND policyOrOther = #{mainOrOther} AND vinNo LIKE CONCAT( '%', #{vinNo}, '%' ) AND policyOrOther = #{mainOrOther}
AND vinNo LIKE CONCAT('%', #{vinNo}, '%')
</select> </select>
<select id="selSumAmountDueMoneyByBusVinSid" resultType="java.lang.String"> <select id="selSumAmountDueMoneyByBusVinSid" resultType="java.lang.String">
SELECT SELECT IFNULL(SUM(dueMoney), 0)
IFNULL(SUM(dueMoney),0)
FROM loan_repayment_plan_details FROM loan_repayment_plan_details
WHERE WHERE scheduleSid = #{mainSid}
scheduleSid = #{mainSid} AND policyOrOther = #{mainOrOther} AND busVinSid =#{busVinSid} AND policyOrOther = #{mainOrOther}
AND busVinSid = #{busVinSid}
</select> </select>
<select id="selPlansExcel" <select id="selPlansExcel"
resultType="com.yxt.anrui.buscenter.api.bussalesorderloancontract.LoanRepaymentPlanDetailsExportVo"> resultType="com.yxt.anrui.buscenter.api.bussalesorderloancontract.LoanRepaymentPlanDetailsExportVo">
@ -166,23 +184,30 @@
</foreach> </foreach>
</select> </select>
<select id="selMoneyAndVin" resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.DetailsVehVo"> <select id="selMoneyAndVin" resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.DetailsVehVo">
SELECT SELECT SUM(dueMoney) as money,
SUM( dueMoney ) as money, vinNo,
vinNo, busVinSid
busVinSid FROM loan_repayment_plan_details AS p
FROM WHERE p.scheduleSid = #{sid}
loan_repayment_plan_details AS p GROUP BY p.vinNo
WHERE
p.scheduleSid = #{sid}
GROUP BY
p.vinNo
</select> </select>
<select id="selByBankContractNoForSleepData" <select id="selByBankContractNoForSleepData"
resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.LoanRepaymentSchedule"> resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.LoanRepaymentSchedule">
select * from loan_repayment_schedule where bankContractNo =#{bankContractNo} and vinNo =#{vinNo} select *
from loan_repayment_schedule
where bankContractNo = #{bankContractNo}
and vinNo = #{vinNo}
</select> </select>
<select id="selByOtherBankContractNoForSleepData" <select id="selByOtherBankContractNoForSleepData"
resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.LoanRepaymentSchedule"> resultType="com.yxt.anrui.riskcenter.api.loanrepaymentschedule.LoanRepaymentSchedule">
select * from loan_repayment_schedule where otherBankNo =#{bankContractNo} and vinNo =#{vinNo} select *
from loan_repayment_schedule
where otherBankNo = #{bankContractNo}
and vinNo = #{vinNo}
</select>
<select id="selSidByVinNo" resultType="java.lang.String">
SELECT p.scheduleSid
FROM loan_repayment_plan_details AS p
WHERE p.vinNo LIKE CONCAT('%', #{vinNo}, '%') LIMIT 1
</select> </select>
</mapper> </mapper>

5
anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanrepaymentschedule/LoanRepaymentScheduleRest.java

@ -106,6 +106,11 @@ public class LoanRepaymentScheduleRest implements LoanRepaymentScheduleFeign {
return loanRepaymentScheduleService.importSleepHistoryData(userSid); return loanRepaymentScheduleService.importSleepHistoryData(userSid);
} }
@Override
public ResultBean importBondAmountsData(MultipartFile file, HttpServletRequest request) throws IOException {
return loanRepaymentScheduleService.importBondAmountsData(file,request);
}
@Override @Override
public ResultBean<String> returnBankOrOtherBankByPlanSid(String planSid) { public ResultBean<String> returnBankOrOtherBankByPlanSid(String planSid) {
return loanRepaymentScheduleService.returnBankOrOtherBankByPlanSid(planSid); return loanRepaymentScheduleService.returnBankOrOtherBankByPlanSid(planSid);

160
anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanrepaymentschedule/LoanRepaymentScheduleService.java

@ -42,10 +42,7 @@ import com.yxt.anrui.riskcenter.api.loanrepaymenthistory.LoanRepaymentHistory;
import com.yxt.anrui.riskcenter.api.loanrepaymentplandetails.LoanRepaymentPlanDetails; import com.yxt.anrui.riskcenter.api.loanrepaymentplandetails.LoanRepaymentPlanDetails;
import com.yxt.anrui.riskcenter.api.loanrepaymentplandetails.LoanRepaymentPlanDetailsDto; import com.yxt.anrui.riskcenter.api.loanrepaymentplandetails.LoanRepaymentPlanDetailsDto;
import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.*; import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.*;
import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.historyData.HistoryDataImportVo; import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.historyData.*;
import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.historyData.ImportSleepData;
import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.historyData.ReturnMsg;
import com.yxt.anrui.riskcenter.api.loanrepaymentschedule.historyData.ReturnSleepMsp;
import com.yxt.anrui.riskcenter.api.loansolutions.LoanSolutions; import com.yxt.anrui.riskcenter.api.loansolutions.LoanSolutions;
import com.yxt.anrui.riskcenter.api.loansolutions.app.SolutionsDetailsVo; import com.yxt.anrui.riskcenter.api.loansolutions.app.SolutionsDetailsVo;
import com.yxt.anrui.riskcenter.api.loansolutionsotherpolicy.LoanSolutionsOtherpolicy; import com.yxt.anrui.riskcenter.api.loansolutionsotherpolicy.LoanSolutionsOtherpolicy;
@ -72,6 +69,7 @@ import com.yxt.common.core.vo.PagerVo;
import com.yxt.messagecenter.api.message.MessageFeign; import com.yxt.messagecenter.api.message.MessageFeign;
import com.yxt.messagecenter.api.message.PushMessageQuery; import com.yxt.messagecenter.api.message.PushMessageQuery;
import com.yxt.messagecenter.api.message.PushSmsDto; import com.yxt.messagecenter.api.message.PushSmsDto;
import io.swagger.annotations.ApiModelProperty;
import org.apache.commons.lang3.time.DateUtils; import org.apache.commons.lang3.time.DateUtils;
import org.apache.poi.hssf.usermodel.HSSFDateUtil; import org.apache.poi.hssf.usermodel.HSSFDateUtil;
import org.apache.poi.hssf.usermodel.HSSFWorkbook; import org.apache.poi.hssf.usermodel.HSSFWorkbook;
@ -159,6 +157,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
private FinUncollectedReceivablesDetailedJRFeign finUncollectedReceivablesDetailedJRFeign; private FinUncollectedReceivablesDetailedJRFeign finUncollectedReceivablesDetailedJRFeign;
@Autowired @Autowired
private LoanPushFundHistoryService loanPushFundHistoryService; private LoanPushFundHistoryService loanPushFundHistoryService;
/** /**
* 根据销售订单SID生成还款计划表回显 * 根据销售订单SID生成还款计划表回显
* *
@ -368,6 +367,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
LoanRepaymentSchedule loanRepaymentSchedule = baseMapper.selectByContractSid(dto.getSalesOrderSid()); LoanRepaymentSchedule loanRepaymentSchedule = baseMapper.selectByContractSid(dto.getSalesOrderSid());
String orderSid = ""; String orderSid = "";
String scheduleSid = ""; String scheduleSid = "";
BigDecimal bondAmounts = BigDecimal.ZERO;//贷款保证金
BusSalesOrderLoancontractDetailsVo loancontract = busSalesOrderLoancontractFeign.fetchDetailsBySid(dto.getSalesOrderSid()).getData(); BusSalesOrderLoancontractDetailsVo loancontract = busSalesOrderLoancontractFeign.fetchDetailsBySid(dto.getSalesOrderSid()).getData();
if (null != loancontract) { if (null != loancontract) {
if (StringUtils.isNotBlank(loancontract.getSalesOrderSid())) { if (StringUtils.isNotBlank(loancontract.getSalesOrderSid())) {
@ -378,6 +378,9 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
ResultBean<SolutionsDetailsVo> solutionsDetailsVoResultBean = loanSolutionsService.selectDetailss(orderSid); ResultBean<SolutionsDetailsVo> solutionsDetailsVoResultBean = loanSolutionsService.selectDetailss(orderSid);
if (solutionsDetailsVoResultBean.getData() != null) { if (solutionsDetailsVoResultBean.getData() != null) {
BeanUtil.copyProperties(solutionsDetailsVoResultBean.getData(), solutionsDetailsssVo); BeanUtil.copyProperties(solutionsDetailsVoResultBean.getData(), solutionsDetailsssVo);
if (StringUtils.isNotBlank(solutionsDetailsVoResultBean.getData().getBondAmounts())) {
bondAmounts = new BigDecimal(solutionsDetailsVoResultBean.getData().getBondAmounts());
}
} }
if (StringUtils.isBlank(dto.getMainRepayDate())) { if (StringUtils.isBlank(dto.getMainRepayDate())) {
return rb.setMsg("请选择主金融产品首期还款日!"); return rb.setMsg("请选择主金融产品首期还款日!");
@ -460,6 +463,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
BeanUtil.copyProperties(dto, loanRepaymentSchedule, "id", "sid"); BeanUtil.copyProperties(dto, loanRepaymentSchedule, "id", "sid");
loanRepaymentSchedule.setLoanContractSid(dto.getSalesOrderSid()); loanRepaymentSchedule.setLoanContractSid(dto.getSalesOrderSid());
loanRepaymentSchedule.setSalesOrderSid(orderSid); loanRepaymentSchedule.setSalesOrderSid(orderSid);
loanRepaymentSchedule.setBondAmounts(bondAmounts);
if (StringUtils.isNotBlank(dto.getOtherBankNo())) { if (StringUtils.isNotBlank(dto.getOtherBankNo())) {
loanRepaymentSchedule.setOtherBankNo(dto.getOtherBankNo()); loanRepaymentSchedule.setOtherBankNo(dto.getOtherBankNo());
} }
@ -1224,6 +1228,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
BeanUtil.copyProperties(dto, entity, "id", "sid"); BeanUtil.copyProperties(dto, entity, "id", "sid");
entity.setLoanContractSid(dto.getSalesOrderSid()); entity.setLoanContractSid(dto.getSalesOrderSid());
entity.setSalesOrderSid(orderSid); entity.setSalesOrderSid(orderSid);
entity.setBondAmounts(bondAmounts);
if (StringUtils.isNotBlank(dto.getUserSid())) { if (StringUtils.isNotBlank(dto.getUserSid())) {
entity.setCreateBySid(dto.getUserSid()); entity.setCreateBySid(dto.getUserSid());
} }
@ -5199,10 +5204,10 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
contracts.add(bsl); contracts.add(bsl);
} }
} }
vehicleData.setTemporaryNo(borrowerNo); vehicleData.setTemporaryNo(borrowerNo);
vehicleData.setBorrowerSid(borrowerSid); vehicleData.setBorrowerSid(borrowerSid);
vehicleData.setLoanContractSid(loanContractSid); vehicleData.setLoanContractSid(loanContractSid);
updateVehicles.add(vehicleData); updateVehicles.add(vehicleData);
} else { } else {
//生成销售订单贷款人表 //生成销售订单贷款人表
BusSalesOrderBorrower busSalesOrderBorrower = new BusSalesOrderBorrower(); BusSalesOrderBorrower busSalesOrderBorrower = new BusSalesOrderBorrower();
@ -5598,6 +5603,117 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
return returnList; return returnList;
} }
public ResultBean importBondAmountsData(MultipartFile file, HttpServletRequest request) {
ResultBean rb = ResultBean.fireFail();
try {
String temp = request.getSession().getServletContext().getRealPath(File.separator) + "temp";// 临时目录
File tempFile = new File(temp);
if (!tempFile.exists()) {
tempFile.mkdirs();
}
String fileName = file.getOriginalFilename();
if (!fileName.matches("^.+\\.(?i)(xls)$") && !fileName.matches("^.+\\.(?i)(xlsx)$")) {
return rb.fail().setMsg("上传文件不正确");
}
boolean isExcel2003 = true;
if (fileName.matches("^.+\\.(?i)(xlsx)$")) {
isExcel2003 = false;
}
InputStream is = file.getInputStream();
Workbook wb = null;
if (isExcel2003) {
wb = new HSSFWorkbook(is);
} else {
wb = new XSSFWorkbook(is);
}
Sheet sheet = wb.getSheetAt(0);
List<ImportBondAmountsVo> list = getBondAmountsSheetVal(sheet);
StringBuffer sbMsg = new StringBuffer();
Set<String> setMsg = new HashSet<>();
List<ImportBondAmountsUpdate> updates = new ArrayList<>();
if (!list.isEmpty() && list.size() > 0) {
for (ImportBondAmountsVo vo : list) {
String vinNo = vo.getVinNo();
String bondAmounts = vo.getBondAmounts();
String sid = baseMapper.selSidByVinNo(vinNo);
if (StringUtils.isBlank(sid)) {
setMsg.add(vinNo);
} else {
ImportBondAmountsUpdate update = new ImportBondAmountsUpdate();
update.setSid(sid);
update.setBondAmounts(bondAmounts);
updates.add(update);
}
}
}
if (null != setMsg && setMsg.size() > 0) {
for (String s : setMsg) {
sbMsg.append(s).append("、");
}
sbMsg.delete(sbMsg.length() - 1, sbMsg.length());
if (StringUtils.isNotBlank(sbMsg.toString())) {
return rb.setMsg("车架号" + sbMsg.toString() + "不存在,导入失败");
}
}
if (!updates.isEmpty()) {
baseMapper.updateBoundsBySid(updates);
}
} catch (Exception e) {
e.printStackTrace();
}
return rb.success().setMsg("导入成功");
}
private List<ImportBondAmountsVo> getBondAmountsSheetVal(Sheet sheet) {
List<ImportBondAmountsVo> list = new ArrayList<>();
Row row1 = sheet.getRow(0);
Map<Integer, String> header = new HashMap<>();
Map<String, String> map = new HashMap<>();
for (int i = 0; i < 3; i++) {
String trim = new String();
try {
trim = getCellVal(row1.getCell(i)).toString().trim();
String temp = getCellVal(row1.getCell(i)).toString().trim();
if (StringUtils.isNotBlank(temp)) {
header.put(i, temp);
}
} catch (Exception e) {
e.printStackTrace();
}
}
for (int r = 2; r <= sheet.getLastRowNum(); r++) {
ImportBondAmountsVo info = new ImportBondAmountsVo();
Row row = sheet.getRow(r);
if (row == null) {
continue;
}
for (int i = 0; i < header.size(); i++) {
try {
String temp = "";
if (null != getCellVal(row.getCell(i))) {
temp = getCellVal(row.getCell(i)).toString().trim();
}
String head = header.get(i);
String field = "";
if (StringUtils.isNotBlank(temp)) {
field = temp;
}
if (head.equals("八位车架号")) {
info.setVinNo(field);
}
if (head.equals("保证金")) {
info.setBondAmounts(field);
}
} catch (Exception e) {
e.printStackTrace();
continue;
}
}
list.add(info);
}
return list;
}
public ResultBean importHistoryData(MultipartFile file, String userSid, HttpServletRequest request) { public ResultBean importHistoryData(MultipartFile file, String userSid, HttpServletRequest request) {
ResultBean rb = ResultBean.fireFail(); ResultBean rb = ResultBean.fireFail();
try { try {
@ -5778,12 +5894,12 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
String customerSid = ""; String customerSid = "";
String customerName = ""; String customerName = "";
if (null != order) { if (null != order) {
if (StringUtils.isNotBlank(order.getCustomerSid())) { if (StringUtils.isNotBlank(order.getCustomerSid())) {
customerSid = order.getCustomerSid(); customerSid = order.getCustomerSid();
} }
if (StringUtils.isNotBlank(order.getCustomerName())) { if (StringUtils.isNotBlank(order.getCustomerName())) {
customerName = order.getCustomerName(); customerName = order.getCustomerName();
} }
} }
String orgSidPath = otherSchedule.getOrgSidPath(); String orgSidPath = otherSchedule.getOrgSidPath();
SysOrganizationVo deptData = sysOrganizationFeign.selectByOrgSidPath(orgSidPath).getData(); SysOrganizationVo deptData = sysOrganizationFeign.selectByOrgSidPath(orgSidPath).getData();
@ -6074,7 +6190,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
fundDay.setIsEnable(3); fundDay.setIsEnable(3);
loanFundDays.add(fundDay); loanFundDays.add(fundDay);
//生成资金占用费计提记录 //生成资金占用费计提记录
LoanPushFundHistory pushFundHistory = new LoanPushFundHistory(); LoanPushFundHistory pushFundHistory = new LoanPushFundHistory();
pushFundHistory.setCreateBySid(userSid); pushFundHistory.setCreateBySid(userSid);
pushFundHistory.setFund(B); pushFundHistory.setFund(B);
pushFundHistory.setBusVinSid(plan.getBusVinSid()); pushFundHistory.setBusVinSid(plan.getBusVinSid());
@ -6209,7 +6325,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
fundDay.setBusSid(p.getSid()); fundDay.setBusSid(p.getSid());
loanFundDays.add(fundDay); loanFundDays.add(fundDay);
//生成资金占用费计提记录 //生成资金占用费计提记录
LoanPushFundHistory pushFundHistory = new LoanPushFundHistory(); LoanPushFundHistory pushFundHistory = new LoanPushFundHistory();
pushFundHistory.setCreateBySid(userSid); pushFundHistory.setCreateBySid(userSid);
pushFundHistory.setFund(B1); pushFundHistory.setFund(B1);
pushFundHistory.setBusVinSid(p.getBusVinSid()); pushFundHistory.setBusVinSid(p.getBusVinSid());
@ -6337,7 +6453,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
fundDay.setBusSid(p.getSid()); fundDay.setBusSid(p.getSid());
loanFundDays.add(fundDay); loanFundDays.add(fundDay);
//生成资金占用费计提记录 //生成资金占用费计提记录
LoanPushFundHistory pushFundHistory = new LoanPushFundHistory(); LoanPushFundHistory pushFundHistory = new LoanPushFundHistory();
pushFundHistory.setCreateBySid(userSid); pushFundHistory.setCreateBySid(userSid);
pushFundHistory.setFund(B1); pushFundHistory.setFund(B1);
pushFundHistory.setBusVinSid(p.getBusVinSid()); pushFundHistory.setBusVinSid(p.getBusVinSid());
@ -6434,7 +6550,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
fundDay.setBusSid(plan.getSid()); fundDay.setBusSid(plan.getSid());
loanFundDays.add(fundDay); loanFundDays.add(fundDay);
//生成资金占用费计提记录 //生成资金占用费计提记录
LoanPushFundHistory pushFundHistory = new LoanPushFundHistory(); LoanPushFundHistory pushFundHistory = new LoanPushFundHistory();
pushFundHistory.setCreateBySid(userSid); pushFundHistory.setCreateBySid(userSid);
pushFundHistory.setFund(B); pushFundHistory.setFund(B);
pushFundHistory.setBusVinSid(plan.getBusVinSid()); pushFundHistory.setBusVinSid(plan.getBusVinSid());
@ -6587,7 +6703,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
fundDay.setBusSid(p.getSid()); fundDay.setBusSid(p.getSid());
loanFundDays.add(fundDay); loanFundDays.add(fundDay);
//生成资金占用费计提记录 //生成资金占用费计提记录
LoanPushFundHistory pushFundHistory = new LoanPushFundHistory(); LoanPushFundHistory pushFundHistory = new LoanPushFundHistory();
pushFundHistory.setCreateBySid(userSid); pushFundHistory.setCreateBySid(userSid);
pushFundHistory.setFund(B1); pushFundHistory.setFund(B1);
pushFundHistory.setBusVinSid(p.getBusVinSid()); pushFundHistory.setBusVinSid(p.getBusVinSid());
@ -6715,7 +6831,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
fundDay.setBusSid(p.getSid()); fundDay.setBusSid(p.getSid());
loanFundDays.add(fundDay); loanFundDays.add(fundDay);
//生成资金占用费计提记录 //生成资金占用费计提记录
LoanPushFundHistory pushFundHistory = new LoanPushFundHistory(); LoanPushFundHistory pushFundHistory = new LoanPushFundHistory();
pushFundHistory.setCreateBySid(userSid); pushFundHistory.setCreateBySid(userSid);
pushFundHistory.setFund(B1); pushFundHistory.setFund(B1);
pushFundHistory.setBusVinSid(p.getBusVinSid()); pushFundHistory.setBusVinSid(p.getBusVinSid());
@ -6819,7 +6935,7 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
LocalDate endDate = LocalDate.of(y1, m1, d1); LocalDate endDate = LocalDate.of(y1, m1, d1);
Period period = Period.between(startDate, endDate); Period period = Period.between(startDate, endDate);
int totalMonths = period.getDays() == 0 ? int totalMonths = period.getDays() == 0 ?
period.getYears() * 12 + period.getMonths() - 1: period.getYears() * 12 + period.getMonths(); period.getYears() * 12 + period.getMonths() - 1 : period.getYears() * 12 + period.getMonths();
return totalMonths + 1; return totalMonths + 1;
} }
@ -7278,4 +7394,6 @@ public class LoanRepaymentScheduleService extends MybatisBaseService<LoanRepayme
} }
return rb.success().setData(bankOrOtherBank); return rb.success().setData(bankOrOtherBank);
} }
} }

12
anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loansettleapply/LoanSettleApplyService.java

@ -89,6 +89,7 @@ import com.yxt.anrui.riskcenter.biz.loansettlecompanyreduction.LoanSettleCompany
import com.yxt.anrui.riskcenter.biz.loansettlecompanyreduction.LoanSettleCompanyReductionService; import com.yxt.anrui.riskcenter.biz.loansettlecompanyreduction.LoanSettleCompanyReductionService;
import com.yxt.anrui.riskcenter.biz.loansettlevehicle.LoanSettleVehicleService; import com.yxt.anrui.riskcenter.biz.loansettlevehicle.LoanSettleVehicleService;
import com.yxt.anrui.riskcenter.biz.loansolutions.LoanSolutionsMapper; import com.yxt.anrui.riskcenter.biz.loansolutions.LoanSolutionsMapper;
import com.yxt.anrui.riskcenter.biz.loansolutions.LoanSolutionsService;
import com.yxt.anrui.riskcenter.biz.loansolutionsdetail.LoanSolutionsDetailService; import com.yxt.anrui.riskcenter.biz.loansolutionsdetail.LoanSolutionsDetailService;
import com.yxt.common.base.config.component.DocPdfComponent; import com.yxt.common.base.config.component.DocPdfComponent;
import com.yxt.common.base.config.component.FileUploadComponent; import com.yxt.common.base.config.component.FileUploadComponent;
@ -196,7 +197,8 @@ public class LoanSettleApplyService extends MybatisBaseService<LoanSettleApplyMa
private FinKingDeeFeign finKingDeeFeign; private FinKingDeeFeign finKingDeeFeign;
@Autowired @Autowired
private BasePurchaseSystemFeign basePurchaseSystemFeign; private BasePurchaseSystemFeign basePurchaseSystemFeign;
@Autowired
private LoanSolutionsService loanSolutionsService;
public PagerVo<LoanSettleApplyVo> listPageVo(PagerQuery<LoanSettleApplyQuery> pq) { public PagerVo<LoanSettleApplyVo> listPageVo(PagerQuery<LoanSettleApplyQuery> pq) {
LoanSettleApplyQuery query = pq.getParams(); LoanSettleApplyQuery query = pq.getParams();
QueryWrapper<LoanSettleApply> qw = new QueryWrapper<>(); QueryWrapper<LoanSettleApply> qw = new QueryWrapper<>();
@ -622,6 +624,14 @@ public class LoanSettleApplyService extends MybatisBaseService<LoanSettleApplyMa
BigDecimal bondAmounts = BigDecimal.ZERO; BigDecimal bondAmounts = BigDecimal.ZERO;
if (null != schedule.getBondAmounts()) { if (null != schedule.getBondAmounts()) {
bondAmounts = schedule.getBondAmounts(); bondAmounts = schedule.getBondAmounts();
} else {
ResultBean<SolutionsDetailsVo> solutionsDetailsVoResultBean = loanSolutionsService.selectDetailss(schedule.getSalesOrderSid());
if (solutionsDetailsVoResultBean.getData() != null) {
SolutionsDetailsVo solutionsDetailsVo = solutionsDetailsVoResultBean.getData();
if (StringUtils.isNotBlank(solutionsDetailsVo.getBondAmounts())) {
bondAmounts = new BigDecimal(solutionsDetailsVo.getBondAmounts());
}
}
} }
settleApplyCommonVo.setLoanDeposit(bondAmounts.toString()); settleApplyCommonVo.setLoanDeposit(bondAmounts.toString());
//贷款保证金扣罚金额 //贷款保证金扣罚金额

2
anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatecheck/relation/yiheduidanchefanli.vue

@ -274,7 +274,7 @@ export default {
req.checkApplyGetAlreadyUploadVehRebate(this.listQuery).then((response) => { req.checkApplyGetAlreadyUploadVehRebate(this.listQuery).then((response) => {
console.log('列表查询结果:', response) console.log('列表查询结果:', response)
this.listLoading = false this.listLoading = false
if (response.success && response.data && response.data.total > 0) { if (response.success) {
this.list = response.data.records this.list = response.data.records
this.listQuery.total = response.data.total this.listQuery.total = response.data.total
} else { } else {

73
anrui-scm/anrui-scm-ui/src/views/kucunguanli/tiaojiaguanli/priceAdd.vue

@ -116,12 +116,12 @@
<el-table-column label="调整后销售指导价(元)" header-align="center"> <el-table-column label="调整后销售指导价(元)" header-align="center">
<el-table-column label="全款价" align="left" header-align="center" width="140"> <el-table-column label="全款价" align="left" header-align="center" width="140">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.tzhGuidedPrice" placeholder="" @keyup.native="UpNumber" @keydown.native="UpNumber" class="addinputw" clearable/> <el-input v-model="scope.row.tzhGuidedPrice" placeholder="" @keyup.native="scope.row.tzhGuidedPrice = getNumber(scope.row.tzhGuidedPrice, 0)" class="addinputw" clearable/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="贷款价" align="left" header-align="center" width="140"> <el-table-column label="贷款价" align="left" header-align="center" width="140">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.tzhManufactorSettlementPrice" placeholder="" @keyup.native="UpNumber" @keydown.native="UpNumber" class="addinputw" clearable/> <el-input v-model="scope.row.tzhManufactorSettlementPrice" placeholder="" @keyup.native="scope.row.tzhManufactorSettlementPrice = getNumber(scope.row.tzhManufactorSettlementPrice, 0)" class="addinputw" clearable/>
</template> </template>
</el-table-column> </el-table-column>
</el-table-column> </el-table-column>
@ -150,7 +150,7 @@ import req from '@/api/kucunguanli/price'
import configuration from './chexingbyconfiguration' import configuration from './chexingbyconfiguration'
export default { export default {
name: 'priceAdd', name: 'PriceAdd',
components: { components: {
configuration configuration
}, },
@ -191,27 +191,23 @@ export default {
} }
}, },
methods: { methods: {
// getNumber(val, limit) {
newDate() { val = val.replace(/[^0-9.]/g, '') //
var date = new Date() val = val.replace(/^00/, '0.') // 0
var year = date.getFullYear() // val = val.replace(/^\./g, '0.') // 0.
var month = date.getMonth() + 1 // val = val.replace(/\.{2,}/g, '.') //
var day = date.getDate() // val = val.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.'); //
if (month < 10) { /^0\d+/.test(val) ? val = val.slice(1) : '' // 0
month = '0' + month const str = '^(\\d+)\\.(\\d{' + limit + '}).*$'
} const reg = new RegExp(str)
if (day < 10) { if (limit === 0) {
day = '0' + day //
} val = val.replace(reg, '$1')
this.formobj.createTime = year + '-' + month + '-' + day } else {
}, //
UpNumber(e) { val = val.replace(reg, '$1.$2')
e.target.value = e.target.value.replace(/[^\d]/g, '') // ."-"
e.target.value = e.target.value.replace(/^00/, '0') // 0
if (e.target.value.indexOf('.') < 0 && e.target.value !== '' && e.target.value !== '-') {
// 0102
e.target.value = parseFloat(e.target.value)
} }
return val
}, },
// //
addCommodity() { addCommodity() {
@ -223,7 +219,6 @@ export default {
this.formobj.baseModelModpriceModels.splice(index, 1) this.formobj.baseModelModpriceModels.splice(index, 1)
}, },
showAdd(createOrgSid) { showAdd(createOrgSid) {
this.newDate()
this.$nextTick(() => { this.$nextTick(() => {
this.$refs['form_obj'].clearValidate() this.$refs['form_obj'].clearValidate()
}) })
@ -235,6 +230,13 @@ export default {
this.formobj.orgPath = window.sessionStorage.getItem('defaultOrgPath') this.formobj.orgPath = window.sessionStorage.getItem('defaultOrgPath')
this.formobj.deptName = window.sessionStorage.getItem('defaultOrgPathName').substring(window.sessionStorage.getItem('defaultOrgPathName').lastIndexOf('/') + 1) this.formobj.deptName = window.sessionStorage.getItem('defaultOrgPathName').substring(window.sessionStorage.getItem('defaultOrgPathName').lastIndexOf('/') + 1)
this.formobj.deptSid = window.sessionStorage.getItem('defaultOrgPath').substring(window.sessionStorage.getItem('defaultOrgPath').lastIndexOf('/') + 1) this.formobj.deptSid = window.sessionStorage.getItem('defaultOrgPath').substring(window.sessionStorage.getItem('defaultOrgPath').lastIndexOf('/') + 1)
var nowDate = new Date()
var date = {
year: nowDate.getFullYear(),
month: nowDate.getMonth() + 1,
day: nowDate.getDate()
}
this.formobj.createTime = date.year + '-' + (date.month >= 10 ? date.month : '0' + date.month) + '-' + (date.day >= 10 ? date.day : '0' + date.day)
this.viewTitle = '【新增】车型调价申请' this.viewTitle = '【新增】车型调价申请'
}, },
showEdit(row) { showEdit(row) {
@ -345,11 +347,7 @@ export default {
if (valid) { if (valid) {
this.submitdisabled = true this.submitdisabled = true
req.saveOrUpdate(this.formobj).then((resp) => { req.saveOrUpdate(this.formobj).then((resp) => {
this.$message({ this.$message({ showClose: true, type: 'success', message: resp.msg })
showClose: true,
type: 'success',
message: resp.msg
})
this.handleReturn('true') this.handleReturn('true')
}).catch(() => { }).catch(() => {
this.submitdisabled = false this.submitdisabled = false
@ -360,16 +358,23 @@ export default {
}) })
}, },
submitVehicleApply() { submitVehicleApply() {
if (this.formobj.baseModelModpriceModels.length > 0) {
for (var i = 0; i < this.formobj.baseModelModpriceModels.length; i++) {
if (this.formobj.baseModelModpriceModels[i].tzhGuidedPrice === '' || this.formobj.baseModelModpriceModels[i].tzhManufactorSettlementPrice === '') {
this.$message({ showClose: true, type: 'error', message: '车型列表中调整后销售指导价的全款价及贷款价均不能为空' })
return
}
}
} else {
this.$message({ showClose: true, type: 'error', message: '车型列表不能为空' })
return
}
this.$refs['form_obj'].validate((valid) => { this.$refs['form_obj'].validate((valid) => {
if (valid) { if (valid) {
this.submitdisabled = true this.submitdisabled = true
req.submitVehicleApply(this.formobj).then((res) => { req.submitVehicleApply(this.formobj).then((res) => {
if (res.success) { if (res.success) {
this.$message({ this.$message({ showClose: true, type: 'success', message: resp.msg })
showClose: true,
type: 'success',
message: '提交成功'
})
this.handleReturn('true') this.handleReturn('true')
} }
}).catch(() => { }).catch(() => {

13
anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatecheck/relation/yiheduizhuanxiangfanli.vue

@ -206,10 +206,12 @@ export default {
}, },
handleSelectionChange(row) { handleSelectionChange(row) {
var dateTime = '' var dateTime = ''
let date = new Date() var nowDate = new Date()
let year = date.getFullYear() // var date = {
let month = date.getMonth() + 1 // year: nowDate.getFullYear(),
dateTime = year + '年' + month + '月' month: nowDate.getMonth() + 1
}
dateTime = date.year + '年' + (date.month >= 10 ? date.month : '0' + date.month) + '月'
const aa = [] const aa = []
const bb = [] const bb = []
row.forEach((element) => { row.forEach((element) => {
@ -240,7 +242,6 @@ export default {
}) })
this.sids = aa this.sids = aa
this.sids_list = bb this.sids_list = bb
console.log('sids', this.sids, bb, 99999999)
}, },
// //
getList() { getList() {
@ -248,7 +249,7 @@ export default {
req.checkApplyGetAlreadyUploadVehRebate(this.listQuery).then((response) => { req.checkApplyGetAlreadyUploadVehRebate(this.listQuery).then((response) => {
console.log('列表查询结果:', response) console.log('列表查询结果:', response)
this.listLoading = false this.listLoading = false
if (response.success && response.data && response.data.total > 0) { if (response.success) {
this.list = response.data.records this.list = response.data.records
this.listQuery.total = response.data.total this.listQuery.total = response.data.total
} else { } else {

293
anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatecheck/specialrebatetobechecked.vue

@ -53,9 +53,14 @@
<el-table :key="tableKey" v-loading="listLoading" :data="list" border style="width: 100%;" @selection-change="handleSelectionChange"> <el-table :key="tableKey" v-loading="listLoading" :data="list" border style="width: 100%;" @selection-change="handleSelectionChange">
<el-table-column fixed type="selection" align="center" width="50px"/> <el-table-column fixed type="selection" align="center" width="50px"/>
<el-table-column fixed label="序号" type="index" :index="indexMethod" align="center" width="80px"/> <el-table-column fixed label="序号" type="index" :index="indexMethod" align="center" width="80px"/>
<el-table-column label="上传状态" align="center" width="200"> <el-table-column label="上传状态" align="center" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.uploadState === '0' ? '未调整' : scope.row.uploadState === '1' ? '已调整' : scope.row.uploadState === '2' ? '未上传' : scope.row.uploadState === '3' ? '已上传' : ''}}</span> <span>{{ scope.row.uploadState == '0' ? '未上传' : scope.row.uploadState == '1' ? '已上传' : ''}}</span>
</template>
</el-table-column>
<el-table-column label="调整状态" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.uploadState == '0' ? '未调整' : scope.row.uploadState == '1' ? '已调整' : ''}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="品牌" align="center" width="200"> <el-table-column label="品牌" align="center" width="200">
@ -85,12 +90,12 @@
</el-table-column> </el-table-column>
<el-table-column label="上传日期" align="center" width="200"> <el-table-column label="上传日期" align="center" width="200">
<template slot-scope="scope"> <template slot-scope="scope">
<el-date-picker v-model="scope.row.uploadDate" type="date" style="width: 160px" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/> <el-date-picker v-model="scope.row.uploadDate" type="date" :disabled="scope.row.secondaryUploadDate !== ''" style="width: 160px" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="上传金额" align="center" width="150"> <el-table-column label="上传金额" align="center" width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.uploadMoney" @keyup.native="UpNumber" @keydown.native="UpNumber" clearable placeholder=""></el-input> <el-input v-model="scope.row.uploadMoney" :disabled="scope.row.secondaryUploadDate !== ''" @input="isAdjustmentInput(scope.row)" @keyup.native="scope.row.uploadMoney = getNumber(scope.row.uploadMoney, 2)" clearable placeholder=""></el-input>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="二次上传日期" align="center" width="120"> <el-table-column label="二次上传日期" align="center" width="120">
@ -105,36 +110,35 @@
</el-table-column> </el-table-column>
<el-table-column label="待确定金额" align="center" width="150"> <el-table-column label="待确定金额" align="center" width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.stayDetermineMoney" @keyup.native="UpNumber" @keydown.native="UpNumber" clearable placeholder=""></el-input> <el-input v-model="scope.row.stayDetermineMoney" @input="isAdjustmentInput(scope.row)" @keyup.native="scope.row.stayDetermineMoney = getNumber(scope.row.stayDetermineMoney, 2)" clearable placeholder=""></el-input>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="费用" align="center" width="150"> <el-table-column label="费用" align="center" width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.money" @keyup.native="UpNumber" @keydown.native="UpNumber" clearable placeholder=""></el-input> <el-input v-model="scope.row.money" @input="isAdjustmentInput(scope.row)" @keyup.native="scope.row.money = getNumber(scope.row.money, 2)" clearable placeholder=""></el-input>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="是否调整" align="center" width="100"> <el-table-column label="是否调整" align="center" width="100">
<template slot-scope="scope"><!--@change="changeIsAdjustment(scope.row)" --> <template slot-scope="scope">
<el-select v-model="scope.row.isAdjustment" @change="changeIsAdjustment(scope.row)" placeholder="" filterable> <el-select v-model="scope.row.isAdjustment" :disabled="!scope.row.adjustOrNot" @change="isAdjustmentChange($event, scope.row)" placeholder="" filterable>
<el-option v-for="item in whether_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"/> <el-option v-for="item in whether_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"/>
</el-select> </el-select>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="调整金额" align="center" width="150"> <el-table-column label="调整金额" align="center" width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<!-- <el-input :disabled="scope.row.isAdjustment === '' || scope.row.isAdjustment === '否'" v-model="scope.row.adjustmentMoney" clearable placeholder=""></el-input>-->
<span>{{ scope.row.adjustmentMoney }}</span> <span>{{ scope.row.adjustmentMoney }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="调整说明" align="center" width="300"> <el-table-column label="调整说明" align="center" width="300">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input :disabled="scope.row.isAdjustment === '' || scope.row.isAdjustment === '否'" v-model="scope.row.adjustmentRemarks" clearable placeholder=""></el-input> <el-input v-model="scope.row.adjustmentRemarks" clearable placeholder=""></el-input>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center" width="180px" > <el-table-column label="操作" align="center" width="180px">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="primary" size="mini" @click="toSave(scope.row)">保存</el-button> <el-button type="primary" v-if="scope.row.adjustmentState == '0'" size="mini" @click="toSave(scope.row)">保存</el-button>
<el-button type="primary" :disabled="scope.row.isAdjustment === '' || scope.row.isAdjustment === '是'" size="mini" @click="toAdjust(scope.row)">调整</el-button> <el-button type="primary" v-if="scope.row.isAdjustment == '否' || (scope.row.uploadState == '3' && scope.row.adjustmentState == '0')" size="mini" @click="toAdjust(scope.row)">调整</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -145,8 +149,11 @@
</div> </div>
</div> </div>
</div> </div>
<!-- 核对审核申请分页列表 -->
<specialrebatecheck v-show="viewState == 2" ref="divCheck" @doback="resetState"/> <specialrebatecheck v-show="viewState == 2" ref="divCheck" @doback="resetState"/>
<!-- 新增核对审核申请 -->
<specialrebatecheckAdd v-show="viewState == 3" ref="divCheckAdd" @doback="resetState"/> <specialrebatecheckAdd v-show="viewState == 3" ref="divCheckAdd" @doback="resetState"/>
<!-- 二次调整页面 -->
<el-dialog center :visible.sync="dialogVisible" width="60%"> <el-dialog center :visible.sync="dialogVisible" width="60%">
<div class="app-container"> <div class="app-container">
<div class="tab-header webtop"> <div class="tab-header webtop">
@ -268,13 +275,6 @@ export default {
btnKey: 'toAdd', btnKey: 'toAdd',
btnLabel: '核对审核申请' btnLabel: '核对审核申请'
}, },
{
type: 'primary',
size: 'small',
icon: '',
btnKey: 'toClick',
btnLabel: '调整'
},
{ {
type: 'info', type: 'info',
size: 'small', size: 'small',
@ -353,7 +353,8 @@ export default {
secondaryUploadMoney: '', secondaryUploadMoney: '',
secondCost: '', secondCost: '',
secondRebate: '', secondRebate: '',
adjustmentMoney: '' adjustmentMoney: '',
cost: ''
} }
} }
}, },
@ -401,9 +402,6 @@ export default {
case 'doImport': case 'doImport':
this.doImport() this.doImport()
break break
case 'doDel':
this.doDel()
break
case 'doClose': case 'doClose':
this.doClose() this.doClose()
break break
@ -434,7 +432,7 @@ export default {
req.listPage(this.listQuery).then((response) => { req.listPage(this.listQuery).then((response) => {
console.log('列表查询结果:', response) console.log('列表查询结果:', response)
this.listLoading = false this.listLoading = false
if (response.success && response.data && response.data.total > 0) { if (response.success) {
this.list = response.data.records this.list = response.data.records
this.listQuery.total = response.data.total this.listQuery.total = response.data.total
} else { } else {
@ -468,88 +466,57 @@ export default {
} }
this.init() this.init()
}, },
UpNumber(e) { getNumber(val, limit) {
e.target.value = e.target.value.replace(/[^\d]/g, '') // ."-" val = val.replace(/[^0-9.]/g, '') //
e.target.value = e.target.value.replace(/^00/, '0') // 0 val = val.replace(/^00/, '0.') // 0
if (e.target.value.indexOf('.') < 0 && e.target.value !== '' && e.target.value !== '-') { val = val.replace(/^\./g, '0.') // 0.
// 0102 val = val.replace(/\.{2,}/g, '.') //
console.log(e.target.value) val = val.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.'); //
e.target.value = parseFloat(e.target.value) /^0\d+/.test(val) ? val = val.slice(1) : '' // 0
} const str = '^(\\d+)\\.(\\d{' + limit + '}).*$'
}, const reg = new RegExp(str)
changeIsAdjustment(row) { if (limit === 0) {
if (row.isAdjustment === '是') { //
if (row.uploadMoney === '') { val = val.replace(reg, '$1')
row.isAdjustment = '' } else {
this.$message({ showClose: true, type: 'error', message: '上传金额不能为空' }) //
return val = val.replace(reg, '$1.$2')
}
if (row.money === '') {
row.isAdjustment = ''
this.$message({ showClose: true, type: 'error', message: '费用不能为空' })
return
}
if (row.stayDetermineMoney === '') {
row.isAdjustment = ''
this.$message({ showClose: true, type: 'error', message: '待确定金额不能为空' })
return
}
if (row.uploadMoney !== '' && row.money !== '' && row.stayDetermineMoney !== '') {
row.adjustmentMoney = parseInt(row.uploadMoney) - parseInt(row.money) - parseInt(row.stayDetermineMoney) - parseInt(row.estimateRebate)
}
} else if (row.isAdjustment === '否') {
row.adjustmentMoney = 0
row.adjustmentRemarks = ''
} }
return val
}, },
adjustmentMoneyAdd() { isAdjustmentInput(row) {
this.formobj.adjustmentMoney = parseInt(this.formobj.firstRebate - 0) + parseInt(this.formobj.secondRebate - 0) - parseInt(this.formobj.surplusRebate - 0) let money = '0'
return this.formobj.adjustmentMoney // - - -
}, money = parseFloat(row.uploadMoney !== '' ? row.uploadMoney : 0) - parseFloat(row.money !== '' ? row.money : 0) - parseFloat(row.stayDetermineMoney !== '' ? row.stayDetermineMoney : 0) - parseFloat(row.estimateRebate !== '' ? row.estimateRebate : 0)
handleSave() { if (row.stayDetermineMoney === '0') {
let aa = null if (parseFloat(money) > 0) {
if (!this.checked) { row.isAdjustment = '是'
aa = { row.adjustmentMoney = parseFloat(money)
sid: this.formobj.sid, row.adjustOrNot = true
stayDetermineMoney: 0, } else if (parseFloat(money) === 0) {
cost: this.formobj.firstCost, row.isAdjustment = '是'
secondaryUploadDate: '', row.adjustmentMoney = parseFloat(money)
secondaryUploadMoney: 0, row.adjustOrNot = false
adjustmentMoney: this.formobj.firstRebate } else {
row.isAdjustment = '否'
row.adjustmentMoney = '0'
row.adjustmentRemarks = ''
row.adjustOrNot = true
} }
} else { } else {
aa = { row.isAdjustment = '否'
sid: this.formobj.sid, row.adjustmentMoney = '0'
stayDetermineMoney: 0, row.adjustmentRemarks = ''
cost: parseInt(this.formobj.firstCost) + parseInt(this.formobj.secondCost), row.adjustOrNot = false
secondaryUploadDate: this.formobj.secondaryUploadDate,
secondaryUploadMoney: this.formobj.secondaryUploadMoney,
adjustmentMoney: this.formobj.adjustmentMoney
}
} }
req.adjustment(aa).then((resp) => {
if (resp.success) {
this.$message({ showClose: true, type: 'success', message: '保存成功' })
this.getList()
this.handleReturn()
}
})
}, },
handleReturn() { isAdjustmentChange(val, row) {
this.dialogVisible = false if (val === '是') {
this.formobj = { row.adjustmentMoney = parseFloat(row.uploadMoney !== '' ? row.uploadMoney : 0) - parseFloat(row.money !== '' ? row.money : 0) - parseFloat(row.stayDetermineMoney !== '' ? row.stayDetermineMoney : 0) - parseFloat(row.estimateRebate !== '' ? row.estimateRebate : 0)
sid: '', } else if (val === '否') {
stayDetermineMoney: '', row.adjustmentMoney = '0'
firstCost: '', row.adjustmentRemarks = ''
firstRebate: '',
surplusRebate: '',
secondaryUploadDate: '',
secondaryUploadMoney: '',
secondCost: '',
secondRebate: '',
adjustmentMoney: ''
} }
this.checked = false
}, },
handleClick() { handleClick() {
this.viewState = 2 this.viewState = 2
@ -576,41 +543,6 @@ export default {
this.$message({ showClose: true, type: 'error', message: '费用不能为空' }) this.$message({ showClose: true, type: 'error', message: '费用不能为空' })
return return
} }
if (row.stayDetermineMoney !== '0') {
if (row.isAdjustment === '是') {
this.$message({ showClose: true, type: 'error', message: '因待确定金额大于0,是否调整选项需选择否' })
return
}
} else if (row.stayDetermineMoney === '0') {
if (row.adjustmentMoney.toString().indexOf('-') !== -1) {
if (row.isAdjustment === '是') {
this.$message({ showClose: true, type: 'error', message: '因待确定金额等于0且调整金额小于0,是否调整选项需选择否' })
return
}
} else if (row.adjustmentMoney !== '0') {
if (row.isAdjustment === '否') {
if ((parseInt(row.uploadMoney) - parseInt(row.estimateRebate)) > 0) {
this.$message({ showClose: true, type: 'error', message: '因待确定金额等于0且调整金额大于0,是否调整选项需选择是' })
return
}
}
} else if (row.adjustmentMoney === '0') {
if (row.isAdjustment === '否') {
this.$message({ showClose: true, type: 'error', message: '因待确定金额等于0且调整金额等于0,是否调整选项需选择是' })
return
}
}
}
if (row.isAdjustment === '是') {
if (row.adjustmentMoney === '') {
this.$message({ showClose: true, type: 'error', message: '调整金额不能为空' })
return
}
if (row.adjustmentRemarks === '') {
this.$message({ showClose: true, type: 'error', message: '调整说明不能为空' })
return
}
}
req.updateDate(row).then((resp) => { req.updateDate(row).then((resp) => {
if (resp.success) { if (resp.success) {
this.$message({ showClose: true, type: 'success', message: '保存成功' }) this.$message({ showClose: true, type: 'success', message: '保存成功' })
@ -618,10 +550,6 @@ export default {
} }
}) })
}, },
toInfo(row) {
this.viewState = 4
this.$refs['divInfo'].showInfo(row)
},
toAdjust(row) { toAdjust(row) {
this.dialogVisible = true this.dialogVisible = true
this.formobj.stayDetermineMoney = row.stayDetermineMoney this.formobj.stayDetermineMoney = row.stayDetermineMoney
@ -631,37 +559,72 @@ export default {
this.formobj.secondCost = 0 this.formobj.secondCost = 0
this.formobj.secondRebate = 0 this.formobj.secondRebate = 0
this.formobj.secondaryUploadMoney = 0 this.formobj.secondaryUploadMoney = 0
this.formobj.surplusRebate = parseInt(row.estimateRebate) - parseInt(row.uploadMoney) this.formobj.cost = row.money
this.formobj.surplusRebate = parseFloat(row.estimateRebate !== '' ? row.estimateRebate : 0) - parseFloat(row.uploadMoney !== '' ? row.uploadMoney : 0)
}, },
doDel() { // --
if (this.sids.length === 0) { firstCostInput() {
this.$message({ showClose: true, type: 'error', message: '请选择至少一条记录进行删除操作' }) // = -
return this.formobj.firstRebate = parseFloat(this.formobj.stayDetermineMoney !== '' ? this.formobj.stayDetermineMoney : 0) - parseFloat(this.formobj.firstCost !== '' ? this.formobj.firstCost : 0)
this.adjustmentMoneyAdd()
},
// --
secondCostInput() {
// = -
this.formobj.secondRebate = parseFloat(this.formobj.secondaryUploadMoney !== '' ? this.formobj.secondaryUploadMoney : 0) - parseFloat(this.formobj.secondCost !== '' ? this.formobj.secondCost : 0)
this.adjustmentMoneyAdd()
},
// --
adjustmentMoneyAdd() {
// = -
this.formobj.adjustmentMoney = parseFloat(this.formobj.firstRebate !== '' ? this.formobj.firstRebate : 0) + parseFloat(this.formobj.secondRebate !== '' ? this.formobj.secondRebate : 0) - parseFloat(this.formobj.surplusRebate !== '' ? this.formobj.surplusRebate : 0)
},
handleSave() {
let aa = null
if (!this.checked) {
aa = {
sid: this.formobj.sid,
stayDetermineMoney: 0,
cost: parseFloat(this.formobj.cost !== '' ? this.formobj.cost : 0) + parseFloat(this.formobj.firstCost !== '' ? this.formobj.firstCost : 0),
secondaryUploadDate: '',
secondaryUploadMoney: 0,
adjustmentMoney: this.formobj.adjustmentMoney
}
} else {
aa = {
sid: this.formobj.sid,
stayDetermineMoney: 0,
cost: parseFloat(this.formobj.cost !== '' ? this.formobj.cost : 0) + parseFloat(this.formobj.firstCost !== '' ? this.formobj.firstCost : 0) + parseFloat(this.formobj.secondCost !== '' ? this.formobj.secondCost : 0),
secondaryUploadDate: this.formobj.secondaryUploadDate,
secondaryUploadMoney: this.formobj.secondaryUploadMoney,
adjustmentMoney: this.formobj.adjustmentMoney
}
} }
const tip = '请确认是否删除所选 ' + this.sids.length + ' 条记录?' req.adjustment(aa).then((resp) => {
this.$confirm(tip, '提示', { if (resp.success) {
confirmButtonText: '确定', this.$message({ showClose: true, type: 'success', message: '保存成功' })
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
const loading = this.$loading({
lock: true,
text: 'Loading',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
})
req.delete(this.sids).then(resp => {
if (resp.success) {
this.$message({ type: 'success', message: resp.msg, showClose: true })
}
this.getList() this.getList()
loading.close() this.handleReturn()
}).catch(e => { }
loading.close()
})
}).catch(() => {
}) })
}, },
handleReturn() {
this.dialogVisible = false
this.formobj = {
sid: '',
stayDetermineMoney: '',
firstCost: '',
firstRebate: '',
surplusRebate: '',
secondaryUploadDate: '',
secondaryUploadMoney: '',
secondCost: '',
secondRebate: '',
adjustmentMoney: '',
cost: ''
}
this.checked = false
},
resetState() { resetState() {
this.viewState = 1 this.viewState = 1
}, },

15
anrui-scm/anrui-scm-ui/src/views/workFlow/danchefanliheduiFlow/relation/yiheduidanchefanli.vue

@ -231,14 +231,16 @@ export default {
}, },
handleSelectionChange(row) { handleSelectionChange(row) {
var dateTime = '' var dateTime = ''
let date = new Date() var nowDate = new Date()
let year = date.getFullYear() // var date = {
let month = date.getMonth() + 1 // year: nowDate.getFullYear(),
dateTime = year + '年' + month + '月' month: nowDate.getMonth() + 1
}
dateTime = date.year + '年' + (date.month >= 10 ? date.month : '0' + date.month) + '月'
const aa = [] const aa = []
const bb = [] const bb = []
row.forEach((element) => { row.forEach((element) => {
if (element.withholdingDateCopy === dateTime) { if (element.palceGenDateCopy === dateTime) {
aa.push({ aa.push({
sid: element.sid, sid: element.sid,
rebateTypeValue: element.rebateTypeValue, rebateTypeValue: element.rebateTypeValue,
@ -265,7 +267,6 @@ export default {
}) })
this.sids = aa this.sids = aa
this.sids_list = bb this.sids_list = bb
console.log('sids', this.sids, bb, 99999999)
}, },
// //
getList() { getList() {
@ -273,7 +274,7 @@ export default {
req.checkApplyGetAlreadyUploadVehRebate(this.listQuery).then((response) => { req.checkApplyGetAlreadyUploadVehRebate(this.listQuery).then((response) => {
console.log('列表查询结果:', response) console.log('列表查询结果:', response)
this.listLoading = false this.listLoading = false
if (response.success && response.data && response.data.total > 0) { if (response.success) {
this.list = response.data.records this.list = response.data.records
this.listQuery.total = response.data.total this.listQuery.total = response.data.total
} else { } else {

49
anrui-scm/anrui-scm-ui/src/views/workFlow/tiaojiaguanliFlow/tiaojiaguanli/tiaojiaEdit.vue

@ -115,12 +115,12 @@
<el-table-column label="调整后销售指导价(元)" header-align="center"> <el-table-column label="调整后销售指导价(元)" header-align="center">
<el-table-column label="全款价" align="left" header-align="center" width="140"> <el-table-column label="全款价" align="left" header-align="center" width="140">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.tzhGuidedPrice" placeholder="" @keyup.native="UpNumber" @keydown.native="UpNumber" class="addinputw" clearable/> <el-input v-model="scope.row.tzhGuidedPrice" placeholder="" @keyup.native="scope.row.tzhGuidedPrice = getNumber(scope.row.tzhGuidedPrice, 0)" class="addinputw" clearable/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="贷款价" align="left" header-align="center" width="140"> <el-table-column label="贷款价" align="left" header-align="center" width="140">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.tzhManufactorSettlementPrice" placeholder="" @keyup.native="UpNumber" @keydown.native="UpNumber" class="addinputw" clearable/> <el-input v-model="scope.row.tzhManufactorSettlementPrice" placeholder="" @keyup.native="scope.row.tzhManufactorSettlementPrice = getNumber(scope.row.tzhManufactorSettlementPrice, 0)" class="addinputw" clearable/>
</template> </template>
</el-table-column> </el-table-column>
</el-table-column> </el-table-column>
@ -207,13 +207,23 @@ export default {
}, '*') }, '*')
}, },
methods: { methods: {
UpNumber(e) { getNumber(val, limit) {
e.target.value = e.target.value.replace(/[^\d]/g, '') // ."-" val = val.replace(/[^0-9.]/g, '') //
e.target.value = e.target.value.replace(/^00/, '0') // 0 val = val.replace(/^00/, '0.') // 0
if (e.target.value.indexOf('.') < 0 && e.target.value !== '' && e.target.value !== '-') { val = val.replace(/^\./g, '0.') // 0.
// 0102 val = val.replace(/\.{2,}/g, '.') //
e.target.value = parseFloat(e.target.value) val = val.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.'); //
/^0\d+/.test(val) ? val = val.slice(1) : '' // 0
const str = '^(\\d+)\\.(\\d{' + limit + '}).*$'
const reg = new RegExp(str)
if (limit === 0) {
//
val = val.replace(reg, '$1')
} else {
//
val = val.replace(reg, '$1.$2')
} }
return val
}, },
// //
addCommodity() { addCommodity() {
@ -332,11 +342,7 @@ export default {
if (valid) { if (valid) {
this.submitdisabled = true this.submitdisabled = true
req.saveOrUpdate(this.formobj).then((resp) => { req.saveOrUpdate(this.formobj).then((resp) => {
this.$message({ this.$message({ showClose: true, type: 'success', message: resp.msg })
showClose: true,
type: 'success',
message: resp.msg
})
// () // ()
window.parent.postMessage({ window.parent.postMessage({
cmd: 'returnHeight', cmd: 'returnHeight',
@ -354,16 +360,23 @@ export default {
}) })
}, },
submitVehicleApply() { submitVehicleApply() {
if (this.formobj.baseModelModpriceModels.length > 0) {
for (var i = 0; i < this.formobj.baseModelModpriceModels.length; i++) {
if (this.formobj.baseModelModpriceModels[i].tzhGuidedPrice === '' || this.formobj.baseModelModpriceModels[i].tzhManufactorSettlementPrice === '') {
this.$message({ showClose: true, type: 'error', message: '车型列表中调整后销售指导价的全款价及贷款价均不能为空' })
return
}
}
} else {
this.$message({ showClose: true, type: 'error', message: '车型列表不能为空' })
return
}
this.$refs['form_obj'].validate((valid) => { this.$refs['form_obj'].validate((valid) => {
if (valid) { if (valid) {
this.submitdisabled = true this.submitdisabled = true
req.submitVehicleApply(this.formobj).then((res) => { req.submitVehicleApply(this.formobj).then((res) => {
if (res.success) { if (res.success) {
this.$message({ this.$message({ showClose: true, type: 'success', message: resp.msg })
showClose: true,
type: 'success',
message: '提交成功'
})
// () // ()
window.parent.postMessage({ window.parent.postMessage({
cmd: 'returnHeight', cmd: 'returnHeight',

13
anrui-scm/anrui-scm-ui/src/views/workFlow/zhuanxiangfanliheduiFlow/relation/yiheduizhuanxiangfanli.vue

@ -206,10 +206,12 @@ export default {
}, },
handleSelectionChange(row) { handleSelectionChange(row) {
var dateTime = '' var dateTime = ''
let date = new Date() var nowDate = new Date()
let year = date.getFullYear() // var date = {
let month = date.getMonth() + 1 // year: nowDate.getFullYear(),
dateTime = year + '年' + month + '月' month: nowDate.getMonth() + 1
}
dateTime = date.year + '年' + (date.month >= 10 ? date.month : '0' + date.month) + '月'
const aa = [] const aa = []
const bb = [] const bb = []
row.forEach((element) => { row.forEach((element) => {
@ -240,7 +242,6 @@ export default {
}) })
this.sids = aa this.sids = aa
this.sids_list = bb this.sids_list = bb
console.log('sids', this.sids, bb, 99999999)
}, },
// //
getList() { getList() {
@ -248,7 +249,7 @@ export default {
req.checkApplyGetAlreadyUploadVehRebate(this.listQuery).then((response) => { req.checkApplyGetAlreadyUploadVehRebate(this.listQuery).then((response) => {
console.log('列表查询结果:', response) console.log('列表查询结果:', response)
this.listLoading = false this.listLoading = false
if (response.success && response.data && response.data.total > 0) { if (response.success) {
this.list = response.data.records this.list = response.data.records
this.listQuery.total = response.data.total this.listQuery.total = response.data.total
} else { } else {

Loading…
Cancel
Save