hhq 4 年 前
コミット
1b6e4d14aa
78 ファイル変更3693 行追加336 行削除
  1. 19 0
      kmall-admin/src/main/java/com/kmall/admin/controller/GoodsController.java
  2. 112 0
      kmall-admin/src/main/java/com/kmall/admin/controller/GoodsTransportInfoController.java
  3. 168 0
      kmall-admin/src/main/java/com/kmall/admin/controller/GoodsTransportInfoDetailController.java
  4. 2 0
      kmall-admin/src/main/java/com/kmall/admin/controller/OrderController.java
  5. 5 5
      kmall-admin/src/main/java/com/kmall/admin/controller/alarm/Mall2OrderingEarlyWarningRemindsController.java
  6. 5 5
      kmall-admin/src/main/java/com/kmall/admin/controller/alarm/Mall2ShippingReminderAlarmController.java
  7. 5 5
      kmall-admin/src/main/java/com/kmall/admin/controller/mk/Mk2GoodsTopicHistoryPriceController.java
  8. 43 5
      kmall-admin/src/main/java/com/kmall/admin/controller/mk/Mk2GoodsTopicPriceController.java
  9. 5 5
      kmall-admin/src/main/java/com/kmall/admin/controller/mk/store/StoreTopicController.java
  10. 5 5
      kmall-admin/src/main/java/com/kmall/admin/controller/vip/Mall2MemberConsumptionRecordsController.java
  11. 5 5
      kmall-admin/src/main/java/com/kmall/admin/controller/vip/Mall2MemberPointsController.java
  12. 5 5
      kmall-admin/src/main/java/com/kmall/admin/controller/vip/Mall2PointsRulesController.java
  13. 3 0
      kmall-admin/src/main/java/com/kmall/admin/dao/GoodsDao.java
  14. 15 0
      kmall-admin/src/main/java/com/kmall/admin/dao/GoodsTransportInfoDao.java
  15. 23 0
      kmall-admin/src/main/java/com/kmall/admin/dao/GoodsTransportInfoDetailDao.java
  16. 7 0
      kmall-admin/src/main/java/com/kmall/admin/dao/ProductStoreRelaDao.java
  17. 8 0
      kmall-admin/src/main/java/com/kmall/admin/dao/alarm/Mall2OrderingEarlyWarningRemindsDao.java
  18. 13 0
      kmall-admin/src/main/java/com/kmall/admin/dao/alarm/Mall2ShippingReminderAlarmDao.java
  19. 2 0
      kmall-admin/src/main/java/com/kmall/admin/dao/mk/Mk2GoodsTopicPriceDao.java
  20. 2 0
      kmall-admin/src/main/java/com/kmall/admin/dao/mk/store/MkStorePromTypeDao.java
  21. 2 0
      kmall-admin/src/main/java/com/kmall/admin/dao/mk/store/StoreTopicDao.java
  22. 1 0
      kmall-admin/src/main/java/com/kmall/admin/dao/vip/Mall2MemberPointsDao.java
  23. 258 0
      kmall-admin/src/main/java/com/kmall/admin/dto/GoodsPanoramaDto.java
  24. 95 0
      kmall-admin/src/main/java/com/kmall/admin/dto/StoreTopicGoodsDto.java
  25. 205 0
      kmall-admin/src/main/java/com/kmall/admin/entity/GoodsTransportInfoDetailEntity.java
  26. 256 0
      kmall-admin/src/main/java/com/kmall/admin/entity/GoodsTransportInfoEntity.java
  27. 28 0
      kmall-admin/src/main/java/com/kmall/admin/entity/mk/Mk2GoodsTopicHistoryPriceEntity.java
  28. 9 13
      kmall-admin/src/main/java/com/kmall/admin/entity/mk/Mk2GoodsTopicPriceEntity.java
  29. 6 0
      kmall-admin/src/main/java/com/kmall/admin/service/GoodsService.java
  30. 78 0
      kmall-admin/src/main/java/com/kmall/admin/service/GoodsTransportInfoDetailService.java
  31. 74 0
      kmall-admin/src/main/java/com/kmall/admin/service/GoodsTransportInfoService.java
  32. 3 0
      kmall-admin/src/main/java/com/kmall/admin/service/alarm/Mall2OrderingEarlyWarningRemindsService.java
  33. 5 0
      kmall-admin/src/main/java/com/kmall/admin/service/alarm/Mall2ShippingReminderAlarmService.java
  34. 7 0
      kmall-admin/src/main/java/com/kmall/admin/service/impl/GoodsServiceImpl.java
  35. 71 0
      kmall-admin/src/main/java/com/kmall/admin/service/impl/GoodsTransportInfoDetailServiceImpl.java
  36. 60 0
      kmall-admin/src/main/java/com/kmall/admin/service/impl/GoodsTransportInfoServiceImpl.java
  37. 212 78
      kmall-admin/src/main/java/com/kmall/admin/service/impl/OrderServiceImpl.java
  38. 134 2
      kmall-admin/src/main/java/com/kmall/admin/service/impl/alarm/Mall2OrderingEarlyWarningRemindsServiceImpl.java
  39. 123 2
      kmall-admin/src/main/java/com/kmall/admin/service/impl/alarm/Mall2ShippingReminderAlarmServiceImpl.java
  40. 115 0
      kmall-admin/src/main/java/com/kmall/admin/service/impl/mk/Mk2GoodsTopicPriceServiceImpl.java
  41. 4 0
      kmall-admin/src/main/java/com/kmall/admin/service/mk/Mk2GoodsTopicPriceService.java
  42. 45 0
      kmall-admin/src/main/java/com/kmall/admin/task/OrderRemindsTask.java
  43. 44 0
      kmall-admin/src/main/java/com/kmall/admin/task/ShippingRemindsTask.java
  44. 25 0
      kmall-admin/src/main/resources/XmlTemplate/StoreTopicDtoList.xml
  45. 15 0
      kmall-admin/src/main/resources/mybatis/mapper/GoodsDao.xml
  46. 147 0
      kmall-admin/src/main/resources/mybatis/mapper/GoodsTransportInfoDao.xml
  47. 159 0
      kmall-admin/src/main/resources/mybatis/mapper/GoodsTransportInfoDetailDao.xml
  48. 25 9
      kmall-admin/src/main/resources/mybatis/mapper/ProductStoreRelaDao.xml
  49. 3 0
      kmall-admin/src/main/resources/mybatis/mapper/StoreDao.xml
  50. 79 1
      kmall-admin/src/main/resources/mybatis/mapper/alarm/Mall2OrderingEarlyWarningRemindsDao.xml
  51. 89 1
      kmall-admin/src/main/resources/mybatis/mapper/alarm/Mall2ShippingReminderAlarmDao.xml
  52. 58 2
      kmall-admin/src/main/resources/mybatis/mapper/mk/Mk2GoodsTopicHistoryPriceDao.xml
  53. 70 8
      kmall-admin/src/main/resources/mybatis/mapper/mk/Mk2GoodsTopicPriceDao.xml
  54. 1 1
      kmall-admin/src/main/resources/mybatis/mapper/mk/Mk2MemberBirthdayDao.xml
  55. 25 8
      kmall-admin/src/main/resources/mybatis/mapper/mk/store/MkStorePromTypeDao.xml
  56. 22 0
      kmall-admin/src/main/resources/mybatis/mapper/mk/store/StoreTopicDao.xml
  57. 1 1
      kmall-admin/src/main/resources/mybatis/mapper/vip/Mall2MemberConsumptionRecordsDao.xml
  58. 16 1
      kmall-admin/src/main/resources/mybatis/mapper/vip/Mall2MemberPointsDao.xml
  59. 1 1
      kmall-admin/src/main/resources/mybatis/mapper/vip/Mall2PointsRulesDao.xml
  60. 8 0
      kmall-admin/src/main/webapp/WEB-INF/page/mk/mk2goodstopicprice.html
  61. 3 22
      kmall-admin/src/main/webapp/WEB-INF/page/mk/storetopic.html
  62. 87 0
      kmall-admin/src/main/webapp/WEB-INF/page/shop/goodstransportinfo.html
  63. 82 0
      kmall-admin/src/main/webapp/WEB-INF/page/shop/goodstransportinfodetail.html
  64. 6 27
      kmall-admin/src/main/webapp/WEB-INF/page/vip/mall2memberconsumptionrecords.html
  65. 4 28
      kmall-admin/src/main/webapp/WEB-INF/page/vip/mall2memberpoints.html
  66. 9 7
      kmall-admin/src/main/webapp/js/alarm/mall2orderingearlywarningreminds.js
  67. 12 11
      kmall-admin/src/main/webapp/js/alarm/mall2shippingreminderalarm.js
  68. 6 11
      kmall-admin/src/main/webapp/js/mk/mk2goodstopichistoryprice.js
  69. 50 16
      kmall-admin/src/main/webapp/js/mk/mk2goodstopicprice.js
  70. 10 19
      kmall-admin/src/main/webapp/js/mk/storetopic.js
  71. 41 9
      kmall-admin/src/main/webapp/js/sale/sale.js
  72. 151 0
      kmall-admin/src/main/webapp/js/shop/goodstransportinfo.js
  73. 193 0
      kmall-admin/src/main/webapp/js/shop/goodstransportinfodetail.js
  74. 2 6
      kmall-admin/src/main/webapp/js/vip/mall2memberconsumptionrecords.js
  75. 2 6
      kmall-admin/src/main/webapp/js/vip/mall2memberpoints.js
  76. 2 6
      kmall-admin/src/main/webapp/js/vip/mall2pointsrules.js
  77. BIN
      kmall-admin/src/main/webapp/statics/file/store_topic_goods_export_yyyy_mm_dd_v1.0.0.xlsx
  78. 2 0
      kmall-common/src/main/java/com/kmall/common/constant/JxlsXmlTemplateName.java

+ 19 - 0
kmall-admin/src/main/java/com/kmall/admin/controller/GoodsController.java

@@ -2,6 +2,7 @@ package com.kmall.admin.controller;
 
 import com.kmall.admin.dto.GoodsDetailsDto;
 import com.kmall.admin.dto.GoodsDto;
+import com.kmall.admin.dto.GoodsPanoramaDto;
 import com.kmall.admin.entity.GoodsEntity;
 import com.kmall.admin.entity.GoodsGalleryEntity;
 import com.kmall.admin.service.GoodsGalleryService;
@@ -299,5 +300,23 @@ public class GoodsController {
     }
 
 
+    /**
+     * 根据商品编码或者条码查询商品信息(17.商品全景图)
+     * @param keyword
+     * @return
+     */
+    @GetMapping("/search/{keyword}")
+    public R searchByKeyword(@PathVariable("keyword") String keyword){
+        if (keyword == null || "".equals(keyword)){
+            return R.error("请输入商品编码或者条码!");
+        }
+        GoodsPanoramaDto goodsPanoramaDto = goodsService.searchGoodsPanoramaDtoByKeyword(keyword);
+        //GoodsEntity goods = goodsService.searchGoodsByKeyword(keyword);
+        if (goodsPanoramaDto == null || "".equals(goodsPanoramaDto)) {
+            return R.error("没有该商品!");
+        }
+        return R.ok().put("goodsPanoramaDto",goodsPanoramaDto);
+    }
+
 
 }

+ 112 - 0
kmall-admin/src/main/java/com/kmall/admin/controller/GoodsTransportInfoController.java

@@ -0,0 +1,112 @@
+package com.kmall.admin.controller;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
+
+import com.kmall.common.utils.PageUtils;
+import com.kmall.common.utils.Query;
+import com.kmall.common.utils.R;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Controller;
+import org.springframework.web.bind.annotation.*;
+
+import com.kmall.admin.entity.GoodsTransportInfoEntity;
+import com.kmall.admin.service.GoodsTransportInfoService;
+
+
+/**
+ * 在途运输信息表Controller
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:07:33
+ */
+@Controller
+@RequestMapping("goodstransportinfo")
+public class GoodsTransportInfoController {
+    @Autowired
+    private GoodsTransportInfoService goodsTransportInfoService;
+
+    /**
+     * 查看列表
+     */
+    @RequestMapping("/list")
+//    @RequiresPermissions("goodstransportinfo:list")
+    @ResponseBody
+    public R list(@RequestParam Map<String, Object> params) {
+        //查询列表数据
+        Query query = new Query(params);
+
+        List<GoodsTransportInfoEntity> goodsTransportInfoList = goodsTransportInfoService.queryList(query);
+        int total = goodsTransportInfoService.queryTotal(query);
+
+        PageUtils pageUtil = new PageUtils(goodsTransportInfoList, total, query.getLimit(), query.getPage());
+
+        return R.ok().put("page", pageUtil);
+    }
+
+    /**
+     * 查看信息
+     */
+    @RequestMapping("/info/{transId}")
+//    @RequiresPermissions("goodstransportinfo:info")
+    @ResponseBody
+    public R info(@PathVariable("transId") Integer transId) {
+        GoodsTransportInfoEntity goodsTransportInfo = goodsTransportInfoService.queryObject(transId);
+
+        return R.ok().put("goodsTransportInfo", goodsTransportInfo);
+    }
+
+    /**
+     * 保存
+     */
+    @RequestMapping("/save")
+//    @RequiresPermissions("goodstransportinfo:save")
+    @ResponseBody
+    public R save(@RequestBody GoodsTransportInfoEntity goodsTransportInfo) {
+        goodsTransportInfoService.save(goodsTransportInfo);
+
+        return R.ok();
+    }
+
+    /**
+     * 修改
+     */
+    @RequestMapping("/update")
+//    @RequiresPermissions("goodstransportinfo:update")
+    @ResponseBody
+    public R update(@RequestBody GoodsTransportInfoEntity goodsTransportInfo) {
+        goodsTransportInfoService.update(goodsTransportInfo);
+
+        return R.ok();
+    }
+
+    /**
+     * 删除
+     */
+    @RequestMapping("/delete")
+//    @RequiresPermissions("goodstransportinfo:delete")
+    @ResponseBody
+    public R delete(@RequestBody Integer[]transIds) {
+        goodsTransportInfoService.deleteBatch(transIds);
+
+        return R.ok();
+    }
+
+    /**
+     * 查看所有列表
+     */
+    @RequestMapping("/queryAll")
+    @ResponseBody
+    public R queryAll(@RequestParam Map<String, Object> params) {
+
+        List<GoodsTransportInfoEntity> list = goodsTransportInfoService.queryList(params);
+
+        return R.ok().put("list", list);
+    }
+
+
+
+}

+ 168 - 0
kmall-admin/src/main/java/com/kmall/admin/controller/GoodsTransportInfoDetailController.java

@@ -0,0 +1,168 @@
+package com.kmall.admin.controller;
+
+import java.util.*;
+
+import com.kmall.admin.entity.GoodsTransportInfoEntity;
+import com.kmall.common.constant.JxlsXmlTemplateName;
+import com.kmall.common.utils.PageUtils;
+import com.kmall.common.utils.Query;
+import com.kmall.common.utils.R;
+import com.kmall.common.utils.excel.ExcelUtil;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Controller;
+import org.springframework.web.bind.annotation.*;
+
+import com.kmall.admin.entity.GoodsTransportInfoDetailEntity;
+import com.kmall.admin.service.GoodsTransportInfoDetailService;
+import org.springframework.web.multipart.MultipartFile;
+
+/**
+ * 在途商品明细表Controller
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:19:23
+ */
+@Controller
+@RequestMapping("goodstransportinfodetail")
+public class GoodsTransportInfoDetailController {
+    @Autowired
+    private GoodsTransportInfoDetailService goodsTransportInfoDetailService;
+    @Autowired
+    private ExcelUtil excelUtil;
+
+    /**
+     * 查看列表
+     */
+    @RequestMapping("/list")
+//    @RequiresPermissions("goodstransportinfodetail:list")
+    @ResponseBody
+    public R list(@RequestParam Map<String, Object> params) {
+        //查询列表数据
+        Query query = new Query(params);
+
+        List<GoodsTransportInfoDetailEntity> goodsTransportInfoDetailList = goodsTransportInfoDetailService.queryList(query);
+        int total = goodsTransportInfoDetailService.queryTotal(query);
+
+        PageUtils pageUtil = new PageUtils(goodsTransportInfoDetailList, total, query.getLimit(), query.getPage());
+
+        return R.ok().put("page", pageUtil);
+    }
+
+    /**
+     * 查看信息
+     */
+    @RequestMapping("/info/{transItemId}")
+//    @RequiresPermissions("goodstransportinfodetail:info")
+    @ResponseBody
+    public R info(@PathVariable("transItemId") Integer transItemId) {
+        GoodsTransportInfoDetailEntity goodsTransportInfoDetail = goodsTransportInfoDetailService.queryObject(transItemId);
+
+        return R.ok().put("goodsTransportInfoDetail", goodsTransportInfoDetail);
+    }
+
+    /**
+     * 保存
+     */
+    @RequestMapping("/save")
+//    @RequiresPermissions("goodstransportinfodetail:save")
+    @ResponseBody
+    public R save(@RequestBody GoodsTransportInfoDetailEntity goodsTransportInfoDetail) {
+        if (goodsTransportInfoDetail.getWayStatus()==null || goodsTransportInfoDetail.getSku() == null){
+            return R.error("是否在途和sku必须要填");
+        }
+        goodsTransportInfoDetail.setCreateTime(new Date());
+        goodsTransportInfoDetail.setModTime(new Date());
+        goodsTransportInfoDetail.setTstm(new Date());
+        goodsTransportInfoDetailService.save(goodsTransportInfoDetail);
+
+        return R.ok();
+    }
+
+    /**
+     * 修改
+     */
+    @RequestMapping("/update")
+//    @RequiresPermissions("goodstransportinfodetail:update")
+    @ResponseBody
+    public R update(@RequestBody GoodsTransportInfoDetailEntity goodsTransportInfoDetail) {
+        if (goodsTransportInfoDetail.getWayStatus()==null || goodsTransportInfoDetail.getSku() == null){
+            return R.error("是否在途和sku必须要填");
+        }
+        goodsTransportInfoDetail.setModTime(new Date());
+        goodsTransportInfoDetail.setTstm(new Date());
+        goodsTransportInfoDetailService.update(goodsTransportInfoDetail);
+
+        return R.ok();
+    }
+
+    /**
+     * 删除
+     */
+    @RequestMapping("/delete")
+//    @RequiresPermissions("goodstransportinfodetail:delete")
+    @ResponseBody
+    public R delete(@RequestBody Integer[]transItemIds) {
+        goodsTransportInfoDetailService.deleteBatch(transItemIds);
+
+        return R.ok();
+    }
+
+    /**
+     * 查看所有列表
+     */
+    @RequestMapping("/queryAll")
+    @ResponseBody
+    public R queryAll(@RequestParam Map<String, Object> params) {
+
+        List<GoodsTransportInfoDetailEntity> list = goodsTransportInfoDetailService.queryList(params);
+
+        return R.ok().put("list", list);
+    }
+
+
+    /**
+     * 根据是否在途和sku查询
+     * @param params
+     * @return
+     */
+    @GetMapping("/searchListByStatusAndSku")
+    @ResponseBody
+    public R searchListByStatusAndSku(@RequestParam Map<String, Object> params){
+        //查询列表数据
+        Query query = new Query(params);
+        Integer wayStatus = null;
+        if(params.get("wayStatus")!=null && !"".equals(params.get("wayStatus"))){
+            wayStatus = Integer.parseInt(params.get("wayStatus").toString());
+        }
+        String sku = (String) params.get("sku");
+        List<GoodsTransportInfoDetailEntity> goodsTransportInfoDetailList = goodsTransportInfoDetailService.searchListByStatusAndSku(query,wayStatus,sku);
+        int total = goodsTransportInfoDetailService.queryTotalByStatusAndSku(query,wayStatus,sku);
+
+        PageUtils pageUtil = new PageUtils(goodsTransportInfoDetailList, total, query.getLimit(), query.getPage());
+
+        return R.ok().put("page", pageUtil);
+    }
+
+    /**
+     * 上传文件
+     */
+    @PostMapping("/transInfoDetailUpload")
+    @ResponseBody
+    public R transInfoDetailUpload(@RequestParam("file") MultipartFile file) {
+        List<GoodsTransportInfoDetailEntity> list = new ArrayList<>();
+        //上传文件
+        try {
+
+            if (file.isEmpty()) {
+                return R.error("文件不能为空!");
+            }
+
+        } catch (Exception e) {
+            e.printStackTrace();
+            return R.error("导入失败!");
+        }
+        return R.ok("导入成功!");
+    }
+}

+ 2 - 0
kmall-admin/src/main/java/com/kmall/admin/controller/OrderController.java

