Browse Source

优惠包清单下载、交车确认优化

master
fanzongzhe 2 years ago
parent
commit
f2c8ade2bc
  1. 1
      anrui-buscenter/anrui-buscenter-api/src/main/java/com/yxt/anrui/buscenter/api/busdiscountpackagehandover/BusDiscountpackageHandover.java
  2. 2
      anrui-buscenter/anrui-buscenter-api/src/main/java/com/yxt/anrui/buscenter/api/busdiscountpackagehandover/app/AppBusDiscountpackageHandoverVo.java
  3. 3
      anrui-buscenter/anrui-buscenter-biz/src/main/java/com/yxt/anrui/buscenter/biz/busdiscountpackagehandover/BusDiscountpackageHandoverMapper.xml
  4. 19
      anrui-buscenter/anrui-buscenter-biz/src/main/java/com/yxt/anrui/buscenter/biz/busdiscountpackagehandover/BusDiscountpackageHandoverService.java
  5. 37
      anrui-buscenter/anrui-buscenter-biz/src/main/java/com/yxt/anrui/buscenter/biz/bushandover/BusHandoverService.java
  6. 4
      anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/autoservice/discountPackageHandover/AppBusDiscountpackageHandoversVo.java

1
anrui-buscenter/anrui-buscenter-api/src/main/java/com/yxt/anrui/buscenter/api/busdiscountpackagehandover/BusDiscountpackageHandover.java

@ -60,4 +60,5 @@ public class BusDiscountpackageHandover extends BaseEntity {
@ApiModelProperty("移交备注")
private String transferRemarks;
private String orgSidPath;
private String filePath;
}

2
anrui-buscenter/anrui-buscenter-api/src/main/java/com/yxt/anrui/buscenter/api/busdiscountpackagehandover/app/AppBusDiscountpackageHandoverVo.java

@ -46,4 +46,6 @@ public class AppBusDiscountpackageHandoverVo implements Vo {
private Boolean showUploadBtn; // 已交接显示
@ApiModelProperty("车架号")
private String vins; // 车架号
private boolean showDownloadBtn;
private String filePath;
}

3
anrui-buscenter/anrui-buscenter-biz/src/main/java/com/yxt/anrui/buscenter/biz/busdiscountpackagehandover/BusDiscountpackageHandoverMapper.xml

@ -40,7 +40,8 @@
transferName as receiveName,
transferPhone as receivePhone,
transferStateValue as nodeState,
vins
vins,
filePath
FROM
bus_discountpackage_handover
<where>${ew.sqlSegment}</where>

19
anrui-buscenter/anrui-buscenter-biz/src/main/java/com/yxt/anrui/buscenter/biz/busdiscountpackagehandover/BusDiscountpackageHandoverService.java

