Commit e27c903b7a4185ef3e4ead4a087e3c3514f7367a
1 parent
b9c4450acb
Exists in
master
and in
6 other branches
儿保数据同步
Showing 7 changed files with 202 additions and 35 deletions
- platform-dal/src/main/java/com/lyms/platform/pojo/BabyCheckModel.java
- platform-job-index/src/main/java/com/lyms/platform/job/index/restore/data/ConvertHelper.java
- platform-job-index/src/main/java/com/lyms/platform/job/index/restore/data/SyncDataWork.java
- platform-job-index/src/main/resources/conf.properties
- platform-job-index/src/main/resources/spring/applicationContext-sync-data.xml
- platform-job-index/src/main/webapp/WEB-INF/lib/mainData.jar
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/Test.java
platform-dal/src/main/java/com/lyms/platform/pojo/BabyCheckModel.java
View file @
e27c903
... | ... | @@ -1612,5 +1612,154 @@ |
1612 | 1612 | } |
1613 | 1613 | } |
1614 | 1614 | |
1615 | + @Override | |
1616 | + public String toString() { | |
1617 | + return "BabyCheckModel{" + | |
1618 | + "id='" + id + '\'' + | |
1619 | + ", yn=" + yn + | |
1620 | + ", buildId='" + buildId + '\'' + | |
1621 | + ", checkDate=" + checkDate + | |
1622 | + ", ylSelect='" + ylSelect + '\'' + | |
1623 | + ", tcType=" + tcType + | |
1624 | + ", mainFoster='" + mainFoster + '\'' + | |
1625 | + ", feedType='" + feedType + '\'' + | |
1626 | + ", pee='" + pee + '\'' + | |
1627 | + ", excrement='" + excrement + '\'' + | |
1628 | + ", sleep='" + sleep + '\'' + | |
1629 | + ", activity='" + activity + '\'' + | |
1630 | + ", vitaminD='" + vitaminD + '\'' + | |
1631 | + ", assistFood='" + assistFood + '\'' + | |
1632 | + ", homeMeasure='" + homeMeasure + '\'' + | |
1633 | + ", morbidity='" + morbidity + '\'' + | |
1634 | + ", drugGllergic='" + drugGllergic + '\'' + | |
1635 | + ", temperature='" + temperature + '\'' + | |
1636 | + ", weight='" + weight + '\'' + | |
1637 | + ", height='" + height + '\'' + | |
1638 | + ", head='" + head + '\'' + | |
1639 | + ", heightWeight='" + heightWeight + '\'' + | |
1640 | + ", chestw='" + chestw + '\'' + | |
1641 | + ", growthEvaluate='" + growthEvaluate + '\'' + | |
1642 | + ", bilirubinHead='" + bilirubinHead + '\'' + | |
1643 | + ", bilirubinChest='" + bilirubinChest + '\'' + | |
1644 | + ", bilirubinBelly='" + bilirubinBelly + '\'' + | |
1645 | + ", bregma='" + bregma + '\'' + | |
1646 | + ", tooth='" + tooth + '\'' + | |
1647 | + ", faceColor='" + faceColor + '\'' + | |
1648 | + ", skin='" + skin + '\'' + | |
1649 | + ", eye='" + eye + '\'' + | |
1650 | + ", eyesight='" + eyesight + '\'' + | |
1651 | + ", ear='" + ear + '\'' + | |
1652 | + ", hearing='" + hearing + '\'' + | |
1653 | + ", neck='" + neck + '\'' + | |
1654 | + ", chest='" + chest + '\'' + | |
1655 | + ", belly='" + belly + '\'' + | |
1656 | + ", spineFours='" + spineFours + '\'' + | |
1657 | + ", portaGenitals='" + portaGenitals + '\'' + | |
1658 | + ", stepStatus='" + stepStatus + '\'' + | |
1659 | + ", stoopStatus='" + stoopStatus + '\'' + | |
1660 | + ", stoopSign='" + stoopSign + '\'' + | |
1661 | + ", nerve='" + nerve + '\'' + | |
1662 | + ", bonez='" + bonez + '\'' + | |
1663 | + ", hipJoint='" + hipJoint + '\'' + | |
1664 | + ", hemoglobin='" + hemoglobin + '\'' + | |
1665 | + ", whiteCell='" + whiteCell + '\'' + | |
1666 | + ", platelet='" + platelet + '\'' + | |
1667 | + ", otherBlood='" + otherBlood + '\'' + | |
1668 | + ", urineProtein='" + urineProtein + '\'' + | |
1669 | + ", urineSugar='" + urineSugar + '\'' + | |
1670 | + ", urineAcetone='" + urineAcetone + '\'' + | |
1671 | + ", hematuria='" + hematuria + '\'' + | |
1672 | + ", otherUrine='" + otherUrine + '\'' + | |
1673 | + ", diagnose='" + diagnose + '\'' + | |
1674 | + ", handlSuggest='" + handlSuggest + '\'' + | |
1675 | + ", guideSuggest='" + guideSuggest + '\'' + | |
1676 | + ", checkDoctor='" + checkDoctor + '\'' + | |
1677 | + ", nextDate=" + nextDate + | |
1678 | + ", highRisk=" + highRisk + | |
1679 | + ", modified=" + modified + | |
1680 | + ", created=" + created + | |
1681 | + ", hospitalId='" + hospitalId + '\'' + | |
1682 | + ", weightEvaluate='" + weightEvaluate + '\'' + | |
1683 | + ", heightEvaluate='" + heightEvaluate + '\'' + | |
1684 | + ", headEvaluate='" + headEvaluate + '\'' + | |
1685 | + ", birth=" + birth + | |
1686 | + ", checkMonth=" + checkMonth + | |
1687 | + ", sportsEvaluation='" + sportsEvaluation + '\'' + | |
1688 | + ", heartAction='" + heartAction + '\'' + | |
1689 | + ", askOther='" + askOther + '\'' + | |
1690 | + ", babyCheckOther='" + babyCheckOther + '\'' + | |
1691 | + ", assistCheckOther='" + assistCheckOther + '\'' + | |
1692 | + ", navel=" + navel + | |
1693 | + ", cnqk='" + cnqk + '\'' + | |
1694 | + ", mtcnNum='" + mtcnNum + '\'' + | |
1695 | + ", xbNum='" + xbNum + '\'' + | |
1696 | + ", dbNum='" + dbNum + '\'' + | |
1697 | + ", qdtlTime='" + qdtlTime + '\'' + | |
1698 | + ", pfhrTime='" + pfhrTime + '\'' + | |
1699 | + ", wssAd='" + wssAd + '\'' + | |
1700 | + ", douhbqk=" + douhbqk + | |
1701 | + ", kq='" + kq + '\'' + | |
1702 | + ", cyNum='" + cyNum + '\'' + | |
1703 | + ", qcNum='" + qcNum + '\'' + | |
1704 | + ", btt='" + btt + '\'' + | |
1705 | + ", xf='" + xf + '\'' + | |
1706 | + ", xlClass=" + xlClass + | |
1707 | + ", xldq='" + xldq + '\'' + | |
1708 | + ", nd='" + nd + '\'' + | |
1709 | + ", ygbmky='" + ygbmky + '\'' + | |
1710 | + ", ygbmkt='" + ygbmkt + '\'' + | |
1711 | + ", ygeky='" + ygeky + '\'' + | |
1712 | + ", ygekt='" + ygekt + '\'' + | |
1713 | + ", yghxkt='" + yghxkt + '\'' + | |
1714 | + ", wlTong='" + wlTong + '\'' + | |
1715 | + ", wlXin='" + wlXin + '\'' + | |
1716 | + ", wlGai='" + wlGai + '\'' + | |
1717 | + ", wlMei='" + wlMei + '\'' + | |
1718 | + ", wlTie='" + wlTie + '\'' + | |
1719 | + ", wlQian='" + wlQian + '\'' + | |
1720 | + ", wlGe='" + wlGe + '\'' + | |
1721 | + ", wlMeng='" + wlMeng + '\'' + | |
1722 | + ", ygbmkyNum='" + ygbmkyNum + '\'' + | |
1723 | + ", ygbmktNum='" + ygbmktNum + '\'' + | |
1724 | + ", ygekyNum='" + ygekyNum + '\'' + | |
1725 | + ", ygektNum='" + ygektNum + '\'' + | |
1726 | + ", yghxktNum='" + yghxktNum + '\'' + | |
1727 | + ", xqgbzam='" + xqgbzam + '\'' + | |
1728 | + ", xqgczam='" + xqgczam + '\'' + | |
1729 | + ", albumin='" + albumin + '\'' + | |
1730 | + ", totalBilirubin='" + totalBilirubin + '\'' + | |
1731 | + ", jhBilirubin='" + jhBilirubin + '\'' + | |
1732 | + ", bcgYs='" + bcgYs + '\'' + | |
1733 | + ", bcgXz='" + bcgXz + '\'' + | |
1734 | + ", bcgHbx='" + bcgHbx + '\'' + | |
1735 | + ", bcgBxb='" + bcgBxb + '\'' + | |
1736 | + ", bcgSpxb='" + bcgSpxb + '\'' + | |
1737 | + ", bcgZlxb='" + bcgZlxb + '\'' + | |
1738 | + ", bcgDfkl='" + bcgDfkl + '\'' + | |
1739 | + ", bcgZfkl='" + bcgZfkl + '\'' + | |
1740 | + ", bcgJxw='" + bcgJxw + '\'' + | |
1741 | + ", bcgZwxw='" + bcgZwxw + '\'' + | |
1742 | + ", bcgZbj='" + bcgZbj + '\'' + | |
1743 | + ", bcgZj='" + bcgZj + '\'' + | |
1744 | + ", bcgJsc='" + bcgJsc + '\'' + | |
1745 | + ", bcgYc='" + bcgYc + '\'' + | |
1746 | + ", bcgQw='" + bcgQw + '\'' + | |
1747 | + ", wssa='" + wssa + '\'' + | |
1748 | + ", jcwd='" + jcwd + '\'' + | |
1749 | + ", wsse='" + wsse + '\'' + | |
1750 | + ", rzfx=" + rzfx + | |
1751 | + ", chatSc=" + chatSc + | |
1752 | + ", yyfyTest=" + yyfyTest + | |
1753 | + ", zlcp='" + zlcp + '\'' + | |
1754 | + ", gdzsc='" + gdzsc + '\'' + | |
1755 | + ", ssfx='" + ssfx + '\'' + | |
1756 | + ", gjzh='" + gjzh + '\'' + | |
1757 | + ", rxnl='" + rxnl + '\'' + | |
1758 | + ", xxbsc='" + xxbsc + '\'' + | |
1759 | + ", zlsc='" + zlsc + '\'' + | |
1760 | + ", qtfz='" + qtfz + '\'' + | |
1761 | + ", correctAge='" + correctAge + '\'' + | |
1762 | + '}'; | |
1763 | + } | |
1615 | 1764 | } |
platform-job-index/src/main/java/com/lyms/platform/job/index/restore/data/ConvertHelper.java
View file @
e27c903
... | ... | @@ -387,6 +387,15 @@ |
387 | 387 | babyCheckDiagnosis.setDrugGllergic(drugGllergic); |
388 | 388 | babyCheckDiagnosis.setOtherText(babyCheckModel.getAskOther()); |
389 | 389 | |
390 | + babyCheckDiagnosis.setCnqk(babyCheckModel.getCnqk()); | |
391 | + babyCheckDiagnosis.setMtcnNum(babyCheckModel.getMtcnNum()); | |
392 | + babyCheckDiagnosis.setXbNum(babyCheckModel.getXbNum()); | |
393 | + babyCheckDiagnosis.setDbNum(babyCheckModel.getDbNum()); | |
394 | + babyCheckDiagnosis.setQdtlTime(babyCheckModel.getQdtlTime()); | |
395 | + babyCheckDiagnosis.setPfhrTime(babyCheckModel.getPfhrTime()); | |
396 | + babyCheckDiagnosis.setWssAd(babyCheckModel.getWssAd()); | |
397 | + babyCheckDiagnosis.setDouhbqk(JsonUtil.obj2JsonString(babyCheckModel.getDouhbqk())); | |
398 | + | |
390 | 399 | return babyCheckDiagnosis; |
391 | 400 | } |
392 | 401 | return null; |
platform-job-index/src/main/java/com/lyms/platform/job/index/restore/data/SyncDataWork.java
View file @
e27c903
... | ... | @@ -433,6 +433,7 @@ |
433 | 433 | logger.info("loadRpBaby babycheck by:" + hospitalId + ",babycheck size:" + (null == babyCheckModels ? 0 : babyCheckModels.size())); |
434 | 434 | if (CollectionUtils.isNotEmpty(babyCheckModels)) { |
435 | 435 | for (BabyCheckModel babyCheckModel : babyCheckModels) { |
436 | + System.out.println("待同步的儿保检查数据:"+babyCheckModel.toString()); | |
436 | 437 | //儿保信息 |
437 | 438 | BabyCheckBase babyCheckBase = ConvertHelper.convertToBabyCheckBase(babyCheckModel, babyModel); |
438 | 439 | babyCheckBase.setPatientId(patients.getId()); |
platform-job-index/src/main/resources/conf.properties
View file @
e27c903
1 | -#需要导入的妈咪贝比 | |
2 | 1 | maindata.driver=com.mysql.jdbc.Driver |
3 | -maindata.jdbcurl=jdbc:mysql://119.90.43.68:3307/mommybaby?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8 | |
4 | -maindata.username=lyms_chengdu | |
5 | -maindata.password=lyms2015 | |
2 | +#maindata.jdbcurl=jdbc:mysql://192.168.1.69:3306/mommybaby?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8 | |
3 | +#maindata.username=lyms_chengdu | |
4 | +#maindata.password=lyms2015 | |
6 | 5 | |
6 | +maindata.jdbcurl=jdbc:mysql://192.168.1.26:3306/mommybaby?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8 | |
7 | +maindata.username=mommybaby | |
8 | +maindata.password=Lyms123456 | |
9 | + | |
10 | + | |
7 | 11 | maindata.maxpoolsize=5 |
8 | 12 | maindata.initialpoolsize=2 |
9 | 13 | maindata.minpoolsize=2 |
10 | 14 | |
11 | 15 | |
12 | 16 | |
17 | +sequence.create.size=3000 | |
18 | +sequence.index=20000000 | |
19 | +sequence.min.size=300 | |
20 | +sequence.schedule.expression=0 0 * * 1 ? | |
13 | 21 | |
14 | -mongo.db.host=119.90.57.26 | |
15 | -mongo.db.port=27018 | |
22 | + | |
23 | + | |
24 | + | |
25 | +mongo.db.host=192.168.1.26 | |
26 | +mongo.db.port=10001 | |
16 | 27 | mongo.db.dbname=platform |
17 | 28 | mongo.db.username=platform |
18 | 29 | mongo.db.password=platform123 |
19 | 30 | |
20 | 31 | |
21 | 32 | |
... | ... | @@ -24,24 +35,21 @@ |
24 | 35 | mongo.autoConnectRetry=true |
25 | 36 | mongo.socketKeepAlive=true |
26 | 37 | |
27 | -mysql.db.name=platform | |
28 | -mysql.db.password=platform123 | |
29 | -mysql.driver=com.mysql.jdbc.Driver | |
30 | -mysql.jdbcurl=jdbc:mysql://119.90.43.68:3307/platform?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8 | |
38 | +#mysql.db.name=platform | |
39 | +#mysql.db.password=platform123 | |
40 | +#mysql.driver=com.mysql.jdbc.Driver | |
41 | +#mysql.jdbcurl=jdbc:mysql://192.168.1.39:3306/platform?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8 | |
31 | 42 | |
32 | 43 | mysql.maxpoolsize=5 |
33 | 44 | mysql.initialpoolsize=2 |
34 | 45 | mysql.minpoolsize=2 |
35 | 46 | |
36 | 47 | |
37 | - | |
38 | - | |
39 | 48 | mysql.master.db.name=platform |
40 | 49 | mysql.master.db.password=platform123 |
41 | 50 | mysql.master.driver=com.mysql.jdbc.Driver |
42 | -mysql.master.jdbcurl=jdbc:mysql://119.90.57.26:3306/platform?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8 | |
51 | +mysql.master.jdbcurl=jdbc:mysql://192.168.1.26:3306/platform?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8 | |
43 | 52 | |
44 | - | |
45 | 53 | redis.servers=localhost:6379 |
46 | 54 | |
47 | 55 | |
... | ... | @@ -49,5 +57,5 @@ |
49 | 57 | report.db.username=LYMS_ODS |
50 | 58 | report.db.password=Welcome1 |
51 | 59 | |
52 | -file.path=c://lastsynctime.txt | |
60 | +file.path=c://data/lastsynctime.txt |
platform-job-index/src/main/resources/spring/applicationContext-sync-data.xml
View file @
e27c903
... | ... | @@ -9,19 +9,19 @@ |
9 | 9 | <!-- 采用注释的方式配置bean --> |
10 | 10 | <context:annotation-config /> |
11 | 11 | |
12 | - <!--<bean id="configProperties"--> | |
13 | - <!--class="org.springframework.beans.factory.config.PropertiesFactoryBean">--> | |
14 | - <!--<property name="locations">--> | |
15 | - <!--<list>--> | |
16 | - <!--<value>classpath:conf.properties</value>--> | |
17 | - <!--</list>--> | |
18 | - <!--</property>--> | |
19 | - <!--</bean>--> | |
12 | + <bean id="configProperties" | |
13 | + class="org.springframework.beans.factory.config.PropertiesFactoryBean"> | |
14 | + <property name="locations"> | |
15 | + <list> | |
16 | + <value>classpath:conf.properties</value> | |
17 | + </list> | |
18 | + </property> | |
19 | + </bean> | |
20 | 20 | |
21 | - <!--<bean id="propertyConfigurer"--> | |
22 | - <!--class="org.springframework.beans.factory.config.PreferencesPlaceholderConfigurer">--> | |
23 | - <!--<property name="properties" ref="configProperties" />--> | |
24 | - <!--</bean>--> | |
21 | + <bean id="propertyConfigurer" | |
22 | + class="org.springframework.beans.factory.config.PreferencesPlaceholderConfigurer"> | |
23 | + <property name="properties" ref="configProperties" /> | |
24 | + </bean> | |
25 | 25 | |
26 | 26 | <!--<!– DataSource configuration 项目主数据库 –>--> |
27 | 27 | <bean id="mainDataSource" class="com.mchange.v2.c3p0.ComboPooledDataSource"> |
platform-job-index/src/main/webapp/WEB-INF/lib/mainData.jar
View file @
e27c903
platform-operate-api/src/main/java/com/lyms/platform/operate/web/Test.java
View file @
e27c903
1 | 1 | package com.lyms.platform.operate.web; |
2 | 2 | |
3 | 3 | import com.lyms.platform.common.utils.DateUtil; |
4 | -import com.lyms.platform.common.utils.SerializUtils; | |
5 | 4 | import com.lyms.platform.pojo.BasicConfig; |
6 | -import com.lyms.platform.pojo.DiagnoseConfigModel; | |
7 | 5 | import net.sourceforge.pinyin4j.PinyinHelper; |
8 | -import org.apache.commons.codec.binary.Base64; | |
9 | 6 | import org.apache.log4j.Logger; |
10 | 7 | |
11 | -import java.io.Serializable; | |
12 | 8 | import java.util.Comparator; |
13 | 9 | import java.util.Date; |
14 | 10 | import java.util.List; |
15 | 11 | |
16 | 12 | |
... | ... | @@ -22,17 +18,21 @@ |
22 | 18 | private static org.apache.log4j.Logger log = Logger.getLogger("HTTP-INVOKE"); |
23 | 19 | |
24 | 20 | public static void main(String[] args) throws Exception { |
21 | + Date date = new Date(); | |
22 | + date.setTime(1524043320001L); | |
23 | + System.out.println(DateUtil.getyyyy_MM_dd_hms(date)); | |
24 | + | |
25 | 25 | //月龄套餐 |
26 | 26 | //月龄套餐 |
27 | 27 | // List jctc = EnumUtil.toJson(ChildCareEnums.JCTCEnums.class); |
28 | 28 | // System.out.println(jctc); |
29 | 29 | |
30 | 30 | //根据出生孕周计算末次月经 |
31 | - Date LastMens = DateUtil.addWeek(DateUtil.parseYMD("2018-01-01"),-34); | |
31 | + // Date LastMens = DateUtil.addWeek(DateUtil.parseYMD("2018-01-01"),-34); | |
32 | 32 | //根据末次月经计算预产期 |
33 | - Date dueDate = DateUtil.addMonth(LastMens, 9); | |
34 | - dueDate = DateUtil.addDay(dueDate, 7); | |
35 | - System.out.println(DateUtil.getyyyy_MM_dd(dueDate)); | |
33 | + // Date dueDate = DateUtil.addMonth(LastMens, 9); | |
34 | + // dueDate = DateUtil.addDay(dueDate, 7); | |
35 | + // System.out.println(DateUtil.getyyyy_MM_dd(dueDate)); | |
36 | 36 | // System.out.println(EnumUtil.toJson(BabyDeformityEnums.class)); |
37 | 37 | |
38 | 38 | // int day = DateUtil.getExcludeMonthDay(DateUtil.parseYMD("2018-04-19"),new Date()); |