Parcourir la source

:art: 之前未提交代码

Twelve615 il y a 1 an
Parent
commit
09078342a3

+ 2 - 2
crmeb-front/src/main/resources/application-dev.yml

@@ -78,8 +78,8 @@ logging:
 mybatis-plus:
   mapper-locations: classpath*:mapper/*/*Mapper.xml #xml扫描,多个目录用逗号或者分号分隔(告诉 Mapper 所对应的 XML 文件位置)
   # 配置slq打印日志
-  #  configuration:
-  #    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
+  configuration:
+    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
   global-config:
     db-config:
       #      logic-delete-field: isDel  #全局逻辑删除字段值 3.3.0开始支持,详情看下面。

+ 1 - 1
crmeb-front/src/main/resources/application-prod.yml

@@ -62,7 +62,7 @@ debug: true
 logging:
   level:
     io.swagger.*: error
-    com.zbjk.crmeb: debug
+    com.zbjk.crmeb: info
     org.springframework.boot.autoconfigure: ERROR
   config: classpath:logback-spring.xml
   file:

+ 4 - 4
crmeb-front/src/main/resources/logback-spring.xml

@@ -216,9 +216,9 @@
     <!-- 日志输出级别 -->
     <root level="INFO">
         <appender-ref ref="STDOUT"/>
-        <appender-ref ref="DEBUG_FILE" />
-        <appender-ref ref="INFO_FILE" />
-        <appender-ref ref="WARN_FILE" />
-        <appender-ref ref="ERROR_FILE" />
+<!--        <appender-ref ref="DEBUG_FILE" />-->
+<!--        <appender-ref ref="INFO_FILE" />-->
+<!--        <appender-ref ref="WARN_FILE" />-->
+<!--        <appender-ref ref="ERROR_FILE" />-->
     </root>
 </configuration>

+ 1 - 0
crmeb-service/src/main/java/com/zbkj/service/dao/UserDao.java

@@ -20,4 +20,5 @@ public interface UserDao extends BaseMapper<User> {
     List<UserSpreadPeopleItemResponse> getSpreadPeopleList(Map<String, Object> map);
 
     List<Integer> getParentId(Integer userId);
+    List<Integer> getParentById(Integer userId);
 }

+ 7 - 0
crmeb-service/src/main/java/com/zbkj/service/service/UserService.java

@@ -347,6 +347,13 @@ public interface UserService extends IService<User> {
     List<Integer> getParentId(Integer userId);
 
     /**
+     * 通过企业子账户id查询企业主账户id
+     * @param userId
+     * @return
+     */
+    List<Integer> getParentById(Integer userId);
+
+    /**
      * 通过账号获取用户
      * @param openId
      * @return

+ 3 - 2
crmeb-service/src/main/java/com/zbkj/service/service/impl/OrderServiceImpl.java

@@ -382,8 +382,9 @@ public class OrderServiceImpl extends ServiceImpl<OrderDao, Order> implements Or
             pageResponse.setShippingType(merchantOrder.getShippingType());
             pageResponse.setUserRemark(merchantOrder.getUserRemark());
             pageResponse.setMerRemark(merchantOrder.getMerchantRemark());
-            pageResponse.setNickName(userMap.get(e.getUid()).getNickname());
-            pageResponse.setIsLogoff(userMap.get(e.getUid()).getIsLogoff());
+            User user = userMap.get(e.getUid());
+            pageResponse.setNickName(user == null ? "" : user.getNickname());
+            pageResponse.setIsLogoff(user == null || user.getIsLogoff());
             pageResponse.setIsRemit(e.getIsRemit());
             pageResponse.setQyName(e.getProcureUnit());
             pageResponse.setQyId(e.getQyId());

+ 5 - 0
crmeb-service/src/main/java/com/zbkj/service/service/impl/UserServiceImpl.java

@@ -1348,6 +1348,11 @@ public class UserServiceImpl extends ServiceImpl<UserDao, User> implements UserS
     }
 
     @Override
+    public List<Integer> getParentById(Integer userId) {
+        return dao.getParentById(userId);
+    }
+
+    @Override
     public User getByAccount(String openId) {
         LambdaQueryWrapper<User> lqw = new LambdaQueryWrapper<>();
         lqw.eq(User::getAccount, openId);

+ 1 - 1
crmeb-service/src/main/resources/mapper/cat/CartShareMapper.xml

@@ -3,7 +3,7 @@
 <mapper namespace="com.zbkj.service.dao.CartShareDao">
 
 <update id="cartShareId">
-            UPDATE `crmebjava`.`eb_cart_share`
+            UPDATE `eb_cart_share`
                 SET `is_invalid` = #{isInvalid}
             where`share_id` = #{cartShareId}
     </update>

+ 9 - 0
crmeb-service/src/main/resources/mapper/user/UserMapper.xml

@@ -112,4 +112,13 @@
         WHERE
         	user_id = #{userId})
     </select>
+
+    <select id="getParentById" parameterType="java.lang.Integer" resultType="java.lang.Integer">
+        SELECT
+            enterprise_id
+        FROM
+            eb_user_bypassaccount
+        WHERE
+            user_id = #{userId}
+    </select>
 </mapper>