From eb49b39db4de118a2161fd2a57b96f8f1b84eade Mon Sep 17 00:00:00 2001
From: puhanshu <a9236326>
Date: 星期三, 05 一月 2022 18:11:01 +0800
Subject: [PATCH] 商家后台相关代码提交2

---
 springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ConvenientMerchantServiceImpl.java |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ConvenientMerchantServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ConvenientMerchantServiceImpl.java
index 2f8779f..6c9aa04 100644
--- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ConvenientMerchantServiceImpl.java
+++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ConvenientMerchantServiceImpl.java
@@ -432,4 +432,20 @@
         this.baseMapper.batchUpdateMerchantViewNum(viewVOList);
         return R.ok();
     }
+
+    /**
+     * check商家/店铺是否有效
+     * @param userId
+     * @return
+     */
+    @Override
+    public Boolean checkStoreIsValid(Long userId) {
+        R<LoginUserInfoVO> loginUserInfo = userService.getUserInfoByUserId(userId.toString());
+        LoginUserInfoVO loginUserInfoVO =
+                JSONObject.parseObject(JSONObject.toJSONString(loginUserInfo.getData()), LoginUserInfoVO.class);
+        if (isNull(loginUserInfoVO) || !loginUserInfoVO.getType().equals(10) || loginUserInfoVO.getStatus() != 1) {
+            return false;
+        }
+        return true;
+    }
 }

--
Gitblit v1.7.1