From ab8b3af2bc6460dba2a807d27004e128d772ab24 Mon Sep 17 00:00:00 2001 From: YYC <1833023622@qq.com> Date: 星期五, 12 七月 2024 09:30:09 +0800 Subject: [PATCH] 增城配置 --- src/main/java/com/fzzy/async/fzzy40/impl/Fzzy40Sync1023.java | 18 ++++++-- src/main/resources/application-pro5352.yml | 57 ++++++++++++++++++++++++++++ 2 files changed, 70 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/fzzy/async/fzzy40/impl/Fzzy40Sync1023.java b/src/main/java/com/fzzy/async/fzzy40/impl/Fzzy40Sync1023.java index a575d00..95c015e 100644 --- a/src/main/java/com/fzzy/async/fzzy40/impl/Fzzy40Sync1023.java +++ b/src/main/java/com/fzzy/async/fzzy40/impl/Fzzy40Sync1023.java @@ -5,6 +5,7 @@ import com.fzzy.api.data.PushProtocol; import com.fzzy.api.entity.*; import com.fzzy.api.service.ApiCommonService; +import com.fzzy.api.service.ApiTriggerService; import com.fzzy.api.utils.ContextUtil; import com.fzzy.api.view.repository.*; import com.fzzy.async.fzzy40.entity.*; @@ -54,6 +55,8 @@ private ApiCommonService commonService; @Autowired private ApiInfoDataRep apiInfoDataRep; + @Autowired + private ApiTriggerService apiTriggerService; /** @@ -64,7 +67,7 @@ * @param end */ public void syncData(String kqdm, String deptId, Date start, Date end) { - log.info("-------------1023鎺ュ彛璁惧淇℃伅寮�濮嬪悓姝�------------------"); + log.info("-------------1023鎺ュ彛鐔忚捀澶囨淇℃伅寮�濮嬪悓姝�------------------"); //鍚屾鏁版嵁锛屽彧璁板綍澶辫触鐨勪俊鎭� ApiLog apiLog = new ApiLog(); @@ -113,6 +116,9 @@ GD2022Api1023.setYjlx(data.getDrugType()); GD2022Api1023.setLqrq(data.getLqsj()); GD2022Api1023.setZhgxsj(data.getUpdateTime()); + if(data.getLqr().contains("銆�")){ + GD2022Api1023.setLqr(data.getLqr().replace('銆�', '|')); + } //鍌ㄧ伯绮儏鏄庣粏琛� List<Fz40DrugLogDtl> dtls = drugLogDtlRep.listDrugLogDtl(data.getXzbm()); @@ -121,10 +127,12 @@ BeanUtils.copyProperties(data, gd2022Api1023Dtl); if (null != api1105) { gd2022Api1023Dtl.setCfmc(api1105.getHwmc()); - gd2022Api1023Dtl.setCfdm(api1105.getHwdm().substring(0,25)); + gd2022Api1023Dtl.setCfdm(api1105.getHwdm().substring(0, 25)); } - gd2022Api1023Dtl.setLspzdm(data.getFoodVariety()); + //绮鍝佺 + String mappingCode = apiTriggerService.getMappingCode(Constant.TRIGGER_P_LSPZ, data.getFoodVariety()); + gd2022Api1023Dtl.setLspzdm(mappingCode); gd2022Api1023Dtl.setLsxzdm(data.getFoodType()); gd2022Api1023Dtl.setLsdjdm(data.getFoodLevel()); gd2022Api1023Dtl.setLssl(data.getNumber()); @@ -209,8 +217,8 @@ } } catch (Exception e) { - log.error("---璁惧淇℃伅鍚屾鎵ц澶辫触----{}", e.toString()); - apiLog.setResult("璁惧淇℃伅鍚屾鎵ц澶辫触锛�" + e.getMessage()); + log.error("---鐔忚捀澶囨鍚屾鎵ц澶辫触----{}", e.toString()); + apiLog.setResult("鐔忚捀澶囨淇℃伅鍚屾鎵ц澶辫触锛�" + e.getMessage()); apiLogRep.save(apiLog); } } diff --git a/src/main/resources/application-pro5352.yml b/src/main/resources/application-pro5352.yml new file mode 100644 index 0000000..3758a27 --- /dev/null +++ b/src/main/resources/application-pro5352.yml @@ -0,0 +1,57 @@ +########################## 骞夸笢澧炲煄鍐烽摼 ########################## +server: + port: 8090 + jetty: + max-http-post-size: 209715200 + tomcat: + max-http-post-size: 209715200 +spring: + datasource: + #涓绘暟鎹簮 + primary: + url: jdbc:mysql://127.0.0.1:3306/igds_api?useUnicode=true&characterEncoding=utf-8 + username: root + password: Fzzy@#$%5432..K + driver-class-name: com.mysql.jdbc.Driver + #娆℃暟鎹簮 + secondary: + url: jdbc:mysql://127.0.0.1:3306/igds_master?useUnicode=true&characterEncoding=utf-8 + username: root + password: Fzzy@#$%5432..K + driver-class-name: com.mysql.jdbc.Driver + jpa: + #涓籮pa閰嶇疆 + primary: + show-sql: true + properties: + hibernate: + hbm2ddl: + auto: update + dialect: org.hibernate.dialect.MySQL5InnoDBDialect + #娆pa閰嶇疆 + secondary: + show-sql: true + properties: + hibernate: + hbm2ddl: + auto: none + dialect: org.hibernate.dialect.MySQL5InnoDBDialect + # Redis鐩稿叧閰嶇疆 + redis: + database: 1 + host: 127.0.0.1 + port: 6379 + password: Redispwd.. + # 杩炴帴姹犳渶澶ц繛鎺ユ暟锛堜娇鐢ㄨ礋鍊艰〃绀烘病鏈夐檺鍒讹級 + pool: + max-active: 200 + max-wait: -1 + max-idle: 10 + min-idle: 0 + timeout: 6000 +igds: + default: + companyId: 5352 + + file-path: D:/IGDS-API/FILE/ + img-path: D:/IGDS/FILE/ \ No newline at end of file -- Gitblit v1.9.3