|
@@ -224,7 +224,7 @@ public class ReportSettlementServiceImpl implements IReportSettlementService {
|
|
ImageIO.write(bufferImg, imagePath.substring(imagePath.lastIndexOf(".") + 1), byteArrayOut);
|
|
ImageIO.write(bufferImg, imagePath.substring(imagePath.lastIndexOf(".") + 1), byteArrayOut);
|
|
int startIndex = settlementList.size() +6;
|
|
int startIndex = settlementList.size() +6;
|
|
//anchor主要用于设置图片的属性
|
|
//anchor主要用于设置图片的属性
|
|
- HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 255, 255, (short) 2, startIndex+(5*j)+50*j, (short) 10, startIndex+(5*j)+50*(j+1));
|
|
|
|
|
|
+ HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 255, 255, (short) 0, startIndex+(5*j)+50*j, (short) 25, startIndex+(5*j)+50*(j+1));
|
|
//HSSFClientAnchor anchor2 = new HSSFClientAnchor(0, 0, 255, 255, (short) 5, settlementList.size() + 40, (short) 10, 40 * 2);
|
|
//HSSFClientAnchor anchor2 = new HSSFClientAnchor(0, 0, 255, 255, (short) 5, settlementList.size() + 40, (short) 10, 40 * 2);
|
|
anchor.setAnchorType(ClientAnchor.AnchorType.DONT_MOVE_AND_RESIZE);
|
|
anchor.setAnchorType(ClientAnchor.AnchorType.DONT_MOVE_AND_RESIZE);
|
|
//插入图片
|
|
//插入图片
|
|
@@ -421,7 +421,7 @@ public class ReportSettlementServiceImpl implements IReportSettlementService {
|
|
ImageIO.write(bufferImg, imagePath.substring(imagePath.lastIndexOf(".") + 1), byteArrayOut);
|
|
ImageIO.write(bufferImg, imagePath.substring(imagePath.lastIndexOf(".") + 1), byteArrayOut);
|
|
//anchor主要用于设置图片的属性
|
|
//anchor主要用于设置图片的属性
|
|
int startIndex = settlementList.size()+7;
|
|
int startIndex = settlementList.size()+7;
|
|
- HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 255, 255, (short) 2, startIndex+(5*j)+50*j, (short) 10, startIndex+(5*j)+50*(j+1));
|
|
|
|
|
|
+ HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 255, 255, (short) 0, startIndex+(5*j)+50*j, (short) 25, startIndex+(5*j)+50*(j+1));
|
|
//HSSFClientAnchor anchor2 = new HSSFClientAnchor(0, 0, 255, 255, (short) 5, settlementList.size() + 40, (short) 10, 40 * 2);
|
|
//HSSFClientAnchor anchor2 = new HSSFClientAnchor(0, 0, 255, 255, (short) 5, settlementList.size() + 40, (short) 10, 40 * 2);
|
|
anchor.setAnchorType(ClientAnchor.AnchorType.DONT_MOVE_AND_RESIZE);
|
|
anchor.setAnchorType(ClientAnchor.AnchorType.DONT_MOVE_AND_RESIZE);
|
|
//插入图片
|
|
//插入图片
|
|
@@ -478,7 +478,7 @@ public class ReportSettlementServiceImpl implements IReportSettlementService {
|
|
}
|
|
}
|
|
List<ProfitReportBytedanceVo> resultList = new ArrayList<>(list.size());
|
|
List<ProfitReportBytedanceVo> resultList = new ArrayList<>(list.size());
|
|
for (Map<String, Object> map : list) {
|
|
for (Map<String, Object> map : list) {
|
|
- //查看该账户 状态信息
|
|
|
|
|
|
+ /* //查看该账户 状态信息
|
|
QueryWrapper<CtopCwjsSettlementInfo> settlementAccountQw = new QueryWrapper<>();
|
|
QueryWrapper<CtopCwjsSettlementInfo> settlementAccountQw = new QueryWrapper<>();
|
|
settlementAccountQw.eq("account_id",map.get("accountId"));
|
|
settlementAccountQw.eq("account_id",map.get("accountId"));
|
|
//账户状态 0-开 1-关
|
|
//账户状态 0-开 1-关
|
|
@@ -488,7 +488,7 @@ public class ReportSettlementServiceImpl implements IReportSettlementService {
|
|
List<CtopCwjsSettlementInfo> settlementAccountList = settlementInfoMapper.selectList(settlementAccountQw);
|
|
List<CtopCwjsSettlementInfo> settlementAccountList = settlementInfoMapper.selectList(settlementAccountQw);
|
|
if (Check.isNull(settlementAccountList)){
|
|
if (Check.isNull(settlementAccountList)){
|
|
continue;
|
|
continue;
|
|
- }
|
|
|
|
|
|
+ }*/
|
|
|
|
|
|
ProfitReportBytedanceVo voSource = new ProfitReportBytedanceVo();
|
|
ProfitReportBytedanceVo voSource = new ProfitReportBytedanceVo();
|
|
//查询销售
|
|
//查询销售
|
|
@@ -530,19 +530,18 @@ public class ReportSettlementServiceImpl implements IReportSettlementService {
|
|
ProfitReportBytedanceVo vo = new ProfitReportBytedanceVo();
|
|
ProfitReportBytedanceVo vo = new ProfitReportBytedanceVo();
|
|
//使用政策 返点类型和比例
|
|
//使用政策 返点类型和比例
|
|
Map<String,Object> policyRateMap = reportSettlementMapper.getProfitRebate(map.get("productName")+"",stringMap.get("startDate"),stringMap.get("endDate"));
|
|
Map<String,Object> policyRateMap = reportSettlementMapper.getProfitRebate(map.get("productName")+"",stringMap.get("startDate"),stringMap.get("endDate"));
|
|
- // vo.setRebateType(policyRateMap.getOrDefault("rebateType","")+"");//返点类型
|
|
|
|
-
|
|
|
|
- if(policyRateMap.getOrDefault("rebateType","").equals("0")){
|
|
|
|
- vo.setRebateType("返现");//返点类型
|
|
|
|
- }else if (policyRateMap.getOrDefault("rebateType","").equals("1")){
|
|
|
|
- vo.setRebateType("返货");
|
|
|
|
- }else if (policyRateMap.getOrDefault("rebateType","").equals("2")){
|
|
|
|
- vo.setRebateType("返现+返货");
|
|
|
|
|
|
+ if (!Check.isNull(policyRateMap)){
|
|
|
|
+ if(Integer.valueOf(policyRateMap.get("rebateType").toString())== 0){
|
|
|
|
+ vo.setRebateType("返现");//返点类型
|
|
|
|
+ }else if (Integer.valueOf(policyRateMap.get("rebateType").toString())== 1){
|
|
|
|
+ vo.setRebateType("返货");
|
|
|
|
+ }else if (Integer.valueOf(policyRateMap.get("rebateType").toString())== 2){
|
|
|
|
+ vo.setRebateType("返现+返货");
|
|
|
|
+ }
|
|
|
|
+ vo.setRebateRate(policyRateMap.getOrDefault("rebateRate","")+"%");//返点比列
|
|
}else {
|
|
}else {
|
|
vo.setRebateType("");
|
|
vo.setRebateType("");
|
|
}
|
|
}
|
|
-
|
|
|
|
- vo.setRebateRate(policyRateMap.getOrDefault("rebateRate","")+"");//返点比列
|
|
|
|
// 时间段内 账户流水 信息
|
|
// 时间段内 账户流水 信息
|
|
List<Map<String,Object>> listAccount = reportSettlementMapper.getProfitBytedanceCost(map.get("accountId")+"",stringMap.get("startDate"),stringMap.get("endDate"));
|
|
List<Map<String,Object>> listAccount = reportSettlementMapper.getProfitBytedanceCost(map.get("accountId")+"",stringMap.get("startDate"),stringMap.get("endDate"));
|
|
listAccount.removeAll(Collections.singleton(null));
|
|
listAccount.removeAll(Collections.singleton(null));
|
|
@@ -681,7 +680,7 @@ public class ReportSettlementServiceImpl implements IReportSettlementService {
|
|
}else if (Integer.valueOf(policyRateMap.get("rebateType").toString())== 2){
|
|
}else if (Integer.valueOf(policyRateMap.get("rebateType").toString())== 2){
|
|
vo.setRebateType("返现+返货");
|
|
vo.setRebateType("返现+返货");
|
|
}
|
|
}
|
|
- vo.setRebateRate(policyRateMap.getOrDefault("rebateRate","")+"");//返点比列
|
|
|
|
|
|
+ vo.setRebateRate(policyRateMap.getOrDefault("rebateRate","")+"%");//返点比列
|
|
}else {
|
|
}else {
|
|
vo.setRebateType("");
|
|
vo.setRebateType("");
|
|
}
|
|
}
|