修改话费

new-dev
袁野 1 year ago
parent d4cc23cce6
commit cea4c34719
  1. 2
      hai-service/src/main/java/com/hai/config/ThirdProductConfig.java
  2. 5
      hai-service/src/main/java/com/hai/service/BsConfigService.java
  3. 62
      hai-service/src/main/java/com/hai/service/BsPushScheduleTaskService.java
  4. 51
      hai-service/src/main/java/com/hai/service/impl/BsConfigServiceImpl.java
  5. 35
      hai-service/src/main/java/com/hai/service/impl/BsPushScheduleTaskServiceImpl.java

@ -120,7 +120,7 @@ public class ThirdProductConfig {
} else { } else {
object.put("productPayType" , bsConfigService.getProductPayTypeByMap(listMap)); object.put("productPayType" , bsConfigService.getProductPayTypeByMap(listMap));
} }
object.put("productPayTypeNew" , bsConfigService.getProductPayTypeNewByMap(listMap));
object.put("productPlatform" , bsConfigService.getProductPlatformByMap(listMap)); object.put("productPlatform" , bsConfigService.getProductPlatformByMap(listMap));
return object; return object;

@ -1,9 +1,11 @@
package com.hai.service; package com.hai.service;
import com.alibaba.fastjson.JSONObject;
import com.hai.entity.BsProductDiscount; import com.hai.entity.BsProductDiscount;
import com.hai.entity.BsProductPayType; import com.hai.entity.BsProductPayType;
import com.hai.entity.BsProductPlatform; import com.hai.entity.BsProductPlatform;
import java.util.List;
import java.util.Map; import java.util.Map;
/** /**
@ -45,4 +47,7 @@ public interface BsConfigService {
*/ */
String getProductPayTypeByMap(Map<String, Object> map); String getProductPayTypeByMap(Map<String, Object> map);
List<BsProductPayType> getProductPayTypeNewByMap(Map<String, Object> map);
} }

@ -0,0 +1,62 @@
package com.hai.service;
import com.hai.entity.BsMsg;
import com.hai.entity.BsPushScheduleTask;
import com.hai.entity.HighUser;
import java.util.List;
import java.util.Map;
/**
* @serviceName BsPushScheduleTaskService.java
* @author Sum1Dream
* @version 1.0.0
* @Description // 定时发布任务功能
* @createTime 15:41 2023/6/27
**/
public interface BsPushScheduleTaskService {
/**
* @Author Sum1Dream
* @Name insertPushScheduleTask
* @Description // 新增发布任务
* @Date 18:06 2023/6/28
* @Param [bsPushScheduleTask]
* @Return void
*/
void insertPushScheduleTask(BsPushScheduleTask bsPushScheduleTask);
/**
* @Author Sum1Dream
* @Name updatePushScheduleTask
* @Description // 更新发布任务
* @Date 18:07 2023/6/28
* @Param [bsPushScheduleTask5]
* @Return void
*/
void updatePushScheduleTask(BsPushScheduleTask bsPushScheduleTask5);
/**
* @Author Sum1Dream
* @Name findPushScheduleTask
* @Description // 查询发布任务详情
* @Date 18:07 2023/6/28
* @Param [id]
* @Return com.hai.entity.BsMsg
*/
BsMsg findPushScheduleTask(Long id);
/**
* @Author Sum1Dream
* @Name getPushScheduleTaskByList
* @Description // 查询发布任务列表
* @Date 18:07 2023/6/28
* @Param [map]
* @Return java.util.List<com.hai.entity.BsMsg>
*/
List<BsMsg> getPushScheduleTaskByList(Map<String , Object> map);
}

@ -1,5 +1,6 @@
package com.hai.service.impl; package com.hai.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.hai.dao.BsProductDiscountMapper; import com.hai.dao.BsProductDiscountMapper;
import com.hai.dao.BsProductPayTypeMapper; import com.hai.dao.BsProductPayTypeMapper;
import com.hai.dao.BsProductPlatformMapper; import com.hai.dao.BsProductPlatformMapper;
@ -9,6 +10,7 @@ import org.apache.commons.collections4.MapUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
@ -121,4 +123,53 @@ public class BsConfigServiceImpl implements BsConfigService {
} }
} }
@Override
public List<BsProductPayType> getProductPayTypeNewByMap(Map<String, Object> map) {
try {
BsProductPayTypeExample example = new BsProductPayTypeExample();
BsProductPayTypeExample.Criteria criteria = example.createCriteria();
// 获取平台编码
Integer platformId = MapUtils.getInteger(map , "platformId");
if (MapUtils.getInteger(map , "productType") != null) {
criteria.andProductTypeEqualTo(MapUtils.getInteger(map , "productType"));
}
if (MapUtils.getLong(map , "sourceId") != null) {
criteria.andSourceIdEqualTo(MapUtils.getLong(map , "sourceId"));
}
List<BsProductPayType> list = bsProductPayTypeMapper.selectByExample(example);
List<BsProductPayType> productPayTypes = new ArrayList<>();
// 1:支付宝 2:微信 3:汇联通工会卡 4:银联 5:银联分期 6 嗨森逛油卡 7:嗨森逛车队油卡 8:积分兑换
for (BsProductPayType productPayType : list) {
// platformId 1:小程序 2:h5 3:银联
if (platformId != null) {
if (platformId == 1 || platformId == 2) {
if (!(productPayType.getPayTypeId() == 4 || productPayType.getPayTypeId() == 5 )) {
productPayTypes.add(productPayType);
}
} else if (platformId == 3) {
if (productPayType.getPayTypeId() != 2) {
productPayTypes.add(productPayType);
}
}
}
}
return productPayTypes;
} catch (Exception e) {
System.out.println(e);
return null;
}
}
} }

@ -0,0 +1,35 @@
package com.hai.service.impl;
import com.hai.entity.BsMsg;
import com.hai.entity.BsPushScheduleTask;
import com.hai.service.BsPushScheduleTaskService;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
import java.util.Map;
@Service("bsPushScheduleTaskService")
public class BsPushScheduleTaskServiceImpl implements BsPushScheduleTaskService {
@Override
public void insertPushScheduleTask(BsPushScheduleTask bsPushScheduleTask) {
}
@Override
public void updatePushScheduleTask(BsPushScheduleTask bsPushScheduleTask5) {
}
@Override
public BsMsg findPushScheduleTask(Long id) {
return null;
}
@Override
public List<BsMsg> getPushScheduleTaskByList(Map<String, Object> map) {
return null;
}
}
Loading…
Cancel
Save