提交代码

master
胡锐 5 months ago
parent cac57f0474
commit f758d75633
  1. 1
      bweb/src/main/java/com/bweb/config/AuthConfig.java
  2. 8
      bweb/src/main/java/com/bweb/controller/BsGasChannelConfigController.java
  3. 29
      bweb/src/main/java/com/bweb/controller/BsGasOrderController.java
  4. 6
      service/src/main/java/com/hfkj/channel/gas/newlink/NewLinkGasService.java
  5. 1
      service/src/main/java/com/hfkj/dao/BsGasOrderMapperExt.java
  6. 17
      service/src/main/java/com/hfkj/model/order/ExportGasOrderModel.java
  7. 5
      service/src/main/java/com/hfkj/service/gas/impl/BsGasOilGunNoServiceImpl.java
  8. 4
      service/src/main/java/com/hfkj/service/gas/impl/BsGasOrderServiceImpl.java
  9. 2
      service/src/main/java/com/hfkj/service/order/impl/BsGasChannelConfigServiceImpl.java

@ -88,6 +88,7 @@ public class AuthConfig implements WebMvcConfigurer {
.excludePathPatterns("/client/*") .excludePathPatterns("/client/*")
.excludePathPatterns("/sms/*") .excludePathPatterns("/sms/*")
.excludePathPatterns("/common/*") .excludePathPatterns("/common/*")
.excludePathPatterns("/gasChannelConfig/*")
.excludePathPatterns("/secUser/login") .excludePathPatterns("/secUser/login")
.excludePathPatterns("/secUser/loginOut") .excludePathPatterns("/secUser/loginOut")
.excludePathPatterns("/agentMer/*") .excludePathPatterns("/agentMer/*")

@ -10,6 +10,7 @@ import com.hfkj.entity.BsGasChannelConfig;
import com.hfkj.model.ResponseData; import com.hfkj.model.ResponseData;
import com.hfkj.service.order.BsGasChannelConfigService; import com.hfkj.service.order.BsGasChannelConfigService;
import com.hfkj.sysenum.MerchantSourceTypeEnum; import com.hfkj.sysenum.MerchantSourceTypeEnum;
import com.hfkj.sysenum.order.OrderPayChannelEnum;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import io.swagger.models.auth.In; import io.swagger.models.auth.In;
@ -43,9 +44,12 @@ public class BsGasChannelConfigController {
throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, "");
} }
// 查询配置 // 查询配置
BsGasChannelConfig config = gasChannelConfigService.getDetail(MerchantSourceTypeEnum.type2); BsGasChannelConfig config = gasChannelConfigService.getDetail(MerchantSourceTypeEnum.getDataByType(body.getGasChannelType()));
if (config == null) { if (config == null) {
throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); config = new BsGasChannelConfig();
config.setGasChannelType(body.getGasChannelType());
config.setChannelType(OrderPayChannelEnum.type1.getCode());
config.setStatus(1);
} }
if(body.getLedgerAccountFlag().equals(true)) { if(body.getLedgerAccountFlag().equals(true)) {
if (StringUtils.isBlank(body.getLedgerAccountData())) { if (StringUtils.isBlank(body.getLedgerAccountData())) {

@ -63,6 +63,8 @@ public class BsGasOrderController {
@RequestParam(name = "orderNo", required = false) String orderNo, @RequestParam(name = "orderNo", required = false) String orderNo,
@RequestParam(name = "payType", required = false) String payType, @RequestParam(name = "payType", required = false) String payType,
@RequestParam(name = "paySerialNo", required = false) String paySerialNo, @RequestParam(name = "paySerialNo", required = false) String paySerialNo,
@RequestParam(name = "channelType", required = false) Integer channelType,
@RequestParam(name = "channelOrderNo", required = false) String channelOrderNo,
@RequestParam(name = "status", required = false) Integer status, @RequestParam(name = "status", required = false) Integer status,
@RequestParam(name = "createTimeS", required = false) Long createTimeS, @RequestParam(name = "createTimeS", required = false) Long createTimeS,
@RequestParam(name = "createTimeE", required = false) Long createTimeE, @RequestParam(name = "createTimeE", required = false) Long createTimeE,
@ -81,6 +83,8 @@ public class BsGasOrderController {
param.put("orderNo", orderNo); param.put("orderNo", orderNo);
param.put("payType", payType); param.put("payType", payType);
param.put("paySerialNo", paySerialNo); param.put("paySerialNo", paySerialNo);
param.put("channelType", channelType);
param.put("channelOrderNo", channelOrderNo);
param.put("userPhone", userPhone); param.put("userPhone", userPhone);
param.put("status", status); param.put("status", status);
param.put("createTimeS", createTimeS); param.put("createTimeS", createTimeS);
@ -131,6 +135,8 @@ public class BsGasOrderController {
@RequestParam(name = "orderNo", required = false) String orderNo, @RequestParam(name = "orderNo", required = false) String orderNo,
@RequestParam(name = "payType", required = false) String payType, @RequestParam(name = "payType", required = false) String payType,
@RequestParam(name = "paySerialNo", required = false) String paySerialNo, @RequestParam(name = "paySerialNo", required = false) String paySerialNo,
@RequestParam(name = "channelType", required = false) Integer channelType,
@RequestParam(name = "channelOrderNo", required = false) String channelOrderNo,
@RequestParam(name = "status", required = false) Integer status, @RequestParam(name = "status", required = false) Integer status,
@RequestParam(name = "createTimeS", required = false) Long createTimeS, @RequestParam(name = "createTimeS", required = false) Long createTimeS,
@RequestParam(name = "createTimeE", required = false) Long createTimeE, @RequestParam(name = "createTimeE", required = false) Long createTimeE,
@ -151,7 +157,8 @@ public class BsGasOrderController {
param.put("orderNo", orderNo); param.put("orderNo", orderNo);
param.put("payType", payType); param.put("payType", payType);
param.put("paySerialNo", paySerialNo); param.put("paySerialNo", paySerialNo);
param.put("paySerialNo", paySerialNo); param.put("channelType", channelType);
param.put("channelOrderNo", channelOrderNo);
param.put("userPhone", userPhone); param.put("userPhone", userPhone);
param.put("status", status); param.put("status", status);
param.put("createTimeS", createTimeS); param.put("createTimeS", createTimeS);
@ -204,6 +211,8 @@ public class BsGasOrderController {
@RequestParam(name = "orderNo", required = false) String orderNo, @RequestParam(name = "orderNo", required = false) String orderNo,
@RequestParam(name = "payType", required = false) String payType, @RequestParam(name = "payType", required = false) String payType,
@RequestParam(name = "paySerialNo", required = false) String paySerialNo, @RequestParam(name = "paySerialNo", required = false) String paySerialNo,
@RequestParam(name = "channelType", required = false) Integer channelType,
@RequestParam(name = "channelOrderNo", required = false) String channelOrderNo,
@RequestParam(name = "status", required = false) Integer status, @RequestParam(name = "status", required = false) Integer status,
@RequestParam(name = "createTimeS", required = false) Long createTimeS, @RequestParam(name = "createTimeS", required = false) Long createTimeS,
@RequestParam(name = "createTimeE", required = false) Long createTimeE, @RequestParam(name = "createTimeE", required = false) Long createTimeE,
@ -222,6 +231,8 @@ public class BsGasOrderController {
param.put("orderNo", orderNo); param.put("orderNo", orderNo);
param.put("payType", payType); param.put("payType", payType);
param.put("paySerialNo", paySerialNo); param.put("paySerialNo", paySerialNo);
param.put("channelType", channelType);
param.put("channelOrderNo", channelOrderNo);
param.put("userPhone", userPhone); param.put("userPhone", userPhone);
param.put("status", status); param.put("status", status);
param.put("createTimeS", createTimeS); param.put("createTimeS", createTimeS);
@ -265,7 +276,8 @@ public class BsGasOrderController {
model = new ExportGasOrderModel(); model = new ExportGasOrderModel();
model.setAgentName(StringUtils.isBlank(gasOrder.getAgentName())?"无":gasOrder.getAgentName()); model.setAgentName(StringUtils.isBlank(gasOrder.getAgentName())?"无":gasOrder.getAgentName());
model.setAgentStaffName(StringUtils.isBlank(gasOrder.getAgentStaffName())?"无":gasOrder.getAgentStaffName()); model.setAgentStaffName(StringUtils.isBlank(gasOrder.getAgentStaffName())?"无":gasOrder.getAgentStaffName());
model.setChannelTypeName(MerchantSourceTypeEnum.getNameByType(gasOrder.getChannelType())); model.setChannelType(MerchantSourceTypeEnum.getNameByType(gasOrder.getChannelType()));
model.setChannelOrderNo(gasOrder.getChannelOrderNo());
model.setOrderNo(gasOrder.getOrderNo()); model.setOrderNo(gasOrder.getOrderNo());
model.setUserPhone(StringUtils.isBlank(gasOrder.getUserPhone())?"无":gasOrder.getUserPhone()); model.setUserPhone(StringUtils.isBlank(gasOrder.getUserPhone())?"无":gasOrder.getUserPhone());
model.setMerName(gasOrder.getMerName()); model.setMerName(gasOrder.getMerName());
@ -290,6 +302,8 @@ public class BsGasOrderController {
model.setPayTime(gasOrder.getPayTime()); model.setPayTime(gasOrder.getPayTime());
model.setRefundTime(gasOrder.getRefundTime()); model.setRefundTime(gasOrder.getRefundTime());
model.setCancelTime(gasOrder.getCancelTime()); model.setCancelTime(gasOrder.getCancelTime());
model.setAbnormal(gasOrder.getAbnormal()?"异常":"正常");
model.setAbnormalContent(gasOrder.getAbnormalContent());
dataList.add(model); dataList.add(model);
} }
@ -322,13 +336,16 @@ public class BsGasOrderController {
includeColumnFiledNames.add("payTime"); includeColumnFiledNames.add("payTime");
includeColumnFiledNames.add("refundTime"); includeColumnFiledNames.add("refundTime");
includeColumnFiledNames.add("cancelTime"); includeColumnFiledNames.add("cancelTime");
includeColumnFiledNames.add("abnormal");
includeColumnFiledNames.add("abnormalContent");
if (sessionObject.getAccount().getObjectType().equals(SecUserObjectTypeEnum.type1.getCode())) { if (sessionObject.getAccount().getObjectType().equals(SecUserObjectTypeEnum.type1.getCode())) {
includeColumnFiledNames.add("agentName"); includeColumnFiledNames.add("agentName");
includeColumnFiledNames.add("agentStaffName"); includeColumnFiledNames.add("agentStaffName");
includeColumnFiledNames.add("merName"); includeColumnFiledNames.add("merName");
includeColumnFiledNames.add("gasStaffName"); includeColumnFiledNames.add("gasStaffName");
includeColumnFiledNames.add("channelTypeName"); includeColumnFiledNames.add("channelType");
includeColumnFiledNames.add("channelOrderNo");
includeColumnFiledNames.add("userPhone"); includeColumnFiledNames.add("userPhone");
} else if (sessionObject.getAccount().getObjectType().equals(SecUserObjectTypeEnum.type2.getCode()) ) { } else if (sessionObject.getAccount().getObjectType().equals(SecUserObjectTypeEnum.type2.getCode()) ) {
@ -341,11 +358,13 @@ public class BsGasOrderController {
} else if (sessionObject.getAccount().getObjectType().equals(SecUserObjectTypeEnum.type4.getCode()) ) { } else if (sessionObject.getAccount().getObjectType().equals(SecUserObjectTypeEnum.type4.getCode()) ) {
includeColumnFiledNames.add("agentStaffName"); includeColumnFiledNames.add("agentStaffName");
includeColumnFiledNames.add("merName"); includeColumnFiledNames.add("merName");
includeColumnFiledNames.add("channelTypeName"); includeColumnFiledNames.add("channelType");
includeColumnFiledNames.add("channelOrderNo");
} else if (sessionObject.getAccount().getObjectType().equals(SecUserObjectTypeEnum.type5.getCode()) ) { } else if (sessionObject.getAccount().getObjectType().equals(SecUserObjectTypeEnum.type5.getCode()) ) {
includeColumnFiledNames.add("merName"); includeColumnFiledNames.add("merName");
includeColumnFiledNames.add("channelTypeName"); includeColumnFiledNames.add("channelType");
includeColumnFiledNames.add("channelOrderNo");
} }
EasyExcel.write(fileUrl+pathName) EasyExcel.write(fileUrl+pathName)

@ -112,6 +112,7 @@ public class NewLinkGasService {
merchant.setLatitude(gasData.getString("gasAddressLatitude")); merchant.setLatitude(gasData.getString("gasAddressLatitude"));
merchant.setContactsName(merchant.getMerName()); merchant.setContactsName(merchant.getMerName());
merchant.setContactsTel(merchant.getMerNo()); merchant.setContactsTel(merchant.getMerNo());
merchant.setCustomerServiceTel("400-0236806");
merchant.setMerLabel(StringUtils.join(gasData.getJSONArray("gasFeatureList"),",")); merchant.setMerLabel(StringUtils.join(gasData.getJSONArray("gasFeatureList"),","));
if (merchant.getId() == null) { if (merchant.getId() == null) {
merchantService.createMerchant(merchant); merchantService.createMerchant(merchant);
@ -263,4 +264,9 @@ public class NewLinkGasService {
} }
return ret; return ret;
} }
public static void main(String[] args) {
String str = "123456.11xxx--1s";
System.out.println();
}
} }

@ -24,6 +24,7 @@ public interface BsGasOrderMapperExt {
" <if test='param.merName != null'> and mer_name like concat('%',#{param.merName},'%') </if>" + " <if test='param.merName != null'> and mer_name like concat('%',#{param.merName},'%') </if>" +
" <if test='param.orderNo != null'> and order_no like concat('%',#{param.orderNo},'%') </if>" + " <if test='param.orderNo != null'> and order_no like concat('%',#{param.orderNo},'%') </if>" +
" <if test='param.orderChildNo != null'> and order_child_no like concat('%',#{param.orderChildNo},'%') </if>" + " <if test='param.orderChildNo != null'> and order_child_no like concat('%',#{param.orderChildNo},'%') </if>" +
" <if test='param.channelType != null'> and channel_type = #{param.channelType} </if>" +
" <if test='param.channelOrderNo != null'> and channel_order_no like concat('%',#{param.channelOrderNo},'%') </if>" + " <if test='param.channelOrderNo != null'> and channel_order_no like concat('%',#{param.channelOrderNo},'%') </if>" +
" <if test='param.payType != null'> and pay_type = #{param.payType} </if>" + " <if test='param.payType != null'> and pay_type = #{param.payType} </if>" +
" <if test='param.paySerialNo != null'> and pay_serial_no like concat('%',#{param.paySerialNo},'%') </if>" + " <if test='param.paySerialNo != null'> and pay_serial_no like concat('%',#{param.paySerialNo},'%') </if>" +

@ -28,6 +28,14 @@ public class ExportGasOrderModel {
@ExcelProperty("交易单号") @ExcelProperty("交易单号")
private String orderNo; private String orderNo;
@ColumnWidth(25)
@ExcelProperty("渠道")
private String channelType;
@ColumnWidth(25)
@ExcelProperty("渠道单号")
private String channelOrderNo;
@ColumnWidth(15) @ColumnWidth(15)
@ExcelProperty("客户电话") @ExcelProperty("客户电话")
private String userPhone; private String userPhone;
@ -121,6 +129,11 @@ public class ExportGasOrderModel {
private Date cancelTime; private Date cancelTime;
@ColumnWidth(22) @ColumnWidth(22)
@ExcelProperty("渠道") @ExcelProperty("异常状态")
private String channelTypeName; private String abnormal;
@ColumnWidth(22)
@ExcelProperty("异常原因")
private String abnormalContent;
} }

@ -100,7 +100,10 @@ public class BsGasOilGunNoServiceImpl implements BsGasOilGunNoService {
@Override @Override
public List<BsGasOilGunNo> getOilGunNoList(String merNo, String oilNo) { public List<BsGasOilGunNo> getOilGunNoList(String merNo, String oilNo) {
return getOilGunNoList(merNo).stream().filter(o->o.getOilNo().equals(oilNo)).collect(Collectors.toList()); return getOilGunNoList(merNo).stream()
.filter(o->o.getOilNo().equals(oilNo))
.sorted(Comparator.comparing(o-> Integer.parseInt(o.getGunNo().replaceAll("\\D", ""))))
.collect(Collectors.toList());
} }
@Override @Override

@ -129,6 +129,10 @@ public class BsGasOrderServiceImpl implements BsGasOrderService {
criteria.andOrderNoLike("%"+MapUtils.getString(param, "orderNo")+"%"); criteria.andOrderNoLike("%"+MapUtils.getString(param, "orderNo")+"%");
} }
if (MapUtils.getInteger(param, "channelType") != null) {
criteria.andChannelTypeEqualTo(MapUtils.getInteger(param, "channelType"));
}
if (StringUtils.isNotBlank(MapUtils.getString(param, "orderChildNo"))) { if (StringUtils.isNotBlank(MapUtils.getString(param, "orderChildNo"))) {
criteria.andOrderChildNoLike("%"+MapUtils.getString(param, "orderChildNo")+"%"); criteria.andOrderChildNoLike("%"+MapUtils.getString(param, "orderChildNo")+"%");
} }

@ -44,7 +44,7 @@ public class BsGasChannelConfigServiceImpl implements BsGasChannelConfigService
return (BsGasChannelConfig) obj; return (BsGasChannelConfig) obj;
} }
BsGasChannelConfigExample example = new BsGasChannelConfigExample(); BsGasChannelConfigExample example = new BsGasChannelConfigExample();
example.createCriteria().andGasChannelTypeEqualTo(gasSourceType.getNumber()); example.createCriteria().andGasChannelTypeEqualTo(gasSourceType.getNumber()).andStatusNotEqualTo(0);
List<BsGasChannelConfig> list = gasChannelConfigMapper.selectByExample(example); List<BsGasChannelConfig> list = gasChannelConfigMapper.selectByExample(example);
if (!list.isEmpty()) { if (!list.isEmpty()) {
BsGasChannelConfig gasChannelConfig = list.get(0); BsGasChannelConfig gasChannelConfig = list.get(0);

Loading…
Cancel
Save