leon 4 年之前
父節點
當前提交
82ebbbf816

+ 2 - 0
src/main/java/com/mokamrp/privates/mapper/crawer/AppBaseBasicProfileMapper.java

@@ -1,5 +1,6 @@
 package com.mokamrp.privates.mapper.crawer;
 
+import com.baomidou.dynamic.datasource.annotation.DS;
 import com.mokamrp.privates.mapper.crawer.pojo.AppBaseBasicProfile;
 import com.baomidou.mybatisplus.core.mapper.BaseMapper;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
@@ -16,6 +17,7 @@ import java.util.List;
  * @since 2021-11-29
  */
 @Component
+@DS("crawerdb")
 public interface AppBaseBasicProfileMapper extends BaseMapper<AppBaseBasicProfile> {
     public List<AppBaseBasicProfile> getList(Page<AppBaseBasicProfile> pageObj);
 }

+ 2 - 0
src/main/java/com/mokamrp/privates/mapper/crawer/SettingpageMapper.java

@@ -1,5 +1,6 @@
 package com.mokamrp.privates.mapper.crawer;
 
+import com.baomidou.dynamic.datasource.annotation.DS;
 import com.mokamrp.privates.mapper.crawer.pojo.Settingpage;
 import com.baomidou.mybatisplus.core.mapper.BaseMapper;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
@@ -16,6 +17,7 @@ import java.util.List;
  * @since 2021-11-29
  */
 @Component
+@DS("crawerdb")
 public interface SettingpageMapper extends BaseMapper<Settingpage> {
     public List<Settingpage> getList(Page<Settingpage> pageObj);
 }

+ 2 - 0
src/main/java/com/mokamrp/privates/service/crawer/impl/AppBaseBasicProfileServiceImpl.java

@@ -1,5 +1,6 @@
 package com.mokamrp.privates.service.crawer.impl;
 
+import com.baomidou.dynamic.datasource.annotation.DS;
 import com.mokamrp.privates.mapper.crawer.pojo.AppBaseBasicProfile;
 import com.mokamrp.privates.mapper.crawer.AppBaseBasicProfileMapper;
 import com.mokamrp.privates.service.crawer.AppBaseBasicProfileService;
@@ -21,6 +22,7 @@ import java.util.*;
  * @since 2021-11-29
  */
 @Service
+@DS("crawerdb")
 public class AppBaseBasicProfileServiceImpl extends ServiceImpl<AppBaseBasicProfileMapper, AppBaseBasicProfile> implements AppBaseBasicProfileService {
 
     @Autowired

+ 2 - 0
src/main/java/com/mokamrp/privates/service/crawer/impl/SettingpageServiceImpl.java

@@ -1,5 +1,6 @@
 package com.mokamrp.privates.service.crawer.impl;
 
+import com.baomidou.dynamic.datasource.annotation.DS;
 import com.mokamrp.privates.mapper.crawer.pojo.Settingpage;
 import com.mokamrp.privates.mapper.crawer.SettingpageMapper;
 import com.mokamrp.privates.service.crawer.SettingpageService;
@@ -21,6 +22,7 @@ import java.util.*;
  * @since 2021-11-29
  */
 @Service
+@DS("crawerdb")
 public class SettingpageServiceImpl extends ServiceImpl<SettingpageMapper, Settingpage> implements SettingpageService {
 
     @Autowired

+ 1 - 2
src/main/java/com/mokamrp/privates/service/pangu/impl/FosterwxStationBindBoxServiceImpl.java

@@ -75,7 +75,6 @@ public class FosterwxStationBindBoxServiceImpl extends ServiceImpl<FosterwxStati
      * @param row
      * @return
      */
-    @Transactional(rollbackFor = Exception.class)
     public VoltaHandle<Boolean> importData(List<Map<String, String>> row, User authUser) throws Exception {
         VoltaHandle<Boolean> res = new VoltaHandle<>();
         if (row.size() <= 0) {
@@ -104,7 +103,7 @@ public class FosterwxStationBindBoxServiceImpl extends ServiceImpl<FosterwxStati
                 if (boxInfo == null) {
                     throw new Exception("第" + (i + 1) + "行,ghId 在珊瑚云不存在");
                 }
-                fosterwxStationBindBox.setBoxType(Integer.parseInt(boxInfo.get("box_type").toString()));
+                fosterwxStationBindBox.setBoxType(Integer.parseInt(boxInfo.get("boxType").toString()));
                 AppBaseBasicProfile appBaseBasicProfile =  appBaseBasicProfileService.getOne(
                         new QueryWrapper<AppBaseBasicProfile>().eq("primary_key",fosterwxStationBindBox.getGhId())
                 );