@@ -662,6 +662,8 @@ public class OrderController {
         List<OrderEntity> orderList = orderService.queryOffilineOrderList(query);
         int total = orderService.queryTotal(query);
 
+        // 遍历循环订单是哪个店员销售的,根据订单号查询
+
         PageUtils pageUtil = new PageUtils(orderList, total, query.getLimit(), query.getPage());
 
         return R.ok().put("page", pageUtil);

+ 5 - 5
kmall-admin/src/main/java/com/kmall/admin/controller/alarm/Mall2OrderingEarlyWarningRemindsController.java

@@ -31,7 +31,7 @@ public class Mall2OrderingEarlyWarningRemindsController {
      * 查看列表
      */
     @RequestMapping("/list")
-    @RequiresPermissions("mall2orderingearlywarningreminds:list")
+//    @RequiresPermissions("mall2orderingearlywarningreminds:list")
     @ResponseBody
     public R list(@RequestParam Map<String, Object> params) {
         //查询列表数据
@@ -49,7 +49,7 @@ public class Mall2OrderingEarlyWarningRemindsController {
      * 查看信息
      */
     @RequestMapping("/info/{moewrId}")
-    @RequiresPermissions("mall2orderingearlywarningreminds:info")
+//    @RequiresPermissions("mall2orderingearlywarningreminds:info")
     @ResponseBody
     public R info(@PathVariable("moewrId") Integer moewrId) {
         Mall2OrderingEarlyWarningRemindsEntity mall2OrderingEarlyWarningReminds = mall2OrderingEarlyWarningRemindsService.queryObject(moewrId);
@@ -61,7 +61,7 @@ public class Mall2OrderingEarlyWarningRemindsController {
      * 保存
      */
     @RequestMapping("/save")
-    @RequiresPermissions("mall2orderingearlywarningreminds:save")
+//    @RequiresPermissions("mall2orderingearlywarningreminds:save")
     @ResponseBody
     public R save(@RequestBody Mall2OrderingEarlyWarningRemindsEntity mall2OrderingEarlyWarningReminds) {
         mall2OrderingEarlyWarningRemindsService.save(mall2OrderingEarlyWarningReminds);
@@ -73,7 +73,7 @@ public class Mall2OrderingEarlyWarningRemindsController {
      * 修改
      */
     @RequestMapping("/update")
-    @RequiresPermissions("mall2orderingearlywarningreminds:update")
+//    @RequiresPermissions("mall2orderingearlywarningreminds:update")
     @ResponseBody
     public R update(@RequestBody Mall2OrderingEarlyWarningRemindsEntity mall2OrderingEarlyWarningReminds) {
         mall2OrderingEarlyWarningRemindsService.update(mall2OrderingEarlyWarningReminds);
@@ -85,7 +85,7 @@ public class Mall2OrderingEarlyWarningRemindsController {
      * 删除
      */
     @RequestMapping("/delete")
-    @RequiresPermissions("mall2orderingearlywarningreminds:delete")
+//    @RequiresPermissions("mall2orderingearlywarningreminds:delete")
     @ResponseBody
     public R delete(@RequestBody Integer[]moewrIds) {
         mall2OrderingEarlyWarningRemindsService.deleteBatch(moewrIds);

+ 5 - 5
kmall-admin/src/main/java/com/kmall/admin/controller/alarm/Mall2ShippingReminderAlarmController.java

@@ -31,7 +31,7 @@ public class Mall2ShippingReminderAlarmController {
      * 查看列表
      */
     @RequestMapping("/list")
-    @RequiresPermissions("mall2shippingreminderalarm:list")
+//    @RequiresPermissions("mall2shippingreminderalarm:list")
     @ResponseBody
     public R list(@RequestParam Map<String, Object> params) {
         //查询列表数据
@@ -49,7 +49,7 @@ public class Mall2ShippingReminderAlarmController {
      * 查看信息
      */
     @RequestMapping("/info/{msraId}")
-    @RequiresPermissions("mall2shippingreminderalarm:info")
+//    @RequiresPermissions("mall2shippingreminderalarm:info")
     @ResponseBody
     public R info(@PathVariable("msraId") Integer msraId) {
         Mall2ShippingReminderAlarmEntity mall2ShippingReminderAlarm = mall2ShippingReminderAlarmService.queryObject(msraId);
@@ -61,7 +61,7 @@ public class Mall2ShippingReminderAlarmController {
      * 保存
      */
     @RequestMapping("/save")
-    @RequiresPermissions("mall2shippingreminderalarm:save")
+//    @RequiresPermissions("mall2shippingreminderalarm:save")
     @ResponseBody
     public R save(@RequestBody Mall2ShippingReminderAlarmEntity mall2ShippingReminderAlarm) {
         mall2ShippingReminderAlarmService.save(mall2ShippingReminderAlarm);
@@ -73,7 +73,7 @@ public class Mall2ShippingReminderAlarmController {
      * 修改
      */
     @RequestMapping("/update")
-    @RequiresPermissions("mall2shippingreminderalarm:update")
+//    @RequiresPermissions("mall2shippingreminderalarm:update")
     @ResponseBody
     public R update(@RequestBody Mall2ShippingReminderAlarmEntity mall2ShippingReminderAlarm) {
         mall2ShippingReminderAlarmService.update(mall2ShippingReminderAlarm);
@@ -85,7 +85,7 @@ public class Mall2ShippingReminderAlarmController {
      * 删除
      */
     @RequestMapping("/delete")
-    @RequiresPermissions("mall2shippingreminderalarm:delete")
+//    @RequiresPermissions("mall2shippingreminderalarm:delete")
     @ResponseBody
     public R delete(@RequestBody Integer[]msraIds) {
         mall2ShippingReminderAlarmService.deleteBatch(msraIds);

+ 5 - 5
kmall-admin/src/main/java/com/kmall/admin/controller/mk/Mk2GoodsTopicHistoryPriceController.java

@@ -31,7 +31,7 @@ public class Mk2GoodsTopicHistoryPriceController {
      * 查看列表
      */
     @RequestMapping("/list")
-    @RequiresPermissions("mk2goodstopichistoryprice:list")
+//    @RequiresPermissions("mk2goodstopichistoryprice:list")
     @ResponseBody
     public R list(@RequestParam Map<String, Object> params) {
         //查询列表数据
@@ -49,7 +49,7 @@ public class Mk2GoodsTopicHistoryPriceController {
      * 查看信息
      */
     @RequestMapping("/info/{mgthpId}")
-    @RequiresPermissions("mk2goodstopichistoryprice:info")
+//    @RequiresPermissions("mk2goodstopichistoryprice:info")
     @ResponseBody
     public R info(@PathVariable("mgthpId") Integer mgthpId) {
         Mk2GoodsTopicHistoryPriceEntity mk2GoodsTopicHistoryPrice = mk2GoodsTopicHistoryPriceService.queryObject(mgthpId);
@@ -61,7 +61,7 @@ public class Mk2GoodsTopicHistoryPriceController {
      * 保存
      */
     @RequestMapping("/save")
-    @RequiresPermissions("mk2goodstopichistoryprice:save")
+//    @RequiresPermissions("mk2goodstopichistoryprice:save")
     @ResponseBody
     public R save(@RequestBody Mk2GoodsTopicHistoryPriceEntity mk2GoodsTopicHistoryPrice) {
         mk2GoodsTopicHistoryPriceService.save(mk2GoodsTopicHistoryPrice);
@@ -73,7 +73,7 @@ public class Mk2GoodsTopicHistoryPriceController {
      * 修改
      */
     @RequestMapping("/update")
-    @RequiresPermissions("mk2goodstopichistoryprice:update")
+//    @RequiresPermissions("mk2goodstopichistoryprice:update")
     @ResponseBody
     public R update(@RequestBody Mk2GoodsTopicHistoryPriceEntity mk2GoodsTopicHistoryPrice) {
         mk2GoodsTopicHistoryPriceService.update(mk2GoodsTopicHistoryPrice);
@@ -85,7 +85,7 @@ public class Mk2GoodsTopicHistoryPriceController {
      * 删除
      */
     @RequestMapping("/delete")
-    @RequiresPermissions("mk2goodstopichistoryprice:delete")
+//    @RequiresPermissions("mk2goodstopichistoryprice:delete")
     @ResponseBody
     public R delete(@RequestBody Integer[]mgthpIds) {
         mk2GoodsTopicHistoryPriceService.deleteBatch(mgthpIds);

+ 43 - 5
kmall-admin/src/main/java/com/kmall/admin/controller/mk/Mk2GoodsTopicPriceController.java

@@ -1,12 +1,19 @@
 package com.kmall.admin.controller.mk;
 
+import java.text.ParseException;
+import java.util.ArrayList;
+import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
+import com.kmall.admin.dto.StoreGoodsDto;
+import com.kmall.admin.dto.StoreTopicGoodsDto;
 import com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity;
+import com.kmall.common.constant.JxlsXmlTemplateName;
 import com.kmall.common.utils.PageUtils;
 import com.kmall.common.utils.Query;
 import com.kmall.common.utils.R;
+import com.kmall.common.utils.excel.ExcelUtil;
 import org.apache.shiro.authz.annotation.RequiresPermissions;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Controller;
@@ -14,6 +21,7 @@ import org.springframework.web.bind.annotation.*;
 
 import com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity;
 import com.kmall.admin.service.mk.Mk2GoodsTopicPriceService;
+import org.springframework.web.multipart.MultipartFile;
 
 /**
  * 商品活动价格表Controller
@@ -27,12 +35,14 @@ import com.kmall.admin.service.mk.Mk2GoodsTopicPriceService;
 public class Mk2GoodsTopicPriceController {
     @Autowired
     private Mk2GoodsTopicPriceService mk2GoodsTopicPriceService;
+    @Autowired
+    private ExcelUtil excelUtil;
 
     /**
      * 查看列表
      */
     @RequestMapping("/list")
-    @RequiresPermissions("mk2goodstopicprice:list")
+//    @RequiresPermissions("mk2goodstopicprice:list")
     @ResponseBody
     public R list(@RequestParam Map<String, Object> params) {
         //查询列表数据
@@ -50,7 +60,7 @@ public class Mk2GoodsTopicPriceController {
      * 查看信息
      */
     @RequestMapping("/info/{mgthpId}")
-    @RequiresPermissions("mk2goodstopicprice:info")
+//    @RequiresPermissions("mk2goodstopicprice:info")
     @ResponseBody
     public R info(@PathVariable("mgthpId") Integer mgthpId) {
         Mk2GoodsTopicPriceEntity mk2GoodsTopicPrice = mk2GoodsTopicPriceService.queryObject(mgthpId);
@@ -62,7 +72,7 @@ public class Mk2GoodsTopicPriceController {
      * 保存
      */
     @RequestMapping("/save")
-    @RequiresPermissions("mk2goodstopicprice:save")
+//    @RequiresPermissions("mk2goodstopicprice:save")
     @ResponseBody
     public R save(@RequestBody Mk2GoodsTopicPriceEntity mk2GoodsTopicPrice) {
         mk2GoodsTopicPriceService.save(mk2GoodsTopicPrice);
@@ -74,7 +84,7 @@ public class Mk2GoodsTopicPriceController {
      * 修改
      */
     @RequestMapping("/update")
-    @RequiresPermissions("mk2goodstopicprice:update")
+//    @RequiresPermissions("mk2goodstopicprice:update")
     @ResponseBody
     public R update(@RequestBody Mk2GoodsTopicPriceEntity mk2GoodsTopicPrice) {
         mk2GoodsTopicPriceService.update(mk2GoodsTopicPrice);
@@ -86,7 +96,7 @@ public class Mk2GoodsTopicPriceController {
      * 删除
      */
     @RequestMapping("/delete")
-    @RequiresPermissions("mk2goodstopicprice:delete")
+//    @RequiresPermissions("mk2goodstopicprice:delete")
     @ResponseBody
     public R delete(@RequestBody Integer[]mgthpIds) {
         mk2GoodsTopicPriceService.deleteBatch(mgthpIds);
@@ -105,4 +115,32 @@ public class Mk2GoodsTopicPriceController {
 
         return R.ok().put("list", list);
     }
+
+
+    @PostMapping("/goodsTopicPriceUpload")
+    @ResponseBody
+    public R storeUpload(@RequestParam("file") MultipartFile file) {
+        List<StoreTopicGoodsDto> storeTopicGoodsDtoList = new ArrayList<>();//信息
+        try {
+            StoreTopicGoodsDto storeTopicGoodsDto = new StoreTopicGoodsDto();
+            Map<String, Object> beans = new HashMap<String, Object>();
+            beans.put("storeTopicGoodsDto", storeTopicGoodsDto);
+            beans.put("storeTopicGoodsDtoList", storeTopicGoodsDtoList);
+            if (file.isEmpty()) {
+                return R.error("文件不能为空!");
+            }
+            excelUtil.readExcel(JxlsXmlTemplateName.STORE_TOPIC_DTO_LIST, beans, file.getInputStream());
+        } catch (Exception e) {
+            e.printStackTrace();
+            return R.error("导入失败!");
+        }
+        try {
+            mk2GoodsTopicPriceService.uploadExcel(storeTopicGoodsDtoList);
+        } catch (ParseException e) {
+            e.printStackTrace();
+            return R.error("导入失败!");
+        }
+        //上传文件
+        return R.ok("导入成功!");
+    }
 }

+ 5 - 5
kmall-admin/src/main/java/com/kmall/admin/controller/mk/store/StoreTopicController.java

@@ -31,7 +31,7 @@ public class StoreTopicController {
      * 查看列表
      */
     @RequestMapping("/list")
-    @RequiresPermissions("storetopic:list")
+//    @RequiresPermissions("storetopic:list")
     @ResponseBody
     public R list(@RequestParam Map<String, Object> params) {
         ParamUtils.setQueryPowerByRoleType(params, "storeId", "merchSn", "thirdPartyMerchCode");
@@ -51,7 +51,7 @@ public class StoreTopicController {
      * 查看信息
      */
     @RequestMapping("/info/{id}")
-    @RequiresPermissions("storetopic:info")
+//    @RequiresPermissions("storetopic:info")
     @ResponseBody
     public R info(@PathVariable("id") Integer id) {
         StoreTopicEntity storeTopic = storeTopicService.queryObject(id);
@@ -63,7 +63,7 @@ public class StoreTopicController {
      * 保存
      */
     @RequestMapping("/save")
-    @RequiresPermissions("storetopic:save")
+//    @RequiresPermissions("storetopic:save")
     @ResponseBody
     public R save(@RequestBody StoreTopicEntity storeTopic) {
         storeTopicService.save(storeTopic);
@@ -75,7 +75,7 @@ public class StoreTopicController {
      * 修改
      */
     @RequestMapping("/update")
-    @RequiresPermissions("storetopic:update")
+//    @RequiresPermissions("storetopic:update")
     @ResponseBody
     public R update(@RequestBody StoreTopicEntity storeTopic) {
         storeTopicService.update(storeTopic);
@@ -87,7 +87,7 @@ public class StoreTopicController {
      * 删除
      */
     @RequestMapping("/delete")
-    @RequiresPermissions("storetopic:delete")
+//    @RequiresPermissions("storetopic:delete")
     @ResponseBody
     public R delete(@RequestBody Integer[]ids) {
         storeTopicService.deleteBatch(ids);

+ 5 - 5
kmall-admin/src/main/java/com/kmall/admin/controller/vip/Mall2MemberConsumptionRecordsController.java

@@ -31,7 +31,7 @@ public class Mall2MemberConsumptionRecordsController {
      * 查看列表
      */
     @RequestMapping("/list")
-    @RequiresPermissions("mall2memberconsumptionrecords:list")
+//    @RequiresPermissions("mall2memberconsumptionrecords:list")
     @ResponseBody
     public R list(@RequestParam Map<String, Object> params) {
         //查询列表数据
@@ -49,7 +49,7 @@ public class Mall2MemberConsumptionRecordsController {
      * 查看信息
      */
     @RequestMapping("/info/{mmcrId}")
-    @RequiresPermissions("mall2memberconsumptionrecords:info")
+//    @RequiresPermissions("mall2memberconsumptionrecords:info")
     @ResponseBody
     public R info(@PathVariable("mmcrId") Integer mmcrId) {
         Mall2MemberConsumptionRecordsEntity mall2MemberConsumptionRecords = mall2MemberConsumptionRecordsService.queryObject(mmcrId);
@@ -61,7 +61,7 @@ public class Mall2MemberConsumptionRecordsController {
      * 保存
      */
     @RequestMapping("/save")
-    @RequiresPermissions("mall2memberconsumptionrecords:save")
+//    @RequiresPermissions("mall2memberconsumptionrecords:save")
     @ResponseBody
     public R save(@RequestBody Mall2MemberConsumptionRecordsEntity mall2MemberConsumptionRecords) {
         mall2MemberConsumptionRecordsService.save(mall2MemberConsumptionRecords);
@@ -73,7 +73,7 @@ public class Mall2MemberConsumptionRecordsController {
      * 修改
      */
     @RequestMapping("/update")
-    @RequiresPermissions("mall2memberconsumptionrecords:update")
+//    @RequiresPermissions("mall2memberconsumptionrecords:update")
     @ResponseBody
     public R update(@RequestBody Mall2MemberConsumptionRecordsEntity mall2MemberConsumptionRecords) {
         mall2MemberConsumptionRecordsService.update(mall2MemberConsumptionRecords);
@@ -85,7 +85,7 @@ public class Mall2MemberConsumptionRecordsController {
      * 删除
      */
     @RequestMapping("/delete")
-    @RequiresPermissions("mall2memberconsumptionrecords:delete")
+//    @RequiresPermissions("mall2memberconsumptionrecords:delete")
     @ResponseBody
     public R delete(@RequestBody Integer[]mmcrIds) {
         mall2MemberConsumptionRecordsService.deleteBatch(mmcrIds);

+ 5 - 5
kmall-admin/src/main/java/com/kmall/admin/controller/vip/Mall2MemberPointsController.java

@@ -31,7 +31,7 @@ public class Mall2MemberPointsController {
      * 查看列表
      */
     @RequestMapping("/list")
-    @RequiresPermissions("mall2memberpoints:list")
+//    @RequiresPermissions("mall2memberpoints:list")
     @ResponseBody
     public R list(@RequestParam Map<String, Object> params) {
         //查询列表数据
@@ -49,7 +49,7 @@ public class Mall2MemberPointsController {
      * 查看信息
      */
     @RequestMapping("/info/{mmpId}")
-    @RequiresPermissions("mall2memberpoints:info")
+//    @RequiresPermissions("mall2memberpoints:info")
     @ResponseBody
     public R info(@PathVariable("mmpId") Integer mmpId) {
         Mall2MemberPointsEntity mall2MemberPoints = mall2MemberPointsService.queryObject(mmpId);
@@ -61,7 +61,7 @@ public class Mall2MemberPointsController {
      * 保存
      */
     @RequestMapping("/save")
-    @RequiresPermissions("mall2memberpoints:save")
+//    @RequiresPermissions("mall2memberpoints:save")
     @ResponseBody
     public R save(@RequestBody Mall2MemberPointsEntity mall2MemberPoints) {
         mall2MemberPointsService.save(mall2MemberPoints);
@@ -73,7 +73,7 @@ public class Mall2MemberPointsController {
      * 修改
      */
     @RequestMapping("/update")
-    @RequiresPermissions("mall2memberpoints:update")
+//    @RequiresPermissions("mall2memberpoints:update")
     @ResponseBody
     public R update(@RequestBody Mall2MemberPointsEntity mall2MemberPoints) {
         mall2MemberPointsService.update(mall2MemberPoints);
@@ -85,7 +85,7 @@ public class Mall2MemberPointsController {
      * 删除
      */
     @RequestMapping("/delete")
-    @RequiresPermissions("mall2memberpoints:delete")
+//    @RequiresPermissions("mall2memberpoints:delete")
     @ResponseBody
     public R delete(@RequestBody Integer[]mmpIds) {
         mall2MemberPointsService.deleteBatch(mmpIds);

+ 5 - 5
kmall-admin/src/main/java/com/kmall/admin/controller/vip/Mall2PointsRulesController.java

@@ -31,7 +31,7 @@ public class Mall2PointsRulesController {
      * 查看列表
      */
     @RequestMapping("/list")
-    @RequiresPermissions("mall2pointsrules:list")
+//    @RequiresPermissions("mall2pointsrules:list")
     @ResponseBody
     public R list(@RequestParam Map<String, Object> params) {
         //查询列表数据
@@ -49,7 +49,7 @@ public class Mall2PointsRulesController {
      * 查看信息
      */
     @RequestMapping("/info/{mprId}")
-    @RequiresPermissions("mall2pointsrules:info")
+//    @RequiresPermissions("mall2pointsrules:info")
     @ResponseBody
     public R info(@PathVariable("mprId") Integer mprId) {
         Mall2PointsRulesEntity mall2PointsRules = mall2PointsRulesService.queryObject(mprId);
@@ -61,7 +61,7 @@ public class Mall2PointsRulesController {
      * 保存
      */
     @RequestMapping("/save")
-    @RequiresPermissions("mall2pointsrules:save")
+//    @RequiresPermissions("mall2pointsrules:save")
     @ResponseBody
     public R save(@RequestBody Mall2PointsRulesEntity mall2PointsRules) {
         mall2PointsRulesService.save(mall2PointsRules);
@@ -73,7 +73,7 @@ public class Mall2PointsRulesController {
      * 修改
      */
     @RequestMapping("/update")
-    @RequiresPermissions("mall2pointsrules:update")
+//    @RequiresPermissions("mall2pointsrules:update")
     @ResponseBody
     public R update(@RequestBody Mall2PointsRulesEntity mall2PointsRules) {
         mall2PointsRulesService.update(mall2PointsRules);
@@ -85,7 +85,7 @@ public class Mall2PointsRulesController {
      * 删除
      */
     @RequestMapping("/delete")
-    @RequiresPermissions("mall2pointsrules:delete")
+//    @RequiresPermissions("mall2pointsrules:delete")
     @ResponseBody
     public R delete(@RequestBody Integer[]mprIds) {
         mall2PointsRulesService.deleteBatch(mprIds);

+ 3 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/GoodsDao.java

@@ -1,6 +1,7 @@
 package com.kmall.admin.dao;
 
 import com.kmall.admin.dto.GoodsDetailsDto;
+import com.kmall.admin.dto.GoodsPanoramaDto;
 import com.kmall.admin.entity.GoodsEntity;
 import com.kmall.manager.dao.BaseDao;
 import org.apache.ibatis.annotations.Param;
@@ -33,4 +34,6 @@ public interface GoodsDao extends BaseDao<GoodsEntity> {
     GoodsEntity queryObjectByStoreId(@Param("id") Long id, @Param("storeId") Long storeId);
 
     GoodsEntity queryGoodsByGoodsSnAndStoreId(@Param("goodsSn") String goodsSn, @Param("storeId") Long storeId);
+
+    GoodsPanoramaDto searchGoodsPanoramaDtoByKeyword(@Param("keyword") String keyword);
 }

+ 15 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/GoodsTransportInfoDao.java

@@ -0,0 +1,15 @@
+package com.kmall.admin.dao;
+
+import com.kmall.admin.entity.GoodsTransportInfoEntity;
+import com.kmall.manager.dao.BaseDao;
+
+/**
+ * 在途运输信息表Dao
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:07:33
+ */
+public interface GoodsTransportInfoDao extends BaseDao<GoodsTransportInfoEntity> {
+
+}

+ 23 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/GoodsTransportInfoDetailDao.java

@@ -0,0 +1,23 @@
+package com.kmall.admin.dao;
+
+import com.kmall.admin.entity.GoodsTransportInfoDetailEntity;
+import com.kmall.common.utils.Query;
+import com.kmall.manager.dao.BaseDao;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+/**
+ * 在途商品明细表Dao
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:19:23
+ */
+public interface GoodsTransportInfoDetailDao extends BaseDao<GoodsTransportInfoDetailEntity> {
+
+
+    List<GoodsTransportInfoDetailEntity> searchListByStatusAndSku(@Param("query") Query query, @Param("wayStatus") Integer wayStatus, @Param("sku")String sku);
+
+    int queryTotalByStatusAndSku(@Param("query") Query query, @Param("wayStatus") Integer wayStatus, @Param("sku")String sku);
+}

+ 7 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/ProductStoreRelaDao.java

@@ -69,4 +69,11 @@ public interface ProductStoreRelaDao extends BaseDao<ProductStoreRelaEntity> {
      * @param productStoreRelaEntity
      */
     void updateStockNumByGoodsId(ProductStoreRelaEntity productStoreRelaEntity);
+
+    /**
+     * 根据门店id查询商品
+     * @param id
+     * @return
+     */
+    List<ProductStoreRelaEntity> queryByStoreId(Long id);
 }

+ 8 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/alarm/Mall2OrderingEarlyWarningRemindsDao.java

@@ -3,6 +3,8 @@ package com.kmall.admin.dao.alarm;
 import com.kmall.admin.entity.alarm.Mall2OrderingEarlyWarningRemindsEntity;
 import com.kmall.manager.dao.BaseDao;
 
+import java.util.List;
+
 /**
  * 订货提醒预警表Dao
  *
@@ -12,4 +14,10 @@ import com.kmall.manager.dao.BaseDao;
  */
 public interface Mall2OrderingEarlyWarningRemindsDao extends BaseDao<Mall2OrderingEarlyWarningRemindsEntity> {
 
+
+    void insertBatch(List<Mall2OrderingEarlyWarningRemindsEntity> insertRemiderList);
+
+    void updateBatch(List<Mall2OrderingEarlyWarningRemindsEntity> updateRemiderList);
+
+    Mall2OrderingEarlyWarningRemindsEntity queryByGoodsId(Long goodsId);
 }

+ 13 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/alarm/Mall2ShippingReminderAlarmDao.java

@@ -2,6 +2,9 @@ package com.kmall.admin.dao.alarm;
 
 import com.kmall.admin.entity.alarm.Mall2ShippingReminderAlarmEntity;
 import com.kmall.manager.dao.BaseDao;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
 
 /**
  * 出货提醒预警表Dao
@@ -12,4 +15,14 @@ import com.kmall.manager.dao.BaseDao;
  */
 public interface Mall2ShippingReminderAlarmDao extends BaseDao<Mall2ShippingReminderAlarmEntity> {
 
+    /**
+     * 根据商品id查询出货提醒表
+     * @param goodsId
+     * @return
+     */
+    Mall2ShippingReminderAlarmEntity queryByGoodsIdAndStoreId(@Param("goodsId") Long goodsId, @Param("storeId") Long storeId);
+
+    void insertBatch(List<Mall2ShippingReminderAlarmEntity> insertRemiderList);
+
+    void updateBatch(List<Mall2ShippingReminderAlarmEntity> updateRemiderList);
 }

+ 2 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/mk/Mk2GoodsTopicPriceDao.java

@@ -2,6 +2,7 @@ package com.kmall.admin.dao.mk;
 
 import com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity;
 import com.kmall.manager.dao.BaseDao;
+import org.apache.ibatis.annotations.Param;
 
 /**
  * 商品活动价格表Dao
@@ -12,4 +13,5 @@ import com.kmall.manager.dao.BaseDao;
  */
 public interface Mk2GoodsTopicPriceDao extends BaseDao<Mk2GoodsTopicPriceEntity> {
 
+    Mk2GoodsTopicPriceEntity queryByTopicIdAndGoodsId(@Param("mgthpId") Integer mgthpId, @Param("sku") String  sku);
 }

+ 2 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/mk/store/MkStorePromTypeDao.java

@@ -1,5 +1,6 @@
 package com.kmall.admin.dao.mk.store;
 
+import com.kmall.admin.entity.mk.store.MkStorePromEntity;
 import com.kmall.admin.entity.mk.store.MkStorePromTypeEntity;
 import com.kmall.manager.dao.BaseDao;
 
@@ -12,4 +13,5 @@ import com.kmall.manager.dao.BaseDao;
  */
 public interface MkStorePromTypeDao extends BaseDao<MkStorePromTypeEntity> {
 
+    MkStorePromTypeEntity queryByName(String promTypeName);
 }

+ 2 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/mk/store/StoreTopicDao.java

@@ -2,6 +2,7 @@ package com.kmall.admin.dao.mk.store;
 
 import com.kmall.admin.entity.mk.store.StoreTopicEntity;
 import com.kmall.manager.dao.BaseDao;
+import org.apache.ibatis.annotations.Param;
 
 /**
  * 门店活动表Dao
@@ -12,4 +13,5 @@ import com.kmall.manager.dao.BaseDao;
  */
 public interface StoreTopicDao extends BaseDao<StoreTopicEntity> {
 
+    StoreTopicEntity queryByStoreIdAndType(@Param("storeId") Integer storeId, @Param("promTypeId") Integer promTypeId);
 }

+ 1 - 0
kmall-admin/src/main/java/com/kmall/admin/dao/vip/Mall2MemberPointsDao.java

@@ -12,4 +12,5 @@ import com.kmall.manager.dao.BaseDao;
  */
 public interface Mall2MemberPointsDao extends BaseDao<Mall2MemberPointsEntity> {
 
+    Mall2MemberPointsEntity queryByUserId(Integer userId);
 }

+ 258 - 0
kmall-admin/src/main/java/com/kmall/admin/dto/GoodsPanoramaDto.java

@@ -0,0 +1,258 @@
+package com.kmall.admin.dto;
+
+import java.io.Serializable;
+
+
+/**
+ * @author 小问号
+ */
+public class GoodsPanoramaDto implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+    // 商品id
+    private Integer id;
+    // 商品名称
+    private String name;
+    // 商品简称
+    private String simpleName;
+    // 商品规格
+    private String ciqProdModel;
+    // 基本单位
+    private String goodsBasicUnit;
+    // 品类id
+    private Integer categoryId;
+    // 品类名称
+    private String categoryName;
+    // 部门 找不到字段
+    private String departmentName;
+    // 品牌厅 找不到字段
+    private String brandHall;
+    // 进货单位
+    private String goodsPurchaseUnit;
+    // 主供应商id
+    private Integer supplierId;
+    // 主供应商名称
+    private String supplierName;
+    // 商品U级 找不到字段
+    private String goodsULevel;
+    // 包装含量 找不到字段
+    private String packageContent;
+    // 产地
+    private String origin;
+    // 主条码
+    private String prodBarcode;
+    // PLU编码
+    private String plu;
+    // 编码
+    private String goodsSn;
+    // 品牌
+    private String brand;
+
+
+
+
+
+
+    public Integer getId() {
+        return id;
+    }
+
+    public void setId(Integer id) {
+        this.id = id;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getSimpleName() {
+        return simpleName;
+    }
+
+    public void setSimpleName(String simpleName) {
+        this.simpleName = simpleName;
+    }
+
+    public String getCiqProdModel() {
+        return ciqProdModel;
+    }
+
+    public void setCiqProdModel(String ciqProdModel) {
+        this.ciqProdModel = ciqProdModel;
+    }
+
+    public String getGoodsBasicUnit() {
+        return goodsBasicUnit;
+    }
+
+    public void setGoodsBasicUnit(String goodsBasicUnit) {
+        this.goodsBasicUnit = goodsBasicUnit;
+    }
+
+    public Integer getCategoryId() {
+        return categoryId;
+    }
+
+    public void setCategoryId(Integer categoryId) {
+        this.categoryId = categoryId;
+    }
+
+    public String getCategoryName() {
+        return categoryName;
+    }
+
+    public void setCategoryName(String categoryName) {
+        this.categoryName = categoryName;
+    }
+
+    public String getDepartmentName() {
+        return departmentName;
+    }
+
+    public void setDepartmentName(String departmentName) {
+        this.departmentName = departmentName;
+    }
+
+    public String getBrandHall() {
+        return brandHall;
+    }
+
+    public void setBrandHall(String brandHall) {
+        this.brandHall = brandHall;
+    }
+
+    public String getGoodsPurchaseUnit() {
+        return goodsPurchaseUnit;
+    }
+
+    public void setGoodsPurchaseUnit(String goodsPurchaseUnit) {
+        this.goodsPurchaseUnit = goodsPurchaseUnit;
+    }
+
+    public Integer getSupplierId() {
+        return supplierId;
+    }
+
+    public void setSupplierId(Integer supplierId) {
+        this.supplierId = supplierId;
+    }
+
+    public String getSupplierName() {
+        return supplierName;
+    }
+
+    public void setSupplierName(String supplierName) {
+        this.supplierName = supplierName;
+    }
+
+    public String getGoodsULevel() {
+        return goodsULevel;
+    }
+
+    public void setGoodsULevel(String goodsULevel) {
+        this.goodsULevel = goodsULevel;
+    }
+
+    public String getPackageContent() {
+        return packageContent;
+    }
+
+    public void setPackageContent(String packageContent) {
+        this.packageContent = packageContent;
+    }
+
+    public String getOrigin() {
+        return origin;
+    }
+
+    public void setOrigin(String origin) {
+        this.origin = origin;
+    }
+
+    public String getProdBarcode() {
+        return prodBarcode;
+    }
+
+    public void setProdBarcode(String prodBarcode) {
+        this.prodBarcode = prodBarcode;
+    }
+
+
+    public String getGoodsSn() {
+        return goodsSn;
+    }
+
+    public void setGoodsSn(String goodsSn) {
+        this.goodsSn = goodsSn;
+    }
+
+    public String getBrand() {
+        return brand;
+    }
+
+    public void setBrand(String brand) {
+        this.brand = brand;
+    }
+
+    public GoodsPanoramaDto() {
+    }
+
+    public String getPlu() {
+        return plu;
+    }
+
+    public void setPlu(String plu) {
+        this.plu = plu;
+    }
+
+    @Override
+    public String toString() {
+        return "GoodsPanoramaDto{" +
+                "id=" + id +
+                ", name='" + name + '\'' +
+                ", simpleName='" + simpleName + '\'' +
+                ", ciqProdModel='" + ciqProdModel + '\'' +
+                ", goodsBasicUnit='" + goodsBasicUnit + '\'' +
+                ", categoryId=" + categoryId +
+                ", categoryName='" + categoryName + '\'' +
+                ", departmentName='" + departmentName + '\'' +
+                ", brandHall='" + brandHall + '\'' +
+                ", goodsPurchaseUnit='" + goodsPurchaseUnit + '\'' +
+                ", supplierId=" + supplierId +
+                ", supplierName='" + supplierName + '\'' +
+                ", goodsULevel='" + goodsULevel + '\'' +
+                ", packageContent='" + packageContent + '\'' +
+                ", origin='" + origin + '\'' +
+                ", prodBarcode='" + prodBarcode + '\'' +
+                ", plu='" + plu + '\'' +
+                ", goodsSn='" + goodsSn + '\'' +
+                ", brand='" + brand + '\'' +
+                '}';
+    }
+
+    public GoodsPanoramaDto(Integer id, String name, String simpleName, String ciqProdModel, String goodsBasicUnit, Integer categoryId, String categoryName, String departmentName, String brandHall, String goodsPurchaseUnit, Integer supplierId, String supplierName, String goodsULevel, String packageContent, String origin, String prodBarcode, String plu, String goodsSn, String brand) {
+        this.id = id;
+        this.name = name;
+        this.simpleName = simpleName;
+        this.ciqProdModel = ciqProdModel;
+        this.goodsBasicUnit = goodsBasicUnit;
+        this.categoryId = categoryId;
+        this.categoryName = categoryName;
+        this.departmentName = departmentName;
+        this.brandHall = brandHall;
+        this.goodsPurchaseUnit = goodsPurchaseUnit;
+        this.supplierId = supplierId;
+        this.supplierName = supplierName;
+        this.goodsULevel = goodsULevel;
+        this.packageContent = packageContent;
+        this.origin = origin;
+        this.prodBarcode = prodBarcode;
+        this.plu = plu;
+        this.goodsSn = goodsSn;
+        this.brand = brand;
+    }
+}

+ 95 - 0
kmall-admin/src/main/java/com/kmall/admin/dto/StoreTopicGoodsDto.java

@@ -0,0 +1,95 @@
+package com.kmall.admin.dto;
+
+import java.io.Serializable;
+
+
+/**
+ * @author Scott
+ * @email
+ * @date 2019-10-18 10:41:08
+ */
+public class StoreTopicGoodsDto implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+    private String topic;
+    private String topicName;
+    private String topicContent;
+    private String topicGoodsSku;
+    private String topicGoodsPrice;
+    private String topicBeginTime;
+    private String topicEndTime;
+    private String merchSn;
+    private String shopSn;
+
+    public String getTopic() {
+        return topic;
+    }
+
+    public void setTopic(String topic) {
+        this.topic = topic;
+    }
+
+    public String getTopicName() {
+        return topicName;
+    }
+
+    public void setTopicName(String topicName) {
+        this.topicName = topicName;
+    }
+
+    public String getTopicContent() {
+        return topicContent;
+    }
+
+    public void setTopicContent(String topicContent) {
+        this.topicContent = topicContent;
+    }
+
+    public String getTopicGoodsSku() {
+        return topicGoodsSku;
+    }
+
+    public void setTopicGoodsSku(String topicGoodsSku) {
+        this.topicGoodsSku = topicGoodsSku;
+    }
+
+    public String getTopicGoodsPrice() {
+        return topicGoodsPrice;
+    }
+
+    public void setTopicGoodsPrice(String topicGoodsPrice) {
+        this.topicGoodsPrice = topicGoodsPrice;
+    }
+
+    public String getTopicBeginTime() {
+        return topicBeginTime;
+    }
+
+    public void setTopicBeginTime(String topicBeginTime) {
+        this.topicBeginTime = topicBeginTime;
+    }
+
+    public String getTopicEndTime() {
+        return topicEndTime;
+    }
+
+    public void setTopicEndTime(String topicEndTime) {
+        this.topicEndTime = topicEndTime;
+    }
+
+    public String getMerchSn() {
+        return merchSn;
+    }
+
+    public void setMerchSn(String merchSn) {
+        this.merchSn = merchSn;
+    }
+
+    public String getShopSn() {
+        return shopSn;
+    }
+
+    public void setShopSn(String shopSn) {
+        this.shopSn = shopSn;
+    }
+}

+ 205 - 0
kmall-admin/src/main/java/com/kmall/admin/entity/GoodsTransportInfoDetailEntity.java

@@ -0,0 +1,205 @@
+package com.kmall.admin.entity;
+
+import java.io.Serializable;
+import java.util.Date;
+
+/**
+ * 在途商品明细表实体
+ * 表名 mall_goods_transport_info_detail
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:19:23
+ */
+public class GoodsTransportInfoDetailEntity implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 明细编号
+     */
+    private Integer transItemId;
+    /**
+     * 是否在途(0:是,1:否,默认为0)
+     */
+    private Integer wayStatus;
+    /**
+     * 商品sku
+     */
+    private String sku;
+    /**
+     * 供应商id
+     */
+    private Integer supplierId;
+    /**
+     * 原产地
+     */
+    private String originCountry;
+    /**
+     * 数量
+     */
+    private Integer num;
+    /**
+     * 创建人编号
+     */
+    private String createrSn;
+    /**
+     * 创建时间,yyyy-MM-dd HH:mm:ss
+     */
+    private Date createTime;
+    /**
+     * 修改人编号
+     */
+    private String moderSn;
+    /**
+     * 修改时间,yyyy-MM-dd HH:mm:ss
+     */
+    private Date modTime;
+    /**
+     * 时间戳
+     */
+    private Date tstm;
+
+    /**
+     * 设置:明细编号
+     */
+    public void setTransItemId(Integer transItemId) {
+        this.transItemId = transItemId;
+    }
+
+    /**
+     * 获取:明细编号
+     */
+    public Integer getTransItemId() {
+        return transItemId;
+    }
+    /**
+     * 设置:是否在途(0:是,1:否,默认为0)
+     */
+    public void setWayStatus(Integer wayStatus) {
+        this.wayStatus = wayStatus;
+    }
+
+    /**
+     * 获取:是否在途(0:是,1:否,默认为0)
+     */
+    public Integer getWayStatus() {
+        return wayStatus;
+    }
+    /**
+     * 设置:商品sku
+     */
+    public void setSku(String sku) {
+        this.sku = sku;
+    }
+
+    /**
+     * 获取:商品sku
+     */
+    public String getSku() {
+        return sku;
+    }
+    /**
+     * 设置:供应商id
+     */
+    public void setSupplierId(Integer supplierId) {
+        this.supplierId = supplierId;
+    }
+
+    /**
+     * 获取:供应商id
+     */
+    public Integer getSupplierId() {
+        return supplierId;
+    }
+    /**
+     * 设置:原产地
+     */
+    public void setOriginCountry(String originCountry) {
+        this.originCountry = originCountry;
+    }
+
+    /**
+     * 获取:原产地
+     */
+    public String getOriginCountry() {
+        return originCountry;
+    }
+    /**
+     * 设置:数量
+     */
+    public void setNum(Integer num) {
+        this.num = num;
+    }
+
+    /**
+     * 获取:数量
+     */
+    public Integer getNum() {
+        return num;
+    }
+    /**
+     * 设置:创建人编号
+     */
+    public void setCreaterSn(String createrSn) {
+        this.createrSn = createrSn;
+    }
+
+    /**
+     * 获取:创建人编号
+     */
+    public String getCreaterSn() {
+        return createrSn;
+    }
+    /**
+     * 设置:创建时间,yyyy-MM-dd HH:mm:ss
+     */
+    public void setCreateTime(Date createTime) {
+        this.createTime = createTime;
+    }
+
+    /**
+     * 获取:创建时间,yyyy-MM-dd HH:mm:ss
+     */
+    public Date getCreateTime() {
+        return createTime;
+    }
+    /**
+     * 设置:修改人编号
+     */
+    public void setModerSn(String moderSn) {
+        this.moderSn = moderSn;
+    }
+
+    /**
+     * 获取:修改人编号
+     */
+    public String getModerSn() {
+        return moderSn;
+    }
+    /**
+     * 设置:修改时间,yyyy-MM-dd HH:mm:ss
+     */
+    public void setModTime(Date modTime) {
+        this.modTime = modTime;
+    }
+
+    /**
+     * 获取:修改时间,yyyy-MM-dd HH:mm:ss
+     */
+    public Date getModTime() {
+        return modTime;
+    }
+    /**
+     * 设置:时间戳
+     */
+    public void setTstm(Date tstm) {
+        this.tstm = tstm;
+    }
+
+    /**
+     * 获取:时间戳
+     */
+    public Date getTstm() {
+        return tstm;
+    }
+}

+ 256 - 0
kmall-admin/src/main/java/com/kmall/admin/entity/GoodsTransportInfoEntity.java

@@ -0,0 +1,256 @@
+package com.kmall.admin.entity;
+
+import java.io.Serializable;
+import java.util.Date;
+
+/**
+ * 在途运输信息表实体
+ * 表名 mall_goods_transport_info
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:07:33
+ */
+public class GoodsTransportInfoEntity implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 在途编号
+     */
+    private Integer transId;
+    /**
+     * 00:海运,10:空运,20:公路,30:铁路
+     */
+    private String transportType;
+    /**
+     * 运输工具
+     */
+    private String transportTool;
+    /**
+     * 第三方商户编号
+     */
+    private Integer thirdMerchSn;
+    /**
+     * 0:是,1:否,默认为0
+     */
+    private Integer wayStatus;
+    /**
+     * 始发地
+     */
+    private String origin;
+    /**
+     * 目的地
+     */
+    private String destination;
+    /**
+     * 始发时间
+     */
+    private Date startTime;
+    /**
+     * 到达时间
+     */
+    private Date arrivalTime;
+    /**
+     * 创建人编号
+     */
+    private String createrSn;
+    /**
+     * 创建时间,yyyy-MM-dd HH:mm:ss
+     */
+    private Date createTime;
+    /**
+     * 修改人编号
+     */
+    private String moderSn;
+    /**
+     * 修改时间,yyyy-MM-dd HH:mm:ss
+     */
+    private Date modTime;
+    /**
+     * 时间戳
+     */
+    private Date tstm;
+
+    /**
+     * 设置:在途编号
+     */
+    public void setTransId(Integer transId) {
+        this.transId = transId;
+    }
+
+    /**
+     * 获取:在途编号
+     */
+    public Integer getTransId() {
+        return transId;
+    }
+    /**
+     * 设置:00:海运,10:空运,20:公路,30:铁路
+     */
+    public void setTransportType(String transportType) {
+        this.transportType = transportType;
+    }
+
+    /**
+     * 获取:00:海运,10:空运,20:公路,30:铁路
+     */
+    public String getTransportType() {
+        return transportType;
+    }
+    /**
+     * 设置:运输工具
+     */
+    public void setTransportTool(String transportTool) {
+        this.transportTool = transportTool;
+    }
+
+    /**
+     * 获取:运输工具
+     */
+    public String getTransportTool() {
+        return transportTool;
+    }
+    /**
+     * 设置:第三方商户编号
+     */
+    public void setThirdMerchSn(Integer thirdMerchSn) {
+        this.thirdMerchSn = thirdMerchSn;
+    }
+
+    /**
+     * 获取:第三方商户编号
+     */
+    public Integer getThirdMerchSn() {
+        return thirdMerchSn;
+    }
+    /**
+     * 设置:0:是,1:否,默认为0
+     */
+    public void setWayStatus(Integer wayStatus) {
+        this.wayStatus = wayStatus;
+    }
+
+    /**
+     * 获取:0:是,1:否,默认为0
+     */
+    public Integer getWayStatus() {
+        return wayStatus;
+    }
+    /**
+     * 设置:始发地
+     */
+    public void setOrigin(String origin) {
+        this.origin = origin;
+    }
+
+    /**
+     * 获取:始发地
+     */
+    public String getOrigin() {
+        return origin;
+    }
+    /**
+     * 设置:目的地
+     */
+    public void setDestination(String destination) {
+        this.destination = destination;
+    }
+
+    /**
+     * 获取:目的地
+     */
+    public String getDestination() {
+        return destination;
+    }
+    /**
+     * 设置:始发时间
+     */
+    public void setStartTime(Date startTime) {
+        this.startTime = startTime;
+    }
+
+    /**
+     * 获取:始发时间
+     */
+    public Date getStartTime() {
+        return startTime;
+    }
+    /**
+     * 设置:到达时间
+     */
+    public void setArrivalTime(Date arrivalTime) {
+        this.arrivalTime = arrivalTime;
+    }
+
+    /**
+     * 获取:到达时间
+     */
+    public Date getArrivalTime() {
+        return arrivalTime;
+    }
+    /**
+     * 设置:创建人编号
+     */
+    public void setCreaterSn(String createrSn) {
+        this.createrSn = createrSn;
+    }
+
+    /**
+     * 获取:创建人编号
+     */
+    public String getCreaterSn() {
+        return createrSn;
+    }
+    /**
+     * 设置:创建时间,yyyy-MM-dd HH:mm:ss
+     */
+    public void setCreateTime(Date createTime) {
+        this.createTime = createTime;
+    }
+
+    /**
+     * 获取:创建时间,yyyy-MM-dd HH:mm:ss
+     */
+    public Date getCreateTime() {
+        return createTime;
+    }
+    /**
+     * 设置:修改人编号
+     */
+    public void setModerSn(String moderSn) {
+        this.moderSn = moderSn;
+    }
+
+    /**
+     * 获取:修改人编号
+     */
+    public String getModerSn() {
+        return moderSn;
+    }
+    /**
+     * 设置:修改时间,yyyy-MM-dd HH:mm:ss
+     */
+    public void setModTime(Date modTime) {
+        this.modTime = modTime;
+    }
+
+    /**
+     * 获取:修改时间,yyyy-MM-dd HH:mm:ss
+     */
+    public Date getModTime() {
+        return modTime;
+    }
+    /**
+     * 设置:时间戳
+     */
+    public void setTstm(Date tstm) {
+        this.tstm = tstm;
+    }
+
+    /**
+     * 获取:时间戳
+     */
+    public Date getTstm() {
+        return tstm;
+    }
+}

+ 28 - 0
kmall-admin/src/main/java/com/kmall/admin/entity/mk/Mk2GoodsTopicHistoryPriceEntity.java

@@ -39,6 +39,10 @@ public class Mk2GoodsTopicHistoryPriceEntity implements Serializable {
      * 活动内容
      */
     private String topicContent;
+
+    private Date topicBeginTime;
+    private Date topicEndTime;
+    private String topicGoodsSku;
     /**
      * 创建人编号
      */
@@ -203,4 +207,28 @@ public class Mk2GoodsTopicHistoryPriceEntity implements Serializable {
     public Date getTstm() {
         return tstm;
     }
+
+    public Date getTopicBeginTime() {
+        return topicBeginTime;
+    }
+
+    public void setTopicBeginTime(Date topicBeginTime) {
+        this.topicBeginTime = topicBeginTime;
+    }
+
+    public Date getTopicEndTime() {
+        return topicEndTime;
+    }
+
+    public void setTopicEndTime(Date topicEndTime) {
+        this.topicEndTime = topicEndTime;
+    }
+
+    public String getTopicGoodsSku() {
+        return topicGoodsSku;
+    }
+
+    public void setTopicGoodsSku(String topicGoodsSku) {
+        this.topicGoodsSku = topicGoodsSku;
+    }
 }

+ 9 - 13
kmall-admin/src/main/java/com/kmall/admin/entity/mk/Mk2GoodsTopicPriceEntity.java

@@ -42,7 +42,7 @@ public class Mk2GoodsTopicPriceEntity implements Serializable {
     /**
      * 活动产品
      */
-    private Integer topicGoodsId;
+    private String topicGoodsSku;
     /**
      * 活动开始时间
      */
@@ -154,20 +154,8 @@ public class Mk2GoodsTopicPriceEntity implements Serializable {
     public String getTopicContent() {
         return topicContent;
     }
-    /**
-     * 设置:活动产品
-     */
-    public void setTopicGoodsId(Integer topicGoodsId) {
-        this.topicGoodsId = topicGoodsId;
-    }
 
     /**
-     * 获取:活动产品
-     */
-    public Integer getTopicGoodsId() {
-        return topicGoodsId;
-    }
-    /**
      * 设置:活动开始时间
      */
     public void setTopicBeginTime(Date topicBeginTime) {
@@ -271,4 +259,12 @@ public class Mk2GoodsTopicPriceEntity implements Serializable {
     public Date getTstm() {
         return tstm;
     }
+
+    public String getTopicGoodsSku() {
+        return topicGoodsSku;
+    }
+
+    public void setTopicGoodsSku(String topicGoodsSku) {
+        this.topicGoodsSku = topicGoodsSku;
+    }
 }

+ 6 - 0
kmall-admin/src/main/java/com/kmall/admin/service/GoodsService.java

@@ -2,6 +2,7 @@ package com.kmall.admin.service;
 
 import com.kmall.admin.dto.GoodsDetailsDto;
 import com.kmall.admin.dto.GoodsDto;
+import com.kmall.admin.dto.GoodsPanoramaDto;
 import com.kmall.admin.entity.GoodsEntity;
 
 import java.util.List;
@@ -130,4 +131,9 @@ public interface GoodsService {
      * @return
      */
     GoodsDetailsDto queryGoodsDetailsByProdBarcode(String prodBarcode, String storeId);
+
+
+    GoodsPanoramaDto searchGoodsPanoramaDtoByKeyword(String keyword);
+
+
 }

+ 78 - 0
kmall-admin/src/main/java/com/kmall/admin/service/GoodsTransportInfoDetailService.java

@@ -0,0 +1,78 @@
+package com.kmall.admin.service;
+
+import com.kmall.admin.entity.GoodsTransportInfoDetailEntity;
+import com.kmall.common.utils.Query;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 在途商品明细表Service接口
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:19:23
+ */
+public interface GoodsTransportInfoDetailService {
+
+    /**
+     * 根据主键查询实体
+     *
+     * @param transItemId 主键
+     * @return 实体
+     */
+    GoodsTransportInfoDetailEntity queryObject(Integer transItemId);
+
+    /**
+     * 分页查询
+     *
+     * @param map 参数
+     * @return list
+     */
+    List<GoodsTransportInfoDetailEntity> queryList(Map<String, Object> map);
+
+    /**
+     * 分页统计总数
+     *
+     * @param map 参数
+     * @return 总数
+     */
+    int queryTotal(Map<String, Object> map);
+
+    /**
+     * 保存实体
+     *
+     * @param goodsTransportInfoDetail 实体
+     * @return 保存条数
+     */
+    int save(GoodsTransportInfoDetailEntity goodsTransportInfoDetail);
+
+    /**
+     * 根据主键更新实体
+     *
+     * @param goodsTransportInfoDetail 实体
+     * @return 更新条数
+     */
+    int update(GoodsTransportInfoDetailEntity goodsTransportInfoDetail);
+
+    /**
+     * 根据主键删除
+     *
+     * @param transItemId
+     * @return 删除条数
+     */
+    int delete(Integer transItemId);
+
+    /**
+     * 根据主键批量删除
+     *
+     * @param transItemIds
+     * @return 删除条数
+     */
+    int deleteBatch(Integer[] transItemIds);
+
+
+    List<GoodsTransportInfoDetailEntity> searchListByStatusAndSku(Query query, Integer wayStatus, String sku);
+
+    int queryTotalByStatusAndSku(Query query, Integer wayStatus, String sku);
+}

+ 74 - 0
kmall-admin/src/main/java/com/kmall/admin/service/GoodsTransportInfoService.java

@@ -0,0 +1,74 @@
+package com.kmall.admin.service;
+
+import com.kmall.admin.entity.GoodsTransportInfoEntity;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 在途运输信息表Service接口
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:07:33
+ */
+public interface GoodsTransportInfoService {
+
+    /**
+     * 根据主键查询实体
+     *
+     * @param transId 主键
+     * @return 实体
+     */
+    GoodsTransportInfoEntity queryObject(Integer transId);
+
+    /**
+     * 分页查询
+     *
+     * @param map 参数
+     * @return list
+     */
+    List<GoodsTransportInfoEntity> queryList(Map<String, Object> map);
+
+    /**
+     * 分页统计总数
+     *
+     * @param map 参数
+     * @return 总数
+     */
+    int queryTotal(Map<String, Object> map);
+
+    /**
+     * 保存实体
+     *
+     * @param goodsTransportInfo 实体
+     * @return 保存条数
+     */
+    int save(GoodsTransportInfoEntity goodsTransportInfo);
+
+    /**
+     * 根据主键更新实体
+     *
+     * @param goodsTransportInfo 实体
+     * @return 更新条数
+     */
+    int update(GoodsTransportInfoEntity goodsTransportInfo);
+
+    /**
+     * 根据主键删除
+     *
+     * @param transId
+     * @return 删除条数
+     */
+    int delete(Integer transId);
+
+    /**
+     * 根据主键批量删除
+     *
+     * @param transIds
+     * @return 删除条数
+     */
+    int deleteBatch(Integer[] transIds);
+
+
+}

+ 3 - 0
kmall-admin/src/main/java/com/kmall/admin/service/alarm/Mall2OrderingEarlyWarningRemindsService.java

@@ -69,4 +69,7 @@ public interface Mall2OrderingEarlyWarningRemindsService {
      * @return 删除条数
      */
     int deleteBatch(Integer[] moewrIds);
+
+
+    void orderReminds();
 }

+ 5 - 0
kmall-admin/src/main/java/com/kmall/admin/service/alarm/Mall2ShippingReminderAlarmService.java

@@ -68,4 +68,9 @@ public interface Mall2ShippingReminderAlarmService {
      * @return 删除条数
      */
     int deleteBatch(Integer[] msraIds);
+
+    /**
+     * 查询商品是否需要出货提醒
+     */
+    void shippingReminds();
 }

+ 7 - 0
kmall-admin/src/main/java/com/kmall/admin/service/impl/GoodsServiceImpl.java

@@ -5,6 +5,7 @@ import com.google.common.collect.Maps;
 import com.kmall.admin.dao.*;
 import com.kmall.admin.dto.GoodsDetailsDto;
 import com.kmall.admin.dto.GoodsDto;
+import com.kmall.admin.dto.GoodsPanoramaDto;
 import com.kmall.admin.entity.*;
 import com.kmall.admin.service.GoodsService;
 import com.kmall.admin.utils.ShiroUtils;
@@ -1026,6 +1027,12 @@ public class GoodsServiceImpl implements GoodsService {
     public GoodsDetailsDto queryGoodsDetailsByProdBarcode(String prodBarcode, String storeId) {
         return goodsDao.queryGoodsDetailsByProdBarcode(prodBarcode,storeId);
     }
+
+
+    @Override
+    public GoodsPanoramaDto searchGoodsPanoramaDtoByKeyword(String keyword) {
+        return goodsDao.searchGoodsPanoramaDtoByKeyword(keyword);
+    }
 /*  @Override
     @Transactional
     public int uploadExcel(MultipartFile file) {

+ 71 - 0
kmall-admin/src/main/java/com/kmall/admin/service/impl/GoodsTransportInfoDetailServiceImpl.java

@@ -0,0 +1,71 @@
+package com.kmall.admin.service.impl;
+
+import com.kmall.common.utils.Query;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+import java.util.Map;
+
+import com.kmall.admin.dao.GoodsTransportInfoDetailDao;
+import com.kmall.admin.entity.GoodsTransportInfoDetailEntity;
+import com.kmall.admin.service.GoodsTransportInfoDetailService;
+
+/**
+ * 在途商品明细表Service实现类
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:19:23
+ */
+@Service("goodsTransportInfoDetailService")
+public class GoodsTransportInfoDetailServiceImpl implements GoodsTransportInfoDetailService {
+    @Autowired
+    private GoodsTransportInfoDetailDao goodsTransportInfoDetailDao;
+
+    @Override
+    public GoodsTransportInfoDetailEntity queryObject(Integer transItemId) {
+        return goodsTransportInfoDetailDao.queryObject(transItemId);
+    }
+
+    @Override
+    public List<GoodsTransportInfoDetailEntity> queryList(Map<String, Object> map) {
+        return goodsTransportInfoDetailDao.queryList(map);
+    }
+
+    @Override
+    public int queryTotal(Map<String, Object> map) {
+        return goodsTransportInfoDetailDao.queryTotal(map);
+    }
+
+    @Override
+    public int save(GoodsTransportInfoDetailEntity goodsTransportInfoDetail) {
+        return goodsTransportInfoDetailDao.save(goodsTransportInfoDetail);
+    }
+
+    @Override
+    public int update(GoodsTransportInfoDetailEntity goodsTransportInfoDetail) {
+        return goodsTransportInfoDetailDao.update(goodsTransportInfoDetail);
+    }
+
+    @Override
+    public int delete(Integer transItemId) {
+        return goodsTransportInfoDetailDao.delete(transItemId);
+    }
+
+    @Override
+    public int deleteBatch(Integer[]transItemIds) {
+        return goodsTransportInfoDetailDao.deleteBatch(transItemIds);
+    }
+
+    @Override
+    public List<GoodsTransportInfoDetailEntity> searchListByStatusAndSku(Query query, Integer wayStatus, String sku) {
+        return goodsTransportInfoDetailDao.searchListByStatusAndSku(query,wayStatus,sku);
+    }
+
+    @Override
+    public int queryTotalByStatusAndSku(Query query, Integer wayStatus, String sku) {
+        return goodsTransportInfoDetailDao.queryTotalByStatusAndSku(query,wayStatus,sku);
+    }
+
+}

+ 60 - 0
kmall-admin/src/main/java/com/kmall/admin/service/impl/GoodsTransportInfoServiceImpl.java

@@ -0,0 +1,60 @@
+package com.kmall.admin.service.impl;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+import java.util.Map;
+
+import com.kmall.admin.dao.GoodsTransportInfoDao;
+import com.kmall.admin.entity.GoodsTransportInfoEntity;
+import com.kmall.admin.service.GoodsTransportInfoService;
+
+/**
+ * 在途运输信息表Service实现类
+ *
+ * @author emato
+ * @email admin@qhdswl.com
+ * @date 2020-06-15 18:07:33
+ */
+@Service("goodsTransportInfoService")
+public class GoodsTransportInfoServiceImpl implements GoodsTransportInfoService {
+    @Autowired
+    private GoodsTransportInfoDao goodsTransportInfoDao;
+
+    @Override
+    public GoodsTransportInfoEntity queryObject(Integer transId) {
+        return goodsTransportInfoDao.queryObject(transId);
+    }
+
+    @Override
+    public List<GoodsTransportInfoEntity> queryList(Map<String, Object> map) {
+        return goodsTransportInfoDao.queryList(map);
+    }
+
+    @Override
+    public int queryTotal(Map<String, Object> map) {
+        return goodsTransportInfoDao.queryTotal(map);
+    }
+
+    @Override
+    public int save(GoodsTransportInfoEntity goodsTransportInfo) {
+        return goodsTransportInfoDao.save(goodsTransportInfo);
+    }
+
+    @Override
+    public int update(GoodsTransportInfoEntity goodsTransportInfo) {
+        return goodsTransportInfoDao.update(goodsTransportInfo);
+    }
+
+    @Override
+    public int delete(Integer transId) {
+        return goodsTransportInfoDao.delete(transId);
+    }
+
+    @Override
+    public int deleteBatch(Integer[]transIds) {
+        return goodsTransportInfoDao.deleteBatch(transIds);
+    }
+
+}

+ 212 - 78
kmall-admin/src/main/java/com/kmall/admin/service/impl/OrderServiceImpl.java

@@ -4,15 +4,23 @@ import com.alibaba.fastjson.JSONObject;
 import com.google.common.collect.ImmutableBiMap;
 import com.google.common.collect.Maps;
 import com.kmall.admin.dao.*;
+import com.kmall.admin.dao.mk.Mk2GoodsTopicPriceDao;
+import com.kmall.admin.dao.mk.Mk2MemberBirthdayDao;
 import com.kmall.admin.dao.mk.store.MkStorePromOrderRealDao;
+import com.kmall.admin.dao.mk.store.MkStorePromTypeDao;
+import com.kmall.admin.dao.mk.store.StoreTopicDao;
+import com.kmall.admin.dao.vip.Mall2MemberConsumptionRecordsDao;
+import com.kmall.admin.dao.vip.Mall2MemberPointsDao;
+import com.kmall.admin.dao.vip.Mall2PointsRulesDao;
 import com.kmall.admin.dto.OrderExpressDto;
 import com.kmall.admin.dto.OrderRecognitionDto;
 import com.kmall.admin.entity.*;
 import com.kmall.admin.entity.OrderProcessRecordEntity;
-import com.kmall.admin.entity.mk.store.MkStoreCampMinusEntity;
-import com.kmall.admin.entity.mk.store.MkStoreCampMinusLevelEntity;
-import com.kmall.admin.entity.mk.store.MkStorePromOrderRealEntity;
-import com.kmall.admin.entity.mk.store.MkStoreTicketDiscountEntity;
+import com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity;
+import com.kmall.admin.entity.mk.store.*;
+import com.kmall.admin.entity.vip.Mall2MemberConsumptionRecordsEntity;
+import com.kmall.admin.entity.vip.Mall2MemberPointsEntity;
+import com.kmall.admin.entity.vip.Mall2PointsRulesEntity;
 import com.kmall.admin.fromcomm.dao.SysConfigDao;
 import com.kmall.admin.service.*;
 import com.kmall.admin.service.mk.store.MkStoreCampMinusService;
@@ -118,8 +126,24 @@ public class OrderServiceImpl implements OrderService {
     @Autowired
     private MkStoreTicketDiscountService mkStoreTicketDiscountService;
 
-
-
+    @Autowired
+    private CashierDao cashierDao; // 收银机查询
+    @Autowired
+    private CashierLoginRecordDao cashierLoginRecordDao; // 收银员登录记录
+    @Autowired
+    private StoreTopicDao storeTopicDao; // 查询是否有门店活动
+    @Autowired
+    private Mk2GoodsTopicPriceDao mk2GoodsTopicPriceDao; // 门店商品价格
+    @Autowired
+    private Mall2PointsRulesDao pointsRulesDao; // 积分规则
+    @Autowired
+    private Mall2MemberPointsDao memberPointsDao; // 用户积分
+    @Autowired
+    private Mall2MemberConsumptionRecordsDao memberConsumptionRecordsDao; // 会员消费记录
+    @Autowired
+    private MkStorePromTypeDao storePromTypeDao; // 优惠类型
+    @Autowired
+    private Mk2MemberBirthdayDao memberBirthdayDao; // 生日优惠
 
     @Override
     public OrderEntity queryObject(Long id) {
@@ -1599,8 +1623,12 @@ public class OrderServiceImpl implements OrderService {
         String parCode = (String) param.get("payCode");
         // 解析sessionId(WebSocket) String
         String sessionId = (String) param.get("sessionId");
+        // machineCode
+        String machineCode = (String) param.get("machineCode");
 
         Map resultObj = Maps.newHashMap();
+
+
         try {
             if (user == null) {
                 resultObj.put("errno", 400);
@@ -1630,6 +1658,9 @@ public class OrderServiceImpl implements OrderService {
                     resultObj.put("errmsg", "订单提交失败:商品不存在");
                     return resultObj;
                 }
+
+
+
                 Integer sellVolume = (Integer)goodsDto.get("sellVolume");
 
                 goodsDto.put("goodsId",goodsEntity.getId());
@@ -1648,6 +1679,9 @@ public class OrderServiceImpl implements OrderService {
                         resultObj.put("errmsg", "库存不足,仅剩余" + productInfo.getStockNum());
                         return resultObj;
                     } else {
+
+                        // TODO 判断销售价是否低于底线价
+
                         productInfo.setStockNum(productInfo.getStockNum() - sellVolume);
                         productInfo.setStoreId(Long.valueOf(storeId));
                         productInfo.addSellVolume();
@@ -1658,6 +1692,7 @@ public class OrderServiceImpl implements OrderService {
                             goodsDao.update(goodsEntity);
                         }
                     }
+                    // 借用这个字段来存储购买数
                     goodsEntity.setGoodsNumber(sellVolume);
                     goodsEntities.add(goodsEntity);
                 }
@@ -1678,88 +1713,59 @@ public class OrderServiceImpl implements OrderService {
                 userDao.save(userEntity);
             }
 
-            // TODO 生成订单之前,先查询是否有优惠券或者满减
-            // TODO 20200610 要修改成全部商品
-            // 优惠券的集合
-            List<MkStoreTicketDiscountEntity> mkStoreTicketDiscountEntities = new ArrayList<>();
-            // 满减的集合
-            List<MkStoreCampMinusLevelEntity> mkStoreCampMinusEntities = new ArrayList<>();
-            // 存商品跟金额的关系
-            Map<Long,BigDecimal> moneyMap = new HashMap<>();
-            // 商品总价
-            BigDecimal totalPrice = new BigDecimal(0);
-
-            for(GoodsEntity goodsEntity : goodsEntities){
-                Long goodsId = goodsEntity.getId();
-                // 计算该商品的价格
-                BigDecimal goodsPrice = goodsEntity.getStoreRetailPrice().multiply(new BigDecimal(goodsEntity.getGoodsNumber())).setScale(2, RoundingMode.HALF_UP);
-                moneyMap.put(goodsId,goodsPrice);
-                totalPrice = totalPrice.add(goodsPrice);
-                // 查询该商品id是否有优惠券
-                List<MkStoreTicketDiscountEntity> mkStoreTicketDiscountEntity = mkStoreTicketDiscountService.queryByGoodsId(goodsId);
-                if(mkStoreTicketDiscountEntity != null) {
-                    mkStoreTicketDiscountEntities.addAll(mkStoreTicketDiscountEntity);
-                }
-                // 查询该商品id是否有满减
-                List<MkStoreCampMinusLevelEntity> mkStoreCampMinusEntity = mkStoreCampMinusService.queryByGoodsId(goodsId);
-                if(mkStoreCampMinusEntity != null) {
-                    mkStoreCampMinusEntities.addAll(mkStoreCampMinusEntity);
-                }
-            }
 
-            // 满减优惠的金额
-            BigDecimal campDisCountAmount = new BigDecimal(0);
-            if(mkStoreCampMinusEntities.size() > 0){
-                // 上一次所需金额,用于取最大的优惠力度
-                BigDecimal lastAmount = new BigDecimal(0);
-                for (int i = 0 ; i < mkStoreCampMinusEntities.size() ; i++){
-                    MkStoreCampMinusLevelEntity mkStoreCampMinusLevelEntity = mkStoreCampMinusEntities.get(i);
-                    // TODO 20200610还有满多少件,跟满多少元打折的,逻辑复杂,下次开发
-                    BigDecimal discCond = mkStoreCampMinusLevelEntity.getYuanMinusCond();
-                    // 判断这次金额是否大于上次金额,如果不大于,直接continue
-                    if(discCond.compareTo(lastAmount) > 0){
-                        // 如果总金额大于所需金额,则可以使用该优惠券,记录该优惠券的角标,金额跟优惠的钱
-                        if(totalPrice.compareTo(discCond) > 0){
-                            // 记录上一次金额
-                            lastAmount = discCond;
-                            campDisCountAmount = mkStoreCampMinusLevelEntity.getYuanMinusPref();
-                        }
+
+
+            // 优惠金额
+            BigDecimal disCountAmount = new BigDecimal(0);
+            // 活动id
+            Integer topicId = 0;
+            // 查询活动类别id
+            MkStorePromTypeEntity mkStorePromEntity = storePromTypeDao.queryByName("周活动");
+            // 根据门店id和活动类别查询该门店是否有活动
+            StoreTopicEntity storeTopic = storeTopicDao.queryByStoreIdAndType(storeId,mkStorePromEntity.getPromTypeId());
+            // 判断是否启用了活动,如果启用了活动。则去查询活动价
+            if(storeTopic != null){
+                for(GoodsEntity goodsEntity :goodsEntities){
+                    // 根据活动id跟商品id,查询该商品的价格
+                    Mk2GoodsTopicPriceEntity goodsTopicPriceEntity =
+                            mk2GoodsTopicPriceDao.queryByTopicIdAndGoodsId(storeTopic.getId(),goodsEntity.getSku());
+                    if (goodsEntity.getStoreRetailPrice().compareTo(goodsTopicPriceEntity.getTopicPrice()) <= -1) {
+                        LOGGER.error("销售价格小于活动价格");
+                        throw new RuntimeException("商品"+goodsEntity.getName()+"的销售价格小于活动价格");
                     }
+                    goodsEntity.setStoreRetailPrice(goodsTopicPriceEntity.getTopicPrice());
                 }
+
+            }else{
+                disCountAmount = getDisCountAmout(goodsEntities);
             }
 
-            // 优惠券优惠的金额
-            BigDecimal ticketDisCountAmount = new BigDecimal(0);
-            if(mkStoreTicketDiscountEntities.size() > 0){
-                // 上一次所需金额,用于取最大的优惠力度
-                BigDecimal lastAmount = new BigDecimal(0);
-                for (int i = 0 ; i < mkStoreTicketDiscountEntities.size() ; i++){
-                    MkStoreTicketDiscountEntity mkStoreTicketDiscountEntity = mkStoreTicketDiscountEntities.get(i);
-                    // 代金券所需金额
-                    // TODO 20200610还有折扣券的,逻辑较为复杂,下次在开发
-                    BigDecimal discCond = mkStoreTicketDiscountEntity.getVoucherCond();
-
-                    // 判断这次金额是否大于上次金额,如果不大于,直接continue
-                    if(discCond.compareTo(lastAmount) > 0){
-                        // 如果总金额大于所需金额,则可以使用该优惠券,记录该优惠券的角标,金额跟优惠的钱
-                        if(totalPrice.compareTo(discCond) > 0){
-                            // 记录上一次金额
-                            lastAmount = discCond;
-                            ticketDisCountAmount = mkStoreTicketDiscountEntity.getVoucherMoney();
-                        }
-                    }
-                }
+
+            // 判断该用户是否是生日
+            Boolean isBirth = false;
+            String birthday = "";
+            if(userEntity.getIdNo().length() == 15){
+                birthday = userEntity.getIdNo().substring(8,10) + "-" + userEntity.getIdNo().substring(10,12);
+            }else if(userEntity.getIdNo().length() == 18){
+                birthday = userEntity.getIdNo().substring(10,12) + "-" + userEntity.getIdNo().substring(12,14);
             }
 
-            // 判断两个优惠金额
-            BigDecimal disCountAmount = ticketDisCountAmount.compareTo(campDisCountAmount) > 0 ? ticketDisCountAmount : campDisCountAmount;
+            SimpleDateFormat format = new SimpleDateFormat("MM-dd");
+            String today = format.format(new Date());
+            if(birthday.equalsIgnoreCase(today)){
+                isBirth = true;
+            }
 
 
 
             // 生成订单
             String merchOrderSn = "EMATO" + CommonUtil.generateOrderNumber();
-            OrderVo order = setOrderVo(goodsList, userEntity,storeId.longValue(), user.getMerchSn(),disCountAmount);
+            OrderVo order = setOrderVo(goodsEntities, userEntity,storeId.longValue(), user.getMerchSn(),disCountAmount);
             order.setStore_id(storeId.longValue());
+            if(storeTopic != null){
+                order.setActivity_id(storeTopic.getId().longValue());
+            }
             order.setMerchOrderSn(merchOrderSn);
 
             //插入订单信息和订单商品
@@ -1821,6 +1827,54 @@ public class OrderServiceImpl implements OrderService {
             pickUpCodeEntity.setOrderSn(order.getOrder_sn());
             pickUpCodeService.save(pickUpCodeEntity);
 
+            // 生成销售记录
+            SaleRecordEntity saleRecordEntity = new SaleRecordEntity();
+
+            // 根据收银机机器码,查询收银机
+            CashierEntity cashierEntity = cashierDao.queryByMachineCode(machineCode);
+            if(cashierEntity != null){
+                saleRecordEntity.setCashierSn(cashierEntity.getCashierSn());
+                saleRecordEntity.setOrderSn(order.getOrder_sn());
+                saleRecordEntity.setSallerId(userId+"");
+                saleRecordEntity.setSalesTime(new Date());
+                saleRecordEntity.setDiscountId(topicId + "");
+
+            }
+
+            // 查询积分规则 ,默认先按消费金额1:1积分
+            Mall2PointsRulesEntity pointsRules = null;
+
+            // 增加该会员的积分
+            Mall2MemberPointsEntity memberPointsEntity = memberPointsDao.queryByUserId(userEntity.getId());
+            if(memberPointsEntity == null){
+                memberPointsEntity = new Mall2MemberPointsEntity();
+                memberPointsEntity.setUserId(userEntity.getId()+"");
+                memberPointsEntity.setPoints(order.getActual_price().intValue());
+                memberPointsEntity.setCreaterSn(userId+"");
+                memberPointsEntity.setCreateTime(new Date());
+                memberPointsDao.save(memberPointsEntity);
+            }else{
+                memberPointsEntity.setPoints(order.getActual_price().add(new BigDecimal(memberPointsEntity.getPoints())).intValue());
+                memberPointsEntity.setModerSn(userId+"");
+                memberPointsEntity.setModTime(new Date());
+                memberPointsDao.update(memberPointsEntity);
+            }
+            // 增加该会员的消费记录
+            Mall2MemberConsumptionRecordsEntity consumptionRecords = new Mall2MemberConsumptionRecordsEntity();
+            consumptionRecords.setUserId(userEntity.getId()+"");
+            consumptionRecords.setOrderSn(order.getOrder_sn());
+            consumptionRecords.setConsumptionTime(new Date());
+            consumptionRecords.setShopSn(storeId+"");
+            // TODO 判断是否有使用生日优惠
+            if(isBirth){
+                consumptionRecords.setIsUseBirthdayOffer("0"); // 使用生日优惠
+            }else{
+                consumptionRecords.setIsUseBirthdayOffer("1"); // 没使用生日优惠
+            }
+            consumptionRecords.setCreaterSn(userId+"");
+            consumptionRecords.setCreateTime(new Date());
+            memberConsumptionRecordsDao.save(consumptionRecords);
+
             resultObj.put("code",pickUpCodeEntity.getPickUpCodeSn()); // 系统中累加
 
             resultObj.put("time",new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(new Date()));
@@ -1842,6 +1896,86 @@ public class OrderServiceImpl implements OrderService {
         return resultObj;
     }
 
+    private BigDecimal getDisCountAmout(List<GoodsEntity> goodsEntities) {
+        BigDecimal disCountAmount;
+        // TODO 生成订单之前,先查询是否有优惠券或者满减
+        // TODO 20200610 要修改成全部商品
+        // 优惠券的集合
+        List<MkStoreTicketDiscountEntity> mkStoreTicketDiscountEntities = new ArrayList<>();
+        // 满减的集合
+        List<MkStoreCampMinusLevelEntity> mkStoreCampMinusEntities = new ArrayList<>();
+        // 存商品跟金额的关系
+        Map<Long,BigDecimal> moneyMap = new HashMap<>();
+        // 商品总价
+        BigDecimal totalPrice = new BigDecimal(0);
+
+        for(GoodsEntity goodsEntity : goodsEntities){
+            Long goodsId = goodsEntity.getId();
+            // 计算该商品的价格
+            BigDecimal goodsPrice = goodsEntity.getStoreRetailPrice().multiply(new BigDecimal(goodsEntity.getGoodsNumber())).setScale(2, RoundingMode.HALF_UP);
+            moneyMap.put(goodsId,goodsPrice);
+            totalPrice = totalPrice.add(goodsPrice);
+            // 查询该商品id是否有优惠券
+            List<MkStoreTicketDiscountEntity> mkStoreTicketDiscountEntity = mkStoreTicketDiscountService.queryByGoodsId(goodsId);
+            if(mkStoreTicketDiscountEntity != null) {
+                mkStoreTicketDiscountEntities.addAll(mkStoreTicketDiscountEntity);
+            }
+            // 查询该商品id是否有满减
+            List<MkStoreCampMinusLevelEntity> mkStoreCampMinusEntity = mkStoreCampMinusService.queryByGoodsId(goodsId);
+            if(mkStoreCampMinusEntity != null) {
+                mkStoreCampMinusEntities.addAll(mkStoreCampMinusEntity);
+            }
+        }
+
+        // 满减优惠的金额
+        BigDecimal campDisCountAmount = new BigDecimal(0);
+        if(mkStoreCampMinusEntities.size() > 0){
+            // 上一次所需金额,用于取最大的优惠力度
+            BigDecimal lastAmount = new BigDecimal(0);
+            for (int i = 0 ; i < mkStoreCampMinusEntities.size() ; i++){
+                MkStoreCampMinusLevelEntity mkStoreCampMinusLevelEntity = mkStoreCampMinusEntities.get(i);
+                // TODO 20200610还有满多少件,跟满多少元打折的,逻辑复杂,下次开发
+                BigDecimal discCond = mkStoreCampMinusLevelEntity.getYuanMinusCond();
+                // 判断这次金额是否大于上次金额,如果不大于,直接continue
+                if(discCond.compareTo(lastAmount) > 0){
+                    // 如果总金额大于所需金额,则可以使用该优惠券,记录该优惠券的角标,金额跟优惠的钱
+                    if(totalPrice.compareTo(discCond) > 0){
+                        // 记录上一次金额
+                        lastAmount = discCond;
+                        campDisCountAmount = mkStoreCampMinusLevelEntity.getYuanMinusPref();
+                    }
+                }
+            }
+        }
+
+        // 优惠券优惠的金额
+        BigDecimal ticketDisCountAmount = new BigDecimal(0);
+        if(mkStoreTicketDiscountEntities.size() > 0){
+            // 上一次所需金额,用于取最大的优惠力度
+            BigDecimal lastAmount = new BigDecimal(0);
+            for (int i = 0 ; i < mkStoreTicketDiscountEntities.size() ; i++){
+                MkStoreTicketDiscountEntity mkStoreTicketDiscountEntity = mkStoreTicketDiscountEntities.get(i);
+                // 代金券所需金额
+                // TODO 20200610还有折扣券的,逻辑较为复杂,下次在开发
+                BigDecimal discCond = mkStoreTicketDiscountEntity.getVoucherCond();
+
+                // 判断这次金额是否大于上次金额,如果不大于,直接continue
+                if(discCond.compareTo(lastAmount) > 0){
+                    // 如果总金额大于所需金额,则可以使用该优惠券,记录该优惠券的角标,金额跟优惠的钱
+                    if(totalPrice.compareTo(discCond) > 0){
+                        // 记录上一次金额
+                        lastAmount = discCond;
+                        ticketDisCountAmount = mkStoreTicketDiscountEntity.getVoucherMoney();
+                    }
+                }
+            }
+        }
+
+
+        disCountAmount = ticketDisCountAmount.compareTo(campDisCountAmount) > 0 ? ticketDisCountAmount : campDisCountAmount;
+        return disCountAmount;
+    }
+
     private void AliPay(SysUserEntity user, String parCode,  OrderVo order, OrderProcessRecordEntity processRecordEntity, OrderWXPayRecordEntity orderWXPayRecordCurrent, StoreEntity store) throws Exception {
 
         AliPayRequestParams params = new AliPayRequestParams();
@@ -2069,15 +2203,15 @@ public class OrderServiceImpl implements OrderService {
      * 设置订单数据
      * @return
      */
-    public OrderVo setOrderVo(List<LinkedHashMap> goodsList, UserEntity loginUser,Long storeId, String merchSn, BigDecimal disCountAmount){
+    public OrderVo setOrderVo(List<GoodsEntity> goodsList, UserEntity loginUser,Long storeId, String merchSn, BigDecimal disCountAmount){
         OrderVo orderInfo = new OrderVo();
 
         BigDecimal goodsTotalPrice = new BigDecimal(0.00);
         BigDecimal freightPrice = Constant.ZERO;
-        for (LinkedHashMap goods : goodsList) {
+        for (GoodsEntity goodsEntity : goodsList) {
 
             goodsTotalPrice = goodsTotalPrice
-                    .add(new BigDecimal(goods.get("retailPrice").toString()).multiply(new BigDecimal(goods.get("sellVolume").toString())));
+                    .add(goodsEntity.getStoreRetailPrice().multiply(new BigDecimal(goodsEntity.getGoodsNumber())));
         }
 
         //订单价格计算:订单的总价+运费

+ 134 - 2
kmall-admin/src/main/java/com/kmall/admin/service/impl/alarm/Mall2OrderingEarlyWarningRemindsServiceImpl.java

@@ -1,14 +1,24 @@
 package com.kmall.admin.service.impl.alarm;
 
+import com.kmall.admin.dao.GoodsDao;
+import com.kmall.admin.dao.MerchDao;
+import com.kmall.admin.dao.ProductStoreRelaDao;
+import com.kmall.admin.dao.StoreDao;
+import com.kmall.admin.entity.GoodsEntity;
+import com.kmall.admin.entity.MerchEntity;
+import com.kmall.admin.entity.ProductStoreRelaEntity;
+import com.kmall.admin.entity.StoreEntity;
+import com.kmall.admin.entity.alarm.Mall2ShippingReminderAlarmEntity;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
-import java.util.List;
-import java.util.Map;
+import java.math.BigDecimal;
+import java.util.*;
 
 import com.kmall.admin.dao.alarm.Mall2OrderingEarlyWarningRemindsDao;
 import com.kmall.admin.entity.alarm.Mall2OrderingEarlyWarningRemindsEntity;
 import com.kmall.admin.service.alarm.Mall2OrderingEarlyWarningRemindsService;
+import org.springframework.transaction.annotation.Transactional;
 
 /**
  * 订货提醒预警表Service实现类
@@ -22,6 +32,15 @@ public class Mall2OrderingEarlyWarningRemindsServiceImpl implements Mall2Orderin
     @Autowired
     private Mall2OrderingEarlyWarningRemindsDao mall2OrderingEarlyWarningRemindsDao;
 
+    @Autowired
+    private MerchDao merchDao; // 商户
+    @Autowired
+    private StoreDao storeDao; // 门店
+    @Autowired
+    private ProductStoreRelaDao productStoreRelaDao ; // 门店商品
+    @Autowired
+    private GoodsDao goodsDao; // 商品
+
     @Override
     public Mall2OrderingEarlyWarningRemindsEntity queryObject(Integer moewrId) {
         return mall2OrderingEarlyWarningRemindsDao.queryObject(moewrId);
@@ -56,4 +75,117 @@ public class Mall2OrderingEarlyWarningRemindsServiceImpl implements Mall2Orderin
     public int deleteBatch(Integer[]moewrIds) {
         return mall2OrderingEarlyWarningRemindsDao.deleteBatch(moewrIds);
     }
+
+    @Override
+    @Transactional
+    public void orderReminds() {
+        // 查询所有商户
+        List<MerchEntity> merchEntities = merchDao.queryList(new HashMap<String, Object>());
+
+
+        // 遍历商户集合,查询商户下所有的门店
+        for(MerchEntity merchEntity : merchEntities) {
+            String merchSn = merchEntity.getMerchSn();
+            Map<String,Object> goodsParam = new HashMap<>();
+            goodsParam.put("merchSn", merchSn);
+            // 查询该商户下所有商品
+            List<GoodsEntity> goodsEntities = goodsDao.queryList(goodsParam);
+            if(goodsEntities == null ||goodsEntities.size() == 0){
+                continue;
+            }
+            goodsParam = null;
+
+
+            // 需要新增的记录集合
+            List<Mall2OrderingEarlyWarningRemindsEntity> insertRemiderList = new ArrayList<>();
+            // 需要更新的记录集合
+            List<Mall2OrderingEarlyWarningRemindsEntity> updateRemiderList = new ArrayList<>();
+
+            // 遍历商户集合,根据sku跟商户编号所有门店商品
+            for(GoodsEntity goodsEntity : goodsEntities) {
+                String goodsSn = goodsEntity.getGoodsSn();
+                Map<String,Object> storeRelaParam = new HashMap<>();
+                storeRelaParam.put("goodsSn",goodsSn);
+                storeRelaParam.put("merchSn",merchSn);
+                List<ProductStoreRelaEntity> productStoreRelaEntities = productStoreRelaDao.queryList(storeRelaParam);
+                if(productStoreRelaEntities == null || productStoreRelaEntities.size() == 0 ){
+                    continue;
+                }
+                storeRelaParam = null;
+
+                // 获取商品库存
+                Integer goodsNumber = goodsEntity.getGoodsNumber();
+
+                // 总库存
+                Integer totalNum = goodsNumber ;
+                // 总平均销售量
+                Integer totalSellVolumn = 0;
+
+                // 遍历商品集合,计算商品的平均库存
+                for(ProductStoreRelaEntity productStoreRelaEntity : productStoreRelaEntities){
+                    // 商品id
+                    Long goodsId = productStoreRelaEntity.getGoodsId();
+                    // 该商品的销售量
+                    Integer sellVolume = productStoreRelaEntity.getSellVolume();
+                    // 获取当前时间
+                    Date date = new Date();
+                    // 获取该商品的创建时间
+                    Date createTime = productStoreRelaEntity.getCreateTime();
+                    // 相差的天数
+                    int days = (int) ((date.getTime() - createTime.getTime()) / (1000*3600*24));
+                    days = days == 0? 1 : days;
+                    // 一周平均销售量
+                    Integer avaerageSellVolume = new BigDecimal(sellVolume).divide(new BigDecimal(days),2, BigDecimal.ROUND_HALF_UP).multiply(new BigDecimal(7))
+                            .setScale(0, BigDecimal.ROUND_HALF_UP).intValue();
+                    totalSellVolumn += avaerageSellVolume;
+                    // 该商品的库存
+                    Integer stockNum = productStoreRelaEntity.getStockNum();
+                    totalNum += stockNum;
+                }
+
+                if(totalNum <= totalSellVolumn){
+                    Mall2OrderingEarlyWarningRemindsEntity orderingEarlyWarningRemindsEntity = mall2OrderingEarlyWarningRemindsDao.queryByGoodsId(goodsEntity.getId());
+                    if(orderingEarlyWarningRemindsEntity == null){
+                        orderingEarlyWarningRemindsEntity = new Mall2OrderingEarlyWarningRemindsEntity();
+                        orderingEarlyWarningRemindsEntity.setAverageSales(new BigDecimal(totalSellVolumn));
+                        orderingEarlyWarningRemindsEntity.setTotalNum(totalNum);
+                        orderingEarlyWarningRemindsEntity.setGoodsId(goodsEntity.getId().intValue());
+                        orderingEarlyWarningRemindsEntity.setGoodsName(goodsEntity.getName());
+                        orderingEarlyWarningRemindsEntity.setAlarmType("00");
+                        orderingEarlyWarningRemindsEntity.setAlarmTime(new Date());
+                        orderingEarlyWarningRemindsEntity.setIsWarning(1);
+                        orderingEarlyWarningRemindsEntity.setCreateTime(new Date());
+
+                        insertRemiderList.add(orderingEarlyWarningRemindsEntity);
+                    }else{
+                        orderingEarlyWarningRemindsEntity.setAlarmTime(new Date());
+                        orderingEarlyWarningRemindsEntity.setAverageSales(new BigDecimal(totalSellVolumn));
+                        orderingEarlyWarningRemindsEntity.setTotalNum(totalNum);
+                        orderingEarlyWarningRemindsEntity.setIsWarning(1);
+                        orderingEarlyWarningRemindsEntity.setModTime(new Date());
+
+                        updateRemiderList.add(orderingEarlyWarningRemindsEntity);
+                    }
+
+                }else{
+                    Mall2OrderingEarlyWarningRemindsEntity orderingEarlyWarningRemindsEntity = mall2OrderingEarlyWarningRemindsDao.queryByGoodsId(goodsEntity.getId());
+                    if( orderingEarlyWarningRemindsEntity != null){
+                        orderingEarlyWarningRemindsEntity.setIsWarning(0);
+                        orderingEarlyWarningRemindsEntity.setModTime(new Date());
+                        updateRemiderList.add(orderingEarlyWarningRemindsEntity);
+                    }
+                }
+            }
+
+            if(insertRemiderList != null && insertRemiderList.size() > 0) {
+                mall2OrderingEarlyWarningRemindsDao.insertBatch(insertRemiderList);
+            }
+            if(updateRemiderList != null && updateRemiderList.size() > 0) {
+                mall2OrderingEarlyWarningRemindsDao.updateBatch(updateRemiderList);
+            }
+
+            insertRemiderList = null;
+            updateRemiderList = null;
+        }
+    }
 }

+ 123 - 2
kmall-admin/src/main/java/com/kmall/admin/service/impl/alarm/Mall2ShippingReminderAlarmServiceImpl.java

@@ -1,14 +1,22 @@
 package com.kmall.admin.service.impl.alarm;
 
+import com.kmall.admin.dao.MerchDao;
+import com.kmall.admin.dao.ProductStoreRelaDao;
+import com.kmall.admin.dao.StoreDao;
+import com.kmall.admin.entity.MerchEntity;
+import com.kmall.admin.entity.ProductStoreRelaEntity;
+import com.kmall.admin.entity.StoreEntity;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
-import java.util.List;
-import java.util.Map;
+import java.math.BigDecimal;
+import java.text.SimpleDateFormat;
+import java.util.*;
 
 import com.kmall.admin.dao.alarm.Mall2ShippingReminderAlarmDao;
 import com.kmall.admin.entity.alarm.Mall2ShippingReminderAlarmEntity;
 import com.kmall.admin.service.alarm.Mall2ShippingReminderAlarmService;
+import org.springframework.transaction.annotation.Transactional;
 
 /**
  * 出货提醒预警表Service实现类
@@ -22,6 +30,16 @@ public class Mall2ShippingReminderAlarmServiceImpl implements Mall2ShippingRemin
     @Autowired
     private Mall2ShippingReminderAlarmDao mall2ShippingReminderAlarmDao;
 
+
+    @Autowired
+    private MerchDao merchDao; // 商户
+    @Autowired
+    private StoreDao storeDao; // 门店
+    @Autowired
+    private ProductStoreRelaDao productStoreRelaDao ; // 门店商品
+
+
+
     @Override
     public Mall2ShippingReminderAlarmEntity queryObject(Integer msraId) {
         return mall2ShippingReminderAlarmDao.queryObject(msraId);
@@ -56,4 +74,107 @@ public class Mall2ShippingReminderAlarmServiceImpl implements Mall2ShippingRemin
     public int deleteBatch(Integer[]msraIds) {
         return mall2ShippingReminderAlarmDao.deleteBatch(msraIds);
     }
+
+    /**
+     * 查询商品是否需要出货提醒
+     */
+    @Override
+    @Transactional
+    public void shippingReminds() {
+
+        // 查询所有商户
+        List<MerchEntity> merchEntities = merchDao.queryList(new HashMap<String, Object>());
+
+        // 遍历商户集合,查询商户下所有的门店
+        for(MerchEntity merchEntity : merchEntities){
+            Map<String,Object> storeParam = new HashMap();
+            storeParam.put("merchSn",merchEntity.getMerchSn());
+            storeParam.put("isValid","0");
+            List<StoreEntity> storeEntityList = storeDao.queryList(storeParam);
+            if(storeEntityList == null || storeEntityList.size() == 0){
+                continue;
+            }
+            storeParam = null;
+
+            // 需要新增的记录集合
+            List<Mall2ShippingReminderAlarmEntity> insertRemiderList = new ArrayList<>();
+            // 需要更新的记录集合
+            List<Mall2ShippingReminderAlarmEntity> updateRemiderList = new ArrayList<>();
+
+            // 遍历门店集合,查询门店下所有商品
+            for(StoreEntity storeEntity : storeEntityList){
+                Long storeId = storeEntity.getId();
+                List<ProductStoreRelaEntity> productStoreRelaEntities = productStoreRelaDao.queryByStoreId(storeId);
+                // 遍历商品集合,计算商品的平均销量
+                for(ProductStoreRelaEntity productStoreRelaEntity : productStoreRelaEntities){
+                    // 商品id
+                    Long goodsId = productStoreRelaEntity.getGoodsId();
+                    // 该商品的销售量
+                    Integer sellVolume = productStoreRelaEntity.getSellVolume();
+                    // 获取当前时间
+                    Date date = new Date();
+                    // 获取该商品的创建时间
+                    Date createTime = productStoreRelaEntity.getCreateTime();
+                    // 相差的天数
+                    int days = (int) ((date.getTime() - createTime.getTime()) / (1000*3600*24));
+                    days = days == 0? 1 : days;
+                    // 一周平均销售量
+                    Integer avaerageSellVolume = new BigDecimal(sellVolume).divide(new BigDecimal(days),2, BigDecimal.ROUND_HALF_UP).multiply(new BigDecimal(7))
+                            .setScale(0, BigDecimal.ROUND_HALF_UP).intValue();
+                    // 该商品的库存
+                    Integer stockNum = productStoreRelaEntity.getStockNum();
+                    if(stockNum <= avaerageSellVolume){
+                        Mall2ShippingReminderAlarmEntity mall2ShippingReminderAlarmEntity = mall2ShippingReminderAlarmDao.queryByGoodsIdAndStoreId(goodsId,storeId);
+                        if(mall2ShippingReminderAlarmEntity == null){
+                            mall2ShippingReminderAlarmEntity = new Mall2ShippingReminderAlarmEntity();
+                            mall2ShippingReminderAlarmEntity.setGoodsId(goodsId.intValue());
+                            mall2ShippingReminderAlarmEntity.setGoodsName(productStoreRelaEntity.getGoodsName());
+                            mall2ShippingReminderAlarmEntity.setAverageSales(new BigDecimal(avaerageSellVolume));
+                            mall2ShippingReminderAlarmEntity.setStoreId(storeId.intValue());
+                            mall2ShippingReminderAlarmEntity.setStoreName(storeEntity.getStoreName());
+                            mall2ShippingReminderAlarmEntity.setSku(productStoreRelaEntity.getSku());
+                            mall2ShippingReminderAlarmEntity.setStockNum(productStoreRelaEntity.getStockNum());
+                            mall2ShippingReminderAlarmEntity.setAlarmType("00");
+                            mall2ShippingReminderAlarmEntity.setAlarmTime(new Date());
+                            mall2ShippingReminderAlarmEntity.setIsWarning(1); // 1.为预警 0.为不预警
+                            mall2ShippingReminderAlarmEntity.setCreateTime(new Date());
+
+                            insertRemiderList.add(mall2ShippingReminderAlarmEntity);
+                        }else{
+                            mall2ShippingReminderAlarmEntity.setAverageSales(new BigDecimal(avaerageSellVolume));
+                            mall2ShippingReminderAlarmEntity.setStockNum(productStoreRelaEntity.getStockNum());
+                            mall2ShippingReminderAlarmEntity.setIsWarning(1);
+                            mall2ShippingReminderAlarmEntity.setAlarmTime(new Date());
+                            mall2ShippingReminderAlarmEntity.setModTime(new Date());
+
+                            updateRemiderList.add(mall2ShippingReminderAlarmEntity);
+                        }
+                    }else{
+                        Mall2ShippingReminderAlarmEntity mall2ShippingReminderAlarmEntity = mall2ShippingReminderAlarmDao.queryByGoodsIdAndStoreId(goodsId,storeId);
+                        if( mall2ShippingReminderAlarmEntity != null){
+                            mall2ShippingReminderAlarmEntity.setIsWarning(0);
+                            mall2ShippingReminderAlarmEntity.setModTime(new Date());
+                            updateRemiderList.add(mall2ShippingReminderAlarmEntity);
+                        }
+                    }
+
+                }
+            }
+
+            if(insertRemiderList != null && insertRemiderList.size() > 0) {
+                mall2ShippingReminderAlarmDao.insertBatch(insertRemiderList);
+            }
+            if(updateRemiderList != null && updateRemiderList.size() > 0) {
+                mall2ShippingReminderAlarmDao.updateBatch(updateRemiderList);
+            }
+
+            insertRemiderList = null;
+            updateRemiderList = null;
+
+        }
+
+
+
+
+    }
 }

+ 115 - 0
kmall-admin/src/main/java/com/kmall/admin/service/impl/mk/Mk2GoodsTopicPriceServiceImpl.java

@@ -1,14 +1,39 @@
 package com.kmall.admin.service.impl.mk;
 
+import com.google.common.collect.ImmutableBiMap;
+import com.google.common.collect.Maps;
+import com.kmall.admin.dao.GoodsDao;
+import com.kmall.admin.dao.mk.Mk2GoodsTopicHistoryPriceDao;
+import com.kmall.admin.dao.mk.store.StoreTopicDao;
+import com.kmall.admin.dto.StoreGoodsDto;
+import com.kmall.admin.dto.StoreTopicGoodsDto;
+import com.kmall.admin.entity.*;
+import com.kmall.admin.entity.mk.Mk2GoodsTopicHistoryPriceEntity;
+import com.kmall.admin.entity.mk.store.StoreTopicEntity;
+import com.kmall.admin.fromcomm.entity.SysUserEntity;
+import com.kmall.admin.utils.ShiroUtils;
+import com.kmall.api.util.StockUtil;
+import com.kmall.common.constant.Dict;
+import com.kmall.common.utils.MapBeanUtil;
+import com.kmall.common.utils.R;
+import com.kmall.common.utils.RRException;
+import com.kmall.common.utils.ValidatorUtil;
+import org.apache.commons.lang.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
+import java.math.BigDecimal;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.util.ArrayList;
+import java.util.Date;
 import java.util.List;
 import java.util.Map;
 
 import com.kmall.admin.dao.mk.Mk2GoodsTopicPriceDao;
 import com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity;
 import com.kmall.admin.service.mk.Mk2GoodsTopicPriceService;
+import org.springframework.transaction.annotation.Transactional;
 
 /**
  * 商品活动价格表Service实现类
@@ -21,6 +46,10 @@ import com.kmall.admin.service.mk.Mk2GoodsTopicPriceService;
 public class Mk2GoodsTopicPriceServiceImpl implements Mk2GoodsTopicPriceService {
     @Autowired
     private Mk2GoodsTopicPriceDao mk2GoodsTopicPriceDao;
+    @Autowired
+    private StoreTopicDao storeTopicDao;
+    @Autowired
+    private Mk2GoodsTopicHistoryPriceDao goodsTopicHistoryPriceDao;
 
     @Override
     public Mk2GoodsTopicPriceEntity queryObject(Integer mgthpId) {
@@ -56,4 +85,90 @@ public class Mk2GoodsTopicPriceServiceImpl implements Mk2GoodsTopicPriceService
     public int deleteBatch(Integer[]mgthpIds) {
         return mk2GoodsTopicPriceDao.deleteBatch(mgthpIds);
     }
+
+    @Override
+    @Transactional
+    public void uploadExcel(List<StoreTopicGoodsDto> storeTopicGoodsDtoList) throws ParseException {
+
+
+        if (storeTopicGoodsDtoList != null && storeTopicGoodsDtoList.size() > 0) {
+            StoreTopicEntity storeTopicEntity = null;
+
+            List<Mk2GoodsTopicPriceEntity> goodsTopicPriceEntityList = new ArrayList();
+            List<Mk2GoodsTopicHistoryPriceEntity> goodsTopicHistoryPriceEntityList = new ArrayList();
+
+            SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
+
+            for (int i = 0; i < storeTopicGoodsDtoList.size(); i++) {
+                StoreTopicGoodsDto storeTopicGoodsDto = storeTopicGoodsDtoList.get(i);
+                Map<String, Object> valideDate = MapBeanUtil.fromObject(storeTopicGoodsDto);
+                ImmutableBiMap.Builder builder = new ImmutableBiMap.Builder();
+                builder.put("topic", "活动主题");
+                builder.put("topicName", "活动名称");
+                builder.put("merchSn", "商品编码");
+                builder.put("topicGoodsSku", "活动商品编码");
+                builder.put("topicGoodsPrice", "活动价格");
+                builder.put("topicBeginTime", "活动开始时间");
+                builder.put("topicEndTime", "活动结束时间");
+
+                R r = ValidatorUtil.isEmpty(builder.build(), valideDate);
+                if (Integer.valueOf(r.get("code").toString()) != 0) {
+                    throw new RRException(r.get("msg").toString());
+                }
+                // 1.保存门店活动
+                if(storeTopicEntity == null){
+                    storeTopicEntity = new StoreTopicEntity();
+                    storeTopicEntity.setTitle(storeTopicGoodsDto.getTopic()); // 主题
+                    storeTopicEntity.setContent(storeTopicGoodsDto.getTopicContent()); // 内容
+                    storeTopicEntity.setSubtitle(storeTopicGoodsDto.getTopic());// 子标题
+                    storeTopicEntity.setPromTypeId(10); // 类别
+                    storeTopicEntity.setPromTypeName("每周活动");
+                    storeTopicEntity.setStoreId(Integer.parseInt(storeTopicGoodsDto.getShopSn()));
+                    storeTopicEntity.setIsValid("0");
+                    storeTopicDao.save(storeTopicEntity);
+                }
+
+                // 根据sku查询商品
+
+                // 2.保存门店商品价格
+                Mk2GoodsTopicPriceEntity goodsTopicPriceEntity = new Mk2GoodsTopicPriceEntity() ;
+                goodsTopicPriceEntity.setTopicId(storeTopicEntity.getId());
+                goodsTopicPriceEntity.setTopicType(storeTopicEntity.getPromTypeName());
+                goodsTopicPriceEntity.setTopicPrice(new BigDecimal(storeTopicGoodsDto.getTopicGoodsPrice()));
+                goodsTopicPriceEntity.setTopicName(storeTopicGoodsDto.getTopicName());
+                goodsTopicPriceEntity.setTopicContent(storeTopicGoodsDto.getTopicContent());
+                goodsTopicPriceEntity.setTopicGoodsSku(storeTopicGoodsDto.getTopicGoodsSku());
+                goodsTopicPriceEntity.setTopicBeginTime(format.parse(storeTopicGoodsDto.getTopicBeginTime()));
+                goodsTopicPriceEntity.setTopicEndTime((format.parse(storeTopicGoodsDto.getTopicEndTime())));
+                goodsTopicPriceEntity.setImportTime(new Date());
+                goodsTopicPriceEntityList.add(goodsTopicPriceEntity);
+
+                // 3.保存门店商品历史价格表
+                Mk2GoodsTopicHistoryPriceEntity goodsTopicHistoryPriceEntity = new Mk2GoodsTopicHistoryPriceEntity();
+                goodsTopicHistoryPriceEntity.setTopicId(storeTopicEntity.getId());
+                goodsTopicHistoryPriceEntity.setTopicType(storeTopicEntity.getPromTypeName());
+                goodsTopicHistoryPriceEntity.setTopicPrice(new BigDecimal(storeTopicGoodsDto.getTopicGoodsPrice()));
+                goodsTopicHistoryPriceEntity.setTopicGoodsSku(storeTopicGoodsDto.getTopicGoodsSku());
+                goodsTopicHistoryPriceEntity.setTopicName(storeTopicGoodsDto.getTopicName());
+                goodsTopicHistoryPriceEntity.setTopicContent(storeTopicGoodsDto.getTopicContent());
+                goodsTopicHistoryPriceEntity.setTopicBeginTime(format.parse(storeTopicGoodsDto.getTopicBeginTime()));
+                goodsTopicHistoryPriceEntity.setTopicEndTime((format.parse(storeTopicGoodsDto.getTopicEndTime())));
+                goodsTopicHistoryPriceEntityList.add(goodsTopicHistoryPriceEntity);
+
+
+            }
+            if(goodsTopicPriceEntityList != null && goodsTopicPriceEntityList.size() > 0) {
+                mk2GoodsTopicPriceDao.saveBatch(goodsTopicPriceEntityList);
+            }
+            if(goodsTopicHistoryPriceEntityList != null && goodsTopicHistoryPriceEntityList.size() > 0) {
+                goodsTopicHistoryPriceDao.saveBatch(goodsTopicHistoryPriceEntityList);
+            }
+
+
+
+        }
+
+
+
+    }
 }

+ 4 - 0
kmall-admin/src/main/java/com/kmall/admin/service/mk/Mk2GoodsTopicPriceService.java

@@ -1,7 +1,9 @@
 package com.kmall.admin.service.mk;
 
+import com.kmall.admin.dto.StoreTopicGoodsDto;
 import com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity;
 
+import java.text.ParseException;
 import java.util.List;
 import java.util.Map;
 
@@ -69,4 +71,6 @@ public interface Mk2GoodsTopicPriceService {
      * @return 删除条数
      */
     int deleteBatch(Integer[] mgthpIds);
+
+    void uploadExcel(List<StoreTopicGoodsDto> storeTopicGoodsDtoList) throws ParseException;
 }

+ 45 - 0
kmall-admin/src/main/java/com/kmall/admin/task/OrderRemindsTask.java

@@ -0,0 +1,45 @@
+package com.kmall.admin.task;
+
+import com.kmall.admin.fromcomm.service.SysUserService;
+import com.kmall.admin.service.alarm.Mall2OrderingEarlyWarningRemindsService;
+import com.kmall.admin.websocket.WebSocketServer;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.scheduling.annotation.EnableScheduling;
+import org.springframework.scheduling.annotation.Scheduled;
+import org.springframework.stereotype.Component;
+
+/**
+ * 订货提醒定时器
+ * @author Scott
+ * @email
+ * @date 2016年11月30日 下午1:34:24
+ */
+@Component("orderRemindsTask")
+public class OrderRemindsTask {
+    private Logger logger = LoggerFactory.getLogger(getClass());
+
+    @Autowired
+    private Mall2OrderingEarlyWarningRemindsService orderingEarlyWarningRemindsService;
+
+
+
+    @Scheduled(cron = "0/30 * * * * ?")
+    public void orderReminds() {
+        logger.info("订货提醒查询-----------------" );
+        try {
+            orderingEarlyWarningRemindsService.orderReminds();
+        } catch (Exception e) {
+            e.printStackTrace();
+            logger.info("订货提醒查询异常-----------------原因:"+e.getMessage() );
+        }
+
+        logger.info("订货提醒查询成功-----------" );
+
+    }
+
+
+
+
+}

+ 44 - 0
kmall-admin/src/main/java/com/kmall/admin/task/ShippingRemindsTask.java

@@ -0,0 +1,44 @@
+package com.kmall.admin.task;
+
+import com.kmall.admin.service.alarm.Mall2OrderingEarlyWarningRemindsService;
+import com.kmall.admin.service.alarm.Mall2ShippingReminderAlarmService;
+import com.kmall.admin.websocket.WebSocketServer;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.scheduling.annotation.Scheduled;
+import org.springframework.stereotype.Component;
+
+/**
+ * 出货提醒定时器
+ * @author Scott
+ * @email
+ * @date 2016年11月30日 下午1:34:24
+ */
+@Component("shippingRemindsTask")
+public class ShippingRemindsTask {
+    private Logger logger = LoggerFactory.getLogger(getClass());
+
+    @Autowired
+    private Mall2ShippingReminderAlarmService shippingReminderAlarmService;
+
+
+
+    @Scheduled(cron = "0/30 * * * * ?")
+    public void shippingReminds() {
+        logger.info("出货提醒查询-----------------" );
+        try {
+            shippingReminderAlarmService.shippingReminds();
+        } catch (Exception e) {
+            e.printStackTrace();
+            logger.info("出货提醒查询异常-----------------原因:"+e.getMessage() );
+        }
+
+        logger.info("出货提醒查询成功-----------" );
+
+    }
+
+
+
+
+}

+ 25 - 0
kmall-admin/src/main/resources/XmlTemplate/StoreTopicDtoList.xml

@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<workbook>
+    <worksheet name="Sheet1">
+        <section startRow="0" endRow="1"/>
+        <loop startRow="1" endRow="1" items="storeTopicGoodsDtoList" var="storeTopicGoodsDto"
+              varType="com.kmall.admin.dto.StoreTopicGoodsDto">
+            <section startRow="1" endRow="1">
+                <mapping row="1" col="0">storeTopicGoodsDto.topic</mapping>
+                <mapping row="1" col="1">storeTopicGoodsDto.topicName</mapping>
+                <mapping row="1" col="2">storeTopicGoodsDto.topicContent</mapping>
+                <mapping row="1" col="3">storeTopicGoodsDto.topicGoodsSku</mapping>
+                <mapping row="1" col="4">storeTopicGoodsDto.topicGoodsPrice</mapping>
+                <mapping row="1" col="5">storeTopicGoodsDto.topicBeginTime</mapping>
+                <mapping row="1" col="6">storeTopicGoodsDto.topicEndTime</mapping>
+                <mapping row="1" col="7">storeTopicGoodsDto.merchSn</mapping>
+                <mapping row="1" col="8">storeTopicGoodsDto.shopSn</mapping>
+            </section>
+            <loopbreakcondition>
+                <rowcheck offset="0">
+                    <cellcheck offset="0"></cellcheck>
+                </rowcheck>
+            </loopbreakcondition>
+        </loop>
+    </worksheet>
+</workbook>

+ 15 - 0
kmall-admin/src/main/resources/mybatis/mapper/GoodsDao.xml

@@ -605,4 +605,19 @@
     <select id="queryMaxId" resultType="java.lang.Long" parameterType="map">
         SELECT MAX(id) FROM mall_goods
     </select>
+    <select id="searchGoodsPanoramaDtoByKeyword" resultType="com.kmall.admin.dto.GoodsPanoramaDto">
+        SELECT
+            g.id id,g.name `name`,g.name simpleName,g.ciq_prod_model ciqProdModel,
+            g.goods_unit goodsBasicUnit,g.category_id categoryId,c.name categoryName,
+            g.goods_unit goodsPurchaseUnit,g.supplier_id supplierId,s.child_supplier_name supplierName,
+            g.prod_barcode prodBarcode,g.plu plu,g.goods_sn goodsSn,g.brand brand
+        FROM
+            mall_goods g
+            INNER JOIN mall_category c
+            INNER JOIN mall_supplier s
+        WHERE
+            g.category_id = c.id
+            and g.supplier_id = s.id
+            AND (g.goods_sn=#{keyword} OR g.prod_barcode=#{keyword})
+    </select>
 </mapper>

+ 147 - 0
kmall-admin/src/main/resources/mybatis/mapper/GoodsTransportInfoDao.xml

@@ -0,0 +1,147 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+
+<mapper namespace="com.kmall.admin.dao.GoodsTransportInfoDao">
+
+    <resultMap type="com.kmall.admin.entity.GoodsTransportInfoEntity" id="goodsTransportInfoMap">
+        <result property="transId" column="trans_id"/>
+        <result property="transportType" column="transport_type"/>
+        <result property="transportTool" column="transport_tool"/>
+        <result property="thirdMerchSn" column="third_merch_sn"/>
+        <result property="wayStatus" column="way_status"/>
+        <result property="origin" column="origin"/>
+        <result property="destination" column="destination"/>
+        <result property="startTime" column="start_time"/>
+        <result property="arrivalTime" column="arrival_time"/>
+        <result property="createrSn" column="creater_sn"/>
+        <result property="createTime" column="create_time"/>
+        <result property="moderSn" column="moder_sn"/>
+        <result property="modTime" column="mod_time"/>
+        <result property="tstm" column="tstm"/>
+    </resultMap>
+
+	<select id="queryObject" resultType="com.kmall.admin.entity.GoodsTransportInfoEntity">
+		select
+			`trans_id`,
+			`transport_type`,
+			`transport_tool`,
+			`third_merch_sn`,
+			`way_status`,
+			`origin`,
+			`destination`,
+			`start_time`,
+			`arrival_time`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`
+		from mall_goods_transport_info
+		where trans_id = #{id}
+	</select>
+
+	<select id="queryList" resultType="com.kmall.admin.entity.GoodsTransportInfoEntity">
+		select
+    		`trans_id`,
+    		`transport_type`,
+    		`transport_tool`,
+    		`third_merch_sn`,
+    		`way_status`,
+    		`origin`,
+    		`destination`,
+    		`start_time`,
+    		`arrival_time`,
+    		`creater_sn`,
+    		`create_time`,
+    		`moder_sn`,
+    		`mod_time`,
+    		`tstm`
+		from mall_goods_transport_info
+		WHERE 1=1
+		<if test="name != null and name.trim() != ''">
+			AND name LIKE concat('%',#{name},'%')
+		</if>
+        <choose>
+            <when test="sidx != null and sidx.trim() != ''">
+                order by ${sidx} ${order}
+            </when>
+			<otherwise>
+                order by trans_id desc
+			</otherwise>
+        </choose>
+		<if test="offset != null and limit != null">
+			limit #{offset}, #{limit}
+		</if>
+	</select>
+	
+ 	<select id="queryTotal" resultType="int">
+		select count(*) from mall_goods_transport_info
+		WHERE 1=1
+        <if test="name != null and name.trim() != ''">
+            AND name LIKE concat('%',#{name},'%')
+        </if>
+	</select>
+
+	<insert id="save" parameterType="com.kmall.admin.entity.GoodsTransportInfoEntity" useGeneratedKeys="true" keyProperty="transId">
+		insert into mall_goods_transport_info(
+			`transport_type`,
+			`transport_tool`,
+			`third_merch_sn`,
+			`way_status`,
+			`origin`,
+			`destination`,
+			`start_time`,
+			`arrival_time`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`)
+		values(
+			#{transportType},
+			#{transportTool},
+			#{thirdMerchSn},
+			#{wayStatus},
+			#{origin},
+			#{destination},
+			#{startTime},
+			#{arrivalTime},
+			#{createrSn},
+			#{createTime},
+			#{moderSn},
+			#{modTime},
+			#{tstm})
+	</insert>
+	 
+	<update id="update" parameterType="com.kmall.admin.entity.GoodsTransportInfoEntity">
+		update mall_goods_transport_info 
+		<set>
+			<if test="transportType != null">`transport_type` = #{transportType}, </if>
+			<if test="transportTool != null">`transport_tool` = #{transportTool}, </if>
+			<if test="thirdMerchSn != null">`third_merch_sn` = #{thirdMerchSn}, </if>
+			<if test="wayStatus != null">`way_status` = #{wayStatus}, </if>
+			<if test="origin != null">`origin` = #{origin}, </if>
+			<if test="destination != null">`destination` = #{destination}, </if>
+			<if test="startTime != null">`start_time` = #{startTime}, </if>
+			<if test="arrivalTime != null">`arrival_time` = #{arrivalTime}, </if>
+			<if test="createrSn != null">`creater_sn` = #{createrSn}, </if>
+			<if test="createTime != null">`create_time` = #{createTime}, </if>
+			<if test="moderSn != null">`moder_sn` = #{moderSn}, </if>
+			<if test="modTime != null">`mod_time` = #{modTime}, </if>
+			<if test="tstm != null">`tstm` = #{tstm}</if>
+		</set>
+		where trans_id = #{transId}
+	</update>
+	
+	<delete id="delete">
+		delete from mall_goods_transport_info where trans_id = #{value}
+	</delete>
+	
+	<delete id="deleteBatch">
+		delete from mall_goods_transport_info where trans_id in 
+		<foreach item="transId" collection="array" open="(" separator="," close=")">
+			#{transId}
+		</foreach>
+	</delete>
+
+</mapper>

+ 159 - 0
kmall-admin/src/main/resources/mybatis/mapper/GoodsTransportInfoDetailDao.xml

@@ -0,0 +1,159 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+
+<mapper namespace="com.kmall.admin.dao.GoodsTransportInfoDetailDao">
+
+    <resultMap type="com.kmall.admin.entity.GoodsTransportInfoDetailEntity" id="goodsTransportInfoDetailMap">
+        <result property="transItemId" column="trans_item_id"/>
+        <result property="wayStatus" column="way_status"/>
+        <result property="sku" column="sku"/>
+        <result property="supplierId" column="supplier_id"/>
+        <result property="originCountry" column="origin_country"/>
+        <result property="num" column="num"/>
+        <result property="createrSn" column="creater_sn"/>
+        <result property="createTime" column="create_time"/>
+        <result property="moderSn" column="moder_sn"/>
+        <result property="modTime" column="mod_time"/>
+        <result property="tstm" column="tstm"/>
+    </resultMap>
+
+	<select id="queryObject" resultType="com.kmall.admin.entity.GoodsTransportInfoDetailEntity">
+		select
+			`trans_item_id`,
+			`way_status`,
+			`sku`,
+			`supplier_id`,
+			`origin_country`,
+			`num`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`
+		from mall_goods_transport_info_detail
+		where trans_item_id = #{id}
+	</select>
+
+	<select id="queryList" resultType="com.kmall.admin.entity.GoodsTransportInfoDetailEntity">
+		select
+    		`trans_item_id`,
+    		`way_status`,
+    		`sku`,
+    		`supplier_id`,
+    		`origin_country`,
+    		`num`,
+    		`creater_sn`,
+    		`create_time`,
+    		`moder_sn`,
+    		`mod_time`,
+    		`tstm`
+		from mall_goods_transport_info_detail
+		WHERE 1=1
+		<if test="name != null and name.trim() != ''">
+			AND name LIKE concat('%',#{name},'%')
+		</if>
+        <choose>
+            <when test="sidx != null and sidx.trim() != ''">
+                order by ${sidx} ${order}
+            </when>
+			<otherwise>
+                order by trans_item_id desc
+			</otherwise>
+        </choose>
+		<if test="offset != null and limit != null">
+			limit #{offset}, #{limit}
+		</if>
+	</select>
+	
+ 	<select id="queryTotal" resultType="int">
+		select count(*) from mall_goods_transport_info_detail
+		WHERE 1=1
+        <if test="name != null and name.trim() != ''">
+            AND name LIKE concat('%',#{name},'%')
+        </if>
+	</select>
+	<select id="searchListByStatusAndSku" resultType="com.kmall.admin.entity.GoodsTransportInfoDetailEntity">
+		select * from mall_goods_transport_info_detail where 1=1
+		<if test="wayStatus!=null">
+			AND way_status=#{wayStatus}
+		</if>
+		<if test="sku!=null and sku.trim() != ''">
+			AND sku=#{sku}
+		</if>
+		<choose>
+			<when test="query.sidx != null and query.sidx.trim() != ''">
+				order by ${query.sidx} ${query.order}
+			</when>
+			<otherwise>
+				order by trans_item_id desc
+			</otherwise>
+		</choose>
+		<if test="query.offset != null and query.limit != null">
+			limit #{query.offset}, #{query.limit}
+		</if>
+	</select>
+	<select id="queryTotalByStatusAndSku" resultType="java.lang.Integer">
+		select count(*) from mall_goods_transport_info_detail
+		WHERE 1=1
+		<if test="wayStatus!=null">
+			AND way_status=#{wayStatus}
+		</if>
+		<if test="sku!=null and sku.trim() != ''">
+			AND sku=#{sku}
+		</if>
+	</select>
+
+	<insert id="save" parameterType="com.kmall.admin.entity.GoodsTransportInfoDetailEntity" useGeneratedKeys="true" keyProperty="transItemId">
+		insert into mall_goods_transport_info_detail(
+			`way_status`,
+			`sku`,
+			`supplier_id`,
+			`origin_country`,
+			`num`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`)
+		values(
+			#{wayStatus},
+			#{sku},
+			#{supplierId},
+			#{originCountry},
+			#{num},
+			#{createrSn},
+			#{createTime},
+			#{moderSn},
+			#{modTime},
+			#{tstm})
+	</insert>
+	 
+	<update id="update" parameterType="com.kmall.admin.entity.GoodsTransportInfoDetailEntity">
+		update mall_goods_transport_info_detail 
+		<set>
+			<if test="wayStatus != null">`way_status` = #{wayStatus}, </if>
+			<if test="sku != null">`sku` = #{sku}, </if>
+			<if test="supplierId != null">`supplier_id` = #{supplierId}, </if>
+			<if test="originCountry != null">`origin_country` = #{originCountry}, </if>
+			<if test="num != null">`num` = #{num}, </if>
+			<if test="createrSn != null">`creater_sn` = #{createrSn}, </if>
+			<if test="createTime != null">`create_time` = #{createTime}, </if>
+			<if test="moderSn != null">`moder_sn` = #{moderSn}, </if>
+			<if test="modTime != null">`mod_time` = #{modTime}, </if>
+			<if test="tstm != null">`tstm` = #{tstm}</if>
+		</set>
+		where trans_item_id = #{transItemId}
+	</update>
+	
+	<delete id="delete">
+		delete from mall_goods_transport_info_detail where trans_item_id = #{value}
+	</delete>
+	
+	<delete id="deleteBatch">
+		delete from mall_goods_transport_info_detail where trans_item_id in 
+		<foreach item="transItemId" collection="array" open="(" separator="," close=")">
+			#{transItemId}
+		</foreach>
+	</delete>
+
+</mapper>

+ 25 - 9
kmall-admin/src/main/resources/mybatis/mapper/ProductStoreRelaDao.xml

@@ -740,14 +740,30 @@
         where a.goods_id = #{goodsId}
     </update>
 
-    <!--<select id="queryParkStock" resultType="com.kmall.admin.entity.ProductStoreRelaEntity">-->
-        <!--select a.store_id,a.sku,gs.goods_number as park_stock,a.stock_num-->
-        <!--FROM-->
-        <!--mall_product_store_rela a-->
-        <!--LEFT JOIN mall_goods gs ON a.goods_id = gs.id-->
-        <!--<if test="sku != null and sku != '' ">-->
-            <!--WHERE  a.sku = #{sku}-->
-        <!--</if>-->
-    <!--</select>-->
+
+    <select id="queryByStoreId" resultType="com.kmall.admin.entity.ProductStoreRelaEntity">
+        select
+            a.`id`,
+            a.`store_id`,
+            a.`merch_sn`,
+            a.`product_id`,
+            a.`stock_num`,
+            a.`goods_id`,
+            a.`retail_price`,
+            a.`market_price`,
+            a.`stock_price`,
+            a.`sell_volume`,
+            a.sku,a.goods_biz_type, a.creater_sn, a.create_time, a.moder_sn, a.mod_time, a.tstm,
+            a.category_id,
+            a.attribute_category,
+            a.brand_id,
+            b.NAME goodsName,
+            a.freight_id,
+            supplier_third_id, a.hot_sort_num
+        from mall_product_store_rela a
+        left join mall_goods b on a.goods_id = b.id
+        where a.store_id = #{storeId}
+
+    </select>
 
 </mapper>

+ 3 - 0
kmall-admin/src/main/resources/mybatis/mapper/StoreDao.xml

@@ -126,6 +126,9 @@
 		<if test="isSupplierGoods != null and isSupplierGoods.trim() != ''">
 			AND t.is_supplier_goods = #{isSupplierGoods}
 		</if>
+		<if test="isValid != null and isValid.trim() != ''">
+			AND s.is_valid = #{isValid}
+		</if>
 		<if test="id != null">
 			AND s.id = #{id}
 		</if>

+ 79 - 1
kmall-admin/src/main/resources/mybatis/mapper/alarm/Mall2OrderingEarlyWarningRemindsDao.xml

@@ -55,6 +55,7 @@
     		`tstm`
 		from mall2_ordering_early_warning_reminds
 		WHERE 1=1
+		and is_warning = 1
 		<if test="name != null and name.trim() != ''">
 			AND name LIKE concat('%',#{name},'%')
 		</if>
@@ -74,12 +75,13 @@
  	<select id="queryTotal" resultType="int">
 		select count(*) from mall2_ordering_early_warning_reminds
 		WHERE 1=1
+		and is_warning = 1
         <if test="name != null and name.trim() != ''">
             AND name LIKE concat('%',#{name},'%')
         </if>
 	</select>
 
-	<insert id="save" parameterType="com.kmall.admin.entity.alarm.Mall2OrderingEarlyWarningRemindsEntity">
+	<insert id="save" parameterType="com.kmall.admin.entity.alarm.Mall2OrderingEarlyWarningRemindsEntity" useGeneratedKeys="true" keyProperty="id">
 		insert into mall2_ordering_early_warning_reminds(
 			`moewr_id`,
 			`goods_id`,
@@ -140,4 +142,80 @@
 		</foreach>
 	</delete>
 
+	<insert id="insertBatch" parameterType="java.util.List" useGeneratedKeys="true" keyProperty="id">
+		insert into mall2_ordering_early_warning_reminds(
+			`moewr_id`,
+			`goods_id`,
+			`goods_name`,
+			`average_sales`,
+			`total_num`,
+			`alarm_type`,
+			`alarm_time`,
+			`is_warning`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`)
+		values
+		<foreach collection="list" index="index" item="item" separator=",">
+		(
+			#{item.moewrId},
+			#{item.goodsId},
+			#{item.goodsName},
+			#{item.averageSales},
+			#{item.totalNum},
+			#{item.alarmType},
+			#{item.alarmTime},
+			#{item.isWarning},
+			#{item.createrSn},
+			#{item.createTime},
+			#{item.moderSn},
+			#{item.modTime},
+			#{item.tstm}
+		)
+		</foreach>
+	</insert>
+
+
+	<update id="updateBatch" parameterType="java.util.List">
+		<foreach collection="list" item="item" index="index" open="" close="" separator=";">
+			update mall2_ordering_early_warning_reminds
+			<set>
+				<if test="item.goodsId != null">`goods_id` = #{item.goodsId}, </if>
+				<if test="item.goodsName != null">`goods_name` = #{item.goodsName}, </if>
+				<if test="item.averageSales != null">`average_sales` = #{item.averageSales}, </if>
+				<if test="item.totalNum != null">`total_num` = #{item.totalNum}, </if>
+				<if test="item.alarmType != null">`alarm_type` = #{item.alarmType}, </if>
+				<if test="item.alarmTime != null">`alarm_time` = #{item.alarmTime}, </if>
+				<if test="item.isWarning != null">`is_warning` = #{item.isWarning}, </if>
+				<if test="item.createrSn != null">`creater_sn` = #{item.createrSn}, </if>
+				<if test="item.createTime != null">`create_time` = #{item.createTime}, </if>
+				<if test="item.moderSn != null">`moder_sn` = #{item.moderSn}, </if>
+				<if test="item.modTime != null">`mod_time` = #{item.modTime}, </if>
+				<if test="item.tstm != null">`tstm` = #{item.tstm}</if>
+			</set>
+			where moewr_id = #{item.moewrId}
+		</foreach>
+
+	</update>
+
+	<select id="queryByGoodsId" resultType="com.kmall.admin.entity.alarm.Mall2OrderingEarlyWarningRemindsEntity">
+		select
+			`moewr_id`,
+			`goods_id`,
+			`goods_name`,
+			`average_sales`,
+			`total_num`,
+			`alarm_type`,
+			`alarm_time`,
+			`is_warning`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`
+		from mall2_ordering_early_warning_reminds
+		where goods_id = #{goodsId}
+	</select>
 </mapper>

+ 89 - 1
kmall-admin/src/main/resources/mybatis/mapper/alarm/Mall2ShippingReminderAlarmDao.xml

@@ -64,6 +64,7 @@
     		`tstm`
 		from mall2_shipping_reminder_alarm
 		WHERE 1=1
+		and is_warning = 1
 		<if test="name != null and name.trim() != ''">
 			AND name LIKE concat('%',#{name},'%')
 		</if>
@@ -83,12 +84,13 @@
  	<select id="queryTotal" resultType="int">
 		select count(*) from mall2_shipping_reminder_alarm
 		WHERE 1=1
+		and is_warning = 1
         <if test="name != null and name.trim() != ''">
             AND name LIKE concat('%',#{name},'%')
         </if>
 	</select>
 
-	<insert id="save" parameterType="com.kmall.admin.entity.alarm.Mall2ShippingReminderAlarmEntity">
+	<insert id="save" parameterType="com.kmall.admin.entity.alarm.Mall2ShippingReminderAlarmEntity" useGeneratedKeys="true" keyProperty="id">
 		insert into mall2_shipping_reminder_alarm(
 			`msra_id`,
 			`goods_id`,
@@ -158,4 +160,90 @@
 		</foreach>
 	</delete>
 
+	<select id="queryByGoodsIdAndStoreId" resultType="com.kmall.admin.entity.alarm.Mall2ShippingReminderAlarmEntity">
+		select
+			`msra_id`,
+			`goods_id`,
+			`goods_name`,
+			`average_sales`,
+			`store_id`,
+			`sku`,
+			`store_name`,
+			`stock_num`,
+			`alarm_type`,
+			`alarm_time`,
+			`is_warning`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`
+		from mall2_shipping_reminder_alarm
+		where goods_id = #{goodsId} and store_id = #{storeId}
+	</select>
+
+	<insert id="insertBatch" parameterType="java.util.List" useGeneratedKeys="true" keyProperty="id">
+		insert into mall2_shipping_reminder_alarm(
+			`msra_id`,
+			`goods_id`,
+			`goods_name`,
+			`average_sales`,
+			`store_id`,
+			`sku`,
+			`store_name`,
+			`stock_num`,
+			`alarm_type`,
+			`alarm_time`,
+			`is_warning`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`)
+		values
+		<foreach collection="list" index="index" item="item" separator=",">
+		 (
+			#{item.msraId},
+			#{item.goodsId},
+			#{item.goodsName},
+			#{item.averageSales},
+			#{item.storeId},
+			#{item.sku},
+			#{item.storeName},
+			#{item.stockNum},
+			#{item.alarmType},
+			#{item.alarmTime},
+			#{item.isWarning},
+			#{item.createrSn},
+			#{item.createTime},
+			#{item.moderSn},
+			#{item.modTime},
+			#{item.tstm}
+		)
+		</foreach>
+	</insert>
+
+	<update id="updateBatch" parameterType="java.util.List">
+		<foreach collection="list" item="item" index="index" open="" close="" separator=";">
+			update mall2_shipping_reminder_alarm
+			<set>
+				<if test="item.goodsId != null">`goods_id` = #{item.goodsId}, </if>
+				<if test="item.goodsName != null">`goods_name` = #{item.goodsName}, </if>
+				<if test="item.averageSales != null">`average_sales` = #{item.averageSales}, </if>
+				<if test="item.storeId != null">`store_id` = #{item.storeId}, </if>
+				<if test="item.sku != null">`sku` = #{item.sku}, </if>
+				<if test="item.storeName != null">`store_name` = #{item.storeName}, </if>
+				<if test="item.stockNum != null">`stock_num` = #{item.stockNum}, </if>
+				<if test="item.alarmType != null">`alarm_type` = #{item.alarmType}, </if>
+				<if test="item.alarmTime != null">`alarm_time` = #{item.alarmTime}, </if>
+				<if test="item.isWarning != null">`is_warning` = #{item.isWarning}, </if>
+				<if test="item.createrSn != null">`creater_sn` = #{item.createrSn}, </if>
+				<if test="item.createTime != null">`create_time` = #{item.createTime}, </if>
+				<if test="item.moderSn != null">`moder_sn` = #{item.moderSn}, </if>
+				<if test="item.modTime != null">`mod_time` = #{item.modTime}, </if>
+				<if test="item.tstm != null">`tstm` = #{item.tstm}</if>
+			</set>
+			where msra_id = #{item.msraId}
+		</foreach>
+	</update>
 </mapper>

+ 58 - 2
kmall-admin/src/main/resources/mybatis/mapper/mk/Mk2GoodsTopicHistoryPriceDao.xml

@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 
-<mapper namespace="com.kmall.admin.admin.dao.mk.Mk2GoodsTopicHistoryPriceDao">
+<mapper namespace="com.kmall.admin.dao.mk.Mk2GoodsTopicHistoryPriceDao">
 
     <resultMap type="com.kmall.admin.entity.mk.Mk2GoodsTopicHistoryPriceEntity" id="mk2GoodsTopicHistoryPriceMap">
         <result property="mgthpId" column="mgthp_id"/>
@@ -10,6 +10,9 @@
         <result property="topicPrice" column="topic_price"/>
         <result property="topicName" column="topic_name"/>
         <result property="topicContent" column="topic_content"/>
+		<result property="topicGoodsSku" column="topic_goods_sku"/>
+		<result property="topicBeginTime" column="topic_begin_time"/>
+		<result property="topicEndTime" column="topic_end_time"/>
         <result property="createrSn" column="creater_sn"/>
         <result property="createTime" column="create_time"/>
         <result property="moderSn" column="moder_sn"/>
@@ -25,6 +28,9 @@
 			`topic_price`,
 			`topic_name`,
 			`topic_content`,
+			`topic_goods_sku`,
+			`topic_begin_time`,
+			`topic_end_time`,
 			`creater_sn`,
 			`create_time`,
 			`moder_sn`,
@@ -42,6 +48,9 @@
     		`topic_price`,
     		`topic_name`,
     		`topic_content`,
+			`topic_goods_sku`,
+			`topic_begin_time`,
+			`topic_end_time`,
     		`creater_sn`,
     		`create_time`,
     		`moder_sn`,
@@ -73,7 +82,7 @@
         </if>
 	</select>
 
-	<insert id="save" parameterType="com.kmall.admin.entity.mk.Mk2GoodsTopicHistoryPriceEntity">
+	<insert id="save" parameterType="com.kmall.admin.entity.mk.Mk2GoodsTopicHistoryPriceEntity" useGeneratedKeys="true" keyProperty="id">
 		insert into mk2_goods_topic_history_price(
 			`mgthp_id`,
 			`topic_id`,
@@ -81,6 +90,9 @@
 			`topic_price`,
 			`topic_name`,
 			`topic_content`,
+			`topic_goods_sku`,
+			`topic_begin_time`,
+			`topic_end_time`,
 			`creater_sn`,
 			`create_time`,
 			`moder_sn`,
@@ -93,6 +105,9 @@
 			#{topicPrice},
 			#{topicName},
 			#{topicContent},
+			#{topicGoodsSku},
+			#{topicBeginTime},
+			#{topicEndTime},
 			#{createrSn},
 			#{createTime},
 			#{moderSn},
@@ -108,6 +123,9 @@
 			<if test="topicPrice != null">`topic_price` = #{topicPrice}, </if>
 			<if test="topicName != null">`topic_name` = #{topicName}, </if>
 			<if test="topicContent != null">`topic_content` = #{topicContent}, </if>
+			<if test="topicGoodsSku != null">`topic_goods_sku` = #{topicGoodsSku}, </if>
+			<if test="topicBeginTime != null">`topic_begin_time` = #{topicBeginTime}, </if>
+			<if test="topicEndTime != null">`topic_end_time` = #{topicEndTime}, </if>
 			<if test="createrSn != null">`creater_sn` = #{createrSn}, </if>
 			<if test="createTime != null">`create_time` = #{createTime}, </if>
 			<if test="moderSn != null">`moder_sn` = #{moderSn}, </if>
@@ -128,4 +146,42 @@
 		</foreach>
 	</delete>
 
+
+	<insert id="saveBatch" parameterType="java.util.List" useGeneratedKeys="true" keyProperty="id">
+		insert into mk2_goods_topic_history_price(
+		`mgthp_id`,
+		`topic_id`,
+		`topic_type`,
+		`topic_price`,
+		`topic_name`,
+		`topic_content`,
+		`topic_goods_sku`,
+		`topic_begin_time`,
+		`topic_end_time`,
+		`creater_sn`,
+		`create_time`,
+		`moder_sn`,
+		`mod_time`,
+		`tstm`)
+		values
+		<foreach collection="list" index="index" item="item" separator=",">
+			(
+			#{item.mgthpId},
+			#{item.topicId},
+			#{item.topicType},
+			#{item.topicPrice},
+			#{item.topicName},
+			#{item.topicContent},
+			#{item.topicGoodsSku},
+			#{item.topicBeginTime},
+			#{item.topicEndTime},
+			#{item.createrSn},
+			#{item.createTime},
+			#{item.moderSn},
+			#{item.modTime},
+			#{item.tstm}
+			)
+		</foreach>
+	</insert>
+
 </mapper>

+ 70 - 8
kmall-admin/src/main/resources/mybatis/mapper/mk/Mk2GoodsTopicPriceDao.xml

@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 
-<mapper namespace="com.kmall.admin.dao.Mk2GoodsTopicPriceDao">
+<mapper namespace="com.kmall.admin.dao.mk.Mk2GoodsTopicPriceDao">
 
     <resultMap type="com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity" id="mk2GoodsTopicPriceMap">
         <result property="mgthpId" column="mgthp_id"/>
@@ -10,7 +10,7 @@
         <result property="topicPrice" column="topic_price"/>
         <result property="topicName" column="topic_name"/>
         <result property="topicContent" column="topic_content"/>
-        <result property="topicGoodsId" column="topic_goods_id"/>
+        <result property="topicGoodsSku" column="topic_goods_sku"/>
         <result property="topicBeginTime" column="topic_begin_time"/>
         <result property="topicEndTime" column="topic_end_time"/>
         <result property="importTime" column="import_time"/>
@@ -29,7 +29,7 @@
 			`topic_price`,
 			`topic_name`,
 			`topic_content`,
-			`topic_goods_id`,
+			`topic_goods_sku`,
 			`topic_begin_time`,
 			`topic_end_time`,
 			`import_time`,
@@ -50,7 +50,7 @@
     		`topic_price`,
     		`topic_name`,
     		`topic_content`,
-    		`topic_goods_id`,
+    		`topic_goods_sku`,
     		`topic_begin_time`,
     		`topic_end_time`,
     		`import_time`,
@@ -85,7 +85,7 @@
         </if>
 	</select>
 
-	<insert id="save" parameterType="com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity">
+	<insert id="save" parameterType="com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity" useGeneratedKeys="true" keyProperty="id">
 		insert into mk2_goods_topic_price(
 			`mgthp_id`,
 			`topic_id`,
@@ -93,7 +93,7 @@
 			`topic_price`,
 			`topic_name`,
 			`topic_content`,
-			`topic_goods_id`,
+			`topic_goods_sku`,
 			`topic_begin_time`,
 			`topic_end_time`,
 			`import_time`,
@@ -109,7 +109,7 @@
 			#{topicPrice},
 			#{topicName},
 			#{topicContent},
-			#{topicGoodsId},
+			#{topicGoodsSku},
 			#{topicBeginTime},
 			#{topicEndTime},
 			#{importTime},
@@ -128,7 +128,7 @@
 			<if test="topicPrice != null">`topic_price` = #{topicPrice}, </if>
 			<if test="topicName != null">`topic_name` = #{topicName}, </if>
 			<if test="topicContent != null">`topic_content` = #{topicContent}, </if>
-			<if test="topicGoodsId != null">`topic_goods_id` = #{topicGoodsId}, </if>
+			<if test="topicGoodsSku != null">`topic_goods_sku` = #{topicGoodsSku}, </if>
 			<if test="topicBeginTime != null">`topic_begin_time` = #{topicBeginTime}, </if>
 			<if test="topicEndTime != null">`topic_end_time` = #{topicEndTime}, </if>
 			<if test="importTime != null">`import_time` = #{importTime}, </if>
@@ -152,4 +152,66 @@
 		</foreach>
 	</delete>
 
+
+	<select id="queryByTopicIdAndGoodsId" resultType="com.kmall.admin.entity.mk.Mk2GoodsTopicPriceEntity">
+		select
+			`mgthp_id`,
+			`topic_id`,
+			`topic_type`,
+			`topic_price`,
+			`topic_name`,
+			`topic_content`,
+			`topic_goods_sku`,
+			`topic_begin_time`,
+			`topic_end_time`,
+			`import_time`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`
+		from mk2_goods_topic_price
+		where topic_id = #{mgthpId} and topic_goods_sku = #{sku}
+	</select>
+
+
+	<insert id="saveBatch" parameterType="java.util.List" useGeneratedKeys="true" keyProperty="id">
+		insert into mk2_goods_topic_price(
+		`mgthp_id`,
+		`topic_id`,
+		`topic_type`,
+		`topic_price`,
+		`topic_name`,
+		`topic_content`,
+		`topic_goods_sku`,
+		`topic_begin_time`,
+		`topic_end_time`,
+		`import_time`,
+		`creater_sn`,
+		`create_time`,
+		`moder_sn`,
+		`mod_time`,
+		`tstm`)
+		values
+		<foreach collection="list" index="index" item="item" separator=",">
+			(
+			#{item.mgthpId},
+			#{item.topicId},
+			#{item.topicType},
+			#{item.topicPrice},
+			#{item.topicName},
+			#{item.topicContent},
+			#{item.topicGoodsSku},
+			#{item.topicBeginTime},
+			#{item.topicEndTime},
+			#{item.importTime},
+			#{item.createrSn},
+			#{item.createTime},
+			#{item.moderSn},
+			#{item.modTime},
+			#{item.tstm}
+			)
+		</foreach>
+	</insert>
+
 </mapper>

+ 1 - 1
kmall-admin/src/main/resources/mybatis/mapper/mk/Mk2MemberBirthdayDao.xml

@@ -73,7 +73,7 @@
         </if>
 	</select>
 
-	<insert id="save" parameterType="com.kmall.admin.entity.mk.Mk2MemberBirthdayEntity">
+	<insert id="save" parameterType="com.kmall.admin.entity.mk.Mk2MemberBirthdayEntity" useGeneratedKeys="true" keyProperty="id">
 		insert into mk2_member_birthday(
 			`mmb_id`,
 			`topic_name`,

+ 25 - 8
kmall-admin/src/main/resources/mybatis/mapper/mk/store/MkStorePromTypeDao.xml

@@ -64,7 +64,7 @@
 			limit #{offset}, #{limit}
 		</if>
 	</select>
-	
+
  	<select id="queryTotal" resultType="int">
 		select count(*) from mk_store_prom_type
 		WHERE 1=1
@@ -72,7 +72,7 @@
             AND name LIKE concat('%',#{name},'%')
         </if>
 	</select>
-	 
+
 	<insert id="save" parameterType="com.kmall.admin.entity.mk.store.MkStorePromTypeEntity" useGeneratedKeys="true" keyProperty="promTypeId">
 		insert into mk_store_prom_type(
 			`title`,
@@ -97,9 +97,9 @@
 			#{modTime},
 			#{tstm})
 	</insert>
-	 
+
 	<update id="update" parameterType="com.kmall.admin.entity.mk.store.MkStorePromTypeEntity">
-		update mk_store_prom_type 
+		update mk_store_prom_type
 		<set>
 			<if test="title != null">`title` = #{title}, </if>
 			<if test="promTypeName != null">`prom_type_name` = #{promTypeName}, </if>
@@ -114,16 +114,33 @@
 		</set>
 		where prom_type_id = #{promTypeId}
 	</update>
-	
+
 	<delete id="delete">
 		delete from mk_store_prom_type where prom_type_id = #{value}
 	</delete>
-	
+
 	<delete id="deleteBatch">
-		delete from mk_store_prom_type where prom_type_id in 
+		delete from mk_store_prom_type where prom_type_id in
 		<foreach item="promTypeId" collection="array" open="(" separator="," close=")">
 			#{promTypeId}
 		</foreach>
 	</delete>
 
-</mapper>
+	<select id="queryByName" resultType="com.kmall.admin.entity.mk.store.MkStorePromTypeEntity">
+		select
+			`prom_type_id`,
+			`title`,
+			`prom_type_name`,
+			`pic_url`,
+			`is_valid`,
+			`note`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`
+		from mk_store_prom_type
+		where prom_type_name like concat('%',#{promTypeName},'%')
+	</select>
+
+</mapper>

+ 22 - 0
kmall-admin/src/main/resources/mybatis/mapper/mk/store/StoreTopicDao.xml

@@ -188,4 +188,26 @@
 		</foreach>
 	</delete>
 
+	<select id="queryByStoreIdAndType" resultType="com.kmall.admin.entity.mk.store.StoreTopicEntity">
+		select
+			`id`,
+			`title`,
+			`content`,
+			`item_pic_url`,
+			`subtitle`,
+			`prom_type_id`,
+			`topic_price`,
+			`store_id`,
+			`third_merch_sn`,
+			`is_valid`,
+			`note`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`
+		from mall_store_topic
+		where prom_type_id = #{promTypeId} and store_id = #{storeId} and is_valid = 0 limit 1
+	</select>
+
 </mapper>

+ 1 - 1
kmall-admin/src/main/resources/mybatis/mapper/vip/Mall2MemberConsumptionRecordsDao.xml

@@ -73,7 +73,7 @@
         </if>
 	</select>
 
-	<insert id="save" parameterType="com.kmall.admin.entity.vip.Mall2MemberConsumptionRecordsEntity">
+	<insert id="save" parameterType="com.kmall.admin.entity.vip.Mall2MemberConsumptionRecordsEntity" useGeneratedKeys="true" keyProperty="id">
 		insert into mall2_member_consumption_records(
 			`mmcr_id`,
 			`user_id`,

+ 16 - 1
kmall-admin/src/main/resources/mybatis/mapper/vip/Mall2MemberPointsDao.xml

@@ -67,7 +67,7 @@
         </if>
 	</select>
 
-	<insert id="save" parameterType="com.kmall.admin.entity.vip.Mall2MemberPointsEntity">
+	<insert id="save" parameterType="com.kmall.admin.entity.vip.Mall2MemberPointsEntity" useGeneratedKeys="true" keyProperty="id">
 		insert into mall2_member_points(
 			`mmp_id`,
 			`user_id`,
@@ -116,4 +116,19 @@
 		</foreach>
 	</delete>
 
+	<select id="queryByUserId" resultType="com.kmall.admin.entity.vip.Mall2MemberPointsEntity">
+		select
+			`mmp_id`,
+			`user_id`,
+			`points`,
+			`points_expire_date`,
+			`creater_sn`,
+			`create_time`,
+			`moder_sn`,
+			`mod_time`,
+			`tstm`
+		from mall2_member_points
+		where user_id = #{userId}
+	</select>
+
 </mapper>

+ 1 - 1
kmall-admin/src/main/resources/mybatis/mapper/vip/Mall2PointsRulesDao.xml

@@ -70,7 +70,7 @@
         </if>
 	</select>
 
-	<insert id="save" parameterType="com.kmall.admin.entity.vip.Mall2PointsRulesEntity">
+	<insert id="save" parameterType="com.kmall.admin.entity.vip.Mall2PointsRulesEntity" useGeneratedKeys="true" keyProperty="id">
 		insert into mall2_points_rules(
 			`mpr_id`,
 			`points_type`,

+ 8 - 0
kmall-admin/src/main/webapp/WEB-INF/page/mk/mk2goodstopicprice.html

@@ -14,6 +14,14 @@
                 </i-col>
                 <i-button @click="query">查询</i-button>
                 <i-button @click="reloadSearch">重置</i-button>
+                <i-col style="display: inline-grid;">
+                    <Upload :show-upload-list="false" :on-success="uploadExcelSuccess" :on-error="uploadExcelError" :on-format-error="uploadExcelFormatError"
+                            :format="['xls','xlsx']"
+                            action="../mk2goodstopicprice/goodsTopicPriceUpload">
+                        <i-button type="ghost" icon="ios-cloud-upload-outline">活动商品导入</i-button>
+                    </Upload>
+                </i-col>
+                <a href="../statics/file/store_topic_goods_export_yyyy_mm_dd_v1.0.0.xlsx">活动商品模板下载</a>&nbsp;&nbsp;&nbsp;
             </div>
             <div class="buttons-group">
                 #if($shiro.hasPermission("mk2goodstopicprice:save"))

+ 3 - 22
kmall-admin/src/main/webapp/WEB-INF/page/mk/storetopic.html

@@ -14,17 +14,12 @@
                 </i-col>
                 <i-button @click="query">查询</i-button>
                 <i-button @click="reloadSearch">重置</i-button>
+
             </div>
             <div class="buttons-group">
-                #if($shiro.hasPermission("storetopic:save"))
                 <i-button type="info" @click="add"><i class="fa fa-plus"></i>&nbsp;新增</i-button>
-                #end
-                #if($shiro.hasPermission("storetopic:update"))
                 <i-button type="warning" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</i-button>
-                #end
-                #if($shiro.hasPermission("storetopic:delete"))
                 <i-button type="error" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</i-button>
-                #end
             </div>
         </Row>
 	    <table id="jqGrid"></table>
@@ -67,21 +62,7 @@
             <Form-item label="备注" prop="note">
                 <i-input v-model="storeTopic.note" placeholder="备注"/>
             </Form-item>
-            <Form-item label="创建人编号" prop="createrSn">
-                <i-input v-model="storeTopic.createrSn" placeholder="创建人编号"/>
-            </Form-item>
-            <Form-item label="创建时间" prop="createTime">
-                <i-input v-model="storeTopic.createTime" placeholder="创建时间"/>
-            </Form-item>
-            <Form-item label="修改人编号" prop="moderSn">
-                <i-input v-model="storeTopic.moderSn" placeholder="修改人编号"/>
-            </Form-item>
-            <Form-item label="修改时间" prop="modTime">
-                <i-input v-model="storeTopic.modTime" placeholder="修改时间"/>
-            </Form-item>
-            <Form-item label="时间戳" prop="tstm">
-                <i-input v-model="storeTopic.tstm" placeholder="时间戳"/>
-            </Form-item>
+
             <Form-item>
                 <i-button type="primary" @click="handleSubmit('formValidate')">提交</i-button>
                 <i-button type="warning" @click="reload" style="margin-left: 8px"/>返回</i-button>
@@ -93,4 +74,4 @@
 
 <script src="${rc.contextPath}/js/mk/storetopic.js?_${date.systemTime}"></script>
 </body>
-</html>
+</html>

+ 87 - 0
kmall-admin/src/main/webapp/WEB-INF/page/shop/goodstransportinfo.html

@@ -0,0 +1,87 @@
+<!DOCTYPE html>
+<html>
+<head>
+    <title>在途运输信息表</title>
+    #parse("sys/header.html")
+</head>
+<body>
+<div id="rrapp" v-cloak>
+	<div v-show="showList">
+        <Row :gutter="16">
+            <div class="search-group">
+                <i-col span="4">
+                    <i-input v-model="q.name" @on-enter="query" placeholder="名称"/>
+                </i-col>
+                <i-button @click="query">查询</i-button>
+                <i-button @click="reloadSearch">重置</i-button>
+            </div>
+            <div class="buttons-group">
+                #if($shiro.hasPermission("goodstransportinfo:save"))
+                <i-button type="info" @click="add"><i class="fa fa-plus"></i>&nbsp;新增</i-button>
+                #end
+                #if($shiro.hasPermission("goodstransportinfo:update"))
+                <i-button type="warning" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</i-button>
+                #end
+                #if($shiro.hasPermission("goodstransportinfo:delete"))
+                <i-button type="error" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</i-button>
+                #end
+            </div>
+        </Row>
+	    <table id="jqGrid"></table>
+	    <div id="jqGridPager"></div>
+    </div>
+
+    <Card v-show="!showList">
+        <p slot="title">{{title}}</p>
+		<i-form ref="formValidate" :model="goodsTransportInfo" :rules="ruleValidate" :label-width="80">
+            <Form-item label="传输类型" prop="transportType">
+                <i-input v-model="goodsTransportInfo.transportType" placeholder="传输类型"/>
+            </Form-item>
+            <Form-item label="运输工具" prop="transportTool">
+                <i-input v-model="goodsTransportInfo.transportTool" placeholder="运输工具"/>
+            </Form-item>
+            <Form-item label="第三方商户编号" prop="thirdMerchSn">
+                <i-input v-model="goodsTransportInfo.thirdMerchSn" placeholder="第三方商户编号"/>
+            </Form-item>
+            <Form-item label="是否在途" prop="wayStatus">
+                <i-input v-model="goodsTransportInfo.wayStatus" placeholder="是否在途"/>
+            </Form-item>
+            <Form-item label="始发地" prop="origin">
+                <i-input v-model="goodsTransportInfo.origin" placeholder="始发地"/>
+            </Form-item>
+            <Form-item label="目的地" prop="destination">
+                <i-input v-model="goodsTransportInfo.destination" placeholder="目的地"/>
+            </Form-item>
+            <Form-item label="始发时间" prop="startTime">
+                <i-input v-model="goodsTransportInfo.startTime" placeholder="始发时间"/>
+            </Form-item>
+            <Form-item label="到达时间" prop="arrivalTime">
+                <i-input v-model="goodsTransportInfo.arrivalTime" placeholder="到达时间"/>
+            </Form-item>
+            <Form-item label="创建人编号" prop="createrSn">
+                <i-input v-model="goodsTransportInfo.createrSn" placeholder="创建人编号"/>
+            </Form-item>
+            <Form-item label="创建时间" prop="createTime">
+                <i-input v-model="goodsTransportInfo.createTime" placeholder="创建时间"/>
+            </Form-item>
+            <Form-item label="修改人编号" prop="moderSn">
+                <i-input v-model="goodsTransportInfo.moderSn" placeholder="修改人编号"/>
+            </Form-item>
+            <Form-item label="修改时间" prop="modTime">
+                <i-input v-model="goodsTransportInfo.modTime" placeholder="修改时间"/>
+            </Form-item>
+            <Form-item label="时间戳" prop="tstm">
+                <i-input v-model="goodsTransportInfo.tstm" placeholder="时间戳"/>
+            </Form-item>
+            <Form-item>
+                <i-button type="primary" @click="handleSubmit('formValidate')">提交</i-button>
+                <i-button type="warning" @click="reload" style="margin-left: 8px"/>返回</i-button>
+                <i-button type="ghost" @click="handleReset('formValidate')" style="margin-left: 8px">重置</i-button>
+            </Form-item>
+        </i-form>
+	</Card>
+</div>
+
+<script src="${rc.contextPath}/js/shop/goodstransportinfo.js?_${date.systemTime}"></script>
+</body>
+</html>

+ 82 - 0
kmall-admin/src/main/webapp/WEB-INF/page/shop/goodstransportinfodetail.html

@@ -0,0 +1,82 @@
+<!DOCTYPE html>
+<html>
+<head>
+    <title>在途商品明细表</title>
+    #parse("sys/header.html")
+</head>
+<body>
+<div id="rrapp" v-cloak>
+	<div v-show="showList">
+        <Row :gutter="16">
+            <div class="search-group">
+                <i-col span="2">
+                    <i-input v-model="q.wayStatus" @on-enter="query" placeholder="是否在途"/>
+                </i-col>
+                <i-col span="4">
+                    <i-input v-model="q.sku" @on-enter="query" placeholder="sku"/>
+                </i-col>
+                <i-button @click="query">查询</i-button>
+                <i-button @click="reloadSearch">重置</i-button>
+            </div>
+            <div class="buttons-group">
+                <i-col style="display: inline-grid;">
+                    <Upload :show-upload-list="false" :on-success="uploadExcelSuccess" :on-error="uploadExcelError" :on-format-error="uploadExcelFormatError"
+                            :format="['xls','xlsx']"
+                            action="../goodstransportinfodetail/transInfoDetailUpload">
+                        <i-button type="ghost" icon="ios-cloud-upload-outline">在途商品明细导入</i-button>
+                    </Upload>
+                </i-col>
+                <i-button type="info" @click="add"><i class="fa fa-plus"></i>&nbsp;新增</i-button>
+                <i-button type="warning" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</i-button>
+                <i-button type="error" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</i-button>
+            </div>
+        </Row>
+	    <table id="jqGrid"></table>
+	    <div id="jqGridPager"></div>
+    </div>
+
+    <Card v-show="!showList">
+        <p slot="title">{{title}}</p>
+		<i-form ref="formValidate" :model="goodsTransportInfoDetail" :rules="ruleValidate" :label-width="80">
+            <Form-item label="是否在途" prop="wayStatus">
+                <i-input v-model="goodsTransportInfoDetail.wayStatus" placeholder="是否在途"/>
+            </Form-item>
+            <Form-item label="商品sku" prop="sku">
+                <i-input v-model="goodsTransportInfoDetail.sku" placeholder="商品sku"/>
+            </Form-item>
+            <Form-item label="供应商id" prop="supplierId">
+                <i-input v-model="goodsTransportInfoDetail.supplierId" placeholder="供应商id"/>
+            </Form-item>
+            <Form-item label="原产地" prop="originCountry">
+                <i-input v-model="goodsTransportInfoDetail.originCountry" placeholder="原产地"/>
+            </Form-item>
+            <Form-item label="数量" prop="num">
+                <i-input v-model="goodsTransportInfoDetail.num" placeholder="数量"/>
+            </Form-item>
+            <Form-item label="创建人编号" prop="createrSn">
+                <i-input v-model="goodsTransportInfoDetail.createrSn" placeholder="创建人编号"/>
+            </Form-item>
+            <!--<Form-item label="创建时间" prop="createTime">-->
+                <!--<i-input v-model="goodsTransportInfoDetail.createTime"  placeholder="创建时间"/>-->
+            <!--</Form-item>-->
+            <Form-item label="修改人编号" prop="moderSn">
+                <i-input v-model="goodsTransportInfoDetail.moderSn" placeholder="修改人编号"/>
+            </Form-item>
+            <!--<Form-item label="修改时间" prop="modTime">-->
+                <!--<i-input v-model="goodsTransportInfoDetail.modTime"  placeholder="修改时间"/>-->
+            <!--</Form-item>-->
+            <!--<Form-item label="时间戳" prop="tstm">-->
+                <!--<i-input v-model="goodsTransportInfoDetail.tstm" placeholder="时间戳"/>-->
+            <!--</Form-item>-->
+            <Form-item>
+                <i-button type="primary" @click="handleSubmit('formValidate')">提交</i-button>
+                <i-button type="warning" @click="reload" style="margin-left: 8px"/>返回</i-button>
+                <i-button type="ghost" @click="handleReset('formValidate')" style="margin-left: 8px">重置</i-button>
+            </Form-item>
+        </i-form>
+	</Card>
+</div>
+
+<script src="${rc.contextPath}/js/shop/goodstransportinfodetail.js?_${date.systemTime}"></script>
+</body>
+</html>

+ 6 - 27
kmall-admin/src/main/webapp/WEB-INF/page/vip/mall2memberconsumptionrecords.html

@@ -10,22 +10,15 @@
         <Row :gutter="16">
             <div class="search-group">
                 <i-col span="4">
-                    <i-input v-model="q.name" @on-enter="query" placeholder="名称"/>
+                    <i-input v-model="q.userId" @on-enter="query" placeholder="用户id"/>
+                </i-col>
+                <i-col span="4">
+                    <i-input v-model="q.orderSn" @on-enter="query" placeholder="订单号"/>
                 </i-col>
                 <i-button @click="query">查询</i-button>
                 <i-button @click="reloadSearch">重置</i-button>
             </div>
-            <div class="buttons-group">
-                #if($shiro.hasPermission("mall2memberconsumptionrecords:save"))
-                <i-button type="info" @click="add"><i class="fa fa-plus"></i>&nbsp;新增</i-button>
-                #end
-                #if($shiro.hasPermission("mall2memberconsumptionrecords:update"))
-                <i-button type="warning" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</i-button>
-                #end
-                #if($shiro.hasPermission("mall2memberconsumptionrecords:delete"))
-                <i-button type="error" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</i-button>
-                #end
-            </div>
+
         </Row>
 	    <table id="jqGrid"></table>
 	    <div id="jqGridPager"></div>
@@ -49,21 +42,7 @@
             <Form-item label="是否使用生日优惠" prop="isUseBirthdayOffer">
                 <i-input v-model="mall2MemberConsumptionRecords.isUseBirthdayOffer" placeholder="是否使用生日优惠"/>
             </Form-item>
-            <Form-item label="+创建人编号" prop="createrSn">
-                <i-input v-model="mall2MemberConsumptionRecords.createrSn" placeholder="+创建人编号"/>
-            </Form-item>
-            <Form-item label="+创建时间,yyyy-MM-dd HH:mm:ss" prop="createTime">
-                <i-input v-model="mall2MemberConsumptionRecords.createTime" placeholder="+创建时间,yyyy-MM-dd HH:mm:ss"/>
-            </Form-item>
-            <Form-item label="+修改人编号" prop="moderSn">
-                <i-input v-model="mall2MemberConsumptionRecords.moderSn" placeholder="+修改人编号"/>
-            </Form-item>
-            <Form-item label="+修改时间,yyyy-MM-dd HH:mm:ss" prop="modTime">
-                <i-input v-model="mall2MemberConsumptionRecords.modTime" placeholder="+修改时间,yyyy-MM-dd HH:mm:ss"/>
-            </Form-item>
-            <Form-item label="+时间戳" prop="tstm">
-                <i-input v-model="mall2MemberConsumptionRecords.tstm" placeholder="+时间戳"/>
-            </Form-item>
+
             <Form-item>
                 <i-button type="primary" @click="handleSubmit('formValidate')">提交</i-button>
                 <i-button type="warning" @click="reload" style="margin-left: 8px"/>返回</i-button>

+ 4 - 28
kmall-admin/src/main/webapp/WEB-INF/page/vip/mall2memberpoints.html

@@ -10,22 +10,12 @@
         <Row :gutter="16">
             <div class="search-group">
                 <i-col span="4">
-                    <i-input v-model="q.name" @on-enter="query" placeholder="名称"/>
+                    <i-input v-model="q.userId" @on-enter="query" placeholder="用户id"/>
                 </i-col>
                 <i-button @click="query">查询</i-button>
                 <i-button @click="reloadSearch">重置</i-button>
             </div>
-            <div class="buttons-group">
-                #if($shiro.hasPermission("mall2memberpoints:save"))
-                <i-button type="info" @click="add"><i class="fa fa-plus"></i>&nbsp;新增</i-button>
-                #end
-                #if($shiro.hasPermission("mall2memberpoints:update"))
-                <i-button type="warning" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</i-button>
-                #end
-                #if($shiro.hasPermission("mall2memberpoints:delete"))
-                <i-button type="error" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</i-button>
-                #end
-            </div>
+
         </Row>
 	    <table id="jqGrid"></table>
 	    <div id="jqGridPager"></div>
@@ -43,21 +33,7 @@
             <Form-item label="积分到期时间" prop="pointsExpireDate">
                 <i-input v-model="mall2MemberPoints.pointsExpireDate" placeholder="积分到期时间"/>
             </Form-item>
-            <Form-item label="+创建人编号" prop="createrSn">
-                <i-input v-model="mall2MemberPoints.createrSn" placeholder="+创建人编号"/>
-            </Form-item>
-            <Form-item label="+创建时间,yyyy-MM-dd HH:mm:ss" prop="createTime">
-                <i-input v-model="mall2MemberPoints.createTime" placeholder="+创建时间,yyyy-MM-dd HH:mm:ss"/>
-            </Form-item>
-            <Form-item label="+修改人编号" prop="moderSn">
-                <i-input v-model="mall2MemberPoints.moderSn" placeholder="+修改人编号"/>
-            </Form-item>
-            <Form-item label="+修改时间,yyyy-MM-dd HH:mm:ss" prop="modTime">
-                <i-input v-model="mall2MemberPoints.modTime" placeholder="+修改时间,yyyy-MM-dd HH:mm:ss"/>
-            </Form-item>
-            <Form-item label="+时间戳" prop="tstm">
-                <i-input v-model="mall2MemberPoints.tstm" placeholder="+时间戳"/>
-            </Form-item>
+
             <Form-item>
                 <i-button type="primary" @click="handleSubmit('formValidate')">提交</i-button>
                 <i-button type="warning" @click="reload" style="margin-left: 8px"/>返回</i-button>
@@ -67,6 +43,6 @@
 	</Card>
 </div>
 
-<script src="${rc.contextPath}/vip/shop/mall2memberpoints.js?_${date.systemTime}"></script>
+<script src="${rc.contextPath}/js/vip/mall2memberpoints.js?_${date.systemTime}"></script>
 </body>
 </html>

+ 9 - 7
kmall-admin/src/main/webapp/js/alarm/mall2orderingearlywarningreminds.js

@@ -4,13 +4,15 @@ $(function () {
         datatype: "json",
         colModel: [
 			{label: 'moewrId', name: 'moewrId', index: 'moewr_id', key: true, hidden: true},
-			{label: '商品id', name: 'goodsId', index: 'goods_id', width: 80},
-			{label: '商品名称', name: 'goodsName', index: 'goods_name', width: 80},
-			{label: '平均销量', name: 'averageSales', index: 'average_sales', width: 80},
-			{label: '总库存数', name: 'totalNum', index: 'total_num', width: 80},
-			{label: '预警条件  00 周  10  月', name: 'alarmType', index: 'alarm_type', width: 80},
-			{label: '预警时间', name: 'alarmTime', index: 'alarm_time', width: 80},
-			{label: '是否已经预警', name: 'isWarning', index: 'is_warning', width: 80},
+			{label: '商品id', name: 'goodsId', index: 'goods_id', align:"center",width: 80},
+			{label: '商品名称', name: 'goodsName', index: 'goods_name',align:"center", width: 80},
+			{label: '平均销量', name: 'averageSales', index: 'average_sales',align:"center", width: 80},
+			{label: '总库存数', name: 'totalNum', index: 'total_num',align:"center", width: 80},
+			{
+				label: '预警时间', name: 'alarmTime', index: 'alarm_time',align:"center", width: 80, formatter: function (value) {
+					return transDate(value, 'yyyy-MM-dd hh:mm:ss');
+				}
+			}
 			],
 		viewrecords: true,
         height: 550,

+ 12 - 11
kmall-admin/src/main/webapp/js/alarm/mall2shippingreminderalarm.js

@@ -3,17 +3,18 @@ $(function () {
         url: '../mall2shippingreminderalarm/list',
         datatype: "json",
         colModel: [
-			{label: 'msraId', name: 'msraId', index: 'msra_id', key: true, hidden: true},
-			{label: '商品id', name: 'goodsId', index: 'goods_id', width: 80},
-			{label: '商品名称', name: 'goodsName', index: 'goods_name', width: 80},
-			{label: '平均销量', name: 'averageSales', index: 'average_sales', width: 80},
-			{label: '门店id', name: 'storeId', index: 'store_id', width: 80},
-			{label: '门店商品sku', name: 'sku', index: 'sku', width: 80},
-			{label: '门店名称', name: 'storeName', index: 'store_name', width: 80},
-			{label: '门店库存数', name: 'stockNum', index: 'stock_num', width: 80},
-			{label: '预警条件  00 周  10  月', name: 'alarmType', index: 'alarm_type', width: 80},
-			{label: '预警时间', name: 'alarmTime', index: 'alarm_time', width: 80},
-			{label: '是否已经预警', name: 'isWarning', index: 'is_warning', width: 80},
+			{label: 'msraId', name: 'msraId', index: 'msra_id',  key: true, hidden: true},
+			{label: '门店id', name: 'storeId', index: 'store_id',align:"center", width: 80},
+			{label: '门店商品sku', name: 'sku', index: 'sku',align:"center", width: 80},
+			{label: '门店名称', name: 'storeName', index: 'store_name',align:"center", width: 80},
+			{label: '商品名称', name: 'goodsName', index: 'goods_name',align:"center", width: 100},
+			{label: '剩余库存数', name: 'stockNum', index: 'stock_num',align:"center", width: 80},
+			{label: '平均销量', name: 'averageSales', index: 'average_sales',align:"center", width: 80},
+			{
+				label: '预警时间', name: 'alarmTime', index: 'alarm_time',align:"center", width: 80, formatter: function (value) {
+					return transDate(value, 'yyyy-MM-dd hh:mm:ss');
+				}
+			}
 			],
 		viewrecords: true,
         height: 550,

+ 6 - 11
kmall-admin/src/main/webapp/js/mk/mk2goodstopichistoryprice.js

@@ -4,16 +4,11 @@ $(function () {
         datatype: "json",
         colModel: [
 			{label: 'mgthpId', name: 'mgthpId', index: 'mgthp_id', key: true, hidden: true},
-			{label: '活动id', name: 'topicId', index: 'topic_id', width: 80},
-			{label: '活动类别', name: 'topicType', index: 'topic_type', width: 80},
-			{label: '活动价格', name: 'topicPrice', index: 'topic_price', width: 80},
-			{label: '活动名称', name: 'topicName', index: 'topic_name', width: 80},
-			{label: '活动内容', name: 'topicContent', index: 'topic_content', width: 80},
-			{label: '创建人编号', name: 'createrSn', index: 'creater_sn', width: 80},
-			{label: '创建时间', name: 'createTime', index: 'create_time', width: 80},
-			{label: '修改人编号', name: 'moderSn', index: 'moder_sn', width: 80},
-			{label: '修改时间', name: 'modTime', index: 'mod_time', width: 80},
-			{label: '时间戳', name: 'tstm', index: 'tstm', width: 80}],
+			{label: '活动id', name: 'topicId', index: 'topic_id', align: 'center',width: 80},
+			{label: '活动类别', name: 'topicType', index: 'topic_type', align: 'center',width: 80},
+			{label: '活动价格', name: 'topicPrice', index: 'topic_price', align: 'center',width: 80},
+			{label: '活动名称', name: 'topicName', index: 'topic_name',align: 'center', width: 80},
+			{label: '活动内容', name: 'topicContent', index: 'topic_content', align: 'center',width: 80}],
 		viewrecords: true,
         height: 550,
         rowNum: 10,
@@ -145,4 +140,4 @@ let vm = new Vue({
             handleResetForm(this, name);
         }
 	}
-});
+});

+ 50 - 16
kmall-admin/src/main/webapp/js/mk/mk2goodstopicprice.js

@@ -4,20 +4,22 @@ $(function () {
         datatype: "json",
         colModel: [
 			{label: 'mgthpId', name: 'mgthpId', index: 'mgthp_id', key: true, hidden: true},
-			{label: '活动id', name: 'topicId', index: 'topic_id', width: 80},
-			{label: '活动类别', name: 'topicType', index: 'topic_type', width: 80},
-			{label: '活动价格', name: 'topicPrice', index: 'topic_price', width: 80},
-			{label: '活动名称', name: 'topicName', index: 'topic_name', width: 80},
-			{label: '活动内容', name: 'topicContent', index: 'topic_content', width: 80},
-			{label: '活动产品', name: 'topicGoodsId', index: 'topic_goods_id', width: 80},
-			{label: '活动开始时间', name: 'topicBeginTime', index: 'topic_begin_time', width: 80},
-			{label: '活动结束时间', name: 'topicEndTime', index: 'topic_end_time', width: 80},
-			{label: '导入时间', name: 'importTime', index: 'import_time', width: 80},
-			{label: '创建人编号', name: 'createrSn', index: 'creater_sn', width: 80},
-			{label: '创建时间', name: 'createTime', index: 'create_time', width: 80},
-			{label: '修改人编号', name: 'moderSn', index: 'moder_sn', width: 80},
-			{label: '修改时间', name: 'modTime', index: 'mod_time', width: 80},
-			{label: '时间戳', name: 'tstm', index: 'tstm', width: 80}],
+			{label: '活动id', name: 'topicId', index: 'topic_id', align: 'center',width: 80},
+			{label: '活动类别', name: 'topicType', index: 'topic_type', align: 'center',width: 80},
+			{label: '活动价格', name: 'topicPrice', index: 'topic_price',align: 'center', width: 80},
+			{label: '活动名称', name: 'topicName', index: 'topic_name' ,align: 'center',width: 80},
+			{label: '活动内容', name: 'topicContent', index: 'topic_content', align: 'center',width: 80},
+			{label: '活动产品', name: 'topicGoodsId', index: 'topic_goods_id', align: 'center',width: 80},
+			{label: '活动开始时间', name: 'topicBeginTime', index: 'topic_begin_time', width: 80,align: 'center',
+				formatter: function (value) {
+					return transDate(value, 'yyyy-MM-dd hh:mm:ss');
+				}},
+			{label: '活动结束时间', name: 'topicEndTime', index: 'topic_end_time', width: 80,align: 'center',
+				formatter: function (value) {
+					return transDate(value, 'yyyy-MM-dd hh:mm:ss');
+				}}
+
+			],
 		viewrecords: true,
         height: 550,
         rowNum: 10,
@@ -140,6 +142,32 @@ let vm = new Vue({
             }).trigger("reloadGrid");
             vm.handleReset('formValidate');
 		},
+		uploadExcelSuccess: function () {
+			alert('上传成功', function (index) {
+				$("#jqGrid").trigger("reloadGrid");
+			});
+		},
+		uploadExcelError: function () {
+			alert('上传出现异常');
+		},
+		uploadExcelSuccess: function (data) {
+			if(data.code==0){
+				alert('导入成功', function (index) {
+					vm.reload();
+				});
+			}else{
+				if(data.msg == '导入成功!'){
+					alert(data.msg);
+					vm.reload();
+				}else {
+					alert(data.msg);
+				}
+			}
+		},
+		uploadExcelError: function (data) {
+			console.log(data);
+			alert('上传出现异常,请重试!');
+		},
         handleSubmit: function (name) {
             handleSubmitValidate(this, name, function () {
                 vm.saveOrUpdate()
@@ -147,6 +175,12 @@ let vm = new Vue({
         },
         handleReset: function (name) {
             handleResetForm(this, name);
-        }
+        },
+		uploadExcelFormatError: function (file) {
+			this.$Notice.warning({
+				title: '文件格式不正确',
+				desc: '文件 ' + file.name + ' 格式不正确,请上传 xls 或 xlsx 格式的文件。'
+			});
+		}
 	}
-});
+});

+ 10 - 19
kmall-admin/src/main/webapp/js/mk/storetopic.js

@@ -4,16 +4,16 @@ $(function () {
         datatype: "json",
         colModel: [
 			{label: 'id', name: 'id', index: 'id', key: true, hidden: true},
-			{label: '活动主题', name: 'title', index: 'title', width: 180},
-			{label: '活动内容', name: 'content', index: 'content', width: 280},
+			{label: '活动主题', name: 'title', index: 'title', align: 'center',width: 80},
+			{label: '活动内容', name: 'content', index: 'content',align: 'center', width: 80},
 			// {label: '活动图片', name: 'itemPicUrl', index: 'item_pic_url', width: 80},
-			{label: '子标题', name: 'subtitle', index: 'subtitle', width: 180},
-			{label: '活动类别名称', name: 'promTypeName', index: 'prom_type_id', width: 180},
+			{label: '子标题', name: 'subtitle', index: 'subtitle', align: 'center',width: 80},
+			{label: '活动类别名称', name: 'promTypeName', index: 'prom_type_id',align: 'center', width: 80},
 			// {label: '活动价格', name: 'priceInfo', index: 'price_info', width: 80},
 			// {label: '场景图片链接', name: 'scenePicUrl', index: 'scene_pic_url', width: 80},
-			{label: '门店名称', name: 'storeName', index: 'store_id', width: 180},
-			{label: '第三方商户名称', name: 'thirdPartyMerchName', index: 'third_merch_sn', width: 180},
-            {label: '是否有效', name: 'isValid', index: 'is_valid', width: 100, align: 'center',
+			{label: '门店名称', name: 'storeName', index: 'store_id', align: 'center',width: 80},
+			{label: '第三方商户名称', name: 'thirdPartyMerchName', index: 'third_merch_sn',align: 'center', width: 80},
+            {label: '是否有效', name: 'isValid', index: 'is_valid', width: 50, align: 'center',
                 formatter: function (value) {
                     if (value == '0') {
                         return '有效';
@@ -23,17 +23,8 @@ $(function () {
                     return '-';
                 }
             },
-			{label: '备注', name: 'note', index: 'note', width: 180},
-			{label: '创建人编号', name: 'createrSn', index: 'creater_sn', width: 120},
-			{label: '创建时间', name: 'createTime', index: 'create_time', width: 160,
-                formatter: function (value) {
-                    return transDate(value, 'yyyy-MM-dd hh:mm:ss');
-                }},
-			{label: '修改人编号', name: 'moderSn', index: 'moder_sn', width: 120},
-			{label: '修改时间', name: 'modTime', index: 'mod_time', width: 160,
-                formatter: function (value) {
-                    return transDate(value, 'yyyy-MM-dd hh:mm:ss');
-                }}],
+			{label: '备注', name: 'note', index: 'note', width: 80},
+			],
 		viewrecords: true,
         height: 550,
         rowNum: 10,
@@ -58,7 +49,7 @@ $(function () {
             order: "order"
         },
         gridComplete: function () {
-            $("#jqGrid").closest(".ui-jqgrid-bdiv").css({"overflow-x": "scroll"});
+            $("#jqGrid").closest(".ui-jqgrid-bdiv").css({"overflow-x": "hidden"});
         }
     });
 });

+ 41 - 9
kmall-admin/src/main/webapp/js/sale/sale.js

@@ -31,6 +31,7 @@ let vm = new Vue({
         currentOrderNo:null,
         customname:'',
         customidcard:'',
+        machineCode:'',
         storeId:null,
         index:0,
         max:0,
@@ -97,8 +98,9 @@ let vm = new Vue({
             goods.sellVolume = goods.sellVolume - 1;
         },
         deleteItem:function(value){
+            console.log(value);
             // 删除这条记录
-            this.goodsList.splice(value,1,"");
+            this.goodsList.splice(value,1);
             this.index = value;
 
         },
@@ -117,9 +119,9 @@ let vm = new Vue({
         },
         submitOrder:function(){
             $('#payCode').unbind('keydown').keydown(function(event){});
+            vm.machineCode = sessionStorage.getItem("machineCode");
 
-
-            var param = {'userInfo':vm.userInfo,'payCode':this.$refs.payCode.currentValue,'goodsList':vm.goodsList,'sessionId':vm.sessionId};
+            var param = {'userInfo':vm.userInfo,'payCode':this.$refs.payCode.currentValue,'goodsList':vm.goodsList,'sessionId':vm.sessionId,'machineCode':vm.machineCode};
             this.$refs.payCode.currentValue = '';
             $.ajax({
                 type: "POST",
@@ -135,7 +137,7 @@ let vm = new Vue({
                             })
                             // 打印取货码小票
                             var content = getPrintContent(r.resultObj);
-                            printArea(content);
+                            printArea2(content);
                             vm.goodsList = [];
                             vm.customname = '' ;
                             vm.customidcard = '';
@@ -177,13 +179,13 @@ let vm = new Vue({
                 return ;
             }
             if(!idcardReg.test(this.userInfo.customIDCard)){
-                // alert("请输入正确的身份证号");
-                // return ;
+                alert("请输入正确的身份证号");
+                return ;
             }
 
             if(!(/^1[3456789]\d{9}$/.test(this.userInfo.customPhone))){
-                // alert("手机号码有误,请重填");
-                // return ;
+                alert("手机号码有误,请重填");
+                return ;
             }
 
 
@@ -378,13 +380,43 @@ function printArea(content) {
     doc.write('<div class="">' + content
         + '</div>');
     doc.close();
-    console.log(doc);
     var frameWindow = iframe.contentWindow;
     frameWindow.close();
     frameWindow.focus();
     // frameWindow.print();
     frameWindow.print();
 }
+
+function printArea2(content) {
+    var idPrefix = "printArea_";
+    removePrintArea(idPrefix + printAreaCount);
+    printAreaCount++;
+    var iframeId = idPrefix + printAreaCount;
+    var iframeStyle = 'width:0px;height:0px;left:0px;top:0px;';
+    iframe = document.createElement('IFRAME');
+    $(iframe).attr({
+        style: iframeStyle,
+        id: iframeId
+    });
+    document.body.appendChild(iframe);
+    var doc = iframe.contentWindow.document;
+    doc.open();
+    //$(document).find("link").filter(function () {
+    //return $(this).attr("rel").toLowerCase() == "stylesheet";
+    //}).each(
+    //function () {
+    //doc.write('<link type="text/css" rel="stylesheet" href="'
+    //+ $(this).attr("href") + '" >');
+    //});
+    doc.write('<div class="">' + content
+        + '</div>');
+    doc.close();
+    var frameWindow = iframe.contentWindow;
+    frameWindow.close();
+    frameWindow.focus();
+    frameWindow.print();
+    frameWindow.print();
+}
 var removePrintArea = function (id) {
     $("iframe#" + id).remove();
 };

+ 151 - 0
kmall-admin/src/main/webapp/js/shop/goodstransportinfo.js

@@ -0,0 +1,151 @@
+$(function () {
+    $("#jqGrid").jqGrid({
+        url: '../goodstransportinfo/list',
+        datatype: "json",
+        colModel: [
+			{label: 'transId', name: 'transId', index: 'trans_id', key: true, hidden: true},
+			{label: '传输类型', name: 'transportType', index: 'transport_type', width: 80},
+			{label: '运输工具', name: 'transportTool', index: 'transport_tool', width: 80},
+			{label: '第三方商户编号', name: 'thirdMerchSn', index: 'third_merch_sn', width: 80},
+			{label: '是否在途', name: 'wayStatus', index: 'way_status', width: 80},
+			{label: '始发地', name: 'origin', index: 'origin', width: 80},
+			{label: '目的地', name: 'destination', index: 'destination', width: 80},
+			{label: '始发时间', name: 'startTime', index: 'start_time', width: 80},
+			{label: '到达时间', name: 'arrivalTime', index: 'arrival_time', width: 80},
+			{label: '创建人编号', name: 'createrSn', index: 'creater_sn', width: 80},
+			{label: '创建时间', name: 'createTime', index: 'create_time', width: 80},
+			{label: '修改人编号', name: 'moderSn', index: 'moder_sn', width: 80},
+			{label: '修改时间', name: 'modTime', index: 'mod_time', width: 80},
+			{label: '时间戳', name: 'tstm', index: 'tstm', width: 80}],
+		viewrecords: true,
+        height: 550,
+        rowNum: 10,
+        rowList: [10, 30, 50],
+        rownumbers: true,
+        rownumWidth: 25,
+        autowidth: true,
+        multiselect: true,
+        pager: "#jqGridPager",
+        jsonReader: {
+            root: "page.list",
+            page: "page.currPage",
+            total: "page.totalPage",
+            records: "page.totalCount"
+        },
+        prmNames: {
+            page: "page",
+            rows: "limit",
+            order: "order"
+        },
+        gridComplete: function () {
+            $("#jqGrid").closest(".ui-jqgrid-bdiv").css({"overflow-x": "hidden"});
+        }
+    });
+});
+
+let vm = new Vue({
+	el: '#rrapp',
+	data: {
+        showList: true,
+        title: null,
+		goodsTransportInfo: {},
+		ruleValidate: {
+			name: [
+				{required: true, message: '名称不能为空', trigger: 'blur'}
+			]
+		},
+		q: {
+		    name: ''
+		}
+	},
+	methods: {
+		query: function () {
+			vm.reload();
+		},
+		add: function () {
+			vm.showList = false;
+			vm.title = "新增";
+			vm.goodsTransportInfo = {};
+		},
+		update: function (event) {
+            let transId = getSelectedRow();
+			if (transId == null) {
+				return;
+			}
+			vm.showList = false;
+            vm.title = "修改";
+
+            vm.getInfo(transId)
+		},
+		saveOrUpdate: function (event) {
+            let url = vm.goodsTransportInfo.transId == null ? "../goodstransportinfo/save" : "../goodstransportinfo/update";
+			$.ajax({
+				type: "POST",
+			    url: url,
+			    contentType: "application/json",
+			    data: JSON.stringify(vm.goodsTransportInfo),
+                success: function (r) {
+                    if (r.code === 0) {
+                        alert('操作成功', function (index) {
+                            vm.reload();
+                        });
+                    } else {
+                        alert(r.msg);
+                    }
+                }
+			});
+		},
+		del: function (event) {
+            let transIds = getSelectedRows();
+			if (transIds == null){
+				return;
+			}
+
+			confirm('确定要删除选中的记录?', function () {
+				$.ajax({
+					type: "POST",
+				    url: "../goodstransportinfo/delete",
+				    contentType: "application/json",
+				    data: JSON.stringify(transIds),
+				    success: function (r) {
+						if (r.code == 0) {
+							alert('操作成功', function (index) {
+								$("#jqGrid").trigger("reloadGrid");
+							});
+						} else {
+							alert(r.msg);
+						}
+					}
+				});
+			});
+		},
+		getInfo: function(transId){
+			$.get("../goodstransportinfo/info/"+transId, function (r) {
+                vm.goodsTransportInfo = r.goodsTransportInfo;
+            });
+		},
+        reloadSearch: function() {
+            vm.q = {
+                name: ''
+            }
+            vm.reload();
+		},
+		reload: function (event) {
+			vm.showList = true;
+            let page = $("#jqGrid").jqGrid('getGridParam', 'page');
+			$("#jqGrid").jqGrid('setGridParam', {
+                postData: {'name': vm.q.name},
+                page: page
+            }).trigger("reloadGrid");
+            vm.handleReset('formValidate');
+		},
+        handleSubmit: function (name) {
+            handleSubmitValidate(this, name, function () {
+                vm.saveOrUpdate()
+            });
+        },
+        handleReset: function (name) {
+            handleResetForm(this, name);
+        }
+	}
+});

+ 193 - 0
kmall-admin/src/main/webapp/js/shop/goodstransportinfodetail.js

@@ -0,0 +1,193 @@
+$(function () {
+    $("#jqGrid").jqGrid({
+        url: '../goodstransportinfodetail/searchListByStatusAndSku',
+        datatype: "json",
+        colModel: [
+			{label: 'transItemId', name: 'transItemId', index: 'trans_item_id', key: true, hidden: true},
+			{label: '是否在途', name: 'wayStatus', index: 'way_status', width: 80,formatter: function (value) {
+                    if (value == '0') {
+                        return '是(0)';
+                    } else if(value == '1'){
+                        return '否(1)';
+                    }
+                }},
+			{label: '商品sku', name: 'sku', index: 'sku', width: 80},
+			{label: '供应商id', name: 'supplierId', index: 'supplier_id', width: 80},
+			{label: '原产地', name: 'originCountry', index: 'origin_country', width: 80},
+			{label: '数量', name: 'num', index: 'num', width: 80},
+			{label: '创建人编号', name: 'createrSn', index: 'creater_sn', width: 80},
+			{label: '创建时间', name: 'createTime', index: 'create_time', width: 80, align: 'center',width: 280,formatter: function (value) {
+                    return transDate(value,'yyyy-MM-dd hh:mm:ss');
+                }},
+			{label: '修改人编号', name: 'moderSn', index: 'moder_sn', width: 80},
+			{label: '修改时间', name: 'modTime', index: 'mod_time', width: 80, align: 'center',width: 280,formatter: function (value) {
+                    return transDate(value,'yyyy-MM-dd hh:mm:ss');
+                }},
+			{label: '时间戳', name: 'tstm', index: 'tstm', width: 80}],
+		viewrecords: true,
+        height: 550,
+        rowNum: 10,
+        rowList: [10, 30, 50],
+        rownumbers: true,
+        rownumWidth: 25,
+        autowidth: true,
+        multiselect: true,
+        pager: "#jqGridPager",
+        jsonReader: {
+            root: "page.list",
+            page: "page.currPage",
+            total: "page.totalPage",
+            records: "page.totalCount"
+        },
+        prmNames: {
+            page: "page",
+            rows: "limit",
+            order: "order"
+        },
+        gridComplete: function () {
+            $("#jqGrid").closest(".ui-jqgrid-bdiv").css({"overflow-x": "hidden"});
+        }
+    });
+});
+
+let vm = new Vue({
+	el: '#rrapp',
+	data: {
+        showList: true,
+        title: null,
+		goodsTransportInfoDetail: {},
+        ruleValidate: {
+            sku:{required: true, message: 'sku不能为空', trigger: 'blur'}
+            // wayStatus:{required: true, message: '是否在途不能为空', trigger: 'blur'}
+        },
+		q: {
+            wayStatus: null,
+			sku: null
+		}
+	},
+	methods: {
+		query: function () {
+			vm.reload();
+		},
+		add: function () {
+			vm.showList = false;
+			vm.title = "新增";
+			vm.goodsTransportInfoDetail = {};
+		},
+		update: function (event) {
+            let transItemId = getSelectedRow();
+			if (transItemId == null) {
+				return;
+			}
+			vm.showList = false;
+            vm.title = "修改";
+
+            vm.getInfo(transItemId)
+		},
+		saveOrUpdate: function (event) {
+            let url = vm.goodsTransportInfoDetail.transItemId == null ? "../goodstransportinfodetail/save" : "../goodstransportinfodetail/update";
+			$.ajax({
+				type: "POST",
+			    url: url,
+			    contentType: "application/json",
+			    data: JSON.stringify(vm.goodsTransportInfoDetail),
+                success: function (r) {
+                    if (r.code === 0) {
+                        alert('操作成功', function (index) {
+                            vm.reload();
+                        });
+                    } else {
+                        alert(r.msg);
+                    }
+                }
+			});
+		},
+		del: function (event) {
+            let transItemIds = getSelectedRows();
+			if (transItemIds == null){
+				return;
+			}
+
+			confirm('确定要删除选中的记录?', function () {
+				$.ajax({
+					type: "POST",
+				    url: "../goodstransportinfodetail/delete",
+				    contentType: "application/json",
+				    data: JSON.stringify(transItemIds),
+				    success: function (r) {
+						if (r.code == 0) {
+							alert('操作成功', function (index) {
+								$("#jqGrid").trigger("reloadGrid");
+							});
+						} else {
+							alert(r.msg);
+						}
+					}
+				});
+			});
+		},
+		getInfo: function(transItemId){
+			$.get("../goodstransportinfodetail/info/"+transItemId, function (r) {
+                vm.goodsTransportInfoDetail = r.goodsTransportInfoDetail;
+            });
+		},
+        reloadSearch: function() {
+            vm.q = {
+                wayStatus: null,
+                sku: null
+            }
+            vm.reload();
+		},
+		reload: function (event) {
+			vm.showList = true;
+            let page = $("#jqGrid").jqGrid('getGridParam', 'page');
+			$("#jqGrid").jqGrid('setGridParam', {
+                postData: {'sku': vm.q.sku,'wayStatus' : vm.q.wayStatus},
+                page: page
+            }).trigger("reloadGrid");
+            vm.handleReset('formValidate');
+		},
+        handleSubmit: function (name) {
+            handleSubmitValidate(this, name, function () {
+                vm.saveOrUpdate()
+            });
+        },
+        handleReset: function (name) {
+            handleResetForm(this, name);
+        },
+
+        uploadExcelSuccess: function () {
+            alert('上传成功', function (index) {
+                $("#jqGrid").trigger("reloadGrid");
+            });
+        },
+        uploadExcelError: function () {
+            alert('上传出现异常');
+        },
+
+        uploadExcelSuccess: function (data) {
+            if(data.code==0){
+                alert('导入成功', function (index) {
+                    vm.reload();
+                });
+            }else{
+                if(data.msg == '导入成功!'){
+                    alert(data.msg);
+                    vm.reload();
+                }else {
+                    alert(data.msg);
+                }
+            }
+        },
+        uploadExcelError: function (data) {
+            console.log(data);
+            alert('上传出现异常,请重试!');
+        },
+        uploadExcelFormatError: function (file) {
+            this.$Notice.warning({
+                title: '文件格式不正确',
+                desc: '文件 ' + file.name + ' 格式不正确,请上传 xls 或 xlsx 格式的文件。'
+            });
+        }
+	}
+});

+ 2 - 6
kmall-admin/src/main/webapp/js/vip/mall2memberconsumptionrecords.js

@@ -9,11 +9,7 @@ $(function () {
 			{label: '消费时间', name: 'consumptionTime', index: 'consumption_time', width: 80},
 			{label: '消费门店id', name: 'shopSn', index: 'shop_sn', width: 80},
 			{label: '是否使用生日优惠', name: 'isUseBirthdayOffer', index: 'is_use_birthday_offer', width: 80},
-			{label: '+创建人编号', name: 'createrSn', index: 'creater_sn', width: 80},
-			{label: '+创建时间,yyyy-MM-dd HH:mm:ss', name: 'createTime', index: 'create_time', width: 80},
-			{label: '+修改人编号', name: 'moderSn', index: 'moder_sn', width: 80},
-			{label: '+修改时间,yyyy-MM-dd HH:mm:ss', name: 'modTime', index: 'mod_time', width: 80},
-			{label: '+时间戳', name: 'tstm', index: 'tstm', width: 80}],
+			],
 		viewrecords: true,
         height: 550,
         rowNum: 10,
@@ -145,4 +141,4 @@ let vm = new Vue({
             handleResetForm(this, name);
         }
 	}
-});
+});

+ 2 - 6
kmall-admin/src/main/webapp/js/vip/mall2memberpoints.js

@@ -7,11 +7,7 @@ $(function () {
 			{label: '用户id', name: 'userId', index: 'user_id', width: 80},
 			{label: '积分数', name: 'points', index: 'points', width: 80},
 			{label: '积分到期时间', name: 'pointsExpireDate', index: 'points_expire_date', width: 80},
-			{label: '+创建人编号', name: 'createrSn', index: 'creater_sn', width: 80},
-			{label: '+创建时间,yyyy-MM-dd HH:mm:ss', name: 'createTime', index: 'create_time', width: 80},
-			{label: '+修改人编号', name: 'moderSn', index: 'moder_sn', width: 80},
-			{label: '+修改时间,yyyy-MM-dd HH:mm:ss', name: 'modTime', index: 'mod_time', width: 80},
-			{label: '+时间戳', name: 'tstm', index: 'tstm', width: 80}],
+			],
 		viewrecords: true,
         height: 550,
         rowNum: 10,
@@ -143,4 +139,4 @@ let vm = new Vue({
             handleResetForm(this, name);
         }
 	}
-});
+});

+ 2 - 6
kmall-admin/src/main/webapp/js/vip/mall2pointsrules.js

@@ -8,11 +8,7 @@ $(function () {
 			{label: '积分规则适用开始时间', name: 'pointsBeginTime', index: 'points_begin_time', width: 80},
 			{label: '积分规则适用结束时间', name: 'pointsEndTime', index: 'points_end_time', width: 80},
 			{label: '积分规则是否有效', name: 'isValid', index: 'is_valid', width: 80},
-			{label: '+创建人编号', name: 'createrSn', index: 'creater_sn', width: 80},
-			{label: '+创建时间,yyyy-MM-dd HH:mm:ss', name: 'createTime', index: 'create_time', width: 80},
-			{label: '+修改人编号', name: 'moderSn', index: 'moder_sn', width: 80},
-			{label: '+修改时间,yyyy-MM-dd HH:mm:ss', name: 'modTime', index: 'mod_time', width: 80},
-			{label: '+时间戳', name: 'tstm', index: 'tstm', width: 80}],
+			],
 		viewrecords: true,
         height: 550,
         rowNum: 10,
@@ -144,4 +140,4 @@ let vm = new Vue({
             handleResetForm(this, name);
         }
 	}
-});
+});

BIN
kmall-admin/src/main/webapp/statics/file/store_topic_goods_export_yyyy_mm_dd_v1.0.0.xlsx


+ 2 - 0
kmall-common/src/main/java/com/kmall/common/constant/JxlsXmlTemplateName.java

@@ -16,6 +16,8 @@ public class JxlsXmlTemplateName {
     public static final String SYS_USER_DTO_LIST = "/XmlTemplate/SysUserDtoList.xml";
     //门店商品导入
     public static final String STORE_GOODS_DTO_LIST = "/XmlTemplate/StoreGoodsDtoList.xml";
+    //活动商品价格导入
+    public static final String STORE_TOPIC_DTO_LIST = "/XmlTemplate/StoreTopicDtoList.xml";
 
     public static final String STORE_ID_DTO_LIST = "/XmlTemplate/StoreIdDtoList.xml";