Explorar el Código

Merge remote-tracking branch 'origin/ScrmStores' into ScrmStores

yjwang hace 1 mes
padre
commit
f9f72576e4

+ 0 - 6
fs-admin/src/main/java/com/fs/hisStore/controller/FsStoreScrmController.java

@@ -100,9 +100,6 @@ public class FsStoreScrmController extends BaseController {
     {
         startPage();
         List<FsStoreScrm> list = fsStoreService.selectFsStoreList(fsStore);
-        for (FsStoreScrm store : list) {
-            store.setPhone(ParseUtils.parsePhone(store.getPhone()));
-        }
         return getDataTable(list);
     }
 
@@ -123,9 +120,6 @@ public class FsStoreScrmController extends BaseController {
     {
         storeAuditLogUtil.generateOperId();
         List<FsStoreScrm> list = fsStoreService.selectFsStoreList(fsStore);
-        for (FsStoreScrm store : list) {
-            store.setPhone(ParseUtils.parsePhone(store.getPhone()));
-        }
         ExcelUtil<FsStoreScrm> util = new ExcelUtil<FsStoreScrm>(FsStoreScrm.class);
         return util.exportExcel(list, "店铺管理数据");
     }

+ 15 - 0
fs-service/src/main/java/com/fs/hisStore/domain/FsStoreScrm.java

@@ -461,6 +461,11 @@ public class FsStoreScrm extends BaseEntity {
      * **/
     private LocalDate qualificationUpdateTime;
 
+    /**
+     * 下次需要更新时间
+     * **/
+    private LocalDate nextQualificationUpdateTime;
+
     /**
      * 资质更新剩余天数
      **/
@@ -526,4 +531,14 @@ public class FsStoreScrm extends BaseEntity {
      * **/
     private Long permStatus;
 
+    /**
+     * 资质更新剩余天数最小值
+     **/
+    private Integer daysDiffMin;
+
+    /**
+     * 资质更新剩余天数最大值
+     **/
+    private Integer daysDiffMax;
+
 }

+ 23 - 2
fs-service/src/main/resources/mapper/hisStore/FsStoreScrmMapper.xml

@@ -882,7 +882,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     <select id="selecStorePageList" resultType="com.fs.hisStore.domain.FsStoreScrm">
         SELECT
         store_id,full_name,delivery_type,send_phone, brokerage_rate,refund_phone,refund_address,refund_consignee,
-        city_ids, store_name, descs, brokerage_type,logo_url, address, lng, lat, phone, license_images,
+        city_ids, store_name, descs, brokerage_type,logo_url, address, lng, lat,
+        CASE
+            WHEN phone IS NOT NULL AND phone != '' THEN CONCAT(LEFT(phone, 3), '****', RIGHT(phone, 4))
+            ELSE phone
+        END AS phone,
+        license_images,
         status, create_time, update_time, sales_count, balance, total_money, is_audit, account, password, shipping_type,
         enterprise_address,legal_person_name,unified_social_credit_code,
         business_scope,selectable_product_types,business_license,business_license_expire_start,business_license_expire_end,drug_license,
@@ -895,7 +900,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         drug_code,medical_device1_code,medical_device2_code,medical_device3_code,food_code,medical_code,other_special_qualification_code,
         quality_assurance_agreement_code,settlement_agreement_code,title_name_one,title_Name_two,title_Name_three,
         qualification_update_time,
-        DATEDIFF(qualification_update_time, NOW()) AS days_diff,
+        DATE_ADD(qualification_update_time, INTERVAL 6 MONTH) as next_qualification_update_time,
+        DATEDIFF(DATE_ADD(qualification_update_time, INTERVAL 6 MONTH), NOW()) AS days_diff,
         ( SELECT COUNT(*) FROM fs_store_product_scrm sps WHERE sps.store_id = ss.store_id ) AS productCount
         FROM
         fs_store_scrm ss
@@ -907,6 +913,21 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isAudit != null "> and is_audit = #{isAudit}</if>
             <if test="account != null  and account != ''"> and account like concat('%', #{account}, '%')</if>
             <if test="queryStoreId != null "> or store_id = #{queryStoreId}</if>
+            <if test="daysDiffMax != null">
+                <!-- 判断剩余天数范围 -->
+                <if test="daysDiffMax == 0">
+                    AND DATEDIFF(DATE_ADD(qualification_update_time, INTERVAL 6 MONTH), NOW()) &lt; 0
+                </if>
+                <if test="daysDiffMax == 7">
+                    AND DATEDIFF(DATE_ADD(qualification_update_time, INTERVAL 6 MONTH), NOW()) BETWEEN 1 AND 7
+                </if>
+                <if test="daysDiffMax == 15">
+                    AND DATEDIFF(DATE_ADD(qualification_update_time, INTERVAL 6 MONTH), NOW()) BETWEEN 1 AND 15
+                </if>
+                <if test="daysDiffMax == 30">
+                    AND DATEDIFF(DATE_ADD(qualification_update_time, INTERVAL 6 MONTH), NOW()) BETWEEN 1 AND 30
+                </if>
+            </if>
         </where>
         order by store_id desc
     </select>

+ 22 - 3
fs-store/src/main/java/com/fs/hisStore/controller/store/FsStoreOrderScrmController.java

@@ -66,6 +66,9 @@ import java.util.Map;
 public class FsStoreOrderScrmController extends BaseController
 {
 
+    @Autowired
+    private IFsStoreOrderScrmCommentService fsStoreOrderScrmCommentService;
+
     @Autowired
     private IFsUserService userService;
     @Autowired
@@ -117,6 +120,25 @@ public class FsStoreOrderScrmController extends BaseController
     @Autowired
     private FsStoreVerifyCodeScrmMapper fsStoreVerifyCodeService;
 
+    /**
+     * 获取订单评价详细信息
+     */
+    @GetMapping(value = "/comment/{commentId}")
+    public AjaxResult getCommentInfo(@PathVariable("commentId") Long commentId)
+    {
+        return AjaxResult.success(fsStoreOrderScrmCommentService.selectFsStoreOrderScrmCommentByCommentId(commentId));
+    }
+
+    /**
+     * 修改订单评价
+     */
+    @Log(title = "订单评价", businessType = BusinessType.UPDATE)
+    @PutMapping("/comment")
+    public AjaxResult edit(@RequestBody FsStoreOrderScrmComment fsStoreOrderScrmComment)
+    {
+        return toAjax(fsStoreOrderScrmCommentService.updateFsStoreOrderScrmComment(fsStoreOrderScrmComment));
+    }
+
     /**
      * 查询订单列表
      */
@@ -186,9 +208,6 @@ public class FsStoreOrderScrmController extends BaseController
         return AjaxResult.success(message);
     }
 
-    @Autowired
-    IFsStoreOrderScrmCommentService fsStoreOrderScrmCommentService;
-
     /**
      * 获取订单详细信息
      */

+ 9 - 0
fs-store/src/main/java/com/fs/store/controller/store/FsStoreOrderController.java

@@ -196,6 +196,15 @@ public class FsStoreOrderController extends BaseController
     }
 
 
+    /**
+     * 获取订单评价详细信息
+     */
+    @GetMapping(value = "/comment/{commentId}")
+    public AjaxResult getCommentInfo(@PathVariable("commentId") Long commentId)
+    {
+        return AjaxResult.success(fsStoreOrderScrmCommentService.selectFsStoreOrderScrmCommentByCommentId(commentId));
+    }
+
     /**
      * 修改订单评价
      */