@ -413,6 +413,13 @@ public class BusDiscountpackageHandoverService extends MybatisBaseService<BusDis
if (null != busFiles && i > 0) {
this.uploadPicture(dto);
}
BusDiscountpackageHandoverDetailsVo detailsVo = this.handoverDetails(sid);
String s = commonCreatePdf(detailsVo);
String targetPath = docPdfComponent.getUploadTemplateUrl();
String filePath = s.substring(targetPath.length());
BusDiscountpackageHandover entity = fetchBySid(sid);
entity.setFilePath(filePath);
baseMapper.updateById(entity);
} else if ((sysRoleVo.getName()).contains("优惠包管理员")) {
dto.setTransferStateKey("003");
dto.setTransferStateValue("移交中");
@ -647,9 +654,16 @@ public class BusDiscountpackageHandoverService extends MybatisBaseService<BusDis
IPage<BusDiscountpackageHandover> page = PagerUtil.queryToPage(pq);
IPage<AppBusDiscountpackageHandoverVo> pagging = baseMapper.selectAppPageVo(page, qw);
List<AppBusDiscountpackageHandoverVo> records = pagging.getRecords();
String urlPrefix = docPdfComponent.getPrefixTemplateUrl();
if (null != records && records.size() > 0) {
for (AppBusDiscountpackageHandoverVo record : records) {
if (null != record) {
if (StringUtils.isNotBlank(record.getFilePath())) {
record.setShowDownloadBtn(true);
record.setFilePath(urlPrefix + record.getFilePath());
} else {
record.setShowDownloadBtn(false);
}
if (StringUtils.isBlank(record.getVins())) {
record.setVins("-");
}
@ -901,6 +915,11 @@ public class BusDiscountpackageHandoverService extends MybatisBaseService<BusDis
entity.setRecTime(new Date());
entity.setTransferStateValue("已移交");
entity.setTransferStateKey("004");
BusDiscountpackageHandoverDetailsVo detailsVo = this.handoverDetails(dto.getSid());
String s = commonCreatePdf(detailsVo);
String targetPath = docPdfComponent.getUploadTemplateUrl();
String filePath = s.substring(targetPath.length());
entity.setFilePath(filePath);
baseMapper.updateById(entity);
return rb.success();
}

37
anrui-buscenter/anrui-buscenter-biz/src/main/java/com/yxt/anrui/buscenter/biz/bushandover/BusHandoverService.java

@ -915,11 +915,14 @@ public class BusHandoverService extends MybatisBaseService<BusHandoverMapper, Bu
if (Integer.parseInt(information.getDirverCard()) > 0) {
sbKey.append("008").append("、");
}
if (Integer.parseInt(information.getGasCertificate()) > 0) {
if ("0".equals(data.getIsFuelVehicle())) {
sbKey.append("009").append("、");
if (StringUtils.isNotBlank(information.getGasCertificate())) {
if (Integer.parseInt(information.getGasCertificate()) > 0) {
if ("0".equals(data.getIsFuelVehicle())) {
sbKey.append("009").append("、");
}
}
}
}
} else {
if ("0".equals(data.getIsFuelVehicle())) {
@ -1132,15 +1135,17 @@ public class BusHandoverService extends MybatisBaseService<BusHandoverMapper, Bu
}
}
}
String staffSid = busHandover.getStaffSid();
ResultBean<SysStaffinfoDetailsVo> voResultBean = sysStaffinfoFeign.fetchBySid(staffSid);
if (voResultBean.getSuccess()) {
if (null != voResultBean.getData()) {
SysStaffinfoDetailsVo data = voResultBean.getData();
if (StringUtils.isNotBlank(data.getName())) {
pdfVo.setStaffName(data.getName());
//出门证业务经办人
permitVo.setOperator(data.getName());
if (StringUtils.isNotBlank(busHandover.getStaffSid())) {
String staffSid = busHandover.getStaffSid();
ResultBean<SysStaffinfoDetailsVo> voResultBean = sysStaffinfoFeign.fetchBySid(staffSid);
if (voResultBean.getSuccess()) {
if (null != voResultBean.getData()) {
SysStaffinfoDetailsVo data = voResultBean.getData();
if (StringUtils.isNotBlank(data.getName())) {
pdfVo.setStaffName(data.getName());
//出门证业务经办人
permitVo.setOperator(data.getName());
}
}
}
}
@ -1632,9 +1637,11 @@ public class BusHandoverService extends MybatisBaseService<BusHandoverMapper, Bu
if (Integer.parseInt(information.getDirverCard()) > 0) {
sbKey.append("008").append("、");
}
if (Integer.parseInt(information.getGasCertificate()) > 0) {
if ("0".equals(data.getIsFuelVehicle())) {
sbKey.append("009").append("、");
if (StringUtils.isNotBlank(information.getGasCertificate())) {
if (Integer.parseInt(information.getGasCertificate()) > 0) {
if ("0".equals(data.getIsFuelVehicle())) {
sbKey.append("009").append("、");
}
}
}
}

4
anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/autoservice/discountPackageHandover/AppBusDiscountpackageHandoversVo.java

@ -46,6 +46,6 @@ public class AppBusDiscountpackageHandoversVo implements Vo {
private Boolean showUploadBtn; // 已交接显示
@ApiModelProperty("车架号")
private String vins; // 车架号
private boolean showDownloadBtn;
private String filePath;
}

Loading…
Cancel
Save