|
|
|
@@ -35,6 +35,7 @@ import javax.servlet.http.HttpServletRequest; |
|
|
|
import javax.servlet.http.HttpServletResponse; |
|
|
|
|
|
|
|
import java.lang.reflect.InvocationTargetException; |
|
|
|
import java.math.BigDecimal; |
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Date; |
|
|
|
import java.util.HashMap; |
|
|
|
@@ -640,13 +641,13 @@ public class WxCardSpendServiceImpl implements WxCardSpendService { |
|
|
|
Map<Long,WxMerchant> merchantMap = this.getMerchantMap(merchantIdList, record); |
|
|
|
WxMerchantSubsidy sq = getWxMerchantSubsidyQuery(record,merchantIdList); |
|
|
|
List<Map<String,Object>> merchantSubsidyMap = wxMerchantSubsidyMapper.sumByMerchantId(sq); |
|
|
|
Map<Long,Map<String,Integer>> msmap = new HashMap<Long,Map<String,Integer>>(); |
|
|
|
Map<Long,Map<String,BigDecimal>> msmap = new HashMap<Long,Map<String,BigDecimal>>(); |
|
|
|
if (null != merchantSubsidyMap && merchantSubsidyMap.size() > 0 ) { |
|
|
|
for (int i = 0 ; i < merchantSubsidyMap.size(); i++) { |
|
|
|
Map<String,Object> result = merchantSubsidyMap.get(i) ; |
|
|
|
Map<String,Integer> submap = new HashMap<String,Integer>(); |
|
|
|
submap.put("sum_subsidy", (Integer)result.get("sum_subsidy")); |
|
|
|
submap.put("sum_real_subsidy", (Integer)result.get("sum_real_subsidy")); |
|
|
|
Map<String,BigDecimal> submap = new HashMap<String,BigDecimal>(); |
|
|
|
submap.put("sum_subsidy", (BigDecimal)result.get("sum_subsidy")); |
|
|
|
submap.put("sum_real_subsidy", (BigDecimal)result.get("sum_real_subsidy")); |
|
|
|
msmap.put((Long)result.get("merchant_id"), submap) ; |
|
|
|
} |
|
|
|
} |
|
|
|
@@ -661,7 +662,7 @@ public class WxCardSpendServiceImpl implements WxCardSpendService { |
|
|
|
if (null != merchant) { |
|
|
|
result.put("merchantName", merchant.getName()); |
|
|
|
} |
|
|
|
Map<String,Integer> busmap = msmap.get(merchantId); |
|
|
|
Map<String,BigDecimal> busmap = msmap.get(merchantId); |
|
|
|
if (null != busmap) { |
|
|
|
result.put("sum_subsidy", (null == busmap.get("sum_subsidy"))?0:busmap.get("sum_subsidy")); |
|
|
|
result.put("sum_real_subsidy", (null == busmap.get("sum_real_subsidy")?0:busmap.get("sum_real_subsidy"))); |
|
|
|
@@ -693,7 +694,7 @@ public class WxCardSpendServiceImpl implements WxCardSpendService { |
|
|
|
handleQueryParam(record); |
|
|
|
List<Long> merchantIdList = wxCardSpendMapper.getMerchantIdList(record); |
|
|
|
WxMerchantSubsidy sq = getWxMerchantSubsidyQuery(record,merchantIdList); |
|
|
|
Map<String,Integer> submap = wxMerchantSubsidyMapper.sum(sq); |
|
|
|
Map<String,BigDecimal> submap = wxMerchantSubsidyMapper.sum(sq); |
|
|
|
List<Map<String, Object>> resultList = wxCardSpendMapper.sumCardSpendVoForOwner(record); |
|
|
|
if (null != resultList && resultList.size() > 0 ) { |
|
|
|
for (int i = 0 ; i < resultList.size(); i++) { |
|
|
|
|