fix: app用户登录时候后台地址问题

main^2
dearlin 2023-12-27 10:21:55 +08:00
parent c346cd9d4e
commit 6a7ec92c75
4 changed files with 51 additions and 49 deletions

View File

@ -70,19 +70,19 @@ public class LoginController extends BaseController {
@Autowired @Autowired
private PhotoService photoService; private PhotoService photoService;
@Value("${czks-useridentity}") // @Value("${czks-useridentity}")
private String czksIdentity; // private String czksIdentity;
@Value("${czks-baseimgpath}") // @Value("${czks-baseimgpath}")
private String czksBaseimgpath; // private String czksBaseimgpath;
@Value("${czks-backendaddr}") // @Value("${czks-backendaddr}")
private String czksBackendaddr; // private String czksBackendaddr;
//
@Value("${gwj-useridentity}") // @Value("${gwj-useridentity}")
private String gwjIdentity; // private String gwjIdentity;
@Value("${gwj-baseimgpath}") // @Value("${gwj-baseimgpath}")
private String gwjBaseimgpath; // private String gwjBaseimgpath;
@Value("${gwj-backendaddr}") // @Value("${gwj-backendaddr}")
private String gwjBackendaddr; // private String gwjBackendaddr;
@Autowired @Autowired
private CorpPathService corpPathService; private CorpPathService corpPathService;
@ -187,24 +187,24 @@ public class LoginController extends BaseController {
return map; return map;
} }
// 判断是不是沧州矿石的用户 // 判断是不是沧州矿石的用户
if (czksIdentity.equals(pd.getString("USER_IDENTITY"))) { // if (czksIdentity.equals(pd.getString("USER_IDENTITY"))) {
// 沧州矿石的用户 // // 沧州矿石的用户
// 用户标识 // // 用户标识
map.put("USER_IDENTITY", czksIdentity); // map.put("USER_IDENTITY", czksIdentity);
// 图片路径 // // 图片路径
map.put("baseImgPath", czksBaseimgpath); // map.put("baseImgPath", czksBaseimgpath);
// 后台地址 // // 后台地址
map.put("BACKENDADDR", czksBackendaddr); // map.put("BACKENDADDR", czksBackendaddr);
} // }
if ("".equals(pd.getString("USER_IDENTITY"))) { // if ("".equals(pd.getString("USER_IDENTITY"))) {
// 港股的用户 // // 港股的用户
// 用户标识 // // 用户标识
map.put("USER_IDENTITY", gwjIdentity); // map.put("USER_IDENTITY", gwjIdentity);
// 图片路径 // // 图片路径
map.put("baseImgPath", gwjBaseimgpath); // map.put("baseImgPath", gwjBaseimgpath);
// 后台地址 // // 后台地址
map.put("BACKENDADDR", gwjBackendaddr); // map.put("BACKENDADDR", gwjBackendaddr);
} // }
PageData cpd = corpinfoService.findById(pd); PageData cpd = corpinfoService.findById(pd);
//System.out.println(cpd.getString("ISUSE")); //System.out.println(cpd.getString("ISUSE"));
if (cpd != null) { if (cpd != null) {
@ -291,12 +291,14 @@ public class LoginController extends BaseController {
//查询该用户或企业的图片和后端地址 //查询该用户或企业的图片和后端地址
if (!Tools.isEmpty(pd.getString("CORPINFO_ID")) && !pd.getString("CORPINFO_ID").equals("1")) { if (!Tools.isEmpty(pd.getString("CORPINFO_ID")) && !pd.getString("CORPINFO_ID").equals("1")) {
PageData pathData = corpPathService.getCorpPathByCorpId(pd); PageData pathData = corpPathService.getCorpPathByCorpId(pd);
map.put("picPath",pathData.getString("PIC_PATH")); map.put("baseImgPath",pathData.getString("PIC_PATH"));
map.put("backEndPath", pathData.getString("BACK_END_PATH")); map.put("USER_IDENTITY",pathData.getString("USER_IDENTITY"));
map.put("BACKENDADDR", pathData.getString("BACK_END_PATH"));
} else { } else {
PageData pathData = corpPathService.getCorpPathByPersonInfo(pd); PageData pathData = corpPathService.getCorpPathByPersonInfo(pd);
map.put("picPath", pathData.getString("PIC_PATH")); map.put("baseImgPath",pathData.getString("PIC_PATH"));
map.put("backEndPath", pathData.getString("BACK_END_PATH")); map.put("USER_IDENTITY",pathData.getString("USER_IDENTITY"));
map.put("BACKENDADDR", pathData.getString("BACK_END_PATH"));
} }
} }
} else { } else {

View File

@ -1,13 +1,11 @@
datasource.no1.driver-class-name: com.mysql.cj.jdbc.Driver datasource.no1.driver-class-name: com.mysql.cj.jdbc.Driver
datasource.no1.url=jdbc:mysql://192.168.0.17:3306/qa-gwj-prevention?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=utf-8 datasource.no1.url=jdbc:mysql://39.101.130.96:33068/qa-gwj-prevention?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=utf-8
datasource.no1.username=root datasource.no1.username=root
datasource.no1.password=root datasource.no1.password=Mysql@zcloud88888
datasource.no2.driver-class-name: com.mysql.cj.jdbc.Driver datasource.no2.driver-class-name: com.mysql.cj.jdbc.Driver
datasource.no2.url=jdbc:mysql://192.168.0.17:3306/qa-gwj-regulatory?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=utf-8 datasource.no2.url=jdbc:mysql://39.101.130.96:33068/qa-gwj-regulatory?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=utf-8
datasource.no2.username=root datasource.no2.username=root
datasource.no2.password=root datasource.no2.password=Mysql@zcloud88888
#druid??? #druid???
@ -62,7 +60,8 @@ spring.main.banner-mode=off
#qa-regulatory-gwj.api.url=http://192.168.0.79:8008 #qa-regulatory-gwj.api.url=http://192.168.0.79:8008
corp.default.pic-path=https://qgqy.qhdsafety.com/file/ corp.default.pic-path=https://qgqy.qhdsafety.com/file/
corp.default.back-end-path=http://192.168.151.57:8092/ corp.default.back-end-path=http://192.168.0.31:8991/qa-prevention-gwj/
http.file.url=https://qgqy.qhdsafety.com/file/
preventionxgf.api.url=http://192.168.0.31:8992/qa-prevention-xgf/ preventionxgf.api.url=http://192.168.0.31:8992/qa-prevention-xgf/
qa-regulatory-gwj.api.url=http://192.168.0.31:8992/qa-regulatory-gwj/ qa-regulatory-gwj.api.url=http://192.168.0.31:8992/qa-regulatory-gwj/
@ -78,7 +77,7 @@ rocketmq.consumer.group2=edu-admin-edit
rocketmq.consumer.group1=edu-admin-add rocketmq.consumer.group1=edu-admin-add
#rocketmq.name-server=10.0.140.141:9876 #rocketmq.name-server=10.0.140.141:9876
#rocketmq.name-server=192.168.0.70:9876 #rocketmq.name-server=192.168.0.70:9876
rocketmq.name-server=192.168.0.31:9876 rocketmq.name-server=192.168.0.79:9876
rocketmq.producer.group=libmiddle rocketmq.producer.group=libmiddle
rocketmq.producer.send-message-timeout=3000 rocketmq.producer.send-message-timeout=3000
rocketmq.producer.compress-message-body-threshold=4096 rocketmq.producer.compress-message-body-threshold=4096
@ -94,8 +93,8 @@ mq.group.info=scheduled_tasks
mq.group.eightWork=scheduled_tasks_eightWork mq.group.eightWork=scheduled_tasks_eightWork
corp.default.pic-path=https://qgqy.qhdsafety.com/file/ #corp.default.pic-path=https://qgqy.qhdsafety.com/file/
corp.default.back-end-path=https://skqhdg.porthebei.com:9004/file/ #corp.default.back-end-path=https://skqhdg.porthebei.com:9004/file/
#用户标识 #用户标识

View File

@ -2,9 +2,9 @@ spring.application.name=qa-prevention-gwj
server.port=8091 server.port=8091
#?? #??
spring.profiles.active=local #spring.profiles.active=local
#<23><><EFBFBD><EFBFBD>31ʱʹ<CAB1><CAB9> #<23><><EFBFBD><EFBFBD>31ʱʹ<CAB1><CAB9>
#spring.profiles.active=dev spring.profiles.active=dev
#?? #??
#spring.profiles.active=master #spring.profiles.active=master

View File

@ -12,7 +12,8 @@
CORP_PATH_ID, CORP_PATH_ID,
CORPINFO_ID, CORPINFO_ID,
PIC_PATH, PIC_PATH,
BACK_END_PATH BACK_END_PATH,
USER_IDENTITY
</sql> </sql>
<!-- 字段 --> <!-- 字段 -->
@ -37,7 +38,7 @@
from from
<include refid="tableName"/> <include refid="tableName"/>
where where
CORPINFO_ID = #{corpId} CORPINFO_ID = #{CORPINFO_ID}
</select> </select>
<select id="getCorpPathByPersonInfo" resultType="pd"> <select id="getCorpPathByPersonInfo" resultType="pd">