Commit df0288d9 authored by Quxl's avatar Quxl

xx

parent 55c6830a
...@@ -60,14 +60,24 @@ public class PromoController { ...@@ -60,14 +60,24 @@ public class PromoController {
@GetMapping("getGroupGoodsDetail") @GetMapping("getGroupGoodsDetail")
public Object getGroupGoodsDetail(String orgNo, String shopNo, String promoPaperNO, String promoGroupNO) { public Object getGroupGoodsDetail(String orgNo, String shopNo, String promoPaperNO, String promoGroupNO) {
Integer status = 0; Integer status = 0;
String statusDesc = "正常活动";
Date now = new Date(); Date now = new Date();
Map<String, Object> promoMap = service.getPromoDetail(promoPaperNO); Map<String, Object> promoMap = service.getPromoDetail(promoPaperNO);
Date dPromoBeginDate = (Date)promoMap.get("dPromoBeginDate"); Date dPromoBeginDate = (Date)promoMap.get("dPromoBeginDate");
Date dPromoEndDate = (Date)promoMap.get("dPromoEndDate"); Date dPromoEndDate = (Date)promoMap.get("dPromoEndDate");
Integer nTag = ((Number)promoMap.get("nTag")).intValue();
if(now.compareTo(dPromoBeginDate) < 0) { if(now.compareTo(dPromoBeginDate) < 0) {
status = 1; status = 1;
statusDesc = "活动未开始";
} else if(now.compareTo(dPromoEndDate) > 0) { } else if(now.compareTo(dPromoEndDate) > 0) {
status = 2; status = 2;
statusDesc = "活动已结束";
} else if((nTag&2) != 2) {
status = 3;
statusDesc = "活动未审核";
} else if((nTag&1) == 1) {
status = 4;
statusDesc = "活动已删除";
} }
List<Map<String, Object>> list = service.getGroupGoodsDetail(orgNo, shopNo, promoPaperNO, promoGroupNO); List<Map<String, Object>> list = service.getGroupGoodsDetail(orgNo, shopNo, promoPaperNO, promoGroupNO);
BigDecimal nTotalRealAmount = BigDecimal.ZERO; BigDecimal nTotalRealAmount = BigDecimal.ZERO;
...@@ -85,6 +95,7 @@ public class PromoController { ...@@ -85,6 +95,7 @@ public class PromoController {
promoMap.put("nTotalPayAmount", nTotalPayAmount); promoMap.put("nTotalPayAmount", nTotalPayAmount);
promoMap.put("nTotalQty", nTotalQty); promoMap.put("nTotalQty", nTotalQty);
promoMap.put("status", status); promoMap.put("status", status);
promoMap.put("statusDesc", statusDesc);
promoMap.put("sPromoGrouoNO", promoGroupNO); promoMap.put("sPromoGrouoNO", promoGroupNO);
List<Map<String, Object>> DLPicList = service.getGroupPicList("DL", promoPaperNO, promoGroupNO); List<Map<String, Object>> DLPicList = service.getGroupPicList("DL", promoPaperNO, promoGroupNO);
List<Map<String, Object>> BNPicList = service.getGroupPicList("BN", promoPaperNO, promoGroupNO); List<Map<String, Object>> BNPicList = service.getGroupPicList("BN", promoPaperNO, promoGroupNO);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment