Преглед изворни кода

Merge branch 'dev-1.3.7' of trick9191/patient-co-management into dev-1.3.7

trick9191 пре 7 година
родитељ
комит
eb0e759e30
100 измењених фајлова са 14143 додато и 900 уклоњено
  1. 14 0
      common/common-entity/pom.xml
  2. 15 4
      common/common-entity/src/main/java/com/yihu/device/entity/DevicePatientHealthIndex.java
  3. 280 0
      common/common-entity/src/main/java/com/yihu/es/entity/HealthEduArticlePatient.java
  4. 9 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/address/Country.java
  5. 96 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/health/DoctorHealthStandard.java
  6. 10 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/profile/Doctor.java
  7. 220 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/scheme/DoctorSchemeBloodPressure.java
  8. 266 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/scheme/DoctorSchemeBloodSugger.java
  9. 50 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/scheme/vo/DoctorSchemeBloodPressureVO.java
  10. 50 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/scheme/vo/DoctorSchemeBloodSuggerVO.java
  11. 10 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/team/admin/AdminTeam.java
  12. 1 1
      common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/team/sign/SignPatientLabel.java
  13. 208 170
      common/common-entity/src/main/java/com/yihu/wlyy/entity/education/HealthEduArticlePatient.java
  14. 3 3
      common/common-entity/src/main/java/com/yihu/wlyy/entity/message/Message.java
  15. 9 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/Patient.java
  16. 105 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/PatientAimBloodPressure.java
  17. 94 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/PatientAimBloodSugger.java
  18. 84 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/PatientAimSports.java
  19. 82 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/PatientSchemeList.java
  20. 11 1
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/Prescription.java
  21. 79 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionAdjustReason.java
  22. 5 5
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionExplain.java
  23. 1 1
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionPay.java
  24. 70 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionReasonDict.java
  25. 78 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionReviewedReason.java
  26. 29 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/vo/PatientCodeDeviceType.java
  27. 10 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/security/AccessToken.java
  28. 10 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/security/JsApiTicket.java
  29. 138 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/ylz/PayConfigura.java
  30. 140 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/ylz/PayLog.java
  31. 108 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/zydict/ZyPushLog.java
  32. 3 0
      patient-co-customization/patient-co-modern-medicine/src/main/java/com/yihu/mm/controller/WeixinBaseController.java
  33. 2 2
      patient-co-customization/patient-co-modern-medicine/src/main/java/com/yihu/mm/repository/wlyy/patient/AccessTokenDao.java
  34. 6 1
      patient-co-customization/patient-co-modern-medicine/src/main/java/com/yihu/mm/service/AccessTokenService.java
  35. 29 9
      patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/controller/common/account/CustomerController.java
  36. 11 0
      patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/entity/Doctor.java
  37. 67 0
      patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/service/manager/account/CustomerService.java
  38. 4 1
      patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/service/manager/family/FamilyMemberService.java
  39. 24 17
      patient-co-manage/wlyy-manage/src/main/resources/application.yml
  40. 9 1
      patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/common/dao/PatientHealthIndexDao.java
  41. 9 7
      patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/common/http/HttpClientUtil.java
  42. 4 2
      patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/common/http/HttpHelper.java
  43. 17 10
      patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/common/util/ImUtill.java
  44. 14 0
      patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/model/Patient.java
  45. 13 3
      patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/model/PatientHealthIndex.java
  46. 109 12
      patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/service/DeviceService.java
  47. 10 20
      patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/task/PushMsgTask.java
  48. 4 4
      patient-co-service/wlyy_device/src/main/resources/application.yml
  49. 68 8
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/ArchivesController.java
  50. 1 1
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/CommonController.java
  51. 79 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/HttpController.java
  52. 18 1
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/PrescriptionController.java
  53. 83 32
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/SignController.java
  54. 3 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/dao/DoctorMappingDao.java
  55. 4 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/dao/prescription/PrescriptionDao.java
  56. 3 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/dao/prescription/PrescriptionExpressageDao.java
  57. 4 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/dao/zydict/ZyIvPhysicDictDao.java
  58. 10 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/entity/Patient.java
  59. 13 3
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/entity/device/PatientHealthIndex.java
  60. 10 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/entity/prescription/PrescriptionExpressage.java
  61. 44 1
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/ArchivesService.java
  62. 35 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/SignZYService.java
  63. 1 1
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/ZysoftBaseService.java
  64. 183 11
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/ZysoftService.java
  65. 13 452
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionCAService.java
  66. 509 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionCATestServiceImp.java
  67. 510 0
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionProCAServiceImp.java
  68. 217 114
      patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionService.java
  69. 19 2
      patient-co-service/wlyy_service/src/main/resources/application.yml
  70. 76 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/css/artDialog.css
  71. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/images/articons.png
  72. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/images/loading.gif
  73. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/images/tips-icon.png
  74. 2096 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/js/artDialog.js
  75. 58 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/css/doc.css
  76. 435 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/css/ui-dialog.css
  77. 1314 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/index.html
  78. 1648 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/js/dialog-plus.js
  79. 67 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/js/doc.js
  80. 5 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/js/jquery.js
  81. 9 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/js/sh_languages.js
  82. 435 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/css/ui-dialog.css
  83. 126 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/css/ui-dialog.min.css
  84. 930 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/js/dialog-plus.js
  85. 1 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/js/dialog-plus.min.js
  86. 1597 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/css/chatRoom.css
  87. 342 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/css/cross.css
  88. 496 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/css/cross.ui.css
  89. 61 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/css/prescription-consulting.css
  90. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/bofang_icon.png
  91. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/loading2.gif
  92. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/logo_dibu_img.png
  93. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/xitongtixing_im_icon.png
  94. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/youshanjiao_bg.png
  95. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin-2.gif
  96. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin.gif
  97. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin2_icon.png
  98. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin3.gif
  99. BIN
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin4_icon.png
  100. 0 0
      patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin_icon.png

+ 14 - 0
common/common-entity/pom.xml

@ -45,5 +45,19 @@
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
        </dependency>
        <dependency>
            <groupId>org.elasticsearch</groupId>
            <artifactId>elasticsearch</artifactId>
        </dependency>
        <dependency>
            <groupId>io.searchbox</groupId>
            <artifactId>jest</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.data</groupId>
            <artifactId>spring-data-commons</artifactId>
            <version>1.11.4.RELEASE</version>
        </dependency>
    </dependencies>
</project>

+ 15 - 4
common/common-entity/src/main/java/com/yihu/device/entity/DevicePatientHealthIndex.java

@ -23,11 +23,11 @@ public class DevicePatientHealthIndex extends IdEntity {
	private String intervene;
	// 血糖/收缩压/体重/腰围/早餐前空腹
	private String value1;
	// 舒张压/早餐后空腹
	// 舒张压/早餐后空腹/身高
	private String value2;
	// 午餐空腹
	// 午餐空腹/BMI
	private String value3;
	// 午餐后
	// 午餐后/偏胖-1/正常0/偏瘦1
	private String value4;
	// 晚餐空腹
	private String value5;
@ -35,7 +35,7 @@ public class DevicePatientHealthIndex extends IdEntity {
	private String value6;
	// 睡前
	private String value7;
	// 健康指标类型(1血糖,2血压,3体重,4腰围)
	// 健康指标类型(1血糖,2血压,3体重/身高/BMI,4腰围)
	private int type;
	// 记录时间
@ -51,6 +51,8 @@ public class DevicePatientHealthIndex extends IdEntity {
	//设备编号
	private String deviceSn;
	private Integer status;//状态:0为标准,1为异常
	public String getUser() {
		return user;
	}
@ -186,4 +188,13 @@ public class DevicePatientHealthIndex extends IdEntity {
		this.deviceSn = deviceSn;
	}
	public Integer getStatus() {
		return status;
	}
	public void setStatus(Integer status) {
		this.status = status;
	}
}

+ 280 - 0
common/common-entity/src/main/java/com/yihu/es/entity/HealthEduArticlePatient.java

@ -0,0 +1,280 @@
package com.yihu.es.entity;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.searchbox.annotations.JestId;
import org.springframework.data.annotation.CreatedDate;
import java.util.Date;
/**
 * 推送记录表
 * Created by chenweida on 2017/9/7.
 */
public class HealthEduArticlePatient {
    @JestId
    private String id;
    private String patient; // 患者标识
    private String patientName;    // 患者标识
    private String sendCode;   // 发送人code
    private String sendName;   // 发送人名称
    private String sendPic;   // 发送人头像
    private String sendSex;   // 发送人性别
    private String sendLevel;   // 发送人级别  1专科医生,2全科医生,3健康管理师 4 管理员
    private Integer sendType;//发送类型 1医生发送 2卫纪委发送
    private Long adminTeamCode;// 行政团队
    private String adminTeamName;// 行政团队
    private String hospital; // 所属机构
    private String hospitalName; // 所属机构
    private String town; // 所属区划
    private String townName; // 所属区划
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyyMMdd'T'HHmmss.SSS'Z'")
    @CreatedDate
    private Date createTime;  // 创建时间
    private String batchNo;//批次号记录发送所属批次
    private String articleId;  //文章id
    private String attachedTitle;  //文章标题
    private String attachedPic;//文章封面
    private String attachedContent; //文章内容
    private String attachedMessage; //文章附加文件
    private String articleType;//文章类别
    private String level1Type;//1级类别
    private String level2Type;//2级类别
    private String level;//等级
    private Integer allCount;//所有的推送数目
    private String type;//推送类型 1:文章 2:健康课程
    private String articleUrl;//集美宣教,文章的url
    public String getId() {
        return id;
    }
    public void setId(String id) {
        this.id = id;
    }
    public String getPatient() {
        return patient;
    }
    public void setPatient(String patient) {
        this.patient = patient;
    }
    public String getPatientName() {
        return patientName;
    }
    public void setPatientName(String patientName) {
        this.patientName = patientName;
    }
    public String getSendCode() {
        return sendCode;
    }
    public void setSendCode(String sendCode) {
        this.sendCode = sendCode;
    }
    public String getSendName() {
        return sendName;
    }
    public void setSendName(String sendName) {
        this.sendName = sendName;
    }
    public Integer getSendType() {
        return sendType;
    }
    public void setSendType(Integer sendType) {
        this.sendType = sendType;
    }
    public Long getAdminTeamCode() {
        return adminTeamCode;
    }
    public void setAdminTeamCode(Long adminTeamCode) {
        this.adminTeamCode = adminTeamCode;
    }
    public String getHospital() {
        return hospital;
    }
    public void setHospital(String hospital) {
        this.hospital = hospital;
    }
    public String getTown() {
        return town;
    }
    public void setTown(String town) {
        this.town = town;
    }
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    public String getBatchNo() {
        return batchNo;
    }
    public void setBatchNo(String batchNo) {
        this.batchNo = batchNo;
    }
    public String getArticleId() {
        return articleId;
    }
    public void setArticleId(String articleId) {
        this.articleId = articleId;
    }
    public String getAttachedTitle() {
        return attachedTitle;
    }
    public void setAttachedTitle(String attachedTitle) {
        this.attachedTitle = attachedTitle;
    }
    public String getAttachedPic() {
        return attachedPic;
    }
    public void setAttachedPic(String attachedPic) {
        this.attachedPic = attachedPic;
    }
    public String getAttachedContent() {
        return attachedContent;
    }
    public void setAttachedContent(String attachedContent) {
        this.attachedContent = attachedContent;
    }
    public String getAttachedMessage() {
        return attachedMessage;
    }
    public void setAttachedMessage(String attachedMessage) {
        this.attachedMessage = attachedMessage;
    }
    public String getAdminTeamName() {
        return adminTeamName;
    }
    public void setAdminTeamName(String adminTeamName) {
        this.adminTeamName = adminTeamName;
    }
    public String getHospitalName() {
        return hospitalName;
    }
    public void setHospitalName(String hospitalName) {
        this.hospitalName = hospitalName;
    }
    public String getTownName() {
        return townName;
    }
    public void setTownName(String townName) {
        this.townName = townName;
    }
    public String getArticleType() {
        return articleType;
    }
    public void setArticleType(String articleType) {
        this.articleType = articleType;
    }
    public String getLevel1Type() {
        return level1Type;
    }
    public void setLevel1Type(String level1Type) {
        this.level1Type = level1Type;
    }
    public String getLevel2Type() {
        return level2Type;
    }
    public void setLevel2Type(String level2Type) {
        this.level2Type = level2Type;
    }
    public String getLevel() {
        return level;
    }
    public void setLevel(String level) {
        this.level = level;
    }
    public Integer getAllCount() {
        return allCount;
    }
    public void setAllCount(Integer allCount) {
        this.allCount = allCount;
    }
    public String getSendPic() {
        return sendPic;
    }
    public void setSendPic(String sendPic) {
        this.sendPic = sendPic;
    }
    public String getSendSex() {
        return sendSex;
    }
    public void setSendSex(String sendSex) {
        this.sendSex = sendSex;
    }
    public String getSendLevel() {
        return sendLevel;
    }
    public void setSendLevel(String sendLevel) {
        this.sendLevel = sendLevel;
    }
    public String getType() {
        return type;
    }
    public void setType(String type) {
        this.type = type;
    }
    public String getArticleUrl() {
        return articleUrl;
    }
    public void setArticleUrl(String articleUrl) {
        this.articleUrl = articleUrl;
    }
}

+ 9 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/address/Country.java

@ -17,6 +17,7 @@ public class Country extends IdEntity {
    private String  street ;
    private String  code;
    private String  name;
    private String  jwCode;
    public String getProvince() {
        return province;
@ -65,4 +66,12 @@ public class Country extends IdEntity {
    public void setCode(String code) {
        this.code = code;
    }
    public String getJwCode() {
        return jwCode;
    }
    public void setJwCode(String jwCode) {
        this.jwCode = jwCode;
    }
}

+ 96 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/health/DoctorHealthStandard.java

@ -0,0 +1,96 @@
package com.yihu.wlyy.entity.doctor.health;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * 医生预警值方案
 * @author huangwenjie
 * @date 2017/9/14 21:08
 */
@Entity
@Table(name = "wlyy_doctor_health_standard")
public class DoctorHealthStandard extends IdEntity {
    private static final long serialVersionUID = -8343925049051333359L;
    // 患者标识
    private String doctor;
    // 健康指标类型:1血糖,2血压,3体重,4腰围
    private Integer type;
    // 最低安全值(血糖餐前\收缩压\BMI\腰围)
    private Double minValue1;
    // 最高安全值(血糖餐前\收缩压\BMI\腰围)
    private Double maxValue1;
    // 最低安全值(血糖餐后\舒张压\步数)
    private Double minValue2;
    // 最高安全值(血糖餐后\舒张压\步数)
    private Double maxValue2;
    // 设置时间
    private Date czrq;
    public String getDoctor() {
        return doctor;
    }
    public void setDoctor(String doctor) {
        this.doctor = doctor;
    }
    public Integer getType() {
        return type;
    }
    public void setType(Integer type) {
        this.type = type;
    }
    @Column(name = "min_value_1")
    public Double getMinValue1() {
        return minValue1;
    }
    public void setMinValue1(Double minValue) {
        this.minValue1 = minValue;
    }
    @Column(name = "max_value_1")
    public Double getMaxValue1() {
        return maxValue1;
    }
    public void setMaxValue1(Double maxValue) {
        this.maxValue1 = maxValue;
    }
    @Column(name = "min_value_2")
    public Double getMinValue2() {
        return minValue2;
    }
    public void setMinValue2(Double minValue) {
        this.minValue2 = minValue;
    }
    @Column(name = "max_value_2")
    public Double getMaxValue2() {
        return maxValue2;
    }
    public void setMaxValue2(Double maxValue) {
        this.maxValue2 = maxValue;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCzrq() {
        return czrq;
    }
    public void setCzrq(Date czrq) {
        this.czrq = czrq;
    }
}

+ 10 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/profile/Doctor.java

@ -70,6 +70,8 @@ public class Doctor extends IdEntity {
    private Date certifiedOvertime; //CA证书过期时间
    private String certificateNum;     //CA证书编号
    private String openid; //医生微信openID
    public Double getEvaluateScore() {
        return evaluateScore;
    }
@ -428,4 +430,12 @@ public class Doctor extends IdEntity {
    public void setCertificateNum(String certificateNum) {
        this.certificateNum = certificateNum;
    }
    public String getOpenid() {
        return openid;
    }
    public void setOpenid(String openid) {
        this.openid = openid;
    }
}

+ 220 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/scheme/DoctorSchemeBloodPressure.java

@ -0,0 +1,220 @@
package com.yihu.wlyy.entity.doctor.scheme;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.*;
import java.sql.Time;
import java.sql.Timestamp;
/**
 * 医生监测方案-血压
 * @author huangwenjie
 * @date 2017/9/7 20:14
 */
@Entity
@Table(name = "wlyy_doctor_scheme_blood_pressure")
public class DoctorSchemeBloodPressure extends IdEntity {
    private String name;                //方案名称
    private String code;
    private String doctorcode;          //医生CODE
    private Short dayofweek;            //星期几
    private Short earlyMorning;
    private Time earlyMorningTime;
    private Short morning;
    private Time morningTime;
    private Short noon;
    private Time noonTime;
    private Short afterNoon;
    private Time afterNoonTime;
    private Short night;
    private Time nightTime;
    private Timestamp createTime;      //创建时间
    private Short alertTag;            //是否提醒用户
    private String content;            //方案说明
    private Integer del;          //0为正常,1为删除
    @Basic
    @Column(name = "name")
    public String getName() {
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }
    @Basic
    @Column(name = "code")
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    @Basic
    @Column(name = "doctorcode")
    public String getDoctorcode() {
        return doctorcode;
    }
    public void setDoctorcode(String doctorcode) {
        this.doctorcode = doctorcode;
    }
    @Basic
    @Column(name = "dayofweek")
    public Short getDayofweek() {
        return dayofweek;
    }
    public void setDayofweek(Short dayofweek) {
        this.dayofweek = dayofweek;
    }
    @Basic
    @Column(name = "early_morning")
    public Short getEarlyMorning() {
        return earlyMorning;
    }
    public void setEarlyMorning(Short earlyMorning) {
        this.earlyMorning = earlyMorning;
    }
    @Basic
    @Column(name = "early_morning_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getEarlyMorningTime() {
        return earlyMorningTime;
    }
    public void setEarlyMorningTime(Time earlyMorningTime) {
        this.earlyMorningTime = earlyMorningTime;
    }
    @Basic
    @Column(name = "morning")
    public Short getMorning() {
        return morning;
    }
    public void setMorning(Short morning) {
        this.morning = morning;
    }
    @Basic
    @Column(name = "morning_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getMorningTime() {
        return morningTime;
    }
    public void setMorningTime(Time morningTime) {
        this.morningTime = morningTime;
    }
    @Basic
    @Column(name = "noon")
    public Short getNoon() {
        return noon;
    }
    public void setNoon(Short noon) {
        this.noon = noon;
    }
    @Basic
    @Column(name = "noon_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getNoonTime() {
        return noonTime;
    }
    public void setNoonTime(Time noonTime) {
        this.noonTime = noonTime;
    }
    @Basic
    @Column(name = "after_noon")
    public Short getAfterNoon() {
        return afterNoon;
    }
    public void setAfterNoon(Short afterNoon) {
        this.afterNoon = afterNoon;
    }
    @Basic
    @Column(name = "after_noon_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getAfterNoonTime() {
        return afterNoonTime;
    }
    public void setAfterNoonTime(Time afterNoonTime) {
        this.afterNoonTime = afterNoonTime;
    }
    @Basic
    @Column(name = "night")
    public Short getNight() {
        return night;
    }
    public void setNight(Short night) {
        this.night = night;
    }
    @Basic
    @Column(name = "night_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getNightTime() {
        return nightTime;
    }
    public void setNightTime(Time nightTime) {
        this.nightTime = nightTime;
    }
    @Basic
    @Column(name = "create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Timestamp getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }
    @Basic
    @Column(name = "alert_tag")
    public Short getAlertTag() {
        return alertTag;
    }
    public void setAlertTag(Short alertTag) {
        this.alertTag = alertTag;
    }
    @Basic
    @Column(name = "content")
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    public Integer getDel() {
        return del;
    }
    public void setDel(Integer del) {
        this.del = del;
    }
}

+ 266 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/scheme/DoctorSchemeBloodSugger.java

@ -0,0 +1,266 @@
package com.yihu.wlyy.entity.doctor.scheme;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.*;
import java.sql.Time;
import java.sql.Timestamp;
/**
 * 医生监测方案-血糖
 * @author huangwenjie
 * @date 2017/9/7 20:14
 */
@Entity
@Table(name = "wlyy_doctor_scheme_blood_sugger")
public class DoctorSchemeBloodSugger extends IdEntity {
    private String name;                    //方案名称
    private String code;
    private String doctorcode;
    private Short dayofweek;                //星期几:1-7,1代表周日,7代表周六
    private Short beforeBreakfast;
    private Time beforeBreakfastTime;
    private Short afterBreakfast;
    private Time afterBreakfastTime;
    private Short beforeLunch;
    private Time beforeLunchTime;
    private Short afterLunch;
    private Time afterLunchTime;
    private Short beforeDinner;
    private Time beforeDinnerTime;
    private Short afterDinner;
    private Time afterDinnerTime;
    private Short beforeSleep;
    private Time beforeSleepTime;
    private Timestamp createTime;
    private Short alertTag;                 //是否提醒用户
    private String content;                 //方案说明
    private Integer del;          //0为正常,1为删除
    @Basic
    @Column(name = "name")
    public String getName() {
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }
    @Basic
    @Column(name = "code")
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    @Basic
    @Column(name = "doctorcode")
    public String getDoctorcode() {
        return doctorcode;
    }
    public void setDoctorcode(String doctorcode) {
        this.doctorcode = doctorcode;
    }
    @Basic
    @Column(name = "dayofweek")
    public Short getDayofweek() {
        return dayofweek;
    }
    public void setDayofweek(Short dayofweek) {
        this.dayofweek = dayofweek;
    }
    @Basic
    @Column(name = "before_breakfast")
    public Short getBeforeBreakfast() {
        return beforeBreakfast;
    }
    public void setBeforeBreakfast(Short beforeBreakfast) {
        this.beforeBreakfast = beforeBreakfast;
    }
    @Basic
    @Column(name = "before_breakfast_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getBeforeBreakfastTime() {
        return beforeBreakfastTime;
    }
    public void setBeforeBreakfastTime(Time beforeBreakfastTime) {
        this.beforeBreakfastTime = beforeBreakfastTime;
    }
    @Basic
    @Column(name = "after_breakfast")
    public Short getAfterBreakfast() {
        return afterBreakfast;
    }
    public void setAfterBreakfast(Short afterBreakfast) {
        this.afterBreakfast = afterBreakfast;
    }
    @Basic
    @Column(name = "after_breakfast_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getAfterBreakfastTime() {
        return afterBreakfastTime;
    }
    public void setAfterBreakfastTime(Time afterBreakfastTime) {
        this.afterBreakfastTime = afterBreakfastTime;
    }
    @Basic
    @Column(name = "before_lunch")
    public Short getBeforeLunch() {
        return beforeLunch;
    }
    public void setBeforeLunch(Short beforeLunch) {
        this.beforeLunch = beforeLunch;
    }
    @Basic
    @Column(name = "before_lunch_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getBeforeLunchTime() {
        return beforeLunchTime;
    }
    public void setBeforeLunchTime(Time beforeLunchTime) {
        this.beforeLunchTime = beforeLunchTime;
    }
    @Basic
    @Column(name = "after_lunch")
    public Short getAfterLunch() {
        return afterLunch;
    }
    public void setAfterLunch(Short afterLunch) {
        this.afterLunch = afterLunch;
    }
    @Basic
    @Column(name = "after_lunch_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getAfterLunchTime() {
        return afterLunchTime;
    }
    public void setAfterLunchTime(Time afterLunchTime) {
        this.afterLunchTime = afterLunchTime;
    }
    @Basic
    @Column(name = "before_dinner")
    public Short getBeforeDinner() {
        return beforeDinner;
    }
    public void setBeforeDinner(Short beforeDinner) {
        this.beforeDinner = beforeDinner;
    }
    @Basic
    @Column(name = "before_dinner_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getBeforeDinnerTime() {
        return beforeDinnerTime;
    }
    public void setBeforeDinnerTime(Time beforeDinnerTime) {
        this.beforeDinnerTime = beforeDinnerTime;
    }
    @Basic
    @Column(name = "after_dinner")
    public Short getAfterDinner() {
        return afterDinner;
    }
    public void setAfterDinner(Short afterDinner) {
        this.afterDinner = afterDinner;
    }
    @Basic
    @Column(name = "after_dinner_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getAfterDinnerTime() {
        return afterDinnerTime;
    }
    public void setAfterDinnerTime(Time afterDinnerTime) {
        this.afterDinnerTime = afterDinnerTime;
    }
    @Basic
    @Column(name = "before_sleep")
    public Short getBeforeSleep() {
        return beforeSleep;
    }
    public void setBeforeSleep(Short beforeSleep) {
        this.beforeSleep = beforeSleep;
    }
    @Basic
    @Column(name = "before_sleep_time")
    @JsonFormat(pattern = "HH:mm", timezone = "GMT+08:00")
    public Time getBeforeSleepTime() {
        return beforeSleepTime;
    }
    public void setBeforeSleepTime(Time beforeSleepTime) {
        this.beforeSleepTime = beforeSleepTime;
    }
    @Basic
    @Column(name = "create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Timestamp getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }
    @Basic
    @Column(name = "alert_tag")
    public Short getAlertTag() {
        return alertTag;
    }
    public Integer getDel() {
        return del;
    }
    public void setDel(Integer del) {
        this.del = del;
    }
    public void setAlertTag(Short alertTag) {
        this.alertTag = alertTag;
    }
    @Basic
    @Column(name = "content")
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
}

+ 50 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/scheme/vo/DoctorSchemeBloodPressureVO.java

@ -0,0 +1,50 @@
package com.yihu.wlyy.entity.doctor.scheme.vo;
import com.yihu.wlyy.entity.doctor.scheme.DoctorSchemeBloodPressure;
import java.util.List;
/**
 * 医生血压监测VO类
 * @author huangwenjie
 * @date 2017/9/13 21:28
 */
public class DoctorSchemeBloodPressureVO {
    private String                          code;
    private String                          name;       //名字
    private String                          content;    //说明
    private List<DoctorSchemeBloodPressure> list;       //详情
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    public String getName() {
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    public List<DoctorSchemeBloodPressure> getList() {
        return list;
    }
    public void setList(List<DoctorSchemeBloodPressure> list) {
        this.list = list;
    }
}

+ 50 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/scheme/vo/DoctorSchemeBloodSuggerVO.java

@ -0,0 +1,50 @@
package com.yihu.wlyy.entity.doctor.scheme.vo;
import com.yihu.wlyy.entity.doctor.scheme.DoctorSchemeBloodSugger;
import java.util.List;
/**
 * 医生血糖VO类
 * @author huangwenjie
 * @date 2017/9/13 21:40
 */
public class DoctorSchemeBloodSuggerVO {
    private String                          code;
    private String                          name;       //名字
    private String                          content;    //说明
    private List<DoctorSchemeBloodSugger> list;       //详情
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    public String getName() {
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    public List<DoctorSchemeBloodSugger> getList() {
        return list;
    }
    public void setList(List<DoctorSchemeBloodSugger> list) {
        this.list = list;
    }
}

+ 10 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/team/admin/AdminTeam.java

@ -26,6 +26,7 @@ public class AdminTeam extends IdEntity {
    private String orgName;
    private String townCode;
    private String townName;
    private String mappingCode;
    public String getName() {
        return name;
@ -78,6 +79,15 @@ public class AdminTeam extends IdEntity {
        this.available = available;
    }
    @Column(name = "mapping_code")
    public String getMappingCode() {
        return mappingCode;
    }
    public void setMappingCode(String mappingCode) {
        this.mappingCode = mappingCode;
    }
    @Transient
    public String getOrgName() {
        return orgName;

+ 1 - 1
common/common-entity/src/main/java/com/yihu/wlyy/entity/doctor/team/sign/SignPatientLabel.java

@ -16,7 +16,7 @@ public class SignPatientLabel extends IdEntity {
    private String labelCode;
    // 标签名称
    private String labelName;
    // 标签类型 1:卫计委三大分组 2:健康情况 3:疾病类型 4:自定义
    // 标签类型 1:服务类型 2:健康情况 3:疾病类型 4:自定义
    private String labelType;
    // 是否系统标签
    private Integer isSystem;

+ 208 - 170
common/common-entity/src/main/java/com/yihu/wlyy/entity/education/HealthEduArticlePatient.java

@ -12,180 +12,218 @@ import com.yihu.wlyy.entity.IdEntity;
/**
 * 患者健康教育文章
 * @author George
 *
 * @author George
 */
@Entity
@Table(name = "wlyy_health_edu_article_patient")
public class HealthEduArticlePatient extends IdEntity {
	/**
	 * 
	 */
	private static final long serialVersionUID = -2828104062535279547L;
	// 患者标识
	private String patient;
	// 文章标识
	private String article;
	// 医生标识
	private String doctor;
	// 医生姓名
	private String doctorName;
	// 文章标题
	private String title;
	// 文章链接
	private String url;
	// 文章内容
	private String content;
	// 是否已读:0已读,1未读
	private Integer read;
	// 发布时间
	private Date czrq;
	// 签约类型 1三师 2家庭
	private Integer signType;
	// 行政团队
	private Long adminTeamCode;
	// 简介
	private String summary;
	//附加内容
	private String attachedContent;
	//批次号记录发送所属批次
	private String batchNo;
	//签约表code
	private String signCode;
	private Integer articleId;
	public String getBatchNo() {
		return batchNo;
	}
	public void setBatchNo(String batchNo) {
		this.batchNo = batchNo;
	}
	public String getAttachedContent() {
		return attachedContent;
	}
	public void setAttachedContent(String attachedContent) {
		this.attachedContent = attachedContent;
	}
	public String getPatient() {
		return patient;
	}
	public void setPatient(String patient) {
		this.patient = patient;
	}
	public String getArticle() {
		return article;
	}
	public void setArticle(String article) {
		this.article = article;
	}
	public String getDoctor() {
		return doctor;
	}
	public void setDoctor(String doctor) {
		this.doctor = doctor;
	}
	public String getDoctorName() {
		return doctorName;
	}
	public void setDoctorName(String doctorName) {
		this.doctorName = doctorName;
	}
	@Transient
	public String getTitle() {
		return title;
	}
	public void setTitle(String title) {
		this.title = title;
	}
	@Transient
	public String getUrl() {
		return url;
	}
	public void setUrl(String url) {
		this.url = url;
	}
	@Transient
	public String getContent() {
		return content;
	}
	public void setContent(String content) {
		this.content = content;
	}
	@Column(name = "is_read")
	public Integer getRead() {
		return read;
	}
	public void setRead(Integer read) {
		this.read = read;
	}
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
	public Date getCzrq() {
		return czrq;
	}
	public void setCzrq(Date czrq) {
		this.czrq = czrq;
	}
	public Integer getSignType() {
		return signType;
	}
	public void setSignType(Integer signType) {
		this.signType = signType;
	}
	public Long getAdminTeamCode() {
		return adminTeamCode;
	}
	public void setAdminTeamCode(Long adminTeamCode) {
		this.adminTeamCode = adminTeamCode;
	}
	@Transient
	public String getSummary() {
		return summary;
	}
	public void setSummary(String summary) {
		this.summary = summary;
	}
	public String getSignCode() {
		return signCode;
	}
	public void setSignCode(String signCode) {
		this.signCode = signCode;
	}
	@Transient
	public Integer getArticleId() {
		return articleId;
	}
	public void setArticleId(Integer articleId) {
		this.articleId = articleId;
	}
    /**
     *
     */
    private static final long serialVersionUID = -2828104062535279547L;
    // 患者标识
    private String patient;
    // 文章标识
    private String article;
    // 医生标识
    private String doctor;
    // 医生姓名
    private String doctorName;
    // 文章标题
    private String title;
    // 文章链接
    private String url;
    // 文章内容
    private String content;
    // 是否已读:0已读,1未读
    private Integer read;
    // 发布时间
    private Date czrq;
    // 签约类型 1三师 2家庭
    private Integer signType;
    // 行政团队
    private Long adminTeamCode;
    // 简介
    private String summary;
    //附加内容
    private String attachedContent;
    //批次号记录发送所属批次
    private String batchNo;
    //文章标题
    private String attachedTitle;
    //文章封面
    private String attachedPic;
    //推送类型
    private Integer sendType; //1或者为空 i健康后台推送  2PC端推送
    //签约表code
    private String signCode;
    private Integer articleId;
    public String getBatchNo() {
        return batchNo;
    }
    public void setBatchNo(String batchNo) {
        this.batchNo = batchNo;
    }
    public String getAttachedContent() {
        return attachedContent;
    }
    public void setAttachedContent(String attachedContent) {
        this.attachedContent = attachedContent;
    }
    public String getPatient() {
        return patient;
    }
    public void setPatient(String patient) {
        this.patient = patient;
    }
    public String getArticle() {
        return article;
    }
    public void setArticle(String article) {
        this.article = article;
    }
    public String getDoctor() {
        return doctor;
    }
    public void setDoctor(String doctor) {
        this.doctor = doctor;
    }
    public String getDoctorName() {
        return doctorName;
    }
    public void setDoctorName(String doctorName) {
        this.doctorName = doctorName;
    }
    @Transient
    public String getTitle() {
        return title;
    }
    public void setTitle(String title) {
        this.title = title;
    }
    @Transient
    public String getUrl() {
        return url;
    }
    public void setUrl(String url) {
        this.url = url;
    }
    @Transient
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    @Column(name = "is_read")
    public Integer getRead() {
        return read;
    }
    public void setRead(Integer read) {
        this.read = read;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCzrq() {
        return czrq;
    }
    public void setCzrq(Date czrq) {
        this.czrq = czrq;
    }
    public Integer getSignType() {
        return signType;
    }
    public void setSignType(Integer signType) {
        this.signType = signType;
    }
    public Long getAdminTeamCode() {
        return adminTeamCode;
    }
    public void setAdminTeamCode(Long adminTeamCode) {
        this.adminTeamCode = adminTeamCode;
    }
    @Transient
    public String getSummary() {
        return summary;
    }
    public void setSummary(String summary) {
        this.summary = summary;
    }
    public String getSignCode() {
        return signCode;
    }
    public void setSignCode(String signCode) {
        this.signCode = signCode;
    }
    @Transient
    public Integer getArticleId() {
        return articleId;
    }
    public void setArticleId(Integer articleId) {
        this.articleId = articleId;
    }
    public static long getSerialVersionUID() {
        return serialVersionUID;
    }
    public String getAttachedTitle() {
        return attachedTitle;
    }
    public void setAttachedTitle(String attachedTitle) {
        this.attachedTitle = attachedTitle;
    }
    public String getAttachedPic() {
        return attachedPic;
    }
    public void setAttachedPic(String attachedPic) {
        this.attachedPic = attachedPic;
    }
    public Integer getSendType() {
        return sendType;
    }
    public void setSendType(Integer sendType) {
        this.sendType = sendType;
    }
}

Разлика између датотеке није приказан због своје велике величине
+ 3 - 3
common/common-entity/src/main/java/com/yihu/wlyy/entity/message/Message.java


+ 9 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/Patient.java

@ -98,6 +98,8 @@ public class Patient extends IdEntity implements Serializable {
	private Integer isWxtag;
	//微信iagId
	private Integer wxtagid;
	//居民预警状态:0为标准,1为预警状态
	private Integer standardStatus;
	public Integer getSicardStatus() {
@ -430,4 +432,11 @@ public class Patient extends IdEntity implements Serializable {
		}
	}
	public Integer getStandardStatus() {
		return standardStatus;
	}
	public void setStandardStatus(Integer standardStatus) {
		this.standardStatus = standardStatus;
	}
}

+ 105 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/PatientAimBloodPressure.java

@ -0,0 +1,105 @@
package com.yihu.wlyy.entity.patient;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.*;
import java.sql.Timestamp;
/**
 * 患者监测目标-血压
 * @author huangwenjie
 * @date 2017/9/7 20:07
 */
@Entity
@Table(name = "wlyy_patient_aim_blood_pressure")
public class PatientAimBloodPressure extends IdEntity {
    private String code;
    private String patientcode;
    private String sbp;
    private String dbp;
    private String sbpMin;
    private String dbpMin;
    private String unit;
    private Timestamp createTime;
    @Basic
    @Column(name = "code")
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    @Basic
    @Column(name = "patientcode")
    public String getPatientcode() {
        return patientcode;
    }
    public void setPatientcode(String patientcode) {
        this.patientcode = patientcode;
    }
    @Basic
    @Column(name = "sbp")
    public String getSbp() {
        return sbp;
    }
    public void setSbp(String sbp) {
        this.sbp = sbp;
    }
    @Basic
    @Column(name = "dbp")
    public String getDbp() {
        return dbp;
    }
    public void setDbp(String dbp) {
        this.dbp = dbp;
    }
    @Basic
    @Column(name = "sbp_min")
    public String getSbpMin() {
        return sbpMin;
    }
    public void setSbpMin(String sbpMin) {
        this.sbpMin = sbpMin;
    }
    @Basic
    @Column(name = "dbp_min")
    public String getDbpMin() {
        return dbpMin;
    }
    public void setDbpMin(String dbpMin) {
        this.dbpMin = dbpMin;
    }
    @Basic
    @Column(name = "unit")
    public String getUnit() {
        return unit;
    }
    public void setUnit(String unit) {
        this.unit = unit;
    }
    @Basic
    @Column(name = "create_time")
    public Timestamp getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }
}

+ 94 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/PatientAimBloodSugger.java

@ -0,0 +1,94 @@
package com.yihu.wlyy.entity.patient;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.*;
import java.sql.Timestamp;
/**
 * 患者监测目标-血糖
 * @author huangwenjie
 * @date 2017/9/7 20:07
 */
@Entity
@Table(name = "wlyy_patient_aim_blood_sugger")
public class PatientAimBloodSugger extends IdEntity {
    private String code;
    private String patientcode;
    private String fbg;
    private String hpg;
    private String minimum;
    private String unit;
    private Timestamp createTime;
    @Basic
    @Column(name = "code")
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    @Basic
    @Column(name = "patientcode")
    public String getPatientcode() {
        return patientcode;
    }
    public void setPatientcode(String patientcode) {
        this.patientcode = patientcode;
    }
    @Basic
    @Column(name = "fbg")
    public String getFbg() {
        return fbg;
    }
    public void setFbg(String fbg) {
        this.fbg = fbg;
    }
    @Basic
    @Column(name = "hpg")
    public String getHpg() {
        return hpg;
    }
    public void setHpg(String hpg) {
        this.hpg = hpg;
    }
    @Basic
    @Column(name = "minimum")
    public String getMinimum() {
        return minimum;
    }
    public void setMinimum(String minimum) {
        this.minimum = minimum;
    }
    @Basic
    @Column(name = "unit")
    public String getUnit() {
        return unit;
    }
    public void setUnit(String unit) {
        this.unit = unit;
    }
    @Basic
    @Column(name = "create_time")
    public Timestamp getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }
}

+ 84 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/PatientAimSports.java

@ -0,0 +1,84 @@
package com.yihu.wlyy.entity.patient;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.*;
import java.sql.Timestamp;
/**
 * 患者监测目标-运动
 * @author huangwenjie
 * @date 2017/9/7 20:07
 */
@Entity
@Table(name = "wlyy_patient_aim_sports")
public class PatientAimSports extends IdEntity {
    private String code;                //业务逻辑CODE,如果CODE为default,则该条记录为系统预置数据
    private String patientcode;         //患者CODE
    private Integer dailyStepCount;     //运动步数
    private String bmiMax;              //bmi标准上限
    private String bmiMin;              //bmi标准下线
    private Timestamp createTime;       //创建时间
    @Basic
    @Column(name = "code")
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    @Basic
    @Column(name = "patientcode")
    public String getPatientcode() {
        return patientcode;
    }
    public void setPatientcode(String patientcode) {
        this.patientcode = patientcode;
    }
    @Basic
    @Column(name = "daily_step_count")
    public Integer getDailyStepCount() {
        return dailyStepCount;
    }
    public void setDailyStepCount(Integer dailyStepCount) {
        this.dailyStepCount = dailyStepCount;
    }
    @Basic
    @Column(name = "bmi_max")
    public String getBmiMax() {
        return bmiMax;
    }
    public void setBmiMax(String bmiMax) {
        this.bmiMax = bmiMax;
    }
    @Basic
    @Column(name = "bmi_min")
    public String getBmiMin() {
        return bmiMin;
    }
    public void setBmiMin(String bmiMin) {
        this.bmiMin = bmiMin;
    }
    @Basic
    @Column(name = "create_time")
    public Timestamp getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }
}

+ 82 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/PatientSchemeList.java

@ -0,0 +1,82 @@
package com.yihu.wlyy.entity.patient;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.*;
import java.sql.Timestamp;
/**
 * 患者-医生监测方案关联关系表
 * @author huangwenjie
 * @date 2017/9/7 20:07
 */
@Entity
@Table(name = "wlyy_patient_scheme_list")
public class PatientSchemeList extends IdEntity {
    private String code;
    private String patientcode;
    private String schemecode;
    private Integer type;//方案类型:1为血糖,2为血压
    private String doctorcode;
    private Timestamp createTime;
    @Basic
    @Column(name = "code")
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    @Basic
    @Column(name = "patientcode")
    public String getPatientcode() {
        return patientcode;
    }
    public void setPatientcode(String patientcode) {
        this.patientcode = patientcode;
    }
    @Basic
    @Column(name = "schemecode")
    public String getSchemecode() {
        return schemecode;
    }
    public void setSchemecode(String schemecode) {
        this.schemecode = schemecode;
    }
    public Integer getType() {
        return type;
    }
    public void setType(Integer type) {
        this.type = type;
    }
    @Basic
    @Column(name = "doctorcode")
    public String getDoctorcode() {
        return doctorcode;
    }
    public void setDoctorcode(String doctorcode) {
        this.doctorcode = doctorcode;
    }
    @Basic
    @Column(name = "create_time")
    public Timestamp getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }
}

+ 11 - 1
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/Prescription.java

@ -98,6 +98,8 @@ public class Prescription extends IdEntity {
    private Integer jwPayStatus;//处方结算状态,0为未结算,1为结算成功,默认为0
    private Integer zyCancelState; //智业同步取消表示:0 位同步取消 1已经同步取消
    @Column(name = "code", unique = true, nullable = false)
    public String getCode() {
        return code;
@ -680,7 +682,7 @@ public class Prescription extends IdEntity {
    public void setMinDrugDay(Integer minDrugDay) {
        this.minDrugDay = minDrugDay;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getPresCreateTime() {
        return presCreateTime;
    }
@ -688,4 +690,12 @@ public class Prescription extends IdEntity {
    public void setPresCreateTime(Date presCreateTime) {
        this.presCreateTime = presCreateTime;
    }
    public Integer getZyCancelState() {
        return zyCancelState;
    }
    public void setZyCancelState(Integer zyCancelState) {
        this.zyCancelState = zyCancelState;
    }
}

+ 79 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionAdjustReason.java

@ -0,0 +1,79 @@
package com.yihu.wlyy.entity.patient.prescription;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by Trick on 2017/8/26.
 */
@Entity
@Table(name = "wlyy_prescription_adjust_reason")
public class PrescriptionAdjustReason extends IdEntity {
    private String code;//业务CODE
    private String prescriptionCode;//续方code
    private String adjustCode;//调整code
    private String reasonCode;//调整原因code
    private String reasonValue;//调整原因code
    private Date createTime;//创建时间
    private Date updateTime;//更新时间
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    public String getPrescriptionCode() {
        return prescriptionCode;
    }
    public void setPrescriptionCode(String prescriptionCode) {
        this.prescriptionCode = prescriptionCode;
    }
    public String getAdjustCode() {
        return adjustCode;
    }
    public void setAdjustCode(String adjustCode) {
        this.adjustCode = adjustCode;
    }
    public String getReasonCode() {
        return reasonCode;
    }
    public void setReasonCode(String reasonCode) {
        this.reasonCode = reasonCode;
    }
    public String getReasonValue() {
        return reasonValue;
    }
    public void setReasonValue(String reasonValue) {
        this.reasonValue = reasonValue;
    }
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    public Date getUpdateTime() {
        return updateTime;
    }
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
}

+ 5 - 5
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionExplain.java

@ -16,7 +16,7 @@ public class PrescriptionExplain extends IdEntity {
    private String content;//续方说明
    private String del;//是否有效,1有效,0无效
    private Date createTiem;
    private Date createTime;
    public String getContent() {
        return content;
@ -34,11 +34,11 @@ public class PrescriptionExplain extends IdEntity {
        this.del = del;
    }
    public Date getCreateTiem() {
        return createTiem;
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTiem(Date createTiem) {
        this.createTiem = createTiem;
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}

+ 1 - 1
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionPay.java

@ -9,7 +9,7 @@ import java.util.Date;
/**
 * Created by chenweida on 2017/7/26.
 * 处方支付表
 * 处方支付实体
 */
@Entity
@Table(name = "wlyy_prescription_pay")

+ 70 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionReasonDict.java

@ -0,0 +1,70 @@
package com.yihu.wlyy.entity.patient.prescription;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by Trick on 2017/8/26.
 */
@Entity
@Table(name = "wlyy_prescription_Reason_dict")
public class PrescriptionReasonDict extends IdEntity {
    private String code;//编码code
    private String value;//原因内容
    private Integer type;//类型:0 审核原因标签;1 调整原因标签
    private Integer sort;//排序号
    private Date createTime;//创建时间
    private Date updateTime;//修改时间
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    public String getValue() {
        return value;
    }
    public void setValue(String value) {
        this.value = value;
    }
    public Integer getType() {
        return type;
    }
    public void setType(Integer type) {
        this.type = type;
    }
    public Integer getSort() {
        return sort;
    }
    public void setSort(Integer sort) {
        this.sort = sort;
    }
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    public Date getUpdateTime() {
        return updateTime;
    }
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
}

+ 78 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/prescription/PrescriptionReviewedReason.java

@ -0,0 +1,78 @@
package com.yihu.wlyy.entity.patient.prescription;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by Trick on 2017/8/26.
 */
@Entity
@Table(name = "wlyy_prescription_reviewed_reason")
public class PrescriptionReviewedReason extends IdEntity {
    private String code;//业务CODE
    private String prescriptionCode;//续方code
    private String reviewedCode;//调整code
    private String reasonCode;//审核原因code
    private String reasonValue;//审核原因值
    private Date createTime;//创建时间
    private Date updateTime;//更新时间
    public String getCode() {
        return code;
    }
    public void setCode(String code) {
        this.code = code;
    }
    public String getPrescriptionCode() {
        return prescriptionCode;
    }
    public void setPrescriptionCode(String prescriptionCode) {
        this.prescriptionCode = prescriptionCode;
    }
    public String getReviewedCode() {
        return reviewedCode;
    }
    public void setReviewedCode(String reviewedCode) {
        this.reviewedCode = reviewedCode;
    }
    public String getReasonCode() {
        return reasonCode;
    }
    public void setReasonCode(String reasonCode) {
        this.reasonCode = reasonCode;
    }
    public String getReasonValue() {
        return reasonValue;
    }
    public void setReasonValue(String reasonValue) {
        this.reasonValue = reasonValue;
    }
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    public Date getUpdateTime() {
        return updateTime;
    }
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
}

+ 29 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/patient/vo/PatientCodeDeviceType.java

@ -0,0 +1,29 @@
package com.yihu.wlyy.entity.patient.vo;
/**
 * 患者CODE,设备类型VO类
 * @author huangwenjie
 * @date 2017/9/14 22:44
 */
public class PatientCodeDeviceType {
    private String user;            //患者CODE
    private Integer deviceType;     //患者设备类型
    public String getUser() {
        return user;
    }
    public void setUser(String user) {
        this.user = user;
    }
    public Integer getDeviceType() {
        return deviceType;
    }
    public void setDeviceType(Integer deviceType) {
        this.deviceType = deviceType;
    }
}

+ 10 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/security/AccessToken.java

@ -14,12 +14,22 @@ public class AccessToken extends IdEntity {
    private String access_token;
    private String acc_id;
    private Long add_timestamp;
    private Long expires_in;
    private Date czrq;
    public String getAcc_id() {
        return acc_id;
    }
    public void setAcc_id(String acc_id) {
        this.acc_id = acc_id;
    }
    public String getAccess_token() {
        return access_token;
    }

+ 10 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/security/JsApiTicket.java

@ -18,12 +18,22 @@ public class JsApiTicket extends IdEntity {
    private String jsapi_ticket;
    private String acc_id;;
    private Long add_timestamp;
    private Long expires_in;
    private Date czrq;
    public String getAcc_id() {
        return acc_id;
    }
    public void setAcc_id(String acc_id) {
        this.acc_id = acc_id;
    }
    public String getJsapi_ticket() {
        return jsapi_ticket;
    }

+ 138 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/ylz/PayConfigura.java

@ -0,0 +1,138 @@
package com.yihu.wlyy.entity.ylz;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.io.Serializable;
/**
 * 易联众支付相关配置参数
 * Created by Reece on 2017/9/9/009.
 */
@Entity
@Table(name = "ylz_pay_config")
public class PayConfigura extends IdEntity implements Serializable {
    //    基础配置参数
    private String onepayApi ;
    private String onepayAppId;
    private String onepayAppSecret;
    private int del; //配置状态 0无效 1有效
    //社保卡绑定及查询
    private String bindCardType;
    private String createSicardType;
    //家庭签约支付
    private String chargeType;
    private String chargeQueryType;
    private String receiveNotify;
    private String returnUrl;
    //续方长处方支付
    private String recipeChargeType;
    private String recipeReturnUrl;
    private String receiveRecipeNotify;
    public int getDel() {
        return del;
    }
    public void setDel(int del) {
        this.del = del;
    }
    public String getOnepayApi() {
        return onepayApi;
    }
    public void setOnepayApi(String onepayApi) {
        this.onepayApi = onepayApi;
    }
    public String getOnepayAppId() {
        return onepayAppId;
    }
    public void setOnepayAppId(String onepayAppId) {
        this.onepayAppId = onepayAppId;
    }
    public String getOnepayAppSecret() {
        return onepayAppSecret;
    }
    public void setOnepayAppSecret(String onepayAppSecret) {
        this.onepayAppSecret = onepayAppSecret;
    }
    public String getBindCardType() {
        return bindCardType;
    }
    public void setBindCardType(String bindCardType) {
        this.bindCardType = bindCardType;
    }
    public String getCreateSicardType() {
        return createSicardType;
    }
    public void setCreateSicardType(String createSicardType) {
        this.createSicardType = createSicardType;
    }
    public String getChargeType() {
        return chargeType;
    }
    public void setChargeType(String chargeType) {
        this.chargeType = chargeType;
    }
    public String getChargeQueryType() {
        return chargeQueryType;
    }
    public void setChargeQueryType(String chargeQueryType) {
        this.chargeQueryType = chargeQueryType;
    }
    public String getReceiveNotify() {
        return receiveNotify;
    }
    public void setReceiveNotify(String receiveNotify) {
        this.receiveNotify = receiveNotify;
    }
    public String getReturnUrl() {
        return returnUrl;
    }
    public void setReturnUrl(String returnUrl) {
        this.returnUrl = returnUrl;
    }
    public String getRecipeChargeType() {
        return recipeChargeType;
    }
    public void setRecipeChargeType(String recipeChargeType) {
        this.recipeChargeType = recipeChargeType;
    }
    public String getRecipeReturnUrl() {
        return recipeReturnUrl;
    }
    public void setRecipeReturnUrl(String recipeReturnUrl) {
        this.recipeReturnUrl = recipeReturnUrl;
    }
    public String getReceiveRecipeNotify() {
        return receiveRecipeNotify;
    }
    public void setReceiveRecipeNotify(String receiveRecipeNotify) {
        this.receiveRecipeNotify = receiveRecipeNotify;
    }
}

+ 140 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/ylz/PayLog.java

@ -0,0 +1,140 @@
package com.yihu.wlyy.entity.ylz;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * 易联众相关支付log表
 * Created by Reece on 2017/9/20.
 */
@Entity
@Table(name = "ylz_pay_log")
public class PayLog extends IdEntity {
    // 接口类型 0家庭签约支付 1续方支付
    private String type;
    // 业务内容
    private String content;
    // 调用接口
    private String api;
    // 调用方式
    private String method;
    // 调用参数
    private String params;
    // 调用头部信息
    private String header;
    // 返回结果
    private String response;
    // 状态 0失败 1成功 2已重试
    private String status;
    // 重试次数
    private Integer retryTimes;
    // 创建时间
    private Date createTime;
    //异常信息
    private String error;
    @Column(name = "type")
    public String getType() {
        return type;
    }
    public void setType(String type) {
        this.type = type;
    }
    @Column(name = "content")
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    @Column(name = "api")
    public String getApi() {
        return api;
    }
    public void setApi(String api) {
        this.api = api;
    }
    @Column(name = "method")
    public String getMethod() {
        return method;
    }
    public void setMethod(String method) {
        this.method = method;
    }
    @Column(name = "params")
    public String getParams() {
        return params;
    }
    public void setParams(String params) {
        this.params = params;
    }
    @Column(name = "header")
    public String getHeader() {
        return header;
    }
    public void setHeader(String header) {
        this.header = header;
    }
    @Column(name = "response")
    public String getResponse() {
        return response;
    }
    public void setResponse(String response) {
        this.response = response;
    }
    @Column(name = "status")
    public String getStatus() {
        return status;
    }
    public void setStatus(String status) {
        this.status = status;
    }
    @Column(name = "retry_times")
    public Integer getRetryTimes() {
        return retryTimes;
    }
    public void setRetryTimes(Integer retryTimes) {
        this.retryTimes = retryTimes;
    }
    @Column(name = "create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    @Column(name = "error")
    public String getError() {
        return error;
    }
    public void setError(String error) {
        this.error = error;
    }
}

+ 108 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/zydict/ZyPushLog.java

@ -0,0 +1,108 @@
package com.yihu.wlyy.entity.zydict;
import com.yihu.wlyy.entity.IdEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 *  保存智业推送日志
 * Created by yeshijie on 2017/8/5.
 */
@Entity
@Table(name = "wlyy_zy_push_log")
public class ZyPushLog extends IdEntity {
    private String type;//'接口类型 1(推送续方),2续方请求', 3续方支付
    private String content;//'业务内容',
    private String api;//'调用接口',
    private String method;//'调用方式',
    private String response;//'返回结果',
    private String request;//'请求数据',
    private String error;//'报错信息',
    private String status;//'状态 0失败 1成功 2已重试',
    private Integer retryTimes;//'重试次数',
    private Date createTime;// '创建时间',
    public String getType() {
        return type;
    }
    public void setType(String type) {
        this.type = type;
    }
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    public String getApi() {
        return api;
    }
    public void setApi(String api) {
        this.api = api;
    }
    public String getMethod() {
        return method;
    }
    public void setMethod(String method) {
        this.method = method;
    }
    public String getResponse() {
        return response;
    }
    public void setResponse(String response) {
        this.response = response;
    }
    public String getRequest() {
        return request;
    }
    public void setRequest(String request) {
        this.request = request;
    }
    public String getError() {
        return error;
    }
    public void setError(String error) {
        this.error = error;
    }
    public String getStatus() {
        return status;
    }
    public void setStatus(String status) {
        this.status = status;
    }
    public Integer getRetryTimes() {
        return retryTimes;
    }
    public void setRetryTimes(Integer retryTimes) {
        this.retryTimes = retryTimes;
    }
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}

+ 3 - 0
patient-co-customization/patient-co-modern-medicine/src/main/java/com/yihu/mm/controller/WeixinBaseController.java

@ -27,6 +27,8 @@ public class WeixinBaseController extends BaseController {
	private String appId;
	@Value("${wechat.appSecret}")
	private String appSecret;
	@Value("${wechat.accId}")
	private String accId;
	@Autowired
	private CommonUtil CommonUtil;
	@Autowired
@ -60,6 +62,7 @@ public class WeixinBaseController extends BaseController {
				AccessToken newaccessToken = new AccessToken();
				newaccessToken.setAccess_token(token);
				newaccessToken.setExpires_in(Long.parseLong(expires_in));
				newaccessToken.setAcc_id(accId);
				accessTokenService.addAccessToken(newaccessToken);
				return token;
			} else {

+ 2 - 2
patient-co-customization/patient-co-modern-medicine/src/main/java/com/yihu/mm/repository/wlyy/patient/AccessTokenDao.java

@ -11,7 +11,7 @@ import org.springframework.data.repository.PagingAndSortingRepository;
public interface AccessTokenDao extends PagingAndSortingRepository<AccessToken, Long> {
	
	@Query("select p from AccessToken p order by p.add_timestamp desc")
	Iterable<AccessToken> findAccessToken();
	@Query("select p from AccessToken p where p.acc_id = ?1 order by p.add_timestamp desc")
	Iterable<AccessToken> findAccessToken(String accId);
	
}

+ 6 - 1
patient-co-customization/patient-co-modern-medicine/src/main/java/com/yihu/mm/service/AccessTokenService.java

@ -8,6 +8,7 @@ package com.yihu.mm.service;
import com.yihu.mm.repository.wlyy.patient.AccessTokenDao;
import com.yihu.wlyy.entity.security.AccessToken;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;
import org.springframework.transaction.annotation.Transactional;
import org.springside.modules.utils.Clock;
@ -24,13 +25,16 @@ public class AccessTokenService {
	@Autowired
	private AccessTokenDao accessTokenDao;
	@Value("${wechat.accId}")
	private String accId;
	private Clock clock = Clock.DEFAULT;
	public Iterable<AccessToken> findAccessToken() {
		return accessTokenDao.findAccessToken();
		return accessTokenDao.findAccessToken(accId);
	}
@ -41,6 +45,7 @@ public class AccessTokenService {
	public void addAccessToken(AccessToken accessToken) {
		accessToken.setAdd_timestamp(System.currentTimeMillis());
		accessToken.setCzrq(clock.getCurrentDate());
		accessToken.setAcc_id(accId);
		accessTokenDao.save(accessToken);
	}

+ 29 - 9
patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/controller/common/account/CustomerController.java

@ -1,15 +1,14 @@
package com.yihu.wlyy.controller.common.account;
import com.yihu.wlyy.controller.BaseController;
import com.yihu.wlyy.entity.Doctor;
import com.yihu.wlyy.entity.Patient;
import com.yihu.wlyy.entity.User;
import com.yihu.wlyy.entity.WlyyCustomerLog;
import com.yihu.wlyy.repository.ManageDictDao;
import com.yihu.wlyy.repository.PatientDao;
import com.yihu.wlyy.service.manager.account.CustomerService;
import com.yihu.wlyy.service.manager.family.FamilyMemberService;
import com.yihu.wlyy.service.manager.hos.HosDoctorService;
import com.yihu.wlyy.service.manager.patient.AdminPatientService;
import com.yihu.wlyy.service.manager.sign.SignFamilyService;
import com.yihu.wlyy.service.manager.user.UserService;
import com.yihu.wlyy.service.manager.user.WlyyCustomerLogService;
import io.swagger.annotations.ApiParam;
@ -37,15 +36,9 @@ public class CustomerController extends BaseController {
    @Autowired
    private UserService userService;
    @Autowired
    private ManageDictDao manageDictDao;
    @Autowired
    private AdminPatientService patientService;
    @Autowired
    private CustomerService customerService;
    @Autowired
    private FamilyMemberService familyMemberService;
    @Autowired
    private SignFamilyService signFamilyService;
    @Autowired
    private WlyyCustomerLogService wlyyCustomerLogService;
@ -53,6 +46,8 @@ public class CustomerController extends BaseController {
    @Autowired
    private PatientDao patientDao;
    @Autowired
    private HosDoctorService doctorService;
    @RequestMapping(value = "/login",method = RequestMethod.POST,produces="application/json;charset=UTF-8")
    @ResponseBody
@ -174,4 +169,29 @@ public class CustomerController extends BaseController {
        return write(200,"查询成功","data",respon);
    }
    /**
     * 客服给医生发送短信,微信提醒
     * (医生助手功能)
     * @param msg
     * @param doctorCode
     * @return
     */
    @RequestMapping(value = "/sendMsg",produces="application/json;charset=UTF-8")
    @ResponseBody
    public String sendMsg(@ApiParam(name="msg",value="消息内容")@RequestParam(name="msg")String msg,
                          @ApiParam(name="doctorCode",value="发送给某个医生code")@RequestParam(name="doctorCode")String doctorCode,
                          @ApiParam(name="type",value="发送类型  1发送短信   2发送微信   3短信微信都发送")@RequestParam(name="doctorCode",required = false)String type) throws Exception {
        //用于返回的resp
        Doctor doctor = doctorService.getDoctorByCode(doctorCode);
        if(StringUtils.isBlank(type)){
            type="3";
        }
        Map<String, Object> resp = customerService.sendMsg(doctor,msg,type);
        if(resp.size()==0){
            return write(200,"发送成功");
        }
        return write(-1,"发送失败","data",resp);
    }
}

+ 11 - 0
patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/entity/Doctor.java

@ -99,6 +99,8 @@ public class Doctor extends IdEntity {
    private String adminTeamId;
    private String adminTeamName;
	private String openid; //医生微信openID
    @Column(name = "idcard")
    public String getIdCard() {
        return idCard;
@ -417,4 +419,13 @@ public class Doctor extends IdEntity {
    public void setAdminTeamName(String adminTeamName) {
        this.adminTeamName = adminTeamName;
    }
	@Column(name="openid")
	public String getOpenid() {
		return openid;
	}
	public void setOpenid(String openid) {
		this.openid = openid;
	}
}

+ 67 - 0
patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/service/manager/account/CustomerService.java

@ -6,8 +6,15 @@ import com.yihu.wlyy.entity.SignFamily;
import com.yihu.wlyy.service.manager.family.FamilyMemberService;
import com.yihu.wlyy.service.manager.hos.HosDoctorService;
import com.yihu.wlyy.service.manager.sign.FamilyContractService;
import com.yihu.wlyy.util.HttpClientUtil;
import org.apache.commons.lang3.StringUtils;
import org.apache.http.NameValuePair;
import org.apache.http.message.BasicNameValuePair;
import org.json.JSONObject;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import java.util.ArrayList;
@ -25,6 +32,12 @@ public class CustomerService{
	@Autowired
	private HosDoctorService hosDoctorService;
	@Value(("${doctorAssistant.api}")+"/wlyygc/doctor/message")
	private String messageApi;
	private Logger logger = LoggerFactory.getLogger(CustomerService.class);
	public Map<String,Object> findServerInfo(Patient patient) throws Exception {
		Map<String, Object> resp = new HashMap<>();
@ -93,4 +106,58 @@ public class CustomerService{
		return resp;
	}
	/**
	 *
	 * @param doctor
	 * @param msg
	 * @param type  1发送短信   2发送微信   3短信微信都发送
	 * @return
	 */
	public Map<String, Object> sendMsg(Doctor doctor,String msg,String type) {
		Map<String, Object> resp = new HashMap<String, Object>();
		//发送微信消息啦
		String openId = doctor.getOpenid();
		if(!StringUtils.isBlank(openId)&&!"1".equals(type)){
			List<NameValuePair> par = new ArrayList<NameValuePair>();
			par.add(new BasicNameValuePair("openIds", openId));
			par.add(new BasicNameValuePair("content", msg));
			try {
				logger.info("====================================================================");
				String result = HttpClientUtil.post(messageApi+"/sendWechatMessage", par,"UTF-8");
				logger.info("微信发送消息返回结果:"+result);
				logger.info("====================================================================");
				JSONObject resultJson = new JSONObject(result);
				if(1!=resultJson.getInt("successNum")){
					resp.put("wechat","-1");//-1代表发送失败
				}
			}catch (Exception e){
				resp.put("wechat","-1");//-1代表发送失败
			}
		}
		//发送短信消息啦
		String mobile = doctor.getMobile();
		if(!StringUtils.isBlank(mobile)&&!"2".equals(type)){
			msg+="\n您可通过微信关注\"i健康智能助手\"公众号更快更便捷的获取服务信息。";
			List<NameValuePair> par = new ArrayList<NameValuePair>();
			par.add(new BasicNameValuePair("mobiles", mobile));
			par.add(new BasicNameValuePair("content", msg));
			try {
				logger.info("====================================================================");
				String result = HttpClientUtil.post(messageApi+"/sendMessage",par,"UTF-8");
				logger.info("发送短信消息返回结果:"+result);
				logger.info("======================================================================");
				JSONObject resultJson = new JSONObject(result);
				if(1!=resultJson.getInt("successNum")){
					resp.put("mobile","-1");//-1代表发送失败
				}
			}catch (Exception e){
				resp.put("mobile","-1");//-1代表发送失败
			}
		}
		return resp;
	}
}

+ 4 - 1
patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/service/manager/family/FamilyMemberService.java

@ -109,7 +109,10 @@ public class FamilyMemberService extends BaseService {
                map1.put("sex", map.get("sex"));
                map1.put("isAuthorize", map.get("is_authorize"));//0:未授权,1:已授权
                map1.put("birthday", map.get("birthday"));
                map1.put("idcard", StringUtils.isEmpty(String.valueOf(map.get("idcard"))) ? "" : map.get("idcard").toString());
                String idCard = StringUtils.isEmpty(String.valueOf(map.get("idcard"))) ? "" : String.valueOf(map.get("idcard"));
                map1.put("idcard", CommonUtil.getIdcardEncode(idCard));
                map1.put("idcardAll", idCard);
                map1.put("photo", map.get("photo"));
                map1.put("mobile", map.get("mobile"));
                map1.put("address", StringUtils.isEmpty(String.valueOf(map.get("address"))) ? "" : map.get("address"));

+ 24 - 17
patient-co-manage/wlyy-manage/src/main/resources/application.yml

@ -1,6 +1,6 @@
server:
  port: 8180
  context-path: /wlyy_admin
  context-path: /wlyy_manager
  session-timeout: 3000000
spring:
@ -51,13 +51,13 @@ spring:
  profiles: dev
  datasource:
    wlyy:
      url: jdbc:mysql://172.19.103.85:3306/wlyy?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: linzhou
      password: linzhou
      url: jdbc:mysql://172.19.103.77:3306/wlyy?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: root
      password: 123456
    device:
      url: jdbc:mysql://172.19.103.85:3306/device?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: linzhou
      password: linzhou
      url: jdbc:mysql://172.19.103.77:3306/device?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: root
      password: 123456
    medicine:
      url: jdbc:mysql://172.19.103.77:3306/medicine?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: root
@ -73,15 +73,18 @@ im-service:
  im_service_url: http://172.19.103.88:3000/api/v2
yueren:
  api: http://120.77.209.211:8080
doctorAssistant:
  api: http://192.168.131.113:8080
#  api: http://172.19.103.88:10090/wlyy
---
spring:
  profiles: test
  datasource:
    wlyy:
      url: jdbc:mysql://172.19.103.77:3306/wlyy?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: root
      password: 123456
      url: jdbc:mysql://172.17.110.160/wlyy?useUnicode:true&amp;characterEncoding=utf-8&amp;autoReconnect=true
      username: ssgg
      password: ssgg
    device:
      url: jdbc:mysql://172.19.103.77:3306/device?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: root
@ -103,23 +106,25 @@ im-service:
  im_service_url: http://172.19.103.88:3000/api/v2
yueren:
  api: http://120.77.209.211:8080
doctorAssistant:
  api: http://172.19.103.88:10090/wlyy
---
spring:
  profiles: prod
  datasource:
    wlyy:
      url: jdbc:mysql://59.61.92.94:3306/wlyy?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      url: jdbc:mysql://59.61.92.90:8079/wlyy?useUnicode=true&amp;characterEncoding=utf-8&amp;autoReconnect=true
      username: wlyy
      password: jkzlehr@123
    device:
      url: jdbc:mysql://59.61.92.94:3306/device?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      url: jdbc:mysql://59.61.92.90:8079/device?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: wlyy
      password: jkzlehr@123
    medicine:
      url: jdbc:mysql://172.19.103.77:3306/medicine?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: root
      password: 123456
      url: jdbc:mysql://59.61.92.90:8079/medicine?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
      username: wlyy
      password: jkzlehr@123
  sms: # SMS短信配置
    yihu_sms_url: https://smsapi.ums86.com:9600/sms/Api/Send.do
    yihu_sms_code: 229336
@ -128,6 +133,8 @@ spring:
service-gateway:
  update-team-url: http://59.61.92.90:8072/wlyy_service/third/doctor/LoadTeamInfo
im-service:
  im_service_url: http://120.41.253.95:3000/api/v2
  im_service_url: http://27.155.101.77:3000/api/v2
yueren:
  api: http://120.77.209.211:8080
  api: http://120.77.209.211:8080
doctorAssistant:
  api: http://www.xmtyw.cn/assistant

+ 9 - 1
patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/common/dao/PatientHealthIndexDao.java

@ -51,5 +51,13 @@ public interface PatientHealthIndexDao
	@Query("select a from PatientHealthIndex a where a.user = ?1 and a.deviceSn = ?2 and a.value1 = ?3 and a.type = ?4 and a.recordDate = ?5 and a.del = '1' ")
	List<PatientHealthIndex> findByType(String patient, String deviceSn, String value1, Integer type, Date recordDate);
	
	@Query("select a from PatientHealthIndex a where a.user = ?1 and a.type =?2  order by recordDate desc ")
    List<PatientHealthIndex> findByPatientAndType(String patientCode, int type, Pageable pageable);
	@Query("select count(a) from PatientHealthIndex a where a.recordDate >= ?1 and a.recordDate <= ?2 and a.type in (1,2) and a.status = ?3 and a.del = '1' and user = ?4")
	int getCountByTimeAndStatus(Date start, Date end, int status, String patientCode);
	@Query(value="select * from device.wlyy_patient_health_index where user = ?1 and type = ?2 ORDER BY record_date desc limit 0 ,5",nativeQuery = true)
	List<PatientHealthIndex> findByPatientAndTypeByPage(String patientCode, int type);
}

+ 9 - 7
patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/common/http/HttpClientUtil.java

@ -18,6 +18,7 @@ import org.apache.http.util.EntityUtils;
import org.json.JSONObject;
import org.springframework.http.HttpHeaders;
import org.springframework.http.MediaType;
import org.springframework.stereotype.Component;
import org.springframework.util.StringUtils;
import org.springframework.web.client.RestTemplate;
@ -29,10 +30,11 @@ import java.util.Map;
/**
 * Created by hzp on 2016/8/9.
 */
@Component
public class HttpClientUtil {
    /**************************** 私有方法 *****************************************/
    private static CloseableHttpClient getCloseableHttpClient(SSLConnectionSocketFactory ssl) {
    private CloseableHttpClient getCloseableHttpClient(SSLConnectionSocketFactory ssl) {
        if(ssl == null)
        {
            return HttpClients.createDefault();
@ -45,7 +47,7 @@ public class HttpClientUtil {
        }
    }
    private static void close(CloseableHttpClient httpClient, CloseableHttpResponse response) {
    private void close(CloseableHttpClient httpClient, CloseableHttpResponse response) {
        try {
            if (httpClient != null) {
                httpClient.close();
@ -62,7 +64,7 @@ public class HttpClientUtil {
        }
    }
    private static HttpRequestBase getRequest(String method,String url,Map<String,Object> params,Map<String,Object> header) throws Exception
    private HttpRequestBase getRequest(String method,String url,Map<String,Object> params,Map<String,Object> header) throws Exception
    {
        List<BasicNameValuePair> jsonParams = new ArrayList<>();
        //配置参数
@ -101,7 +103,7 @@ public class HttpClientUtil {
    /**
     * get请求
     */
    public static HttpResponse request(String method,String url,Map<String,Object> params,Map<String,Object> header,SSLConnectionSocketFactory ssl,String user,String password) {
    public HttpResponse request(String method,String url,Map<String,Object> params,Map<String,Object> header,SSLConnectionSocketFactory ssl,String user,String password) {
        HttpResponse re = new HttpResponse();
        CloseableHttpResponse response = null;
        CloseableHttpClient httpclient = getCloseableHttpClient(ssl);
@ -142,7 +144,7 @@ public class HttpClientUtil {
     * @param chatSet 编码格式
     * @return
     */
    public static String get(String url, String chatSet) {
    public String get(String url, String chatSet) {
        CloseableHttpClient httpclient = HttpClients.createDefault();
        try {
            // 创建httpget.
@ -175,7 +177,7 @@ public class HttpClientUtil {
        return null;
    }
    public static String postBody(String url,JSONObject params){
    public String postBody(String url,JSONObject params){
        RestTemplate restTemplate = new RestTemplate();
        HttpHeaders headers = new HttpHeaders();
        MediaType type = MediaType.parseMediaType("application/json; charset=UTF-8");
@ -186,7 +188,7 @@ public class HttpClientUtil {
        return ret;
    }
    public static void putBody(String url,JSONObject params){
    public void putBody(String url,JSONObject params){
        RestTemplate restTemplate = new RestTemplate();
        HttpHeaders headers = new HttpHeaders();
        MediaType type = MediaType.parseMediaType("application/json; charset=UTF-8");

+ 4 - 2
patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/common/http/HttpHelper.java

@ -3,7 +3,7 @@ package com.yihu.hos.device.common.http;
import org.apache.http.conn.ssl.SSLConnectionSocketFactory;
import org.apache.http.conn.ssl.TrustSelfSignedStrategy;
import org.apache.http.ssl.SSLContexts;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import javax.net.ssl.SSLContext;
@ -23,6 +23,8 @@ public class HttpHelper {
    private String httpsUser;
    private String httpsUserPassword;
    @Autowired
    private HttpClientUtil HttpClientUtil;
    private SSLConnectionSocketFactory  getDefaultSSL()
    {
@ -148,7 +150,7 @@ public class HttpHelper {
        }
    }
    public static HttpResponse delete(String url,Map<String,Object> params,Map<String,Object> header,SSLConnectionSocketFactory ssl,String user,String password)
    public HttpResponse delete(String url,Map<String,Object> params,Map<String,Object> header,SSLConnectionSocketFactory ssl,String user,String password)
    {
        return HttpClientUtil.request("DELETE",url,params,header,ssl,user,password);

+ 17 - 10
patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/common/util/ImUtill.java

@ -2,11 +2,18 @@ package com.yihu.hos.device.common.util;
import com.yihu.hos.device.common.http.HttpClientUtil;
import org.json.JSONObject;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
/**
 * Created by 卓 on 2017/1/13.
 */
@Component
public class ImUtill {
    @Autowired
    private HttpClientUtil HttpClientUtil;
    /**
     * 发送消息给IM
     *
@ -14,7 +21,7 @@ public class ImUtill {
     * @param contentType 1文字 2图片消息
     * @param content     内容
     */
    public static String sendImMsg(String baseUrl,String from,String fromName, String sessionId, String contentType, String content,String businessType) {
    public String sendImMsg(String baseUrl,String from,String fromName, String sessionId, String contentType, String content,String businessType) {
        String imAddr = baseUrl + "/api/v2/sessions/"+sessionId+"/messages";
        JSONObject params = new JSONObject();
        params.put("sender_id", from);
@ -35,7 +42,7 @@ public class ImUtill {
     * @param contentType 1文字 2图片消息
     * @param content     内容
     */
    public static String sendTopicIM(String baseUrl,String from,String fromName, String topicId, String contentType, String content) {
    public String sendTopicIM(String baseUrl,String from,String fromName, String topicId, String contentType, String content) {
        String url = baseUrl+ ("api/v2/sessions/topic/"+topicId+"/messages");
        JSONObject params = new JSONObject();
        params.put("sender_id", from);
@ -55,7 +62,7 @@ public class ImUtill {
     * @param endUserName 结束人名字
     * @param sessionId 会话ID
     */
    public static JSONObject endTopics(String baseUrl,String sessionId,String endUser, String endUserName,String topicId) {
    public JSONObject endTopics(String baseUrl,String sessionId,String endUser, String endUserName,String topicId) {
        String imAddr = baseUrl + "api/v2/sessions/"+sessionId+"/topics/"+topicId+"/ended";
        JSONObject params = new JSONObject();
        params.put("session_id", sessionId);
@ -78,7 +85,7 @@ public class ImUtill {
     * @param user 结束人名字
     * @param sessionId 会话ID
     */
    public static void updateTopicUser(String baseUrl,String sessionId,String user) {
    public void updateTopicUser(String baseUrl,String sessionId,String user) {
        String imAddr = baseUrl + "api/v2/sessions/"+sessionId+"/participants/"+user;
        JSONObject params = new JSONObject();
        params.put("user", user+":"+0);
@ -92,7 +99,7 @@ public class ImUtill {
     * @param topicName  议题名称
     * @param participants 成员
     */
    public static JSONObject createTopics(String baseUrl,String sessionId, String topicId, String topicName, JSONObject participants, JSONObject messages, String sessionType) {
    public JSONObject createTopics(String baseUrl,String sessionId, String topicId, String topicName, JSONObject participants, JSONObject messages, String sessionType) {
        String imAddr = baseUrl + "api/v2/sessions/"+topicId+"/topics";
        JSONObject params = new JSONObject();
        params.put("topic_id", topicId);
@ -115,7 +122,7 @@ public class ImUtill {
     * 创建会话(system)
     *
     */
    public static JSONObject createSession(String baseUrl,JSONObject participants,String sessionType,String sessionName,String sessionId) {
    public JSONObject createSession(String baseUrl,JSONObject participants,String sessionType,String sessionName,String sessionId) {
        String imAddr = baseUrl + "api/v2/sessions";
        JSONObject params = new JSONObject();
        params.put("participants", participants.toString());
@ -141,7 +148,7 @@ public class ImUtill {
     * @param images
     * @return
     */
    public static JSONObject getCreateTopicMessage(String senderId,String senderName,String title,String description,String images){
    public JSONObject getCreateTopicMessage(String senderId,String senderName,String title,String description,String images){
        JSONObject messages = new JSONObject();
        messages.put("description",description);
        messages.put("title",title);
@ -151,7 +158,7 @@ public class ImUtill {
        return messages;
    }
    public static JSONObject getTopicMessage(String baseUrl,String topicId,String startMsgId,String endMsgId,int page,int pagesize,String uid){
    public JSONObject getTopicMessage(String baseUrl,String topicId,String startMsgId,String endMsgId,int page,int pagesize,String uid){
        String url = baseUrl
                + "api/v2/sessions/topic/"+topicId+"/messages?topic_id="+topicId+"&end="+startMsgId
                +"&start="+(endMsgId==null?"":endMsgId)+"&page="+page+"&pagesize="+pagesize+"&user="+uid;
@ -176,7 +183,7 @@ public class ImUtill {
     * @param sessionId
     * @return
     */
    public static JSONObject deleteMucUser(String baseUrl,String userId,String oldUserId,String sessionId) throws  Exception{
    public JSONObject deleteMucUser(String baseUrl,String userId,String oldUserId,String sessionId) throws  Exception{
        String url = baseUrl
                + "api/v2/sessions/"+sessionId+"/participant/update";
        try{
@ -202,7 +209,7 @@ public class ImUtill {
     * @param topicId
     * @return
     */
    public static JSONObject getTopic(String baseUrl,String topicId) throws  Exception{
    public JSONObject getTopic(String baseUrl,String topicId) throws  Exception{
        String url =baseUrl
                + "api/v2/sessions/topics/"+topicId+"?topic_id="+topicId;
        try{

+ 14 - 0
patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/model/Patient.java

@ -81,6 +81,8 @@ public class Patient extends IdEntity implements Serializable {
	private String openid;
	// 用户状态:1正常,0禁用,-1恶意注册,2审核中
	private Integer status;
	//居民预警状态:0为标准,1为预警状态
	private Integer standardStatus;
	public Patient(Long id) {
@ -319,4 +321,16 @@ public class Patient extends IdEntity implements Serializable {
	public void setStatus(Integer status) {
		this.status = status;
	}
	public static long getSerialVersionUID() {
		return serialVersionUID;
	}
	public Integer getStandardStatus() {
		return standardStatus;
	}
	public void setStandardStatus(Integer standardStatus) {
		this.standardStatus = standardStatus;
	}
}

+ 13 - 3
patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/model/PatientHealthIndex.java

@ -21,9 +21,9 @@ public class PatientHealthIndex extends IdEntity {
	private String intervene;
	// 血糖/收缩压/体重/腰围/早餐前空腹
	private String value1;
	// 舒张压/早餐后空腹
	// 舒张压/早餐后空腹/身高
	private String value2;
	// 午餐空腹
	// 午餐空腹/身高
	private String value3;
	// 午餐后
	private String value4;
@ -33,7 +33,7 @@ public class PatientHealthIndex extends IdEntity {
	private String value6;
	// 睡前
	private String value7;
	// 健康指标类型(1血糖,2血压,3体重,4腰围)
	// 健康指标类型(1血糖,2血压,3体重/身高/BMI,4腰围)
	private int type;
	// 记录时间
	private Date recordDate;
@ -48,6 +48,8 @@ public class PatientHealthIndex extends IdEntity {
	//设备编号
	private String deviceSn;
	private Integer status;//状态:0为标准,1为异常
	public String getUser() {
		return user;
	}
@ -182,4 +184,12 @@ public class PatientHealthIndex extends IdEntity {
	public void setDeviceSn(String deviceSn) {
		this.deviceSn = deviceSn;
	}
	public Integer getStatus() {
		return status;
	}
	public void setStatus(Integer status) {
		this.status = status;
	}
}

+ 109 - 12
patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/service/DeviceService.java

@ -19,6 +19,9 @@ import org.apache.commons.collections.map.HashedMap;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.math.NumberUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.PageRequest;
import org.springframework.data.domain.Pageable;
import org.springframework.data.domain.Sort;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Service;
@ -54,6 +57,8 @@ public class DeviceService {
    @Autowired
    private HttpHelper httpHelper;
    @Autowired
    private HttpClientUtil HttpClientUtil;
    @Autowired
    private SystemConfig systemConfig;
    @Autowired
    private JdbcTemplate jdbcTemplate;
@ -61,6 +66,8 @@ public class DeviceService {
    private  PatientBloodSuggerDao patientBloodSuggerDao;
    @Autowired
    private PatientHealthTimeDao patientHealthTimeDao;
    @Autowired
    private PushMsgTask pushMsgTask;
    private ObjectMapper objectMapper = new ObjectMapper();
    private Integer aStart;
@ -160,16 +167,16 @@ public class DeviceService {
        return "1";//"空腹血糖"
    }
 /*   private Boolean isInArea(String time, String[] timeArea) {
        String date = DateUtil.getDateFromDateTime(time);
        Long beginTime = DateUtil.compareDateTime(DateUtil.toTimestamp(time), DateUtil.toTimestamp(date + " " + timeArea[0] + ":00"));
        Long endTime = DateUtil.compareDateTime(DateUtil.toTimestamp(time), DateUtil.toTimestamp(date + " " + timeArea[1] + ":00"));
        if (beginTime > 0 && endTime < 0) {
            return true;
        } else {
            return false;
        }
    }*/
    /*   private Boolean isInArea(String time, String[] timeArea) {
           String date = DateUtil.getDateFromDateTime(time);
           Long beginTime = DateUtil.compareDateTime(DateUtil.toTimestamp(time), DateUtil.toTimestamp(date + " " + timeArea[0] + ":00"));
           Long endTime = DateUtil.compareDateTime(DateUtil.toTimestamp(time), DateUtil.toTimestamp(date + " " + timeArea[1] + ":00"));
           if (beginTime > 0 && endTime < 0) {
               return true;
           } else {
               return false;
           }
       }*/
// 判断时间是否在对应时间段
    private Boolean isInArea(String time,String begin,String end) {
        String date = DateUtil.getDateFromDateTime(time);
@ -390,6 +397,69 @@ public class DeviceService {
                uploadHealthIndex(result);
                System.out.println(result);
                //连续5次体征值正常,则修改为非预警状态;连续5次异常,修改为预警状态-----START
                String patientCode = result.getUser();
                //患者信息
                Patient patient = patientDao.findByCode(patientCode);
                int bloodPressureBbnormalCount = 0;//血压异常次数
                int bloodSuggurBbnormalCount = 0;//血糖异常次数
                List<PatientHealthIndex> bloodPressurepatientHealthIndices = new ArrayList<>();
                List<PatientHealthIndex> bloodSuggurpatientHealthIndices = new ArrayList<>();
                bloodPressurepatientHealthIndices = patientHealthIndexDao.findByPatientAndTypeByPage(patientCode,2);
                bloodSuggurpatientHealthIndices = patientHealthIndexDao.findByPatientAndTypeByPage(patientCode,1);
                for (PatientHealthIndex index1 : bloodPressurepatientHealthIndices) {
                    if(index1.getStatus() != null && 1 == index1.getStatus()){
                        bloodPressureBbnormalCount++;
                    }
                }
                for (PatientHealthIndex index2 : bloodSuggurpatientHealthIndices) {
                    if(index2.getStatus() != null && 1 == index2.getStatus()){
                        bloodSuggurBbnormalCount++;
                    }
                }
                //连续3次异常,修改用户为预警状态
                if( (bloodPressureBbnormalCount >=3 || bloodSuggurBbnormalCount >=3) && (patient.getStandardStatus() == null || 0 == patient.getStandardStatus())){
                    patient.setStandardStatus(1);
                }else{
                    Date end = new Date();
                    Date start = DateUtil.setDateTime(end,-7);
                    //计算血糖或者血压一周内的异常记录数量
                    int errorCount = patientHealthIndexDao.getCountByTimeAndStatus(start,end,1,patientCode);
                    if(errorCount >= 5){//超过5次,记为预警状态
                        patient.setStandardStatus(1);
                    }
                }
                //连续5次正常,修改用户为非预警状态
                if(patient.getDisease() != null){
                    if( 1 == patient.getDisease()){
                        if(0 == bloodPressureBbnormalCount && (patient.getStandardStatus() == null || 1 == patient.getStandardStatus())){
                            patient.setStandardStatus(0);
                        }
                    }else if(2 == patient.getDisease()){
                        if(0 == bloodSuggurBbnormalCount && (patient.getStandardStatus() == null || 1 == patient.getStandardStatus())){
                            patient.setStandardStatus(0);
                        }
                    }else if( 3 == patient.getDisease()){
                        if( 0 == bloodSuggurBbnormalCount && 0 == bloodPressureBbnormalCount && (patient.getStandardStatus() == null || 1 == patient.getStandardStatus())){
                            patient.setStandardStatus(0);
                        }
                    }
                }else{
                    patient.setStandardStatus(0);
                }
                patientDao.save(patient);
                //连续5次体征值正常,则修改为非预警状态;连续5次异常,修改为预警状态-----END
            }
        } catch (Exception e) {
            e.printStackTrace();
@ -451,6 +521,7 @@ public class DeviceService {
            obj.setUser(user);
            obj.setIdcard(device.getUserIdcard());
            obj.setStatus(0);
            //  1血糖 2血压 3体重 4腰围
            switch (type) {
                case "1":
@ -485,7 +556,7 @@ public class DeviceService {
                default:
                    throw new Exception("Can not support the metric!");
            }
            patientHealthIndexDao.save(obj);
            obj = patientHealthIndexDao.save(obj);
            return obj;
        } else {
            DeviceInfo deviceInfo = new DeviceInfo();
@ -585,6 +656,20 @@ public class DeviceService {
            Double minValueBefore = healthStandardConfig.getXt_min_before();
            Double maxValueAfter = healthStandardConfig.getXt_max_after();
            Double minValueAfter = healthStandardConfig.getXt_min_after();
            if (standard != null) {
                if (standard.getMaxValue1() > 0) {
                    maxValueBefore = standard.getMaxValue1();
                }
                if (standard.getMinValue1() > 0) {
                    minValueBefore = standard.getMinValue1();
                }
                if (standard.getMaxValue2() > 0) {
                    maxValueAfter = standard.getMaxValue2();
                }
                if (standard.getMinValue2() > 0) {
                    minValueAfter = standard.getMinValue2();
                }
            }
            int index = Integer.valueOf(data.getValue2());
            String value1 = data.getValue1();
@ -592,10 +677,18 @@ public class DeviceService {
            if (index % 2 == 0) {
                if (!checkHealthIndex(NumberUtils.toDouble(value1), maxValueBefore, minValueBefore)) {
                    msgContent += patient.getName() + "血糖异常(" + value1 + "mmol/L),请处理";
                    //体征异常,更新体征数据状态
                    data.setStatus(1);
                    patientHealthIndexDao.save(data);
                }
            } else { //餐前
                if (!checkHealthIndex(NumberUtils.toDouble(value1), maxValueAfter, minValueAfter)) {
                    msgContent += patient.getName() + "血糖异常(" + value1 + "mmol/L),请处理";
                    //体征异常,更新体征数据状态
                    data.setStatus(1);
                    patientHealthIndexDao.save(data);
                }
            }
        }
@ -626,6 +719,10 @@ public class DeviceService {
            // 收缩压/舒张压校验
            if (!checkHealthIndex(NumberUtils.toDouble(value1), maxValueSSY, minValueSSY) || !checkHealthIndex(NumberUtils.toDouble(value2), maxValueSZY, minValueSZY)) {
                msgContent = patient.getName() + "血压异常(舒张压 " + value2 + "mmHg、收缩压 " + value1 + "mmHg),请处理";
                //体征异常,更新体征数据状态
                data.setStatus(1);
                patientHealthIndexDao.save(data);
            }
        }
@ -705,7 +802,7 @@ public class DeviceService {
        // 批量保存消息
        messageDao.save(messages);
        // 推送消息给医生
        PushMsgTask.getInstance().put(array);
        pushMsgTask.put(array);
    }
    /**

+ 10 - 20
patient-co-service/wlyy_device/src/main/java/com/yihu/hos/device/task/PushMsgTask.java

@ -1,39 +1,28 @@
package com.yihu.hos.device.task;
import com.yihu.hos.device.common.configuration.SystemConfig;
import com.yihu.hos.device.common.util.ImUtill;
import net.sf.json.JSONArray;
import net.sf.json.JSONObject;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;
import javax.annotation.PostConstruct;
import java.util.concurrent.LinkedBlockingQueue;
@Component
public class PushMsgTask {
	public static String url="";
	private static Logger logger = LoggerFactory.getLogger(PushMsgTask.class);
	// 最大容量为50的数组堵塞队列
	private static LinkedBlockingQueue<JSONObject> queue = new LinkedBlockingQueue<JSONObject>();
	private static PushMsgTask instance;
	private static Object lock = new Object();
	@Value("${systemConfig.socket_server}")
	private String socket_server;
	@Autowired
	private SystemConfig systemConfig;
	public static PushMsgTask getInstance() {
		synchronized (lock) {
			if (instance == null) {
				instance = new PushMsgTask();
				instance.run();
			}
		}
		return instance;
	}
	private ImUtill ImUtill;
	/**
	 * 添加一条推送消息
@ -75,6 +64,7 @@ public class PushMsgTask {
		}
	}
	@PostConstruct
	private void run() {
		new Thread(new ConsumerTask()).start();
	}
@ -116,7 +106,7 @@ public class PushMsgTask {
	 * @param msg 消息内容
	 * @param data 消息数据
	 */
	public static boolean pushMessage(String receiver, String msgType, String title, String msg, String data) {
	public boolean pushMessage(String receiver, String msgType, String title, String msg, String data) {
		try {
//			String url = "http://127.0.0.1:3000/api/v1/chats/sm";
//			HttpHelper httpHelper=new HttpHelper();
@ -135,8 +125,8 @@ public class PushMsgTask {
//			} else {
//				throw new Exception("接口调用错误!"+response.getBody());
//			}
			String url = "http://127.0.0.1:3000/";
			String url = socket_server +"/";
			org.json.JSONObject participants = new org.json.JSONObject();
			participants.put("system",0);
			participants.put(receiver,0);

+ 4 - 4
patient-co-service/wlyy_device/src/main/resources/application.yml

@ -52,8 +52,8 @@ spring:
  profiles: test
  datasource:
    url: jdbc:mysql://172.19.103.85:3306/device?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
    username: ssgg
    password: ssgg
    username: linzhou
    password: linzhou
    driverClassName: com.mysql.jdbc.Driver
    maxTotal: 500
    maxIdle: 30
@ -77,7 +77,7 @@ healthStandard:
systemConfig:
  msg_push_server: http://127.0.0.1:3000/system/sendmsg.im
  jw_server: http://172.19.103.88:8011/wlyy_service-1.0-SNAPSHOT
  socket_server: http://192.168.131.102:3008
  socket_server: http://172.19.103.88:3000
---
spring:
  profiles: production
@ -107,5 +107,5 @@ healthStandard:
  ssy_max: 140
systemConfig:
  msg_push_server: http://127.0.0.1:3000/system/sendmsg.im
  jw_server: http://59.61.92.90:8087/wlyy_service
  jw_server: http://59.61.92.90:8072/wlyy_service
  socket_server: http://27.155.101.77:3000

+ 68 - 8
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/ArchivesController.java

@ -8,16 +8,14 @@ import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.*;
/**
 * 智业服务接口
 * */
@Controller
@RestController
@RequestMapping(value = "/third/archives/")
@Api(description = "智业档案服务接口")
public class ArchivesController {
@ -28,7 +26,6 @@ public class ArchivesController {
	/********************************* 居民档案相关接口 ****************************************************************/
	@RequestMapping(value = "getEhrSickMedicalList",method = RequestMethod.POST)
	@ResponseBody
	@ApiOperation("查询居民健康体检列表信息接口")
	public Result getEhrSickMedicalList(
			@ApiParam(name="idcard",value="患者身份证",defaultValue = "350821201112240026")
@ -49,7 +46,6 @@ public class ArchivesController {
	}
	@RequestMapping(value = "getEhrSickMedicalRecord",method = RequestMethod.POST)
	@ResponseBody
	@ApiOperation("查询居民健康体检详情接口")
	public Result getEhrSickMedicalRecord(
			@ApiParam(name="medicalNo",value="体检ID",defaultValue = "")
@ -70,7 +66,6 @@ public class ArchivesController {
	}
	@RequestMapping(value = "uploadFollowup",method = RequestMethod.POST)
	@ResponseBody
	@ApiOperation("上传随访记录接口")
	public Result uploadFollowup(@ApiParam(name="id",value="随访记录id",defaultValue = "4")
								  @RequestParam(value="id",required = true) Long id){
@ -90,7 +85,6 @@ public class ArchivesController {
	}
	@RequestMapping(value = "uploadHealthIndex",method = RequestMethod.POST)
	@ResponseBody
	@ApiOperation("上传体征指标接口")
	public Result uploadHealthIndex(@ApiParam(name="id",value="体征记录id",defaultValue = "5226")
									 @RequestParam(value="id",required = true) Long id){
@ -108,4 +102,70 @@ public class ArchivesController {
			}
		}
	}
	/*****************************************自助建档***************************************************/
	@RequestMapping(value = "getSickArchiveFlag",method = RequestMethod.POST)
	@ApiOperation("查询居民是否有建立健康档案接口")
	public Result getSickArchiveFlag(
			@ApiParam(name="idcard",value="身份证号",defaultValue = "")
			@RequestParam(value="idcard",required = true) String idcard){
		try {
			String response = archivesService.getSickArchiveFlag(idcard);
			return Result.success("查询居民是否有建立健康档案接口成功!",response);
		} catch (Exception ex) {
			if(ex instanceof ApiException)
			{
				ApiException apiEx = (ApiException) ex;
				return Result.error(apiEx.errorCode(),ex.getMessage());
			}
			else{
				return Result.error(ex.getMessage());
			}
		}
	}
	@RequestMapping(value = "getSickArchiveRecord",method = RequestMethod.POST)
	@ApiOperation("查询居民健康档案信息接口")
	public Result getSickArchiveRecord(
			@ApiParam(name="idcard",value="身份证号",defaultValue = "")
			@RequestParam(value="idcard",required = true) String idcard){
		try {
			String response = archivesService.getSickArchiveRecord(idcard);
			return Result.success("查询居民健康档案信息接口!",response);
		} catch (Exception ex) {
			ex.printStackTrace();
			if(ex instanceof ApiException)
			{
				ApiException apiEx = (ApiException) ex;
				return Result.error(apiEx.errorCode(),ex.getMessage());
			}
			else{
				return Result.error(ex.getMessage());
			}
		}
	}
	@RequestMapping(value = "saveSickArchiveRecord",method = RequestMethod.POST)
	@ApiOperation("上传居民档案建档信息接口")
	public Result saveSickArchiveRecord(@ApiParam(name="json",value="居民建档信息",defaultValue = "")
										@RequestParam(value="json",required = true) String json,
										@ApiParam(name="doctor",value="医生code",defaultValue = "")
										@RequestParam(value="doctor",required = true) String doctor){
		try {
			String response = archivesService.saveSickArchiveRecord(json,doctor);
			return Result.success("上传居民档案建档信息接口!",response);
		} catch (Exception ex) {
			ex.printStackTrace();
			if(ex instanceof ApiException)
			{
				ApiException apiEx = (ApiException) ex;
				return Result.error(apiEx.errorCode(),ex.getMessage());
			}
			else{
				return Result.error(ex.getMessage());
			}
		}
	}
}

+ 1 - 1
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/CommonController.java

@ -20,7 +20,7 @@ import org.springframework.web.bind.annotation.RestController;
@Controller
@RestController
@RequestMapping(value = "/common/")
@Api(description = "长处方接口")
@Api(description = "公共请求接口")
public class CommonController {
    private static Logger logger = LoggerFactory.getLogger(CommonController.class);

+ 79 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/HttpController.java

@ -0,0 +1,79 @@
package com.yihu.wlyy.service.controller;
import com.yihu.wlyy.service.common.http.HttpHelper;
import com.yihu.wlyy.service.common.http.HttpResponse;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import net.sf.json.JSONObject;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.client.RestTemplate;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;
/**
 * Created by chenweida on 2017/9/9.
 */
@Controller
@RequestMapping(value = "/http")
@Api(description = "http请求接口")
public class HttpController {
    @Autowired
    private HttpHelper httpHelper;
    @RequestMapping(value = "/get", method = RequestMethod.GET)
    @ResponseBody
    @ApiOperation("统一get接口")
    public String get(
            @ApiParam(name = "url", value = "请求的url 例 http://127.0.0.1:8761:xzx/xxx", required = false) @RequestParam(value = "url", required = false) String url,
            @ApiParam(name = "params", value = "请求的参数(json格式)", required = false) @RequestParam(value = "params", required = false) String params
    ) {
        try {
            JSONObject jsonObject = JSONObject.fromObject(params);
            Map<String, Object> mapParams = new HashMap<>();
            Iterator it = jsonObject.keys();
            // 遍历jsonObject数据,添加到Map对象
            while (it.hasNext()) {
                String key = String.valueOf(it.next());
                String value = (String) jsonObject.get(key);
                mapParams.put(key, value);
            }
            HttpResponse h = httpHelper.get(url, mapParams);
            return h.getBody();
        } catch (Exception e) {
            e.printStackTrace();
        }
        return "执行失败";
    }
    @RequestMapping(value = "/post", method = RequestMethod.GET)
    @ResponseBody
    @ApiOperation("统一post接口")
    public String post(
            @ApiParam(name = "url", value = "请求的url", required = false) @RequestParam(value = "url", required = false) String url,
            @ApiParam(name = "params", value = "请求的参数", required = false) @RequestParam(value = "params", required = false) String params) {
        try {
            JSONObject jsonObject = JSONObject.fromObject(params);
            Map<String, Object> mapParams = new HashMap<>();
            Iterator it = jsonObject.keys();
            // 遍历jsonObject数据,添加到Map对象
            while (it.hasNext()) {
                String key = String.valueOf(it.next());
                String value = (String) jsonObject.get(key);
                mapParams.put(key, value);
            }
            HttpResponse h = httpHelper.post(url, mapParams);
            return h.getBody();
        } catch (Exception e) {
            e.printStackTrace();
        }
        return "执行失败";
    }
}

+ 18 - 1
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/PrescriptionController.java

@ -85,7 +85,7 @@ public class PrescriptionController extends BaseController{
	@RequestMapping(value = "readNewsOnline",method = RequestMethod.POST)
	@ApiOperation("提供在线问诊消息调阅")
	public String readNewsOnline(@ApiParam(name="data",value="json串",defaultValue = "{}")
	public String readNewsOnline(@ApiParam(name="data",value="json串",defaultValue = "{\"CODE\":1,\"RECIPE_NO\":\"0\",\"ORDER_NO\":\"DB0537136\"}")
								 @RequestParam(value = "data",required = true) String data){
		try {
			String url = prescriptionService.getReadNewsOnline(data);
@ -195,6 +195,23 @@ public class PrescriptionController extends BaseController{
		}
	}
	@RequestMapping(value = "getRecipeMasterList",method = RequestMethod.POST)
	@ApiOperation("获取历史处方列表")
	public Result getRecipeMasterList(@ApiParam(name="patientCode",value="居民code",defaultValue = "")
							@RequestParam(value = "patientCode",required = true) String patientCode,
							@ApiParam(name="applyTimeFrom",value="开始时间",defaultValue = "")
							@RequestParam(value = "applyTimeFrom",required = false) String applyTimeFrom,
							@ApiParam(name="applyTimeEnd",value="结束时间",defaultValue = "")
							@RequestParam(value = "applyTimeEnd",required = false) String applyTimeEnd){
		try {
			String re = prescriptionService.getRecipeMasterList(patientCode,applyTimeFrom,applyTimeEnd);
			return Result.success("获取历史处方列表!",re);
		} catch (Exception ex) {
			ex.printStackTrace();
			return Result.error(ex.getMessage());
		}
	}
	@RequestMapping(value = "saveRecipe",method = RequestMethod.POST)
	@ApiOperation("挂号开处方接口,调整处方接口")

+ 83 - 32
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/SignController.java

@ -7,12 +7,10 @@ import com.zoe.phip.ssp.sdk.ApiException;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.*;
import java.util.Map;
@ -20,37 +18,90 @@ import java.util.Map;
 * 智业服务接口
 * */
@Controller
@RestController
@RequestMapping(value = "/third/sign/")
@Api(description = "基卫签约服务接口")
public class SignController {
	@Autowired
	ZysoftService zysoftService;
	@Autowired
	private SignZYService signZYService;
	/******************************* 签约接口 ********************************************************/
	@RequestMapping(value = "CheckSignFamily",method = RequestMethod.POST)
	@ResponseBody
	@ApiOperation("查询是否已签约")
	public Result checkSignFamily(
			@ApiParam(name="idcard",value="患者身份证",defaultValue = "350821201112240026")
			@RequestParam(value="idcard",required = true) String idcard){
		try {
			Map<String,String> response = signZYService.checkSignFamily(idcard);
			return Result.success("查询签约成功!",response);
		} catch (Exception ex) {
			if(ex instanceof ApiException)
			{
				ApiException apiEx = (ApiException) ex;
				return Result.error(apiEx.errorCode(),ex.getMessage());
			}
			else{
				return Result.error(ex.getMessage());
			}
		}
	}
    @Autowired
    ZysoftService zysoftService;
    @Autowired
    private SignZYService signZYService;
    /******************************* 签约接口 ********************************************************/
    @RequestMapping(value = "CheckSignFamily",method = RequestMethod.POST)
    @ApiOperation("查询是否已签约")
    public Result checkSignFamily(
            @ApiParam(name="idcard",value="患者身份证",defaultValue = "350821201112240026")
            @RequestParam(value="idcard",required = true) String idcard){
        try {
            Map<String,String> response = signZYService.checkSignFamily(idcard);
            return Result.success("查询签约成功!",response);
        } catch (Exception ex) {
            if(ex instanceof ApiException)
            {
                ApiException apiEx = (ApiException) ex;
                return Result.error(apiEx.errorCode(),ex.getMessage());
            }
            else{
                return Result.error(ex.getMessage());
            }
        }
    }
    @RequestMapping(value = "getSickFamilyDoctorSignLimit",method = RequestMethod.POST)
    @ApiOperation("查询家庭医生签约人数上限接口")
    public Result getSickFamilyDoctorSignLimit(
            @ApiParam(name="jwTeamCode",value="智业行政团队code",defaultValue = "44")
            @RequestParam(value="jwTeamCode",required = true) String jwTeamCode){
        try {
            String response = signZYService.getSickFamilyDoctorSignLimit(jwTeamCode);
            return Result.success("查询签约成功!",response);
        } catch (Exception ex) {
            ex.printStackTrace();
            if(ex instanceof ApiException)
            {
                ApiException apiEx = (ApiException) ex;
                return Result.error(apiEx.errorCode(),ex.getMessage());
            }
            else{
                return Result.error(ex.getMessage());
            }
        }
    }
    @RequestMapping(value = "getSickFamilyDoctorSpecialistControl",method = RequestMethod.POST)
    @ApiOperation("查询家签慢病患者定标情况接口")
    public Result getSickFamilyDoctorSpecialistControl(
            @ApiParam(name="TIME_START",value="修改的开始时间",defaultValue = "2017-6-6 00:00:00")
            @RequestParam(value="TIME_START",required = false) String TIME_START,
            @ApiParam(name="TIME_END",value="修改的开始时间",defaultValue = "2017-6-7 23:59:59")
            @RequestParam(value="TIME_END",required = false) String TIME_END,
            @ApiParam(name="IDENTITY_CARD_NO",value="身份证号",defaultValue = "360502194503120013")
            @RequestParam(value="IDENTITY_CARD_NO",required = false) String IDENTITY_CARD_NO){
        try {
            String response = "";
            if(StringUtils.isBlank(IDENTITY_CARD_NO)){
                response = signZYService.getSickFamilyDoctorSpecialistControl(TIME_START,TIME_END);
            }else{
                response = signZYService.getSickFamilyDoctorSpecialistControlByIdcard(IDENTITY_CARD_NO);
            }
            return Result.success("查询成功!",response);
        } catch (Exception ex) {
            ex.printStackTrace();
            if(ex instanceof ApiException)
            {
                ApiException apiEx = (ApiException) ex;
                return Result.error(apiEx.errorCode(),ex.getMessage());
            }
            else{
                return Result.error(ex.getMessage());
            }
        }
    }
}

+ 3 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/dao/DoctorMappingDao.java

@ -27,4 +27,7 @@ public interface DoctorMappingDao extends PagingAndSortingRepository<DoctorMappi
    @Query("select a from Doctor a,DoctorMapping b where a.code = b.doctorCode and a.code = ?1 and b.jwDoctorHospital = ?2")
    Doctor getDoctor(String docotrCode,String jwDoctorHospital);
    @Query(value = "select a.* from wlyy_doctor_mapping a where a.jw_doctor_hospital = ?1 and a.doctor_code=?2 order by a.id DESC limit 1",nativeQuery = true)
    DoctorMapping findByJwDoctorHospitalAndDoctorCode(String jwDoctorHospital,String doctorCode);
}

+ 4 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/dao/prescription/PrescriptionDao.java

@ -30,4 +30,8 @@ public interface PrescriptionDao extends PagingAndSortingRepository<Prescription
    @Query("from Prescription p where p.visitNo=?1 and p.recipeNo=?2")
    Prescription findByVisitNoAndRecipeNo(String visitNo,String recipeNo);
    @Modifying
    @Query("update Prescription p set p.jwPayStatus=1 where p.code=?1")
    void updatejwPayStatus(String prescriptionCode);
}

+ 3 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/dao/prescription/PrescriptionExpressageDao.java

@ -11,4 +11,7 @@ public interface PrescriptionExpressageDao extends PagingAndSortingRepository<Pr
    @Query("from PrescriptionExpressage p where p.mailno=?1")
    PrescriptionExpressage findByPrescriptionExpressMailno(String mailno);
    @Query(" from PrescriptionExpressage p where p.prescriptionCode=?1 and p.del=1")
    PrescriptionExpressage findByPrescriptionCode(String prescriptionCode);
}

+ 4 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/dao/zydict/ZyIvPhysicDictDao.java

@ -2,10 +2,14 @@ package com.yihu.wlyy.service.dao.zydict;
import com.yihu.wlyy.service.entity.zydict.ZyIvPhysicDict;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.PagingAndSortingRepository;
/**
 * Created by yeshijie on 2017/8/11.
 */
public interface ZyIvPhysicDictDao extends PagingAndSortingRepository<ZyIvPhysicDict, Long>, JpaSpecificationExecutor<ZyIvPhysicDict> {
    @Query("select p from ZyIvPhysicDict p where p.physicCode=?1")
    ZyIvPhysicDict findByPhysicCode(String physicCode);
}

+ 10 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/entity/Patient.java

@ -74,6 +74,8 @@ public class Patient extends IdEntity {
	private Integer status;
	// 用户手机备注
	private String mobileRemarks;
	//居民预警状态:0为标准,1为预警状态
	private Integer standardStatus;
	public Patient() {
	}
@ -312,4 +314,12 @@ public class Patient extends IdEntity {
	public void setMobileRemarks(String mobileRemarks) {
		this.mobileRemarks = mobileRemarks;
	}
	public Integer getStandardStatus() {
		return standardStatus;
	}
	public void setStandardStatus(Integer standardStatus) {
		this.standardStatus = standardStatus;
	}
}

+ 13 - 3
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/entity/device/PatientHealthIndex.java

@ -23,9 +23,9 @@ public class PatientHealthIndex extends IdEntity {
	private String intervene;
	// 血糖/收缩压/体重/腰围/早餐前空腹
	private String value1;
	// 舒张压/早餐后空腹
	// 舒张压/早餐后空腹/身高
	private String value2;
	// 午餐空腹
	// 午餐空腹/BMI
	private String value3;
	// 午餐后
	private String value4;
@ -35,7 +35,7 @@ public class PatientHealthIndex extends IdEntity {
	private String value6;
	// 睡前
	private String value7;
	// 健康指标类型(1血糖,2血压,3体重,4腰围)
	// 健康指标类型(1血糖,2血压,3体重/身高/BMI,4腰围)
	private int type;
	// 记录时间
	private Date recordDate;
@ -50,6 +50,8 @@ public class PatientHealthIndex extends IdEntity {
	//设备编号
	private String deviceSn;
	private int status;//状态:0为标准,1为异常
	public String getUser() {
		return user;
	}
@ -184,4 +186,12 @@ public class PatientHealthIndex extends IdEntity {
	public void setDeviceSn(String deviceSn) {
		this.deviceSn = deviceSn;
	}
	public int getStatus() {
		return status;
	}
	public void setStatus(int status) {
		this.status = status;
	}
}

+ 10 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/entity/prescription/PrescriptionExpressage.java

@ -49,6 +49,8 @@ public class PrescriptionExpressage extends IdEntity {
    private Date createTime;                //创建的时间
    private Integer del;    //1可用 0删除
    private Date deliveryTime; //送达时间
    @Column(name = "code", unique = true , nullable=false)
@ -304,4 +306,12 @@ public class PrescriptionExpressage extends IdEntity {
    public void setAcceptTime(Date acceptTime) {
        this.acceptTime = acceptTime;
    }
    public Date getDeliveryTime() {
        return deliveryTime;
    }
    public void setDeliveryTime(Date deliveryTime) {
        this.deliveryTime = deliveryTime;
    }
}

+ 44 - 1
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/ArchivesService.java

@ -24,7 +24,8 @@ public class ArchivesService {
    @Autowired
    private DoctorDao doctorDao;
    @Autowired
    private DoctorMappingDao doctorMappingDao;
    @Autowired
    private SignFamilyDao signFamilyDao;
@ -330,4 +331,46 @@ public class ArchivesService {
        }
    }
    /*****************************************自助建档***************************************************/
    /**
     * 7.1查询居民是否有建立健康档案接口
     * @param idcard
     * @return
     */
    public String getSickArchiveFlag(String idcard) throws Exception{
        String[] hm = getHospitalMapping(null);
        return zysoftService.getSickArchiveFlag(idcard,hm[0],hm[1]);
    }
    /**
     * 7.2查询居民健康档案信息接口
     * @param idcard
     * @return
     */
    public String getSickArchiveRecord(String idcard) throws Exception{
        String[] hm = getHospitalMapping(null);
        return zysoftService.getSickArchiveRecord(idcard,hm[0],hm[1]);
    }
    /**
     * 上传居民档案建档信息接口
     * @param json
     * @param doctor
     * @return
     * @throws Exception
     */
    public String saveSickArchiveRecord(String json,String doctor) throws Exception{
        Doctor d = doctorDao.findByCode(doctor);
        String[] hm = getHospitalMapping(d.getHospital());
        DoctorMapping doctorMapping = doctorMappingDao.findByJwDoctorHospitalAndDoctorCode(hm[0],doctor);
        return zysoftService.saveSickArchiveRecord(json,hm[0],hm[1],doctorMapping);
    }
}

+ 35 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/SignZYService.java

@ -124,5 +124,40 @@ public class SignZYService {
    }
    /**
     * 7.51查询家庭医生签约人数上限接口
     * @param jwTeamCode
     * @return
     * @throws Exception
     */
    public String getSickFamilyDoctorSignLimit(String jwTeamCode) throws Exception{
        String[] hospitalMapping = getHospitalMapping(null); //获取机构映射
        String response = zysoftService.getSickFamilyDoctorSignLimit(jwTeamCode,hospitalMapping[0],hospitalMapping[1]);
        return response;
    }
    /**
     * 根据时间范围查询家签慢病患者定标情况接口
     * @param time_start
     * @param time_end
     * @return
     */
    public String getSickFamilyDoctorSpecialistControl(String time_start, String time_end)throws Exception {
        String[] hospitalMapping = getHospitalMapping(null); //获取机构映射
        String response = zysoftService.getSickFamilyDoctorSpecialistControl(time_start,time_end,hospitalMapping[0],hospitalMapping[1]);
        return response;
    }
    /**
     * 根据身份证号查询家签慢病患者定标情况接口
     * @param identity_card_no
     * @return
     */
    public String getSickFamilyDoctorSpecialistControlByIdcard(String identity_card_no) throws Exception {
        String[] hospitalMapping = getHospitalMapping(null); //获取机构映射
        String response = zysoftService.getSickFamilyDoctorSpecialistControlByIdcard(identity_card_no,hospitalMapping[0],hospitalMapping[1]);
        return response;
    }
}

+ 1 - 1
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/ZysoftBaseService.java

@ -243,7 +243,7 @@ public class ZysoftBaseService {
            //保存http日志
//            logService.saveHttpLog(isSuccess,api,content,method,msgHeader,msgBody,re,error);
            logService.saveZyPushLog(api,content,null,"POST",msgHeader+","+msgBody,re,"0","2");
            logService.saveZyPushLog(api,content,error,"POST",msgHeader+","+msgBody,re,"0","2");
            if(ex instanceof ApiException)
            {

+ 183 - 11
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/ZysoftService.java

@ -1,8 +1,11 @@
package com.yihu.wlyy.service.service;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.serializer.SerializerFeature;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.yihu.wlyy.service.common.http.HttpApiException;
import com.yihu.wlyy.service.common.util.StringUtil;
import com.yihu.wlyy.service.entity.DoctorMapping;
import com.zoe.phip.ssp.sdk.ApiException;
import net.sf.json.JSONObject;
import org.springframework.beans.factory.annotation.Autowired;
@ -10,7 +13,9 @@ import org.springframework.stereotype.Service;
import java.io.PrintWriter;
import java.io.StringWriter;
import java.util.*;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
 * Created by hzp on 2016/9/9.
@ -115,8 +120,8 @@ public class ZysoftService {
        paramsList.put("msgHeader",msgHeader);
        paramsList.put("msgBody",msgBody);
        //System.out.print("msgHeader:"+msgHeader+"\r\n");
        //System.out.print("msgBody:"+msgBody+"\r\n");
//        System.out.print("msgHeader:"+msgHeader+"\r\n");
//        System.out.print("msgBody:"+msgBody+"\r\n");
        //新增日志
        String method = "POST";
@ -172,6 +177,66 @@ public class ZysoftService {
        return re;
    }
    /**
     * 基卫二次封装Post接口
     */
    private String postSecond(String api, String content, com.alibaba.fastjson.JSONObject jsonParams, Map<String,String> headers) throws Exception
    {
        String re = "";
        headers.put("INTERFACE",api);
        Map<String,String> paramsList = new HashMap<>();
        String msgBody = com.alibaba.fastjson.JSONObject.toJSONString(jsonParams, SerializerFeature.WriteMapNullValue);
        String msgHeader = JSONObject.fromObject(headers).toString();
        paramsList.put("msgHeader",msgHeader);
        paramsList.put("msgBody",msgBody);
        //System.out.print("msgHeader:"+msgHeader+"\r\n");
        //System.out.print("msgBody:"+msgBody+"\r\n");
        //新增日志
        String method = "POST";
        Boolean isSuccess = true;
        String error = "";
        try {
            re = ZysoftApi.getSingleton().post("base/CallEhrInterface", paramsList, null,true);
            Map<String,String> map = objectMapper.readValue(re,Map.class);
            String code = map.get("CODE");
            if(!code.equals("1"))
            {
                throw new HttpApiException(Integer.valueOf(code),map.get("MESSAGE"));
            }
            //保存http日志
            logService.saveHttpLog(isSuccess,api,content,method,msgHeader,msgBody,re,error);
        }
        catch (Exception ex)
        {
            StringWriter sw = new StringWriter();
            PrintWriter pw = new PrintWriter(sw);
            ex.printStackTrace(pw);
            error = sw.toString();
            isSuccess = false;
            //保存http日志
            logService.saveHttpLog(isSuccess,api,content,method,msgHeader,msgBody,re,error);
            if(ex instanceof ApiException)
            {
                ApiException apiEx = (ApiException) ex;
                throw new HttpApiException(apiEx.errorCode(),ex.getMessage());
            }
            else{
                throw new HttpApiException(-1,ex.getMessage());
            }
        }
        return re;
    }
    /*************************** 格式转换 *******************************************************/
    /**
@ -224,9 +289,9 @@ public class ZysoftService {
    }
    /**
     * 查询居民健康档案信息接口
     * 查询是否已签约
     */
    public String getSickArchiveRecord(String idcard,String hospital,String licence)  throws Exception
    public String getSickFamilySignFlag(String idcard,String hospital,String licence)  throws Exception
    {
        Map<String,String> header = new HashMap<>();
        header.put("ORGCODE",hospital);
@ -235,24 +300,28 @@ public class ZysoftService {
        Map<String,String> params = new HashMap<>();
        params.put("IDENTITY_CARD_NO",idcard);
        String response = postSecond("getSickArchiveRecord","查询居民健康档案信息",params,header,false);
        String response = postSecond("getSickFamilySignFlag","查询是否已签约",params,header,false);
        return response;
    }
    /**
     * 查询是否已签约
     * 7.51查询家庭医生签约人数上限接口
     * @param jwTeamCode 智业行政团队code
     * @param hospital
     * @param licence
     * @return
     * @throws Exception
     */
    public String getSickFamilySignFlag(String idcard,String hospital,String licence)  throws Exception
    {
    public String getSickFamilyDoctorSignLimit(String jwTeamCode,String hospital,String licence) throws Exception{
        Map<String,String> header = new HashMap<>();
        header.put("ORGCODE",hospital);
        header.put("LICENCE",licence);
        Map<String,String> params = new HashMap<>();
        params.put("IDENTITY_CARD_NO",idcard);
        params.put("TEAM_CODE",jwTeamCode);
        String response = postSecond("getSickFamilySignFlag","查询是否已签约",params,header,false);
        String response = postSecond("getSickFamilyDoctorSignLimit","查询家庭医生签约人数上限接口",params,header,false);
        return response;
    }
@ -603,6 +672,67 @@ public class ZysoftService {
        }
    }
    /**************************** 建档相关接口 add by ysj at 2017-09-11 *************************************************/
    /**
     * 7.1查询居民是否有建立健康档案接口
     * @param idcard
     * @param hospital
     * @param licence
     * @return
     * @throws Exception
     */
    public String getSickArchiveFlag(String idcard,String hospital,String licence)  throws Exception
    {
        Map<String,String> header = new HashMap<>();
        header.put("ORGCODE",hospital);
        header.put("LICENCE",licence);
        Map<String,String> params = new HashMap<>();
        params.put("IDENTITY_CARD_NO",idcard);
        String response = postSecond("getSickArchiveFlag","查询居民是否有建立健康档案接口",params,header,false);
        return response;
    }
    /**
     * 查询居民健康档案信息接口
     */
    public String getSickArchiveRecord(String idcard,String hospital,String licence)  throws Exception
    {
        Map<String,String> header = new HashMap<>();
        header.put("ORGCODE",hospital);
        header.put("LICENCE",licence);
        Map<String,String> params = new HashMap<>();
        params.put("IDENTITY_CARD_NO",idcard);
        String response = postSecond("getSickArchiveRecord","查询居民健康档案信息",params,header,false);
        return response;
    }
    /**
     * 上传居民档案建档信息接口
     * @param json
     * @param hospital
     * @param licence
     * @param doctor
     * @return
     */
    public String saveSickArchiveRecord(String json, String hospital, String licence, DoctorMapping doctor) throws Exception{
        Map<String,String> header = new HashMap<>();
        header.put("ORGCODE",hospital);
        header.put("LICENCE",licence);
        header.put("OPERATOR",doctor.getJwDoctor());
        com.alibaba.fastjson.JSONObject jsonObject = JSON.parseObject(json);
        jsonObject.put("ARCHIVE_OPERATOR_NAME",doctor.getJwDoctorName());
        String response = postSecond("saveSickArchiveRecord","上传居民档案建档信息接口",jsonObject,header);
        return response;
    }
    /**************************** 妇幼相关接口 add by hzp at 2017-07-12 *********************************************************/
@ -624,4 +754,46 @@ public class ZysoftService {
        return response;
    }
    /**
     * 查询家签慢病患者定标情况接口
     * @param time_start
     * @param time_end
     * @param hospital
     * @param licence
     * @return
     * @throws Exception
     */
    public String getSickFamilyDoctorSpecialistControl(String time_start, String time_end,String hospital,String licence) throws Exception{
        Map<String,String> header = new HashMap<>();
        header.put("ORGCODE",hospital);
        header.put("LICENCE",licence);
        Map<String,String> params = new HashMap<>();
        params.put("TIME_START",time_start);
        params.put("TIME_END",time_end);
        String response = postSecond("getSickFamilyDoctorSpecialistControl","查询家签慢病患者定标情况接口",params,header,false);
        return response;
    }
    /**
     * 根据身份证号查询家签慢病患者定标情况接口
     * @param identity_card_no
     * @return
     */
    public String getSickFamilyDoctorSpecialistControlByIdcard(String identity_card_no,String hospital,String licence) throws Exception{
        Map<String,String> header = new HashMap<>();
        header.put("ORGCODE",hospital);
        header.put("LICENCE",licence);
        Map<String,String> params = new HashMap<>();
        params.put("IDENTITY_CARD_NO",identity_card_no);
        String response = postSecond("getSickFamilyDoctorSpecialistControl","查询家签慢病患者定标情况接口",params,header,false);
        return response;
    }
}

+ 13 - 452
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionCAService.java

@ -1,18 +1,11 @@
package com.yihu.wlyy.service.service.prescription;
import com.alibaba.fastjson.JSONObject;
import com.alibaba.fastjson.serializer.SerializerFeature;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.yihu.wlyy.service.common.SystemConfig;
import com.yihu.wlyy.service.common.http.HttpApiException;
import com.yihu.wlyy.service.common.util.StringUtil;
import com.yihu.wlyy.service.common.util.WebserviceUtil;
import com.yihu.wlyy.service.service.LogService;
import com.yihu.wlyy.service.service.ZysoftApi;
import com.yihu.wlyy.service.service.ZysoftBaseService;
import com.zoe.phip.ssp.sdk.ApiException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.io.PrintWriter;
import java.io.StringWriter;
@ -20,48 +13,12 @@ import java.util.HashMap;
import java.util.Map;
import java.util.UUID;
/**
 * Created by hzp on 2017-07-31
 * 长处方CA认证服务
 * Created by ${liuwenbin} on 2017/8/28.
 */
@Service
public class PrescriptionCAService extends ZysoftBaseService {
    private String IS_APPLIED="XMCAF_SOFT_judgeRealNameSoftCertIsApplied"; //判断实名软证书是否已申请
    private String REQUEST_SIGN = "XMCAF_SOFT_requestRealNameSoftCertAndSign";//请求实名软证书并进行数字签名
    private String EXPIRED_DATETIME = "XMCAF_SOFT_getRealNameSoftCertExpiredDatetime"; //获取实名软证书的过期时间
    private String MODIFY_PASSWD = "XMCAF_SOFT_ModifyRealNameSoftCertCalledPasswd"; //修改实名软证书调用保护口令
    private String VERIFY_SIGN = "XMCA3_JMSVR_verifySignOnMultiServer"; //验证签名(带多服务器负载均衡)
    private String unifiedCallInterface = "XMCA6_UnifiedCallInterface";
    @Autowired
    private LogService logService;
    @Autowired
    private ObjectMapper objectMapper;
public interface PrescriptionCAService {
    private String getHeaderXml(String api,String srcBusinessStreamNO,String srcRequestStreamNO)
    {
        return "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
            "<root>\n" +
            "   <serverName>"+api+"</serverName>\n" +
            "   <format>xml</format>\n" +
            "   <callOperator></callOperator>\n" +
            "   <certificate></certificate>\n" +
            "   <srcIP>10.95.22.10</srcIP >\n" +
            "   <srcUserMac>00:50:56:85:39:82</srcUserMac>\n" +
            "   <srcSystemCode>1</srcSystemCode>\n" +
            "   <srcSystemName>厦门i健康</srcSystemName>\n" +
            "   <srcBusinessNodeCode>node01</srcBusinessNodeCode>\n" +
            "   <srcBusinessNodeName>审核</srcBusinessNodeName>\n" +
            "   <srcOperatorAccount>"+srcBusinessStreamNO+"</srcOperatorAccount>\n" +
            "   <srcBusinessStreamNO>"+srcBusinessStreamNO+"</srcBusinessStreamNO>\n" +
            "   <srcRequestStreamNO>"+srcRequestStreamNO+"</srcRequestStreamNO>\n" +
            "   <srcDataExtProperty></srcDataExtProperty>\n" +
            "</root>";
    }
//    String getHeaderXml(String api,String srcBusinessStreamNO,String srcRequestStreamNO);
    /**
     * 生产环境 智业CA接口二次封装
@ -71,432 +28,36 @@ public class PrescriptionCAService extends ZysoftBaseService {
     * @return
     * @throws Exception
     */
    public String postZyCaServer(String api, Map<String,String> params,String srcBusinessStreamNO,String content) throws Exception{
        String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
                "<root>\n";
        if(params!=null && params.size()>0)
        {
            for(String key : params.keySet())
            {
                msgBody += "    <"+key+">"+params.get(key)+"</"+key+">\n";
            }
        }
        msgBody += "</root>";
        String srcRequestStreamNO = UUID.randomUUID().toString().replace("-", "");
        String msgHeader = getHeaderXml(api,srcBusinessStreamNO,srcRequestStreamNO);
        System.out.println("msgHerder:"+msgHeader);
        System.out.println("msgBody:"+msgBody);
        String re = "";
        Map<String,String> paramsList = new HashMap<>();
        paramsList.put("msgHeader",msgHeader);
        paramsList.put("msgBody",msgBody);
        //新增日志
        String method = "POST";
        Boolean isSuccess = true;
        String error = "";
        int times = 0;
        try {
//            re = ZysoftApi.getSingleton().post(ca_url, paramsList, null,true);
            re = ZysoftApi.getSingleton().capost(paramsList, null,true);
            System.out.println("re=====>:"+re);
//            Map<String,String> map = objectMapper.readValue(re,Map.class);
//            String code = map.get("CODE");
//
//            if(!code.equals("1"))
//            {
//                throw new HttpApiException(Integer.valueOf(code),map.get("MESSAGE"));
//            }
            //保存http日志
            logService.saveHttpLog(isSuccess,api,content,method,msgHeader,msgBody,re,error);
        }
        catch (Exception ex)
        {
            StringWriter sw = new StringWriter();
            PrintWriter pw = new PrintWriter(sw);
            ex.printStackTrace(pw);
            System.out.println("error1:"+ex.getMessage());
            error = sw.toString();
            System.out.println("error2:"+error);
            //保存http日志
            logService.saveHttpLog(isSuccess,api,content,method,msgHeader,msgBody,re,error);
            if(ex instanceof ApiException)
            {
                ApiException apiEx = (ApiException) ex;
                System.out.println("error3:"+ex.getMessage());
                throw new HttpApiException(apiEx.errorCode(),ex.getMessage());
            }
            else{
                System.out.println("error4:"+ex.getMessage());
                throw new HttpApiException(-1,ex.getMessage());
            }
        }
        return re;
    }
//    public String postZyCaServer(String api, Map<String,String> params, String srcBusinessStreamNO, String content) throws Exception;
    /**
     * 测试环境:CA认证服务二次封装
     */
    private String postCAServer(String api, Map<String,String> params,String srcBusinessStreamNO) throws Exception
    {
        String urlString = SystemConfig.sysPropertiesSets.get("ca_url");
        String namespace = SystemConfig.sysPropertiesSets.get("ca_namespace");
        String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
                         "<root>\n";
        if(params!=null && params.size()>0)
        {
            for(String key : params.keySet())
            {
                msgBody += "    <"+key+">"+params.get(key)+"</"+key+">\n";
            }
        }
        msgBody += "</root>";
        String srcRequestStreamNO = UUID.randomUUID().toString().replace("-", "");
        String msgHeader = getHeaderXml(api,srcBusinessStreamNO,srcRequestStreamNO);
        Map<String,String> p = new HashMap<>();
        p.put("msgHeader",msgHeader);
        p.put("msgBody",msgBody);
        return WebserviceUtil.post(urlString,namespace,unifiedCallInterface,p);
    }
    /**
     * 判断是否有实名证书
     **/
    public String isApplied(String strUserIdcardNum,String srcBusinessStreamNO)  throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = IS_APPLIED;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            body = objectMapper.writeValueAsString(params);
//            re = postCAServer(action, params,srcBusinessStreamNO);
            //生产环境,调用智业统一平台接口,rest接口
            re = postZyCaServer(action, params,srcBusinessStreamNO,"判断是否有实名证书");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"判断是否有实名证书","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
//    public String postCAServer(String api, Map<String,String> params,String srcBusinessStreamNO) throws Exception;
    /**
     * 请求实名软证书并进行数字签名
     **/
    public String requestRealNameSoftCertAndSign(String strUserIdcardNum,String strRealNameSoftCertCalledPasswd,String strOriginalData,String srcBusinessStreamNO) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = REQUEST_SIGN;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            params.put("strRealNameSoftCertCalledPasswd",strRealNameSoftCertCalledPasswd);
            params.put("strOriginalData",strOriginalData);
//            params.put("srcBusinessStreamNO",srcBusinessStreamNO);
            body = objectMapper.writeValueAsString(params);
            //测试环境开启下面这行代码,webservice接口
//            re = postCAServer(action, params,srcBusinessStreamNO);
            //生产环境,调用智业统一平台接口,rest接口
            re = postZyCaServer(action, params,srcBusinessStreamNO,"请求实名软证书并进行数字签名");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
    public String requestRealNameSoftCertAndSign(String strUserIdcardNum,String strRealNameSoftCertCalledPasswd,String strOriginalData,String srcBusinessStreamNO)  throws Exception;
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess, action, "请求实名软证书并进行数字签名", "POST", null, body, re, error, logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
    /**
     * 获取实名软证书的过期时间
     **/
    public String getRealNameSoftCertExpiredDatetime(String strUserIdcardNum,String srcBusinessStreamNO)  throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = EXPIRED_DATETIME;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            body = objectMapper.writeValueAsString(params);
//            re = postCAServer(action, params,srcBusinessStreamNO);
            re = postZyCaServer(action, params,srcBusinessStreamNO,"获取实名软证书的过期时间");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"获取实名软证书的过期时间","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
    public String getRealNameSoftCertExpiredDatetime(String strUserIdcardNum,String srcBusinessStreamNO)  throws Exception;
    /**
     * 修改实名软证书调用保护口令
     **/
    public String modifyRealNameSoftCertCalledPasswd(String strUserIdcardNum,String strOldCalledPasswd,String strNewCalledPasswd,String srcBusinessStreamNO) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        Throwable errorLog =null;
        String action = MODIFY_PASSWD;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            params.put("strOldCalledPasswd",strOldCalledPasswd);
            params.put("strNewCalledPasswd",strNewCalledPasswd);
            body = objectMapper.writeValueAsString(params);
//            re = postCAServer(action, params,srcBusinessStreamNO);
            re = postZyCaServer(action, params,srcBusinessStreamNO,"修改实名软证书调用保护口令");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
            errorLog = ex.getCause();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"修改实名软证书调用保护口令","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        if(errorLog!=null)
        {
            throw new Exception("CA服务器维护中。。。");
        }
        return re;
    }
    public String modifyRealNameSoftCertCalledPasswd(String strUserIdcardNum,String strOldCalledPasswd,String strNewCalledPasswd,String srcBusinessStreamNO) throws Exception;
    /**
     * 验证签名(带多服务器负载均衡)
     **/
    public String verifySignOnMultiServer(String strSignData,String strCertData,String strOriginalData,String srcBusinessStreamNO) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = VERIFY_SIGN;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strSignData",strSignData);
            params.put("strCertData",strCertData);
            params.put("strOriginalData",strOriginalData);
            body = objectMapper.writeValueAsString(params);
//            re = postCAServer(action, params,srcBusinessStreamNO);
            re = postZyCaServer(action, params,srcBusinessStreamNO,"验证签名(带多服务器负载均衡)");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
    public String verifySignOnMultiServer(String strSignData,String strCertData,String strOriginalData,String srcBusinessStreamNO)  throws Exception;
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"验证签名","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
//    public static void main(String args[]) {
//        try {
//            String caUrl = SystemConfig.getInstance().getCAUrl();
//            String caNamespace = SystemConfig.getInstance().getCANamespace();
//            /*//获取实名软证书的过期时间
//            String api = "XMCAF_SOFT_getRealNameSoftCertExpiredDatetime";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "    <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "</root>";*/
//
//            /*//判断实名软证书是否已申请
//            String api = "XMCAF_SOFT_judgeRealNameSoftCertIsApplied";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "    <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "</root>";*/
//
//            //修改实名软证书调用保护口令
//            String api = "XMCAF_SOFT_ModifyRealNameSoftCertCalledPasswd";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "    <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "   <strOldCalledPasswd>12345678</strOldCalledPasswd>\n" +
//                    "   <strNewCalledPasswd>11111111</strNewCalledPasswd>\n" +
//                    "</root>";
//
//
//            //请求实名软证书并进行数字签名
//            /*String orgData = "测试数据";
//            String api = "XMCAF_SOFT_requestRealNameSoftCertAndSign";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "   <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "   <strRealNameSoftCertCalledPasswd>11111111</strRealNameSoftCertCalledPasswd>\n" +
//                    "   <strOriginalData>"+ MD5Util.GetMD5Code(orgData)+"</strOriginalData>\n" +
//                    "</root>";*/
//
//            String msgHeader = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n" +
//                    "   <serverName>"+api+"</serverName>\n" +
//                    "   <format>xml</format>\n" +
//                    "   <callOperator></callOperator>\n" +
//                    "   <certificate></certificate>\n" +
//
//                    "   <srcIP>10.95.22.10</srcIP >\n" +
//                    "   <srcUserMac>60-D8-19-57-66-E3</srcUserMac>\n" +
//                    "   <srcSystemCode>1</srcSystemCode>\n" +
//                    "   <srcSystemName>厦门i健康</srcSystemName>\n" +
//                    "   <srcBusinessNodeCode>node01</srcBusinessNodeCode>\n" +
//                    "   <srcBusinessNodeName>审核</srcBusinessNodeName>\n" +
//                    "   <srcOperatorAccount>Zhuangsd</srcOperatorAccount>\n" +
//                    "   <srcBusinessStreamNO>11111</srcBusinessStreamNO>\n" +
//                    "   <srcDataExtProperty></srcDataExtProperty>\n" +
//                    "</root>";
//
//
//
//            Map<String, String> params = new HashMap<>();
//            params.put("msgBody", msgBody);
//            params.put("msgHeader", msgHeader);
//            System.out.print(WebserviceUtil.post(caUrl, caNamespace, "XMCA6_UnifiedCallInterface", params) + "\r\n");
//
//
//
//        }
//        catch (Exception ex)
//        {
//            ex.printStackTrace();
//        }
//    }
    /**
     * 判断是否有实名证书
     **/
    public String isApplied(String strUserIdcardNum,String srcBusinessStreamNO)  throws Exception;
}

+ 509 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionCATestServiceImp.java

@ -0,0 +1,509 @@
package com.yihu.wlyy.service.service.prescription;
import com.alibaba.fastjson.JSONObject;
import com.alibaba.fastjson.serializer.SerializerFeature;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.yihu.wlyy.service.common.SystemConfig;
import com.yihu.wlyy.service.common.http.HttpApiException;
import com.yihu.wlyy.service.common.util.StringUtil;
import com.yihu.wlyy.service.common.util.WebserviceUtil;
import com.yihu.wlyy.service.service.LogService;
import com.yihu.wlyy.service.service.ZysoftApi;
import com.yihu.wlyy.service.service.ZysoftBaseService;
import com.zoe.phip.ssp.sdk.ApiException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Profile;
import org.springframework.stereotype.Service;
import java.io.PrintWriter;
import java.io.StringWriter;
import java.util.HashMap;
import java.util.Map;
import java.util.UUID;
/**
 * Created by hzp on 2017-07-31
 * 长处方CA认证服务
 */
@Profile({"dev","test"})
@Service
public class PrescriptionCATestServiceImp extends ZysoftBaseService implements PrescriptionCAService{
    private String IS_APPLIED="XMCAF_SOFT_judgeRealNameSoftCertIsApplied"; //判断实名软证书是否已申请
    private String REQUEST_SIGN = "XMCAF_SOFT_requestRealNameSoftCertAndSign";//请求实名软证书并进行数字签名
    private String EXPIRED_DATETIME = "XMCAF_SOFT_getRealNameSoftCertExpiredDatetime"; //获取实名软证书的过期时间
    private String MODIFY_PASSWD = "XMCAF_SOFT_ModifyRealNameSoftCertCalledPasswd"; //修改实名软证书调用保护口令
    private String VERIFY_SIGN = "XMCA3_JMSVR_verifySignOnMultiServer"; //验证签名(带多服务器负载均衡)
    private String unifiedCallInterface = "XMCA6_UnifiedCallInterface";
    @Autowired
    private LogService logService;
    @Autowired
    private ObjectMapper objectMapper;
    private String getHeaderXml(String api,String srcBusinessStreamNO,String srcRequestStreamNO)
    {
        return "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
            "<root>\n" +
            "   <serverName>"+api+"</serverName>\n" +
            "   <format>xml</format>\n" +
            "   <callOperator></callOperator>\n" +
            "   <certificate></certificate>\n" +
            "   <srcIP>10.95.22.10</srcIP >\n" +
            "   <srcUserMac>00:50:56:85:39:82</srcUserMac>\n" +
            "   <srcSystemCode>1</srcSystemCode>\n" +
            "   <srcSystemName>厦门i健康</srcSystemName>\n" +
            "   <srcBusinessNodeCode>node01</srcBusinessNodeCode>\n" +
            "   <srcBusinessNodeName>审核</srcBusinessNodeName>\n" +
            "   <srcOperatorAccount>"+srcBusinessStreamNO+"</srcOperatorAccount>\n" +
            "   <srcBusinessStreamNO>"+srcBusinessStreamNO+"</srcBusinessStreamNO>\n" +
            "   <srcRequestStreamNO>"+srcRequestStreamNO+"</srcRequestStreamNO>\n" +
            "   <srcDataExtProperty></srcDataExtProperty>\n" +
            "</root>";
    }
    /**
     * 生产环境 智业CA接口二次封装
     * @param api
     * @param params
     * @param srcBusinessStreamNO
     * @return
     * @throws Exception
     */
//    public String postZyCaServer(String api, Map<String,String> params,String srcBusinessStreamNO,String content) throws Exception{
//
//
//        String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                "<root>\n";
//        if(params!=null && params.size()>0)
//        {
//            for(String key : params.keySet())
//            {
//                msgBody += "    <"+key+">"+params.get(key)+"</"+key+">\n";
//            }
//        }
//        msgBody += "</root>";
//        String srcRequestStreamNO = UUID.randomUUID().toString().replace("-", "");
//        String msgHeader = getHeaderXml(api,srcBusinessStreamNO,srcRequestStreamNO);
//
//        System.out.println("msgHerder:"+msgHeader);
//        System.out.println("msgBody:"+msgBody);
//
//        String re = "";
//        Map<String,String> paramsList = new HashMap<>();
//        paramsList.put("msgHeader",msgHeader);
//        paramsList.put("msgBody",msgBody);
//
//
//        //新增日志
//        String method = "POST";
//        Boolean isSuccess = true;
//        String error = "";
//
//        int times = 0;
//        try {
////            re = ZysoftApi.getSingleton().post(ca_url, paramsList, null,true);
//            re = ZysoftApi.getSingleton().capost(paramsList, null,true);
//
//            System.out.println("re=====>:"+re);
////            Map<String,String> map = objectMapper.readValue(re,Map.class);
////            String code = map.get("CODE");
////
////            if(!code.equals("1"))
////            {
////                throw new HttpApiException(Integer.valueOf(code),map.get("MESSAGE"));
////            }
//
//            //保存http日志
//            logService.saveHttpLog(isSuccess,api,content,method,msgHeader,msgBody,re,error);
//        }
//        catch (Exception ex)
//        {
//            StringWriter sw = new StringWriter();
//            PrintWriter pw = new PrintWriter(sw);
//            ex.printStackTrace(pw);
//            System.out.println("error1:"+ex.getMessage());
//            error = sw.toString();
//            System.out.println("error2:"+error);
//
//            //保存http日志
//            logService.saveHttpLog(isSuccess,api,content,method,msgHeader,msgBody,re,error);
//
//            if(ex instanceof ApiException)
//            {
//                ApiException apiEx = (ApiException) ex;
//                System.out.println("error3:"+ex.getMessage());
//                throw new HttpApiException(apiEx.errorCode(),ex.getMessage());
//            }
//            else{
//                System.out.println("error4:"+ex.getMessage());
//                throw new HttpApiException(-1,ex.getMessage());
//            }
//        }
//
//        return re;
//
//    }
    /**
     * 测试环境:CA认证服务二次封装
     */
    private String postCAServer(String api, Map<String,String> params,String srcBusinessStreamNO) throws Exception
    {
        String urlString = SystemConfig.getInstance().getSystemProperties().getProperty("ca_url");
        String namespace = SystemConfig.getInstance().getSystemProperties().getProperty("ca_namespace");
        String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
                         "<root>\n";
        if(params!=null && params.size()>0)
        {
            for(String key : params.keySet())
            {
                msgBody += "    <"+key+">"+params.get(key)+"</"+key+">\n";
            }
        }
        msgBody += "</root>";
        String srcRequestStreamNO = UUID.randomUUID().toString().replace("-", "");
        String msgHeader = getHeaderXml(api,srcBusinessStreamNO,srcRequestStreamNO);
        Map<String,String> p = new HashMap<>();
        p.put("msgHeader",msgHeader);
        p.put("msgBody",msgBody);
        return WebserviceUtil.post(urlString,namespace,unifiedCallInterface,p);
    }
    /**
     * 判断是否有实名证书
     **/
    @Override
    public String isApplied(String strUserIdcardNum,String srcBusinessStreamNO)  throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = IS_APPLIED;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            body = objectMapper.writeValueAsString(params);
            re = postCAServer(action, params,srcBusinessStreamNO);
            //生产环境,调用智业统一平台接口,rest接口
//            re = postZyCaServer(action, params,srcBusinessStreamNO,"判断是否有实名证书");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"判断是否有实名证书","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
    /**
     * 请求实名软证书并进行数字签名
     **/
    @Override
    public String requestRealNameSoftCertAndSign(String strUserIdcardNum,String strRealNameSoftCertCalledPasswd,String strOriginalData,String srcBusinessStreamNO) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = REQUEST_SIGN;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            params.put("strRealNameSoftCertCalledPasswd",strRealNameSoftCertCalledPasswd);
            params.put("strOriginalData",strOriginalData);
//            params.put("srcBusinessStreamNO",srcBusinessStreamNO);
            body = objectMapper.writeValueAsString(params);
            //测试环境开启下面这行代码,webservice接口
            re = postCAServer(action, params,srcBusinessStreamNO);
            //生产环境,调用智业统一平台接口,rest接口
//            re = postZyCaServer(action, params,srcBusinessStreamNO,"请求实名软证书并进行数字签名");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess, action, "请求实名软证书并进行数字签名", "POST", null, body, re, error, logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
    /**
     * 获取实名软证书的过期时间
     **/
    @Override
    public String getRealNameSoftCertExpiredDatetime(String strUserIdcardNum,String srcBusinessStreamNO)  throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = EXPIRED_DATETIME;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            body = objectMapper.writeValueAsString(params);
            re = postCAServer(action, params,srcBusinessStreamNO);
//            re = postZyCaServer(action, params,srcBusinessStreamNO,"获取实名软证书的过期时间");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"获取实名软证书的过期时间","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
    /**
     * 修改实名软证书调用保护口令
     **/
    @Override
    public String modifyRealNameSoftCertCalledPasswd(String strUserIdcardNum,String strOldCalledPasswd,String strNewCalledPasswd,String srcBusinessStreamNO) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        Throwable errorLog =null;
        String action = MODIFY_PASSWD;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            params.put("strOldCalledPasswd",strOldCalledPasswd);
            params.put("strNewCalledPasswd",strNewCalledPasswd);
            body = objectMapper.writeValueAsString(params);
            re = postCAServer(action, params,srcBusinessStreamNO);
//            re = postZyCaServer(action, params,srcBusinessStreamNO,"修改实名软证书调用保护口令");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
            errorLog = ex.getCause();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"修改实名软证书调用保护口令","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        if(errorLog!=null)
        {
            throw new Exception("CA服务器维护中。。。");
        }
        return re;
    }
    /**
     * 验证签名(带多服务器负载均衡)
     **/
    @Override
    public String verifySignOnMultiServer(String strSignData,String strCertData,String strOriginalData,String srcBusinessStreamNO) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = VERIFY_SIGN;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strSignData",strSignData);
            params.put("strCertData",strCertData);
            params.put("strOriginalData",strOriginalData);
            body = objectMapper.writeValueAsString(params);
            re = postCAServer(action, params,srcBusinessStreamNO);
//            re = postZyCaServer(action, params,srcBusinessStreamNO,"验证签名(带多服务器负载均衡)");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"验证签名","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
//    public static void main(String args[]) {
//        try {
//            String caUrl = SystemConfig.getInstance().getCAUrl();
//            String caNamespace = SystemConfig.getInstance().getCANamespace();
//            /*//获取实名软证书的过期时间
//            String api = "XMCAF_SOFT_getRealNameSoftCertExpiredDatetime";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "    <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "</root>";*/
//
//            /*//判断实名软证书是否已申请
//            String api = "XMCAF_SOFT_judgeRealNameSoftCertIsApplied";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "    <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "</root>";*/
//
//            //修改实名软证书调用保护口令
//            String api = "XMCAF_SOFT_ModifyRealNameSoftCertCalledPasswd";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "    <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "   <strOldCalledPasswd>12345678</strOldCalledPasswd>\n" +
//                    "   <strNewCalledPasswd>11111111</strNewCalledPasswd>\n" +
//                    "</root>";
//
//
//            //请求实名软证书并进行数字签名
//            /*String orgData = "测试数据";
//            String api = "XMCAF_SOFT_requestRealNameSoftCertAndSign";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "   <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "   <strRealNameSoftCertCalledPasswd>11111111</strRealNameSoftCertCalledPasswd>\n" +
//                    "   <strOriginalData>"+ MD5Util.GetMD5Code(orgData)+"</strOriginalData>\n" +
//                    "</root>";*/
//
//            String msgHeader = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n" +
//                    "   <serverName>"+api+"</serverName>\n" +
//                    "   <format>xml</format>\n" +
//                    "   <callOperator></callOperator>\n" +
//                    "   <certificate></certificate>\n" +
//
//                    "   <srcIP>10.95.22.10</srcIP >\n" +
//                    "   <srcUserMac>60-D8-19-57-66-E3</srcUserMac>\n" +
//                    "   <srcSystemCode>1</srcSystemCode>\n" +
//                    "   <srcSystemName>厦门i健康</srcSystemName>\n" +
//                    "   <srcBusinessNodeCode>node01</srcBusinessNodeCode>\n" +
//                    "   <srcBusinessNodeName>审核</srcBusinessNodeName>\n" +
//                    "   <srcOperatorAccount>Zhuangsd</srcOperatorAccount>\n" +
//                    "   <srcBusinessStreamNO>11111</srcBusinessStreamNO>\n" +
//                    "   <srcDataExtProperty></srcDataExtProperty>\n" +
//                    "</root>";
//
//
//
//            Map<String, String> params = new HashMap<>();
//            params.put("msgBody", msgBody);
//            params.put("msgHeader", msgHeader);
//            System.out.print(WebserviceUtil.post(caUrl, caNamespace, "XMCA6_UnifiedCallInterface", params) + "\r\n");
//
//
//
//        }
//        catch (Exception ex)
//        {
//            ex.printStackTrace();
//        }
//    }
}

+ 510 - 0
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionProCAServiceImp.java

@ -0,0 +1,510 @@
package com.yihu.wlyy.service.service.prescription;
import com.alibaba.fastjson.JSONObject;
import com.alibaba.fastjson.serializer.SerializerFeature;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.yihu.wlyy.service.common.SystemConfig;
import com.yihu.wlyy.service.common.http.HttpApiException;
import com.yihu.wlyy.service.common.util.StringUtil;
import com.yihu.wlyy.service.common.util.WebserviceUtil;
import com.yihu.wlyy.service.service.LogService;
import com.yihu.wlyy.service.service.ZysoftApi;
import com.yihu.wlyy.service.service.ZysoftBaseService;
import com.zoe.phip.ssp.sdk.ApiException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Profile;
import org.springframework.stereotype.Service;
import java.io.PrintWriter;
import java.io.StringWriter;
import java.util.HashMap;
import java.util.Map;
import java.util.UUID;
/**
 * Created by hzp on 2017-07-31
 * 长处方CA认证服务
 */
@Profile({"production"})
@Service
public class PrescriptionProCAServiceImp extends ZysoftBaseService implements PrescriptionCAService{
    private String IS_APPLIED="XMCAF_SOFT_judgeRealNameSoftCertIsApplied"; //判断实名软证书是否已申请
    private String REQUEST_SIGN = "XMCAF_SOFT_requestRealNameSoftCertAndSign";//请求实名软证书并进行数字签名
    private String EXPIRED_DATETIME = "XMCAF_SOFT_getRealNameSoftCertExpiredDatetime"; //获取实名软证书的过期时间
    private String MODIFY_PASSWD = "XMCAF_SOFT_ModifyRealNameSoftCertCalledPasswd"; //修改实名软证书调用保护口令
    private String VERIFY_SIGN = "XMCA3_JMSVR_verifySignOnMultiServer"; //验证签名(带多服务器负载均衡)
    private String unifiedCallInterface = "XMCA6_UnifiedCallInterface";
    @Autowired
    private LogService logService;
    @Autowired
    private ObjectMapper objectMapper;
    private String getHeaderXml(String api,String srcBusinessStreamNO,String srcRequestStreamNO)
    {
        return "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
            "<root>\n" +
            "   <serverName>"+api+"</serverName>\n" +
            "   <format>xml</format>\n" +
            "   <callOperator></callOperator>\n" +
            "   <certificate></certificate>\n" +
            "   <srcIP>10.95.22.10</srcIP >\n" +
            "   <srcUserMac>00:50:56:85:39:82</srcUserMac>\n" +
            "   <srcSystemCode>1</srcSystemCode>\n" +
            "   <srcSystemName>厦门i健康</srcSystemName>\n" +
            "   <srcBusinessNodeCode>node01</srcBusinessNodeCode>\n" +
            "   <srcBusinessNodeName>审核</srcBusinessNodeName>\n" +
            "   <srcOperatorAccount>"+srcBusinessStreamNO+"</srcOperatorAccount>\n" +
            "   <srcBusinessStreamNO>"+srcBusinessStreamNO+"</srcBusinessStreamNO>\n" +
            "   <srcRequestStreamNO>"+srcRequestStreamNO+"</srcRequestStreamNO>\n" +
            "   <srcDataExtProperty></srcDataExtProperty>\n" +
            "</root>";
    }
    /**
     * 生产环境 智业CA接口二次封装
     * @param api
     * @param params
     * @param srcBusinessStreamNO
     * @return
     * @throws Exception
     */
    private String postZyCaServer(String api, Map<String,String> params,String srcBusinessStreamNO,String content) throws Exception{
        String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
                "<root>\n";
        if(params!=null && params.size()>0)
        {
            for(String key : params.keySet())
            {
                msgBody += "    <"+key+">"+params.get(key)+"</"+key+">\n";
            }
        }
        msgBody += "</root>";
        String srcRequestStreamNO = UUID.randomUUID().toString().replace("-", "");
        String msgHeader = getHeaderXml(api,srcBusinessStreamNO,srcRequestStreamNO);
        System.out.println("msgHerder:"+msgHeader);
        System.out.println("msgBody:"+msgBody);
        String re = "";
        Map<String,String> paramsList = new HashMap<>();
        paramsList.put("msgHeader",msgHeader);
        paramsList.put("msgBody",msgBody);
        //新增日志
        String method = "POST";
        Boolean isSuccess = true;
        String error = "";
        int times = 0;
        try {
//            re = ZysoftApi.getSingleton().post(ca_url, paramsList, null,true);
            re = ZysoftApi.getSingleton().capost(paramsList, null,true);
            System.out.println("re=====>:"+re);
//            Map<String,String> map = objectMapper.readValue(re,Map.class);
//            String code = map.get("CODE");
//
//            if(!code.equals("1"))
//            {
//                throw new HttpApiException(Integer.valueOf(code),map.get("MESSAGE"));
//            }
            //保存http日志
            logService.saveHttpLog(isSuccess,api,content,method,msgHeader,msgBody,re,error);
        }
        catch (Exception ex)
        {
            StringWriter sw = new StringWriter();
            PrintWriter pw = new PrintWriter(sw);
            ex.printStackTrace(pw);
            System.out.println("error1:"+ex.getMessage());
            error = sw.toString();
            System.out.println("error2:"+error);
            //保存http日志
            logService.saveHttpLog(isSuccess,api,content,method,msgHeader,msgBody,re,error);
            if(ex instanceof ApiException)
            {
                ApiException apiEx = (ApiException) ex;
                System.out.println("error3:"+ex.getMessage());
                throw new HttpApiException(apiEx.errorCode(),ex.getMessage());
            }
            else{
                System.out.println("error4:"+ex.getMessage());
                throw new HttpApiException(-1,ex.getMessage());
            }
        }
        return re;
    }
    /**
     * 测试环境:CA认证服务二次封装
     */
//    public String postCAServer(String api, Map<String,String> params,String srcBusinessStreamNO) throws Exception
//    {
//
//        String urlString = SystemConfig.sysPropertiesSets.get("ca_url");
//        String namespace = SystemConfig.sysPropertiesSets.get("ca_namespace");
//
//        String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                         "<root>\n";
//        if(params!=null && params.size()>0)
//        {
//            for(String key : params.keySet())
//            {
//                msgBody += "    <"+key+">"+params.get(key)+"</"+key+">\n";
//            }
//        }
//
//        msgBody += "</root>";
//        String srcRequestStreamNO = UUID.randomUUID().toString().replace("-", "");
//        String msgHeader = getHeaderXml(api,srcBusinessStreamNO,srcRequestStreamNO);
//
//        Map<String,String> p = new HashMap<>();
//        p.put("msgHeader",msgHeader);
//        p.put("msgBody",msgBody);
//        return WebserviceUtil.post(urlString,namespace,unifiedCallInterface,p);
//    }
    /**
     * 判断是否有实名证书
     **/
    @Override
    public String isApplied(String strUserIdcardNum,String srcBusinessStreamNO)  throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = IS_APPLIED;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            body = objectMapper.writeValueAsString(params);
//            re = postCAServer(action, params,srcBusinessStreamNO);
            //生产环境,调用智业统一平台接口,rest接口
            re = postZyCaServer(action, params,srcBusinessStreamNO,"判断是否有实名证书");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"判断是否有实名证书","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
    /**
     * 请求实名软证书并进行数字签名
     **/
    @Override
    public String requestRealNameSoftCertAndSign(String strUserIdcardNum,String strRealNameSoftCertCalledPasswd,String strOriginalData,String srcBusinessStreamNO) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = REQUEST_SIGN;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            params.put("strRealNameSoftCertCalledPasswd",strRealNameSoftCertCalledPasswd);
            params.put("strOriginalData",strOriginalData);
//            params.put("srcBusinessStreamNO",srcBusinessStreamNO);
            body = objectMapper.writeValueAsString(params);
            //测试环境开启下面这行代码,webservice接口
//            re = postCAServer(action, params,srcBusinessStreamNO);
            //生产环境,调用智业统一平台接口,rest接口
            re = postZyCaServer(action, params,srcBusinessStreamNO,"请求实名软证书并进行数字签名");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess, action, "请求实名软证书并进行数字签名", "POST", null, body, re, error, logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
    /**
     * 获取实名软证书的过期时间
     **/
    @Override
    public String getRealNameSoftCertExpiredDatetime(String strUserIdcardNum,String srcBusinessStreamNO)  throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = EXPIRED_DATETIME;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            body = objectMapper.writeValueAsString(params);
//            re = postCAServer(action, params,srcBusinessStreamNO);
            re = postZyCaServer(action, params,srcBusinessStreamNO,"获取实名软证书的过期时间");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"获取实名软证书的过期时间","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
    /**
     * 修改实名软证书调用保护口令
     **/
    @Override
    public String modifyRealNameSoftCertCalledPasswd(String strUserIdcardNum,String strOldCalledPasswd,String strNewCalledPasswd,String srcBusinessStreamNO) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        Throwable errorLog =null;
        String action = MODIFY_PASSWD;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strUserIdcardNum",strUserIdcardNum);
            params.put("strOldCalledPasswd",strOldCalledPasswd);
            params.put("strNewCalledPasswd",strNewCalledPasswd);
            body = objectMapper.writeValueAsString(params);
//            re = postCAServer(action, params,srcBusinessStreamNO);
            re = postZyCaServer(action, params,srcBusinessStreamNO,"修改实名软证书调用保护口令");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
            errorLog = ex.getCause();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"修改实名软证书调用保护口令","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        if(errorLog!=null)
        {
            throw new Exception("CA服务器维护中。。。");
        }
        return re;
    }
    /**
     * 验证签名(带多服务器负载均衡)
     **/
    @Override
    public String verifySignOnMultiServer(String strSignData,String strCertData,String strOriginalData,String srcBusinessStreamNO) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
        String body = "";
        String error = "";
        String action = VERIFY_SIGN;
        try {
            Map<String,String> params = new HashMap<>();
            params.put("strSignData",strSignData);
            params.put("strCertData",strCertData);
            params.put("strOriginalData",strOriginalData);
            body = objectMapper.writeValueAsString(params);
//            re = postCAServer(action, params,srcBusinessStreamNO);
            re = postZyCaServer(action, params,srcBusinessStreamNO,"验证签名(带多服务器负载均衡)");
            if(StringUtil.isEmpty(re))
            {
                throw new Exception("返回为空!");
            }
            else{
                if(re.startsWith("error"))
                {
                    throw new Exception(re);
                }
            }
        }
        catch (Exception ex)
        {
            isSuccess = false;
            ex.printStackTrace();
            error = ex.getMessage();
        }
        //保存http日志
        logService.saveHttpLog(isSuccess,action,"验证签名","POST",null,body,re,error,logService.caType);
        if(!StringUtil.isEmpty(error))
        {
            throw new Exception(error);
        }
        return re;
    }
//    public static void main(String args[]) {
//        try {
//            String caUrl = SystemConfig.getInstance().getCAUrl();
//            String caNamespace = SystemConfig.getInstance().getCANamespace();
//            /*//获取实名软证书的过期时间
//            String api = "XMCAF_SOFT_getRealNameSoftCertExpiredDatetime";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "    <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "</root>";*/
//
//            /*//判断实名软证书是否已申请
//            String api = "XMCAF_SOFT_judgeRealNameSoftCertIsApplied";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "    <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "</root>";*/
//
//            //修改实名软证书调用保护口令
//            String api = "XMCAF_SOFT_ModifyRealNameSoftCertCalledPasswd";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "    <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "   <strOldCalledPasswd>12345678</strOldCalledPasswd>\n" +
//                    "   <strNewCalledPasswd>11111111</strNewCalledPasswd>\n" +
//                    "</root>";
//
//
//            //请求实名软证书并进行数字签名
//            /*String orgData = "测试数据";
//            String api = "XMCAF_SOFT_requestRealNameSoftCertAndSign";
//            String msgBody = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n"+
//                    "   <strUserIdcardNum>123456</strUserIdcardNum>\n" +
//                    "   <strRealNameSoftCertCalledPasswd>11111111</strRealNameSoftCertCalledPasswd>\n" +
//                    "   <strOriginalData>"+ MD5Util.GetMD5Code(orgData)+"</strOriginalData>\n" +
//                    "</root>";*/
//
//            String msgHeader = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
//                    "<root>\n" +
//                    "   <serverName>"+api+"</serverName>\n" +
//                    "   <format>xml</format>\n" +
//                    "   <callOperator></callOperator>\n" +
//                    "   <certificate></certificate>\n" +
//
//                    "   <srcIP>10.95.22.10</srcIP >\n" +
//                    "   <srcUserMac>60-D8-19-57-66-E3</srcUserMac>\n" +
//                    "   <srcSystemCode>1</srcSystemCode>\n" +
//                    "   <srcSystemName>厦门i健康</srcSystemName>\n" +
//                    "   <srcBusinessNodeCode>node01</srcBusinessNodeCode>\n" +
//                    "   <srcBusinessNodeName>审核</srcBusinessNodeName>\n" +
//                    "   <srcOperatorAccount>Zhuangsd</srcOperatorAccount>\n" +
//                    "   <srcBusinessStreamNO>11111</srcBusinessStreamNO>\n" +
//                    "   <srcDataExtProperty></srcDataExtProperty>\n" +
//                    "</root>";
//
//
//
//            Map<String, String> params = new HashMap<>();
//            params.put("msgBody", msgBody);
//            params.put("msgHeader", msgHeader);
//            System.out.print(WebserviceUtil.post(caUrl, caNamespace, "XMCA6_UnifiedCallInterface", params) + "\r\n");
//
//
//
//        }
//        catch (Exception ex)
//        {
//            ex.printStackTrace();
//        }
//    }
}

+ 217 - 114
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionService.java

@ -1,5 +1,6 @@
package com.yihu.wlyy.service.service.prescription;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONException;
import com.alibaba.fastjson.JSONObject;
@ -11,6 +12,7 @@ import com.yihu.wlyy.service.common.util.DateUtil;
import com.yihu.wlyy.service.dao.*;
import com.yihu.wlyy.service.dao.consult.ConsultTeamDao;
import com.yihu.wlyy.service.dao.prescription.*;
import com.yihu.wlyy.service.dao.zydict.ZyIvPhysicDictDao;
import com.yihu.wlyy.service.entity.*;
import com.yihu.wlyy.service.entity.consult.ConsultTeam;
import com.yihu.wlyy.service.entity.prescription.*;
@ -75,6 +77,8 @@ public class PrescriptionService extends ZysoftBaseService{
    private ConsultTeamDao consultTeamDao;
    @Autowired
    private AmoutUtils amoutUtils;
    @Autowired
    private ZyIvPhysicDictDao zyIvPhysicDictDao;
    /**
     * 新增续方日志
@ -115,105 +119,126 @@ public class PrescriptionService extends ZysoftBaseService{
            JSONObject pre = json.getJSONObject("Data");
            String recipeNo = pre.getString("RECIPE_NO");
            Prescription prescription = prescriptionDao.findByRecipeNo(recipeNo);
            if(prescription.getStatus()==PrescriptionLog.PrescriptionLogStatus.changeing.getValue()||prescription.getStatus()==PrescriptionLog.PrescriptionLogStatus.change_error.getValue()){
                if(CODE==1){
                    prescription.setStatus(PrescriptionLog.PrescriptionLogStatus.change_success.getValue());
                    prescriptionDao.save(prescription);
                    //调整续方的药品信息
                    JSONArray prescription_detail = pre.getJSONArray("PRESCRIPTION_DETAIL");
                    List<PrescriptionInfo> infoList = new ArrayList<>();
                    for(int i =0;i<prescription_detail.size();i++){
                        JSONObject info = prescription_detail.getJSONObject(i);
                        PrescriptionInfo prescriptionInfo = new PrescriptionInfo();
                        prescriptionInfo.setRemark(info.getString("REMARK"));
                        prescriptionInfo.setBindFlag(info.getString("BIND_FLAG"));
                        prescriptionInfo.setDirection(info.getString("USAGE_NAME"));//药品用法
                        prescriptionInfo.setDrugCode(info.getString("ITEM_CODE"));//药品code
                        prescriptionInfo.setDrugName(info.getString("ITEM_NAME"));//药品名称
                        prescriptionInfo.setDrugRate(info.getString("FREQUENCY"));//吃药频率 FREQUENCY
                        prescriptionInfo.setDrugRateName(info.getString("FREQUENCY_NAME"));
                        prescriptionInfo.setDrugFormat(info.getString("ITEM_SPEC"));//药品规格
                        prescriptionInfo.setPrice(CommonUtil.doubleToInt(info.getDouble("ITEM_PRICE")));//药品单价
                        prescriptionInfo.setNum(info.getInteger("ITEM_QUANTITY"));//药品数目
                        prescriptionInfo.setJwSubCode(info.getString("SUB_NO"));//智业子处方号
                        prescriptionInfo.setDrugNumUnit(info.getString("ITEM_UNIT"));//数量单位编码
                        prescriptionInfo.setDrugNumUnitName(info.getString("ITEM_UNIT_NAME"));//数量单位名称
                        prescriptionInfo.setCost(CommonUtil.doubleToInt(info.getDouble("COST")));//金额
                        prescriptionInfo.setCharge(CommonUtil.doubleToInt(info.getDouble("CHARGE")));//自付
                        prescriptionInfo.setBindFlag(info.getString("BIND_FLAG"));//成组标志, 0.非成组,1.成组
                        prescriptionInfo.setDayCount(info.getInteger("DAY_COUNT"));//用药天数
                        prescriptionInfo.setDrugUsage(info.getString("USAGE"));//用药方法编码
                        prescriptionInfo.setUsageName(info.getString("USAGE_NAME"));//用药方法名称
                        prescriptionInfo.setPhysicDose(info.getString("PHYSIC_DOSE"));//用药剂量
                        prescriptionInfo.setPhysicDoseUnit(info.getString("PHYSIC_DOSE_UNIT"));//剂量单位编码
                        prescriptionInfo.setPhysicDoseUnitName(info.getString("PHYSIC_DOSE_UNIT_NAME"));//剂量单位名称
                        prescriptionInfo.setPhysicAmount(info.getString("PHYSIC_AMOUNT"));//用药总量
                        prescriptionInfo.setPhysicAmountUnit(info.getString("PHYSIC_AMOUNT_UNIT"));//总量单位编码
                        prescriptionInfo.setPhysicAmountUnitName(info.getString("PHYSIC_AMOUNT_UNIT_NAME"));//总量单位名称
                        prescriptionInfo.setPhysicInjectPlace(info.getString("PHYSIC_INJECT_PLACE"));//注射地点编码
                        prescriptionInfo.setPhysicInjectPlaceName(info.getString("PHYSIC_INJECT_PLACE_NAME"));//注射地点名称
                        prescriptionInfo.setPhysicSkinTest(info.getString("PHYSIC_SKIN_TEST"));//皮试类型名称
                        prescriptionInfo.setPhysicSkinTestName(info.getString("PHYSIC_SKIN_TEST_NAME"));//皮试类型名称
                        prescriptionInfo.setPrescriptionCode(prescription.getCode());
                        //设置是否冷藏
                        Integer isRefrigerate = 0;
                        StringBuffer sqlbuf = new StringBuffer("SELECT storage_conditions from zy_iv_physic_dict WHERE physic_code = '"+info.getString("ITEM_CODE")+"'");
                        List<Map<String,Object>> list = jdbcTemplate.queryForList(sqlbuf.toString());
                        if(list!=null&&list.size()>0){
                            Object storage_conditions = list.get(0).get("storage_conditions");
                            if(storage_conditions!=null){
                                String storageConditions = storage_conditions.toString();
                                isRefrigerate = "2".equals(storageConditions)?1:isRefrigerate;
            if(prescription==null){
                error = "没有找到对应的续方";
                errMsg = "没有找到对应的续方";
                status = "0";
            }else {
                if(prescription.getStatus()==PrescriptionLog.PrescriptionLogStatus.changeing.getValue()||prescription.getStatus()==PrescriptionLog.PrescriptionLogStatus.change_error.getValue()){
                    if(CODE==1){
                        prescription.setStatus(PrescriptionLog.PrescriptionLogStatus.change_success.getValue());
                        prescriptionDao.save(prescription);
                        //调整续方的药品信息
                        JSONArray prescription_detail = pre.getJSONArray("PRESCRIPTION_DETAIL");
                        List<PrescriptionInfo> infoList = new ArrayList<>();
                        for(int i =0;i<prescription_detail.size();i++){
                            JSONObject info = prescription_detail.getJSONObject(i);
                            PrescriptionInfo prescriptionInfo = new PrescriptionInfo();
                            prescriptionInfo.setCode(getCode());
                            prescriptionInfo.setRemark(info.getString("REMARK"));
                            prescriptionInfo.setBindFlag(info.getString("BIND_FLAG"));
                            prescriptionInfo.setDirection(info.getString("USAGE_NAME"));//药品用法
                            prescriptionInfo.setDrugCode(info.getString("ITEM_CODE"));//药品code
                            prescriptionInfo.setDrugName(info.getString("ITEM_NAME"));//药品名称
                            prescriptionInfo.setDrugRate(info.getString("FREQUENCY"));//吃药频率 FREQUENCY
                            prescriptionInfo.setDrugRateName(info.getString("FREQUENCY_NAME"));
                            String subjectClass = info.getString("SUBJECT_CLASS");
                            if(StringUtils.isBlank(subjectClass)){//处理默认药品的科目类型为空
                                StringBuffer sql = new StringBuffer("SELECT subject_class from zy_iv_physic_dict WHERE physic_code = ?");
                                List<Map<String,Object>> list = jdbcTemplate.queryForList(sql.toString(),info.getString("ITEM_CODE"));
                                if(list!=null&&list.size()>0){
                                    Object subject_class = list.get(0).get("subject_class");
                                    if(subject_class!=null){
                                        subjectClass = subject_class.toString();
                                    }
                                }
                            }
                        }
                        prescriptionInfo.setIsRefrigerate(isRefrigerate);
                            prescriptionInfo.setSubjectClass(subjectClass);//科目编码
                            //prescriptionInfo.setSubjectClass(info.getString("SUBJECT_CLASS"));//"科目类别编码",
                            prescriptionInfo.setDrugFormat(info.getString("ITEM_SPEC"));//药品规格
                            prescriptionInfo.setPrice(CommonUtil.doubleToInt(info.getDouble("ITEM_PRICE")));//药品单价
                            prescriptionInfo.setNum(info.getInteger("ITEM_QUANTITY"));//药品数目
                            prescriptionInfo.setJwSubCode(info.getString("SUB_NO"));//智业子处方号
                            prescriptionInfo.setDrugNumUnit(info.getString("ITEM_UNIT"));//数量单位编码
                            prescriptionInfo.setDrugNumUnitName(info.getString("ITEM_UNIT_NAME"));//数量单位名称
                            prescriptionInfo.setCost(CommonUtil.doubleToInt(info.getDouble("COST")));//金额
                            prescriptionInfo.setCharge(CommonUtil.doubleToInt(info.getDouble("CHARGE")));//自付
                            prescriptionInfo.setBindFlag(info.getString("BIND_FLAG"));//成组标志, 0.非成组,1.成组
                            prescriptionInfo.setDayCount(info.getInteger("DAY_COUNT"));//用药天数
                            prescriptionInfo.setDrugUsage(info.getString("USAGE"));//用药方法编码
                            prescriptionInfo.setUsageName(info.getString("USAGE_NAME"));//用药方法名称
                            prescriptionInfo.setPhysicDose(info.getString("PHYSIC_DOSE"));//用药剂量
                            prescriptionInfo.setPhysicDoseUnit(info.getString("PHYSIC_DOSE_UNIT"));//剂量单位编码
                            prescriptionInfo.setPhysicDoseUnitName(info.getString("PHYSIC_DOSE_UNIT_NAME"));//剂量单位名称
                            prescriptionInfo.setPhysicAmount(info.getString("PHYSIC_AMOUNT"));//用药总量
                            prescriptionInfo.setPhysicAmountUnit(info.getString("PHYSIC_AMOUNT_UNIT"));//总量单位编码
                            prescriptionInfo.setPhysicAmountUnitName(info.getString("PHYSIC_AMOUNT_UNIT_NAME"));//总量单位名称
                            prescriptionInfo.setPhysicInjectPlace(info.getString("PHYSIC_INJECT_PLACE"));//注射地点编码
                            prescriptionInfo.setPhysicInjectPlaceName(info.getString("PHYSIC_INJECT_PLACE_NAME"));//注射地点名称
                            prescriptionInfo.setPhysicSkinTest(info.getString("PHYSIC_SKIN_TEST"));//皮试类型名称
                            prescriptionInfo.setPhysicSkinTestName(info.getString("PHYSIC_SKIN_TEST_NAME"));//皮试类型名称
                            prescriptionInfo.setPrescriptionCode(prescription.getCode());
                            prescriptionInfo.setDel(1);
                            //设置是否冷藏
                            Integer isRefrigerate = 0;
                            StringBuffer sqlbuf = new StringBuffer("SELECT storage_conditions from zy_iv_physic_dict WHERE physic_code = '"+info.getString("ITEM_CODE")+"'");
                            List<Map<String,Object>> list = jdbcTemplate.queryForList(sqlbuf.toString());
                            if(list!=null&&list.size()>0){
                                Object storage_conditions = list.get(0).get("storage_conditions");
                                if(storage_conditions!=null){
                                    String storageConditions = storage_conditions.toString();
                                    isRefrigerate = "2".equals(storageConditions)?1:isRefrigerate;
                                }
                            }
                            prescriptionInfo.setIsRefrigerate(isRefrigerate);
                            //用药频率
                            prescriptionInfo.setDrugRateName(getZyCommonDictName(info.getString("drugRate")));
                        //用药频率
                        prescriptionInfo.setDrugRateName(getZyCommonDictName(info.getString("drugRate")));
                            infoList.add(prescriptionInfo);
                        }
                        infoList.add(prescriptionInfo);
                        //删除所有药品
                        StringBuffer sql = new StringBuffer("UPDATE wlyy_prescription_info SET del = 0 WHERE prescription_code = '" + prescription.getCode() + "'");
                        jdbcTemplate.execute(sql.toString());
                        //保存新的药品
                        prescriptionInfoDao.save(infoList);
                        //发送系统消息
                        Message message = new Message();
                        message.setCzrq(new Date());
                        message.setCreateTime(new Date());
                        message.setContent("您有1个续方申请已在线下调整完成,请点击进行CA认证。");
                        message.setRead(1);//设置未读
                        message.setReceiver(prescription.getDoctor());//设置接受医生的code
                        message.setSender("系统");//设置发送的用户
                        message.setSenderName("system");
                        message.setCode(getCode());
                        message.setTitle("新增系统消息");
                        message.setType(9);
                        message.setReadonly(1);//是否只读消息
                        message.setOver("1");//未处理
                        message.setRelationCode(prescription.getCode());
                        messageDao.save(message);
                        // redis 的发布 {tilte:redisAddPrescription   state: 1 ,//1:成功,2.失败 mes:'开方成功' prescription : "0001" //续方CODE  }
    //                    JSONObject redisMessage = new JSONObject();
    //                    redisMessage.put("title","adjustPrescription");
    //                    redisMessage.put("state",1);
    //                    redisMessage.put("prescription",prescription.getCode());
    //                    redisMessage.put("mes","调整处方完成");
    //                    redisTemplate.opsForList().leftPush(channelTopic,redisMessage.toString());
                    }else {
                        //调整失败
                        prescription.setStatus(4);
                        prescriptionDao.save(prescription);
                        msg = json.getString("MSG");
                    }
                    //删除所有药品
                    StringBuffer sql = new StringBuffer("UPDATE wlyy_prescription_info SET del = 0 WHERE prescription_code = '" + prescription.getCode() + "'");
                    jdbcTemplate.execute(sql.toString());
                    //保存新的药品
                    prescriptionInfoDao.save(infoList);
                    //发送系统消息
                    Message message = new Message();
                    message.setCzrq(new Date());
                    message.setCreateTime(new Date());
                    message.setContent("您有1个续方申请已在线下调整完成,请点击进行CA认证。");
                    message.setRead(1);//设置未读
                    message.setReceiver(prescription.getDoctor());//设置接受医生的code
                    message.setSender("系统");//设置发送的用户
                    message.setSenderName("system");
                    message.setCode(getCode());
                    message.setTitle("新增系统消息");
                    message.setType(9);
                    message.setReadonly(1);//是否只读消息
                    message.setOver("1");//未处理
                    message.setRelationCode(prescription.getCode());
                    messageDao.save(message);
                    // redis 的发布 {tilte:redisAddPrescription   state: 1 ,//1:成功,2.失败 mes:'开方成功' prescription : "0001" //续方CODE  }
//                    JSONObject redisMessage = new JSONObject();
//                    redisMessage.put("title","adjustPrescription");
//                    redisMessage.put("state",1);
//                    redisMessage.put("prescription",prescription.getCode());
//                    redisMessage.put("mes","调整处方完成");
//                    redisTemplate.opsForList().leftPush(channelTopic,redisMessage.toString());
                }else {
                    //调整失败
                    prescription.setStatus(4);
                    prescriptionDao.save(prescription);
                    msg = json.getString("MSG");
                    //新增续方日志
                    addPrescriptionLog(prescription,"接收线下处方调整完成消息-"+msg);
                }
                //新增续方日志
                addPrescriptionLog(prescription,"接收线下处方调整完成消息-"+msg);
            }
        }catch (JSONException ex){
            ex.printStackTrace();
@ -331,18 +356,41 @@ public class PrescriptionService extends ZysoftBaseService{
                    log.setUserCode(prescription.getDoctor());
                    log.setStatus(PrescriptionLog.PrescriptionLogStatus.wait_expressage.getValue());
                    prescriptionLogDao.save(log);
                }
                //判断健管师配送要添加续方消息,提示健管师有续方代配送
                JSONObject message = new JSONObject();
                message.put("title","dispensingComplete");
                message.put("state",1);
                message.put("prescription",prescription.getCode());
                message.put("mes","success");
                    //健管师配送
                    PrescriptionExpressage expressage = prescriptionExpressageDao.findByPrescriptionCode(prescription.getCode());
                    if(StringUtils.isNotBlank(expressage.getExpressageCode())){
                        Message message = new Message();
                        message.setCzrq(new Date());
                        message.setCreateTime(new Date());
                        message.setRead(1);//设置未读
                        message.setOver("1");
                        message.setReceiver(expressage.getExpressageCode());
                        message.setSender("system");
                        message.setCode(getCode());
                        message.setSenderName("系统");
                        message.setTitle("居民"+prescription.getPatientName()+"的续方订单待取药");
                        message.setContent("您有一条新的续方订单待取药!");
                        message.setType(7);//续方订单待取药
                        message.setReadonly(1);//是否只读消息
                        message.setDel("1");
                        message.setRelationCode(prescription.getCode());
                        message.setPrescriptionStatus("0");//待取药
                        message.setData(prescription.getAdminTeamId()+"");
                        messageDao.save(message);
                    }
                    //判断提示健管师有续方代配送,居民待取药
                    JSONObject message = new JSONObject();
                    message.put("title","dispensingComplete");
                    message.put("state",1);
                    message.put("prescription",prescription.getCode());
                    message.put("mes","success");
//                redisTemplate.convertAndSend(channelTopic,message.toString());
//                redisTemplate.watch(channelTopic);
                redisTemplate.opsForList().leftPush(channelTopic,message.toString());
                    redisTemplate.opsForList().leftPush(channelTopic,message.toString());
//                redisTemplate.unwatch();
                }
            }
        }catch (JSONException ex){
@ -651,8 +699,8 @@ public class PrescriptionService extends ZysoftBaseService{
            applyTimeEnd = DateUtil.getStringDateShort();
            applyTimeFrom = DateUtil.getNextDay(new Date(),-60);
        }else{
            applyTimeEnd = DateUtil.getNextDay(prescription.getCreateTime(),10);
            applyTimeFrom = DateUtil.getNextDay(prescription.getCreateTime(),-10);
            applyTimeEnd = DateUtil.getNextDay(prescription.getCreateTime(),0);
            applyTimeFrom = DateUtil.getNextDay(prescription.getCreateTime(),-60);
        }
        params.put("applyTimeFrom",applyTimeFrom);
        params.put("applyTimeEnd",applyTimeEnd);
@ -662,6 +710,43 @@ public class PrescriptionService extends ZysoftBaseService{
        return response;
    }
    /**
     * 获取历史处方列表
     * @param patientCode
     * @param applyTimeFrom
     * @param applyTimeEnd
     * @return
     * @throws Exception
     */
    public String getRecipeMasterList(String patientCode,String applyTimeFrom,String applyTimeEnd)  throws Exception
    {
        Patient patient = patientDao.findByCode(patientCode);
        SignFamily signFamily = signFamilyDao.findByPatient(patientCode);
        String[] hospitalMapping = getHospitalMapping(signFamily.getHospital()); //获取机构映射
        String hospital = hospitalMapping[0];
        String licence = hospitalMapping[1];
        Map<String,String> header = new HashMap<>();
        header.put("ORGCODE",hospital);
        header.put("LICENCE",licence);
        if(StringUtils.isEmpty(applyTimeFrom)){
            applyTimeEnd = DateUtil.getStringDateShort();
            applyTimeFrom = DateUtil.getNextDay(new Date(),-60);
        }
        Map<String,String> params = new HashMap<>();
        params.put("cardNo",patient.getSsc());
        params.put("applyTimeFrom",applyTimeFrom);
        params.put("applyTimeEnd",applyTimeEnd);
        String response = postSecond("getRecipeMasterList","获取历史处方列表",params,null,header,false,2);
        return response;
    }
    /**
     * 7.4 挂号开处方接口,调整处方接口
     * 开方和调整处方接口的区别-开方会传ca认证
@ -784,8 +869,16 @@ public class PrescriptionService extends ZysoftBaseService{
    public String getDispUnSettleFeeInfoList(String cardNo, String visitNo,String recipeNo)  throws Exception
    {
        Prescription prescription = prescriptionDao.findByVisitNoAndRecipeNo(visitNo,recipeNo);
        String hos = "";
        if(prescription==null){
            Patient patient = patientDao.findBySsc(cardNo);
            SignFamily signFamily = signFamilyDao.findByPatient(patient.getCode());
            hos = signFamily.getHospital();
        }else {
            hos = prescription.getHospital();
        }
        String[] hospitalMapping = getHospitalMapping(prescription.getHospital()); //获取机构映射
        String[] hospitalMapping = getHospitalMapping(hos); //获取机构映射
        String hospital = hospitalMapping[0];
        String licence = hospitalMapping[1];
//        String licence = "5YGl5bq35LmL6Lev";
@ -799,10 +892,6 @@ public class PrescriptionService extends ZysoftBaseService{
        params.put("visitNo",visitNo);
        String response = postSecond("getDispUnSettleFeeInfoList","查询处方结算结果列表",params,null,header,false,2);
        //添加日志到wlyy_zy_push_log表
        addZyPushLog(response,"getDispUnSettleFeeInfoList","查询处方结算结果列表",null  ,"POST","","2","");
        return response;
    }
@ -811,6 +900,7 @@ public class PrescriptionService extends ZysoftBaseService{
     * @param  prescriptionCode 处方号
     * @throws Exception
     */
    @Transactional
    public String executeSickSettle(String prescriptionCode)  throws Exception
    {
        Prescription prescription = prescriptionDao.findByCode(prescriptionCode);
@ -839,7 +929,7 @@ public class PrescriptionService extends ZysoftBaseService{
        JSONObject json = new JSONObject();
        json.put("cardNo",prescription.getSsc());// "cardNo": "病人卡号",
        json.put("settleDept",prescription.getJwDeptCode());//结算科室编码
        json.put("saveOperator",prescription.getJwDoctorCode());// "saveOperator": "开单人员编码",
        json.put("settleOperator",prescription.getJwDoctorCode());// "saveOperator": "开单人员编码",
        json.put("visitNo",prescription.getVisitNo());// "院内挂号号,取费用列表中最小的院内挂号号
        //医保支付需要组装以下参数
@ -872,10 +962,18 @@ public class PrescriptionService extends ZysoftBaseService{
        }
        String response = postSecond("executeSickSettle","院内结算确认接口",null,json,header,false,2);
        //添加日志到wlyy_zy_push_log表
        addZyPushLog(response,"executeSickSettle","院内结算确认接口",null  ,"POST","","3","");
        if(StringUtils.isNotBlank(response)){
            JSONObject reobj =  JSON.parseObject(response);
            Integer code = reobj.getInteger("CODE");
            String errmsg = reobj.getString("MESSAGE");
            if(1 != code){
                throw new Exception("基卫接口(院内结算确认接口)请求失败,"+errmsg);
            }else{
                prescriptionDao.updatejwPayStatus(prescriptionCode);
            }
        }else{
            throw new Exception("基卫接口(院内结算确认接口)请求失败,无数据返回!");
        }
        return response;
    }
@ -993,7 +1091,12 @@ public class PrescriptionService extends ZysoftBaseService{
        vo.setD_phone(prescriptionExpressage.getPhone());
        vo.setPay_method(2);
        vo.setExpress_type(11);
        vo.setReceive_time("");//---2017.08.22-huangwnejie,新增收件时间,默认先放空
        //---2017.08.30-huangwnejie,新增收件时间
        if(prescriptionExpressage.getDeliveryTime() != null ){
            vo.setReceive_time(DateUtil.dateToStrLong(prescriptionExpressage.getDeliveryTime()));
        }else{
            vo.setReceive_time("");
        }
        vo.setInfos(prescriptionInfolist);

+ 19 - 2
patient-co-service/wlyy_service/src/main/resources/application.yml

@ -53,7 +53,7 @@ zysoftApi:
  base: base/CallEhrInterface
redisChannel:
    prescription: redisPrescription
    prescription: redisMessage
---
spring:
@ -75,10 +75,27 @@ im:
  data_base_name: im_new
---
spring:
  profiles: test
  profiles: devtest
  datasource:
#    url: jdbc:mysql://172.17.110.160:3306/wlyy?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
    url: jdbc:mysql://172.19.103.85:3306/wlyy?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
    username: linzhou
    password: linzhou
    driverClassName: com.mysql.jdbc.Driver
    maxTotal: 500
    maxIdle: 30
  redis:
    host: 172.19.103.88 # Redis server host.
    port: 6379 # Redis server port.
#    password: jkzl_ehr
im:
  data_base_name: im_new
---
spring:
  profiles: test
  datasource:
    url: jdbc:mysql://172.17.110.160:3306/wlyy?useUnicode=true&characterEncoding=utf-8&autoReconnect=true
    username: ssgg
    password: ssgg
    driverClassName: com.mysql.jdbc.Driver

+ 76 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/css/artDialog.css

@ -0,0 +1,76 @@
@charset "utf-8";
/*
 * artDialog skin
 * http://code.google.com/p/artdialog/
 * (c) 2009-2011 TangBin, http://www.planeArt.cn
 *
 * This is licensed under the GNU LGPL, version 2.1 or later.
 * For details, see: http://creativecommons.org/licenses/LGPL/2.1/
 */
 
/* common start */
body { _margin:0; _height:100%; /*IE6 BUG*/ }
.aui_outer { text-align:left; }
table.aui_border, table.aui_dialog { border:0; margin:0; border-collapse:collapse; width:auto; }
.aui_nw, .aui_n, .aui_ne, .aui_w, .aui_c, .aui_e, .aui_sw, .aui_s, .aui_se, .aui_header, .aui_tdIcon, .aui_main, .aui_footer { padding:0; }
.aui_header, .aui_buttons button { font: 12px/1.11 'Microsoft Yahei', Tahoma, Arial, Helvetica, STHeiti; _font-family:Tahoma,Arial,Helvetica,STHeiti; -o-font-family: Tahoma, Arial; }
.aui_title { overflow:hidden; text-overflow: ellipsis; }
.aui_state_noTitle .aui_title { display:none; }
.aui_close {display:block; position:absolute; text-decoration:none; outline:none; _cursor:pointer; }
.aui_close:hover {text-decoration:none;}
.aui_main { text-align:center; min-width:9em; min-width:0\9/*IE8 BUG*/; }
.aui_content {*zoom:1; *display:inline; text-align:left; border:none 0; }
.aui_content.aui_state_full { display:block; width:100%; margin:0; padding:0!important; height:100%; }
.aui_loading { width:96px; height:32px; text-align:left; text-indent:-999em; overflow:hidden; background:url(../images/loading.gif) no-repeat center center; }
.aui_icon { vertical-align: middle; }
.aui_icon div { width:48px; height:48px; margin:10px 0 10px 10px; background-position: center center; background-repeat:no-repeat; }
.aui_buttons { padding:8px 8px 32px 8px; text-align:center; white-space:nowrap; }
.aui_buttons button { margin-left:15px; padding: 10px 30px; cursor: pointer; display: inline-block; border-radius:2px; text-align: center; line-height: 1; *padding:5px 15px; *height:2em; font-family: Tahoma, Arial/9!important; width:auto; overflow:visible; *width:1; color: #333; border: solid 1px #cbcbcb; background: #f3f3f3; opacity:.9;}
.aui_buttons button::-moz-focus-inner{ border:0; padding:0; margin:0; }
.aui_buttons button:focus { outline:none 0; border-color:#47d7ad; opacity:.9; }
.aui_buttons button:hover { color:#000; border-color:#ccc; opacity:1; }
.aui_buttons button:active { border-color:#666; opacity:1;}
.aui_buttons button[disabled] { cursor:default; color:#666; background:#DDD; border: solid 1px #999; filter:alpha(opacity=50); opacity:.5; box-shadow:none; }
button.aui_state_highlight { color: #FFF; border-color:#47d7ad; background: #47d7ad;}
button.aui_state_highlight:hover { color:#FFF; border-color:#47d7ad; }
button.aui_state_highlight:active { border-color:#47d7ad;}
/* common end */
.aui_inner { background:#FFF; -webkit-box-shadow:0px 0px 5px #ccc; box-shadow:0px 0px 5px #ccc;}
.aui_outer, .aui_inner { border:0; }
.aui_border { /*box-shadow: inset 0 0 1px rgba(255, 255, 255, .9);*/ }
.aui_nw, .aui_ne, .aui_sw, .aui_se { width:8px; height:8px;}
.aui_nw {border-top-left-radius:5px;}
.aui_ne {border-top-right-radius:5px;}
.aui_sw {border-bottom-left-radius:5px;}
.aui_se {border-bottom-right-radius:5px;}
.aui_nw, .aui_n, .aui_ne, .aui_w, .aui_e, .aui_sw, .aui_s, .aui_se { }
.aui_state_lock .aui_nw, .aui_state_lock .aui_n, .aui_state_lock .aui_ne, .aui_state_lock .aui_w, .aui_state_lock .aui_e, .aui_state_lock .aui_sw, .aui_state_lock .aui_s, .aui_state_lock .aui_se {}
.aui_state_focus .aui_dialog { }
.aui_state_focus .aui_outer { }
.aui_state_lock .aui_border { /*box-shadow:0 3px 26px rgba(0, 0, 0, 0.9);*/ }
.aui_state_drag .aui_outer, .aui_outer:active { box-shadow:none; }
.aui_titleBar { position:relative; height:100%; background:#dcdddd }
.aui_title { height:50px; line-height:50px; padding:0 20px; text-align:left; color:#000; font-size:14px; font-weight:bold; background:#fff; border-bottom:#f2f2f2 1px solid; _height:35px; _line-height:35px; _padding:15px 20px 0 20px;}
.aui_state_focus .aui_title { color:#3d3d3d; }
.aui_state_drag .aui_title { color:#000}
.aui_state_drag .aui_titleBar { box-shadow:none; }
.aui_close { padding:0; top:0px; right:-40px; width:40px; height:40px; line-height:40px; font-size:26px; color:#a8a8a8 !important; text-align:center; background:#fafafa; }
.aui_close:hover {color:#ed6f74 !important; line-height:40px; line-height:40px\0; *line-height:40px;}
.aui_close:active { box-shadow: none; }
.aui_content { color:#666; }
.aui_state_focus .aui_content { color:#7d7d7d; }
.aui_buttons { background-color:#fff; }
.aui_state_noTitle .aui_nw, .aui_state_noTitle .aui_ne, .aui_state_noTitle .aui_sw, .aui_state_noTitle .aui_se { width:3px; height:3px; }
.aui_state_noTitle .aui_inner { border:1px solid #666; background:#FFF; }
.aui_state_noTitle .aui_outer { border:none 0; box-shadow:none; }
.aui_state_noTitle .aui_nw, .aui_state_noTitle .aui_n, .aui_state_noTitle .aui_ne, .aui_state_noTitle .aui_w, .aui_state_noTitle .aui_e, .aui_state_noTitle .aui_sw, .aui_state_noTitle .aui_s, .aui_state_noTitle .aui_se { }
.aui_state_noTitle .aui_titleBar { bottom:0; _bottom:0; _margin-top:0; }
.aui_state_noTitle .aui_close { top:0; right:0; width:18px; height:18px; line-height:18px; text-align:center; text-indent:0; font-size:18px; text-decoration:none; color:#214FA3; background:none; filter:!important; }
.aui_state_noTitle .aui_close:hover, .aui_state_noTitle .aui_close:active { text-decoration:none; color:#900; }
.aui_state_noTitle .aui_dialog { box-shadow: none; }
.art-icon {display:inline-block; background:url(../../../../images/articons.png) no-repeat; vertical-align: text-top; overflow:hidden; *display:inline; *zoom:1; width:15px; height:15px; position:relative; top:2px; margin-right:10px}
.icon-title-add {background-position:0 0;}
.icon-title-edit {background-position:0 -33px;}
.icon-title-ask {background-position:0 -100px;}
.icon-title-error {background-position:0 -67px;}

BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/images/articons.png


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/images/loading.gif


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/images/tips-icon.png


+ 2096 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/4.1.7/js/artDialog.js

@ -0,0 +1,2096 @@
/*!
 * artDialog 4.1.7
 * Date: 2013-03-03 08:04
 * http://code.google.com/p/artdialog/
 * (c) 2009-2012 TangBin, http://www.planeArt.cn
 *
 * This is licensed under the GNU LGPL, version 2.1 or later.
 * For details, see: http://creativecommons.org/licenses/LGPL/2.1/
 */
 
;(function (window, undefined) {
//if (window.jQuery) return jQuery;
var $ = window.art = function (selector, context) {
    	return new $.fn.init(selector, context);
	},
    readyBound = false,
    readyList = [],
    DOMContentLoaded,
	isOpacity = 'opacity' in document.documentElement.style,
	quickExpr = /^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]+)$)/,
	rclass = /[\n\t]/g,
	ralpha = /alpha\([^)]*\)/i,
	ropacity = /opacity=([^)]*)/,
    rfxnum = /^([+-]=)?([\d+-.]+)(.*)$/;
if (window.$ === undefined) window.$ = $;
$.fn = $.prototype = {
	constructor: $,
	
    /**
	 * DOM 就绪
	 * @param	{Function}	回调函数
	 */
    ready: function (callback) {
        $.bindReady();
        if ($.isReady) {
            callback.call(document, $);
        } else if (readyList) {
            readyList.push(callback);
        };
        return this;
    },
    /**
	 * 判断样式类是否存在
	 * @param	{String}	名称
	 * @return	{Boolean}
	 */
    hasClass: function (name) {		
		var className = ' ' + name + ' ';
		if ((' ' + this[0].className + ' ').replace(rclass, ' ')
		.indexOf(className) > -1) return true;
		return false;
    },
    /**
	 * 添加样式类
	 * @param	{String}	名称
	 */
    addClass: function (name) {
        if (!this.hasClass(name)) this[0].className += ' ' + name;
        return this;
    },
    /**
	 * 移除样式类
	 * @param	{String}	名称
	 */
    removeClass: function (name) {
        var elem = this[0];
        if (!name) {
            elem.className = '';
        } else
		if (this.hasClass(name)) {
            elem.className = elem.className.replace(name, ' ');
        };
        return this;
    },
    /**
	 * 读写样式<br />
     * css(name) 访问第一个匹配元素的样式属性<br />
     * css(properties) 把一个"名/值对"对象设置为所有匹配元素的样式属性<br />
     * css(name, value) 在所有匹配的元素中,设置一个样式属性的值<br />
	 */
    css: function (name, value) {
        var i, elem = this[0], obj = arguments[0];
        if (typeof name === 'string') {
            if (value === undefined) {
                return $.css(elem, name);
            } else {
                name === 'opacity' ?
					$.opacity.set(elem, value) :
					elem.style[name] = value;
            };
        } else {
            for (i in obj) {
				i === 'opacity' ?
					$.opacity.set(elem, obj[i]) :
					elem.style[i] = obj[i];
			};
        };
		
        return this;
    },
	
	/** 显示元素 */
	show: function () {
		return this.css('display', 'block');
	},
	
	/** 隐藏元素 */
	hide: function () {
		return this.css('display', 'none');
	},
    /**
	 * 获取相对文档的坐标
	 * @return	{Object}	返回left、top的数值
	 */
    offset: function () {
        var elem = this[0],
            box = elem.getBoundingClientRect(),
            doc = elem.ownerDocument,
            body = doc.body,
            docElem = doc.documentElement,
            clientTop = docElem.clientTop || body.clientTop || 0,
            clientLeft = docElem.clientLeft || body.clientLeft || 0,
            top = box.top + (self.pageYOffset || docElem.scrollTop) - clientTop,
            left = box.left + (self.pageXOffset || docElem.scrollLeft) - clientLeft;
        return {
            left: left,
            top: top
        };
    },
	
	/**
	 * 读写HTML - (不支持文本框)
	 * @param	{String}	内容
	 */
	html: function (content) {
		var elem = this[0];
		
		if (content === undefined) return elem.innerHTML;
		$.cleanData(elem.getElementsByTagName('*'));
		elem.innerHTML = content;
		
		return this;
	},
	
	/**
	 * 移除节点
	 */
	remove: function () {
		var elem = this[0];
		$.cleanData(elem.getElementsByTagName('*'));
		$.cleanData([elem]);
		elem.parentNode.removeChild(elem);
		
		return this;
	},
	/**
	 * 事件绑定
	 * @param	{String}	类型
	 * @param	{Function}	要绑定的函数
	 */
	bind: function (type, callback) {
		$.event.add(this[0], type, callback);
		return this;
	},
	/**
	 * 移除事件
	 * @param	{String}	类型
	 * @param	{Function}	要卸载的函数
	 */
	unbind: function(type, callback) {
		$.event.remove(this[0], type, callback);
		return this;
	}
};
$.fn.init = function (selector, context) {
	var match, elem;
	context = context || document;
	
	if (!selector) return this;
	
	if (selector.nodeType) {
		this[0] = selector;
		return this;
	};
	
	if (selector === 'body' && context.body) {
		this[0] = context.body;
		return this;
	};
	
	if (selector === 'head' || selector === 'html') {
		this[0] = context.getElementsByTagName(selector)[0];
		return this;
	};
		
	if (typeof selector === 'string') {
		match = quickExpr.exec(selector);
		if (match && match[2]) {
			elem = context.getElementById(match[2]);
			if (elem && elem.parentNode) this[0] = elem;
			return this;
		};
	};
	
	if (typeof selector === 'function') return $(document).ready(selector);
	
	this[0] = selector;
	
	return this;
};
$.fn.init.prototype = $.fn;
/** 空函数 */
$.noop = function () {};
/** 检测window */
$.isWindow = function (obj) {
	return obj && typeof obj === 'object' && 'setInterval' in obj;
};
/** 数组判定 */
$.isArray = function (obj) {
    return Object.prototype.toString.call(obj) === '[object Array]';
};
/**
 * 搜索子元素
 * 注意:只支持nodeName或.className的形式,并且只返回第一个元素
 * @param	{String}
 */
$.fn.find = function (expr) {
	var value, elem = this[0],
		className = expr.split('.')[1];
	if (className) {
		if (document.getElementsByClassName) {
			value = elem.getElementsByClassName(className);
		} else {
			value = getElementsByClassName(className, elem);
		};
	} else {
		value = elem.getElementsByTagName(expr);
	};
	
	return $(value[0]);
};
function getElementsByClassName (className, node, tag) {
	node = node || document;
	tag = tag || '*';
	var i = 0,
		j = 0,
		classElements = [],
		els = node.getElementsByTagName(tag),
		elsLen = els.length,
		pattern = new RegExp("(^|\\s)" + className + "(\\s|$)");
		
	for (; i < elsLen; i ++) {
		if (pattern.test(els[i].className)) {
			classElements[j] = els[i];
			j ++;
		};
	};
	return classElements;
};
/**
 * 遍历
 * @param {Object}
 * @param {Function}
 */
$.each = function (obj, callback) {
    var name, i = 0,
        length = obj.length,
        isObj = length === undefined;
    if (isObj) {
        for (name in obj) {
            if (callback.call(obj[name], name, obj[name]) === false) break;
        };
    } else {
        for (var value = obj[0];
		i < length && callback.call(value, i, value) !== false;
		value = obj[++i]) {};
    };
	
	return obj;
};
/**
 * 读写缓存
 * @param		{HTMLElement}	元素
 * @param		{String}		缓存名称
 * @param		{Any}			数据
 * @return		{Any}			如果无参数data则返回缓存数据
 */
$.data = function (elem, name, data) {
	var cache = $.cache,
		id = uuid(elem);
	
	if (name === undefined) return cache[id];
	if (!cache[id]) cache[id] = {};
	if (data !== undefined) cache[id][name] = data;
	
	return cache[id][name];
};
/**
 * 删除缓存
 * @param		{HTMLElement}	元素
 * @param		{String}		缓存名称
 */
$.removeData = function (elem, name) {
	var empty = true,
		expando = $.expando,
		cache = $.cache,
		id = uuid(elem),
		thisCache = id && cache[id];
	if (!thisCache) return;
	if (name) {
		delete thisCache[name];
		for (var n in thisCache) empty = false;
		if (empty) delete $.cache[id];
	} else {
		delete cache[id];
		if (elem.removeAttribute) {
			elem.removeAttribute(expando);
		} else {
			elem[expando] = null;
		};
	};
};
$.uuid = 0;
$.cache = {};
$.expando = '@cache' + + new Date
// 标记元素唯一身份
function uuid (elem) {
	var expando = $.expando,
		id = elem === window ? 0 : elem[expando];
	if (id === undefined) elem[expando] = id = ++ $.uuid;
	return id;
};
/**
 * 事件机制
 * @namespace
 * @requires	[$.data, $.removeData]
 */
$.event = {
	
	/**
	 * 添加事件
	 * @param		{HTMLElement}	元素
	 * @param		{String}		事件类型
	 * @param		{Function}		要添加的函数
	 */
	add: function (elem, type, callback) {
		var cache, listeners,
			that = $.event,
			data = $.data(elem, '@events') || $.data(elem, '@events', {});
		
		cache = data[type] = data[type] || {};
		listeners = cache.listeners = cache.listeners || [];
		listeners.push(callback);
		
		if (!cache.handler) {
			cache.elem = elem;
			cache.handler = that.handler(cache);
			
			elem.addEventListener
			? elem.addEventListener(type, cache.handler, false)
			: elem.attachEvent('on' + type, cache.handler);
		};
	},
	
	/**
	 * 卸载事件
	 * @param		{HTMLElement}	元素
	 * @param		{String}		事件类型
	 * @param		{Function}		要卸载的函数
	 */
	remove: function (elem, type, callback) {
		var i, cache, listeners,
			that = $.event,
			empty = true,
			data = $.data(elem, '@events');
		
		if (!data) return;
		if (!type) {
			for (i in data) that.remove(elem, i);
			return;
		};
		
		cache = data[type];
		if (!cache) return;
		
		listeners = cache.listeners;
		if (callback) {
			for (i = 0; i < listeners.length; i ++) {
				listeners[i] === callback && listeners.splice(i--, 1);
			};
		} else {
			cache.listeners = [];
		};
		
		if (cache.listeners.length === 0) {
			elem.removeEventListener
			? elem.removeEventListener(type, cache.handler, false)
			: elem.detachEvent('on' + type, cache.handler);
			
			delete data[type];
			cache = $.data(elem, '@events');
			for (var n in cache) empty = false;
			if (empty) $.removeData(elem, '@events');
		};
	},
	
	/** @inner 事件句柄 */
	handler: function (cache) {
		return function (event) {
			event = $.event.fix(event || window.event);
			for (var i = 0, list = cache.listeners, fn; fn = list[i++];) {
				if (fn.call(cache.elem, event) === false) {
					event.preventDefault();
					event.stopPropagation();
				};
			};
		};
	},
	
	/** @inner Event对象兼容处理 */
	fix: function (event) {
		if (event.target) return event;
		
		var event2 = {
			target: event.srcElement || document,
			preventDefault: function () {event.returnValue = false},
			stopPropagation: function () {event.cancelBubble = true}
		};
		// IE6/7/8 在原生window.event对象写入数据会导致内存无法回收,应当采用拷贝
		for (var i in event) event2[i] = event[i];
		return event2;
	}
	
};
/**
 * 清理元素集的事件与缓存
 * @requires	[$.removeData, $.event]
 * @param		{HTMLCollection}	元素集
 */
$.cleanData = function (elems) {
	var i = 0, elem,
		len = elems.length,
		removeEvent = $.event.remove,
		removeData = $.removeData;
	
	for (; i < len; i ++) {
		elem = elems[i];
		removeEvent(elem);
		removeData(elem);
	};
};
// DOM就绪事件
$.isReady = false;
$.ready = function () {
    if (!$.isReady) {
        if (!document.body) return setTimeout($.ready, 13);
        $.isReady = true;
        if (readyList) {
            var fn, i = 0;
            while ((fn = readyList[i++])) {
                fn.call(document, $);
            };
            readyList = null;
        };
    };
};
$.bindReady = function () {
    if (readyBound) return;
    readyBound = true;
    if (document.readyState === 'complete') {
        return $.ready();
    };
    if (document.addEventListener) {
        document.addEventListener('DOMContentLoaded', DOMContentLoaded, false);
        window.addEventListener('load', $.ready, false);
    } else if (document.attachEvent) {
        document.attachEvent('onreadystatechange', DOMContentLoaded);
        window.attachEvent('onload', $.ready);
        var toplevel = false;
        try {
            toplevel = window.frameElement == null;
        } catch (e) {};
        if (document.documentElement.doScroll && toplevel) {
            doScrollCheck();
        };
    };
};
if (document.addEventListener) {
    DOMContentLoaded = function () {
        document.removeEventListener('DOMContentLoaded', DOMContentLoaded, false);
        $.ready();
    };
} else if (document.attachEvent) {
    DOMContentLoaded = function () {
        if (document.readyState === 'complete') {
            document.detachEvent('onreadystatechange', DOMContentLoaded);
            $.ready();
        };
    };
};
function doScrollCheck () {
    if ($.isReady) return;
    try {
        document.documentElement.doScroll('left');
    } catch (e) {
        setTimeout(doScrollCheck, 1);
        return;
    };
    $.ready();
};
// 获取css
$.css = 'defaultView' in document && 'getComputedStyle' in document.defaultView ?
	function (elem, name) {
		return document.defaultView.getComputedStyle(elem, false)[name];
} :
	function (elem, name) {
		var ret = name === 'opacity' ? $.opacity.get(elem) : elem.currentStyle[name];
		return ret || '';
};
// 跨浏览器处理opacity
$.opacity = {
	get: function (elem) {
		return isOpacity ?
			document.defaultView.getComputedStyle(elem, false).opacity :
			ropacity.test((elem.currentStyle
				? elem.currentStyle.filter
				: elem.style.filter) || '')
				? (parseFloat(RegExp.$1) / 100) + ''
				: 1;
	},
	set: function (elem, value) {
		if (isOpacity) return elem.style.opacity = value;
		var style = elem.style;
		style.zoom = 1;
		var opacity = 'alpha(opacity=' + value * 100 + ')',
			filter = style.filter || '';
		style.filter = ralpha.test(filter) ?
			filter.replace(ralpha, opacity) :
			style.filter + ' ' + opacity;
	}
};
/**
 * 获取滚动条位置 - [不支持写入]
 * $.fn.scrollLeft, $.fn.scrollTop
 * @example		获取文档垂直滚动条:$(document).scrollTop()
 * @return		{Number}	返回滚动条位置
 */
$.each(['Left', 'Top'], function (i, name) {
    var method = 'scroll' + name;
    $.fn[method] = function () {
        var elem = this[0], win;
		win = getWindow(elem);
		return win ?
			('pageXOffset' in win) ?
				win[i ? 'pageYOffset' : 'pageXOffset'] :
				win.document.documentElement[method] || win.document.body[method] :
			elem[method];
    };
});
function getWindow (elem) {
	return $.isWindow(elem) ?
		elem :
		elem.nodeType === 9 ?
			elem.defaultView || elem.parentWindow :
			false;
};
/**
 * 获取窗口或文档尺寸 - [只支持window与document读取]
 * @example 
   获取文档宽度:$(document).width()
   获取可视范围:$(window).width()
 * @return	{Number}
 */
$.each(['Height', 'Width'], function (i, name) {
    var type = name.toLowerCase();
    $.fn[type] = function (size) {
        var elem = this[0];
        if (!elem) {
            return size == null ? null : this;
        };
		return $.isWindow(elem) ?
			elem.document.documentElement['client' + name] || elem.document.body['client' + name] :
			(elem.nodeType === 9) ?
				Math.max(
					elem.documentElement['client' + name],
					elem.body['scroll' + name], elem.documentElement['scroll' + name],
					elem.body['offset' + name], elem.documentElement['offset' + name]
				) : null;
    };
});
/**
 * 简单ajax支持
 * @example
 * $.ajax({
 * 		url: url,
 * 		success: callback,
 * 		cache: cache
 * });
 */
$.ajax = function (config) {
	var ajax = window.XMLHttpRequest ?
			new XMLHttpRequest() :
			new ActiveXObject('Microsoft.XMLHTTP'),
		url = config.url;
	
	if (config.cache === false) {
		var ts = + new Date,
			ret = url.replace(/([?&])_=[^&]*/, "$1_=" + ts );
		url = ret + ((ret === url) ? (/\?/.test(url) ? "&" : "?") + "_=" + ts : "");
	};
	
	ajax.onreadystatechange = function() {
		if (ajax.readyState === 4 && ajax.status === 200) {
			config.success && config.success(ajax.responseText);
			ajax.onreadystatechange = $.noop;
		};
	};
	ajax.open('GET', url, 1);
	ajax.send(null);
};
/** 动画引擎 - [不支持链式列队操作] */
$.fn.animate = function (prop, speed, easing, callback) {
	
	speed = speed || 400;
	if (typeof easing === 'function') callback = easing;
	easing = easing && $.easing[easing] ? easing : 'swing';
	
    var elem = this[0], overflow,
        fx, parts, start, end, unit,
		opt = {
			speed: speed,
			easing: easing,
			callback: function () {
				if (overflow != null) elem.style.overflow = '';
				callback && callback();
			}
		};
	
	opt.curAnim = {};
	$.each(prop, function (name, val) {
		opt.curAnim[name] = val;
	});
	
    $.each(prop, function (name, val) {
        fx = new $.fx(elem, opt, name);
        parts = rfxnum.exec(val);
        start = parseFloat(name === 'opacity'
			|| (elem.style && elem.style[name] != null) ?
			$.css(elem, name) :
			elem[name]);
        end = parseFloat(parts[2]);
        unit = parts[3];
		if (name === 'height' || name === 'width') {
			end = Math.max(0, end);
			overflow = [elem.style.overflow,
			elem.style.overflowX, elem.style.overflowY];
		};
		
        fx.custom(start, end, unit);
    });
	
	if (overflow != null) elem.style.overflow = 'hidden';
    return this;
};
$.timers = [];
$.fx = function (elem, options, prop) {
    this.elem = elem;
    this.options = options;
    this.prop = prop;
};
$.fx.prototype = {
    custom: function (from, to, unit) {
		var that = this;
        that.startTime = $.fx.now();
        that.start = from;
        that.end = to;
        that.unit = unit;
        that.now = that.start;
        that.state = that.pos = 0;
        function t() {
            return that.step();
        };
        t.elem = that.elem;
		t();
        $.timers.push(t);
        if (!$.timerId) $.timerId = setInterval($.fx.tick, 13);
    },
    step: function () {
        var that = this, t = $.fx.now(), done = true;
		
        if (t >= that.options.speed + that.startTime) {
            that.now = that.end;
            that.state = that.pos = 1;
            that.update();
			
			that.options.curAnim[that.prop] = true;
			for (var i in that.options.curAnim) {
				if (that.options.curAnim[i] !== true) {
					done = false;
				};
			};
			
			if (done) that.options.callback.call(that.elem);
			
            return false;
        } else {
            var n = t - that.startTime;
            that.state = n / that.options.speed;
            that.pos = $.easing[that.options.easing](that.state, n, 0, 1, that.options.speed);
            that.now = that.start + ((that.end - that.start) * that.pos);
            that.update();
            return true;
        };
    },
    update: function () {
		var that = this;
		if (that.prop === 'opacity') {
			$.opacity.set(that.elem, that.now);
		} else
		if (that.elem.style && that.elem.style[that.prop] != null) {
			that.elem.style[that.prop] = that.now + that.unit;
		} else {
			that.elem[that.prop] = that.now;
		};
    }
};
$.fx.now = function () {
    return + new Date;
};
$.easing = {
    linear: function (p, n, firstNum, diff) {
        return firstNum + diff * p;
    },
    swing: function (p, n, firstNum, diff) {
        return ((-Math.cos(p * Math.PI) / 2) + 0.5) * diff + firstNum;
    }
};
$.fx.tick = function () {
	var timers = $.timers;
    for (var i = 0; i < timers.length; i++) {
        !timers[i]() && timers.splice(i--, 1);
    };
    !timers.length && $.fx.stop();
};
$.fx.stop = function () {
    clearInterval($.timerId);
    $.timerId = null;
};
$.fn.stop = function () {
	var timers = $.timers;
    for (var i = timers.length - 1; i >= 0; i--) {
    	if (timers[i].elem === this[0]) timers.splice(i, 1);
	};
    return this;
};
//-------------end
return $}(window));
//------------------------------------------------
// 对话框模块
//------------------------------------------------
;(function ($, window, undefined) {
$.noop = $.noop || function () {}; // jQuery 1.3.2
var _box, _thisScript, _skin, _path,
	_count = 0,
	_$window = $(window),
	_$document = $(document),
	_$html = $('html'),
	_elem = document.documentElement,
	_isIE6 = window.VBArray && !window.XMLHttpRequest,
	_isMobile = 'createTouch' in document && !('onmousemove' in _elem)
		|| /(iPhone|iPad|iPod)/i.test(navigator.userAgent),
	_expando = 'artDialog' + + new Date;
var artDialog = function (config, ok, cancel) {
	config = config || {};
	
	if (typeof config === 'string' || config.nodeType === 1) {
		config = {content: config, fixed: !_isMobile};
	};
	
	var api,
		defaults = artDialog.defaults,
		elem = config.follow = this.nodeType === 1 && this || config.follow;
		
	// 合并默认配置
	for (var i in defaults) {
		if (config[i] === undefined) config[i] = defaults[i];		
	};
	
	// 兼容v4.1.0之前的参数,未来版本将删除此
	$.each({ok:"yesFn",cancel:"noFn",close:"closeFn",init:"initFn",okVal:"yesText",cancelVal:"noText"},
	function(i,o){config[i]=config[i]!==undefined?config[i]:config[o]});
	
	// 返回跟随模式或重复定义的ID
	if (typeof elem === 'string') elem = $(elem)[0];
	config.id = elem && elem[_expando + 'follow'] || config.id || _expando + _count;
	api = artDialog.list[config.id];
	if (elem && api) return api.follow(elem).zIndex().focus();
	if (api) return api.zIndex().focus();
	
	// 目前主流移动设备对fixed支持不好
	if (_isMobile) config.fixed = false;
	
	// 按钮队列
	if (!$.isArray(config.button)) {
		config.button = config.button ? [config.button] : [];
	};
	if (ok !== undefined) config.ok = ok;
	if (cancel !== undefined) config.cancel = cancel;
	config.ok && config.button.push({
		name: config.okVal,
		callback: config.ok,
		focus: true
	});
	config.cancel && config.button.push({
		name: config.cancelVal,
		callback: config.cancel
	});
	
	// zIndex全局配置
	artDialog.defaults.zIndex = config.zIndex;
	
	_count ++;
	
	return artDialog.list[config.id] = _box ?
		_box._init(config) : new artDialog.fn._init(config);
};
artDialog.fn = artDialog.prototype = {
	version: '4.1.7',
	
	closed: true,
	
	_init: function (config) {
		var that = this, DOM,
			icon = config.icon,
			iconBg = icon && (_isIE6 ? {png: 'images/' + icon + '.png'}
			: {backgroundImage: 'url(\'' + 'images/' + icon + '.png\')'});
		var artIcon='';
		switch(config.artIcon)
        {
              case 'add':
			  	artIcon='<i class="art-icon icon-title-add"></i>';
                break;
              case 'edit':
			  	artIcon='<i class="art-icon icon-title-edit"></i>';
               	break;
              case 'ask':
			  	artIcon='<i class="art-icon icon-title-ask"></i>';
               	break;
              case 'error':
			  	artIcon='<i class="art-icon icon-title-error"></i>';
              	break;
        }
        that.closed = false;
		that.config = config;
		that.DOM = DOM = that.DOM || that._getDOM();
		
		DOM.wrap.addClass(config.skin);
		DOM.close[config.cancel === false ? 'hide' : 'show']();
		DOM.icon[0].style.display = icon ? '' : 'none';
		DOM.iconBg.css(iconBg || {background: 'none'});
		DOM.se.css('cursor', config.resize ? 'se-resize' : 'auto');
		DOM.title.css('cursor', config.drag ? 'move' : 'auto');
		DOM.content.css('padding', config.padding);
		
		that[config.show ? 'show' : 'hide'](true)
		that.button(config.button)
		.title(artIcon+config.title)
		.content(config.content, true)
		.size(config.width, config.height)
		.time(config.time);
		
		config.follow
		? that.follow(config.follow)
		: that.position(config.left, config.top);
		
		that.zIndex().focus();
		config.lock && that.lock();
		
		that._addEvent();
		that._ie6PngFix();
		_box = null;		
		if(config.tips){
			$('#aui_dialog_title').hide();
		}
		config.init && config.init.call(that, window);
		return that;
	},
	
	/**
	 * 设置内容
	 * @param	{String, HTMLElement}	内容 (可选)
	 * @return	{this, HTMLElement}		如果无参数则返回内容容器DOM对象
	 */
	content: function (msg) {
		var prev, next, parent, display,
			that = this,
			DOM = that.DOM,
			wrap = DOM.wrap[0],
			width = wrap.offsetWidth,
			height = wrap.offsetHeight,
			left = parseInt(wrap.style.left),
			top = parseInt(wrap.style.top),
			cssWidth = wrap.style.width,
			$content = DOM.content,
			content = $content[0];
		
		that._elemBack && that._elemBack();
		wrap.style.width = 'auto';
		
		if (msg === undefined) return content;
		if (typeof msg === 'string') {
			$content.html(msg);
		} else if (msg && msg.nodeType === 1) {
		
			// 让传入的元素在对话框关闭后可以返回到原来的地方
			display = msg.style.display;
			prev = msg.previousSibling;
			next = msg.nextSibling;
			parent = msg.parentNode;
			that._elemBack = function () {
				if (prev && prev.parentNode) {
					prev.parentNode.insertBefore(msg, prev.nextSibling);
				} else if (next && next.parentNode) {
					next.parentNode.insertBefore(msg, next);
				} else if (parent) {
					parent.appendChild(msg);
				};
				msg.style.display = display;
				that._elemBack = null;
			};
			
			$content.html('');
			content.appendChild(msg);
			msg.style.display = 'block';
			
		};
		
		// 新增内容后调整位置
		if (!arguments[1]) {
			if (that.config.follow) {
				that.follow(that.config.follow);
			} else {
				width = wrap.offsetWidth - width;
				height = wrap.offsetHeight - height;
				left = left - width / 2;
				top = top - height / 2;
				wrap.style.left = Math.max(left, 0) + 'px';
				wrap.style.top = Math.max(top, 0) + 'px';
			};
			if (cssWidth && cssWidth !== 'auto') {
				wrap.style.width = wrap.offsetWidth + 'px';
			};
			that._autoPositionType();
		};
		
		that._ie6SelectFix();
		that._runScript(content);
		
		return that;
	},
	
	/**
	 * 设置标题
	 * @param	{String, Boolean}	标题内容. 为false则隐藏标题栏
	 * @return	{this, HTMLElement}	如果无参数则返回内容器DOM对象
	 */
	title: function (text) {
		var DOM = this.DOM,
			wrap = DOM.wrap,
			title = DOM.title,
			className = 'aui_state_noTitle';
			
		if (text === undefined) return title[0];
		if (text === false) {
			title.hide().html('');
			wrap.addClass(className);
		} else {
			title.show().html(text || '');
			wrap.removeClass(className);
		};
		
		return this;
	},
	
	/**
	 * 位置(相对于可视区域)
	 * @param	{Number, String}
	 * @param	{Number, String}
	 */
	position: function (left, top) {
		var that = this,
			config = that.config,
			wrap = that.DOM.wrap[0],
			isFixed = _isIE6 ? false : config.fixed,
			ie6Fixed = _isIE6 && that.config.fixed,
			docLeft = _$document.scrollLeft(),
			docTop = _$document.scrollTop(),
			dl = isFixed ? 0 : docLeft,
			dt = isFixed ? 0 : docTop,
			ww = _$window.width(),
			wh = _$window.height(),
			ow = wrap.offsetWidth,
			oh = wrap.offsetHeight,
			style = wrap.style;
		
		if (left || left === 0) {
			that._left = left.toString().indexOf('%') !== -1 ? left : null;
			left = that._toNumber(left, ww - ow);
			
			if (typeof left === 'number') {
				left = ie6Fixed ? (left += docLeft) : left + dl;
				style.left = Math.max(left, dl) + 'px';
			} else if (typeof left === 'string') {
				style.left = left;
			};
		};
		
		if (top || top === 0) {
			that._top = top.toString().indexOf('%') !== -1 ? top : null;
			top = that._toNumber(top, wh - oh);
			
			if (typeof top === 'number') {
				top = ie6Fixed ? (top += docTop) : top + dt;
				style.top = Math.max(top, dt) + 'px';
			} else if (typeof top === 'string') {
				style.top = top;
			};
		};
		
		if (left !== undefined && top !== undefined) {
			that._follow = null;
			that._autoPositionType();
		};
		
		return that;
	},
	/**
	 *	尺寸
	 *	@param	{Number, String}	宽度
	 *	@param	{Number, String}	高度
	 */
	size: function (width, height) {
		var maxWidth, maxHeight, scaleWidth, scaleHeight,
			that = this,
			config = that.config,
			DOM = that.DOM,
			wrap = DOM.wrap,
			main = DOM.main,
			wrapStyle = wrap[0].style,
			style = main[0].style;
			
		if (width) {
			that._width = width.toString().indexOf('%') !== -1 ? width : null;
			maxWidth = _$window.width() - wrap[0].offsetWidth + main[0].offsetWidth;
			scaleWidth = that._toNumber(width, maxWidth);
			width = scaleWidth;
			
			if (typeof width === 'number') {
				wrapStyle.width = 'auto';
				style.width = Math.max(that.config.minWidth, width) + 'px';
				wrapStyle.width = wrap[0].offsetWidth + 'px'; // 防止未定义宽度的表格遇到浏览器右边边界伸缩
			} else if (typeof width === 'string') {
				style.width = width;
				width === 'auto' && wrap.css('width', 'auto');
			};
		};
		
		if (height) {
			that._height = height.toString().indexOf('%') !== -1 ? height : null;
			maxHeight = _$window.height() - wrap[0].offsetHeight + main[0].offsetHeight;
			scaleHeight = that._toNumber(height, maxHeight);
			height = scaleHeight;
			
			if (typeof height === 'number') {
				style.height = Math.max(that.config.minHeight, height) + 'px';
			} else if (typeof height === 'string') {
				style.height = height;
			};
		};
		
		that._ie6SelectFix();
		
		return that;
	},
	
	/**
	 * 跟随元素
	 * @param	{HTMLElement, String}
	 */
	follow: function (elem) {
		var $elem, that = this, config = that.config;
		
		if (typeof elem === 'string' || elem && elem.nodeType === 1) {
			$elem = $(elem);
			elem = $elem[0];
		};
		
		// 隐藏元素不可用
		if (!elem || !elem.offsetWidth && !elem.offsetHeight) {
			return that.position(that._left, that._top);
		};
		
		var expando = _expando + 'follow',
			winWidth = _$window.width(),
			winHeight = _$window.height(),
			docLeft =  _$document.scrollLeft(),
			docTop = _$document.scrollTop(),
			offset = $elem.offset(),
			width = elem.offsetWidth,
			height = elem.offsetHeight,
			isFixed = _isIE6 ? false : config.fixed,
			left = isFixed ? offset.left - docLeft : offset.left,
			top = isFixed ? offset.top - docTop : offset.top,
			wrap = that.DOM.wrap[0],
			style = wrap.style,
			wrapWidth = wrap.offsetWidth,
			wrapHeight = wrap.offsetHeight,
			setLeft = left - (wrapWidth - width) / 2,
			setTop = top + height,
			dl = isFixed ? 0 : docLeft,
			dt = isFixed ? 0 : docTop;
		
		setLeft = setLeft < dl ? left :
		(setLeft + wrapWidth > winWidth) && (left - wrapWidth > dl)
		? left - wrapWidth + width
		: setLeft;
		setTop = (setTop + wrapHeight > winHeight + dt)
		&& (top - wrapHeight > dt)
		? top - wrapHeight
		: setTop;
		
		style.left = setLeft + 'px';
		style.top = setTop + 'px';
		
		that._follow && that._follow.removeAttribute(expando);
		that._follow = elem;
		elem[expando] = config.id;
		that._autoPositionType();
		return that;
	},
	
	/**
	 * 自定义按钮
	 * @example
		button({
			name: 'login',
			callback: function () {},
			disabled: false,
			focus: true
		}, .., ..)
	 */
	button: function () {
		var that = this,
			ags = arguments,
			DOM = that.DOM,
			buttons = DOM.buttons,
			elem = buttons[0],
			strongButton = 'aui_state_highlight',
			listeners = that._listeners = that._listeners || {},
			list = $.isArray(ags[0]) ? ags[0] : [].slice.call(ags);
		
		if (ags[0] === undefined) return elem;
		$.each(list, function (i, val) {
			var name = val.name,
				isNewButton = !listeners[name],
				button = !isNewButton ?
					listeners[name].elem :
					document.createElement('button');
					
			if (!listeners[name]) listeners[name] = {};
			if (val.callback) listeners[name].callback = val.callback;
			if (val.className) button.className = val.className;
			if (val.focus) {
				that._focus && that._focus.removeClass(strongButton);
				that._focus = $(button).addClass(strongButton);
				that.focus();
			};
			
			// Internet Explorer 的默认类型是 "button",
			// 而其他浏览器中(包括 W3C 规范)的默认值是 "submit"
			// @see http://www.w3school.com.cn/tags/att_button_type.asp
			button.setAttribute('type', 'button');
			
			button[_expando + 'callback'] = name;
			button.disabled = !!val.disabled;
			if (isNewButton) {
				button.innerHTML = name;
				listeners[name].elem = button;
				elem.appendChild(button);
			};
		});
		
		buttons[0].style.display = list.length ? '' : 'none';
		
		that._ie6SelectFix();
		return that;
	},
	
	/** 显示对话框 */
	show: function () {
		
		this.DOM.wrap.show();
		!arguments[0] && this._lockMaskWrap && this._lockMaskWrap.show();
		return this;
	},
	
	/** 隐藏对话框 */
	hide: function () {
		this.DOM.wrap.hide();
		!arguments[0] && this._lockMaskWrap && this._lockMaskWrap.hide();
		return this;
	},
	
	/** 关闭对话框 */
	close: function () {
		if (this.closed) return this;
		var that = this,
			DOM = that.DOM,
			wrap = DOM.wrap,
			list = artDialog.list,
			fn = that.config.close,
			follow = that.config.follow;
		
		that.time();
		if (typeof fn === 'function' && fn.call(that, window) === false) {
			return that;
		};
		
		that.unlock();
		
		// 置空内容
		that._elemBack && that._elemBack();
		wrap[0].className = wrap[0].style.cssText = '';
		DOM.title.html('');
		DOM.content.html('');
		DOM.buttons.html('');
		
		if (artDialog.focus === that) artDialog.focus = null;
		if (follow) follow.removeAttribute(_expando + 'follow');
		delete list[that.config.id];
		that._removeEvent();
		that.hide(true)._setAbsolute();
		
		// 清空除this.DOM之外临时对象,恢复到初始状态,以便使用单例模式
		for (var i in that) {
			if (that.hasOwnProperty(i) && i !== 'DOM') delete that[i];
		};
		
		// 移除HTMLElement或重用
		//_box ? wrap.remove() : _box = that;
		wrap.remove();
		return that;
	},
	
	/**
	 * 定时关闭
	 * @param	{Number}	单位为秒, 无参数则停止计时器
	 */
	time: function (second) {
		var that = this,
			cancel = that.config.cancelVal,
			timer = that._timer;
			
		timer && clearTimeout(timer);
		
		if (second) {
			that._timer = setTimeout(function(){
				that._click(cancel);
			}, 1000 * second);
		};
		
		return that;
	},
	
	/** 设置焦点 */
	focus: function () {
		try {
			if (this.config.focus) {
				var elem = this._focus && this._focus[0] || this.DOM.close[0];
				elem && elem.focus();
			}
		} catch (e) {}; // IE对不可见元素设置焦点会报错
		return this;
	},
	
	/** 置顶对话框 */
	zIndex: function () {
		var that = this,
			DOM = that.DOM,
			wrap = DOM.wrap,
			top = artDialog.focus,
			index = artDialog.defaults.zIndex ++;
		
		// 设置叠加高度
		wrap.css('zIndex', index);
		that._lockMask && that._lockMask.css('zIndex', index - 1);
		
		// 设置最高层的样式
		top && top.DOM.wrap.removeClass('aui_state_focus');
		artDialog.focus = that;
		wrap.addClass('aui_state_focus');
		
		return that;
	},
	
	/** 设置屏锁 */
	lock: function () {
		if (this._lock) return this;
		
		var that = this,
			index = artDialog.defaults.zIndex - 1,
			wrap = that.DOM.wrap,
			config = that.config,
			docWidth = _$document.width(),
			docHeight = _$document.height(),
			lockMaskWrap = that._lockMaskWrap || $(document.body.appendChild(document.createElement('div'))),
			lockMask = that._lockMask || $(lockMaskWrap[0].appendChild(document.createElement('div'))),
			domTxt = '(document).documentElement',
			sizeCss = _isMobile ? 'width:' + docWidth + 'px;height:' + docHeight
				+ 'px' : 'width:100%;height:100%',
			ie6Css = _isIE6 ?
				'position:absolute;left:expression(' + domTxt + '.scrollLeft);top:expression('
				+ domTxt + '.scrollTop);width:expression(' + domTxt
				+ '.clientWidth);height:expression(' + domTxt + '.clientHeight)'
			: '';
		
		that.zIndex();
		wrap.addClass('aui_state_lock');
		
		lockMaskWrap[0].style.cssText = sizeCss + ';position:fixed;z-index:'
			+ index + ';top:0;left:0;overflow:hidden;' + ie6Css;
		lockMask[0].style.cssText = 'height:100%;background:' + config.background
			+ ';filter:alpha(opacity=0);opacity:0';
		
		// 让IE6锁屏遮罩能够盖住下拉控件
		if (_isIE6) lockMask.html(
			'<iframe src="about:blank" style="width:100%;height:100%;position:absolute;' +
			'top:0;left:0;z-index:-1;filter:alpha(opacity=0)"></iframe>');
			
		lockMask.stop();
		lockMask.bind('click', function () {
			that._reset();
		}).bind('dblclick', function () {
			return false;
			//that._click(that.config.cancelVal);
		});
		
		if (config.duration === 0) {
			lockMask.css({opacity: config.opacity});
		} else {
			lockMask.animate({opacity: config.opacity}, config.duration);
		};
		
		that._lockMaskWrap = lockMaskWrap;
		that._lockMask = lockMask;
		
		that._lock = true;
		return that;
	},
	
	/** 解开屏锁 */
	unlock: function () {
		var that = this,
			lockMaskWrap = that._lockMaskWrap,
			lockMask = that._lockMask;
		
		if (!that._lock) return that;
		var style = lockMaskWrap[0].style;
		var un = function () {
			if (_isIE6) {
				style.removeExpression('width');
				style.removeExpression('height');
				style.removeExpression('left');
				style.removeExpression('top');
			};
			style.cssText = 'display:none';
			
			_box && lockMaskWrap.remove();
		};
		
		lockMask.stop().unbind();
		that.DOM.wrap.removeClass('aui_state_lock');
		if (!that.config.duration) {// 取消动画,快速关闭
			un();
		} else {
			lockMask.animate({opacity: 0}, that.config.duration, un);
		};
		
		that._lock = false;
		return that;
	},
	
	// 获取元素
	_getDOM: function () {	
		var wrap = document.createElement('div'),
			body = document.body;
		wrap.style.cssText = 'position:absolute;left:0;top:0';
		wrap.innerHTML = artDialog._templates;
		body.insertBefore(wrap, body.firstChild);
		
		var name, i = 0,
			DOM = {wrap: $(wrap)},
			els = wrap.getElementsByTagName('*'),
			elsLen = els.length;
			
		for (; i < elsLen; i ++) {
			name = els[i].className.split('aui_')[1];
			if (name) DOM[name] = $(els[i]);
		};
		
		return DOM;
	},
	
	// px与%单位转换成数值 (百分比单位按照最大值换算)
	// 其他的单位返回原值
	_toNumber: function (thisValue, maxValue) {
		if (!thisValue && thisValue !== 0 || typeof thisValue === 'number') {
			return thisValue;
		};
		
		var last = thisValue.length - 1;
		if (thisValue.lastIndexOf('px') === last) {
			thisValue = parseInt(thisValue);
		} else if (thisValue.lastIndexOf('%') === last) {
			thisValue = parseInt(maxValue * thisValue.split('%')[0] / 100);
		};
		
		return thisValue;
	},
	
	// 让IE6 CSS支持PNG背景
	_ie6PngFix: _isIE6 ? function () {
		var i = 0, elem, png, pngPath, runtimeStyle,
			path = artDialog.defaults.path + '/skins/',
			list = this.DOM.wrap[0].getElementsByTagName('*');
		
		for (; i < list.length; i ++) {
			elem = list[i];
			png = elem.currentStyle['png'];
			if (png) {
				pngPath = path + png;
				runtimeStyle = elem.runtimeStyle;
				runtimeStyle.backgroundImage = 'none';
				runtimeStyle.filter = "progid:DXImageTransform.Microsoft." +
					"AlphaImageLoader(src='" + pngPath + "',sizingMethod='crop')";
			};
		};
	} : $.noop,
	
	// 强制覆盖IE6下拉控件
	_ie6SelectFix: _isIE6 ? function () {
		var $wrap = this.DOM.wrap,
			wrap = $wrap[0],
			expando = _expando + 'iframeMask',
			iframe = $wrap[expando],
			width = wrap.offsetWidth,
			height = wrap.offsetHeight;
		width = width + 'px';
		height = height + 'px';
		if (iframe) {
			iframe.style.width = width;
			iframe.style.height = height;
		} else {
			iframe = wrap.appendChild(document.createElement('iframe'));
			$wrap[expando] = iframe;
			iframe.src = 'about:blank';
			iframe.style.cssText = 'position:absolute;z-index:-1;left:0;top:0;'
			+ 'filter:alpha(opacity=0);width:' + width + ';height:' + height;
		};
	} : $.noop,
	
	// 解析HTML片段中自定义类型脚本,其this指向artDialog内部
	// <script type="text/dialog">/* [code] */</script>
	_runScript: function (elem) {
		var fun, i = 0, n = 0,
			tags = elem.getElementsByTagName('script'),
			length = tags.length,
			script = [];
			
		for (; i < length; i ++) {
			if (tags[i].type === 'text/dialog') {
				script[n] = tags[i].innerHTML;
				n ++;
			};
		};
		
		if (script.length) {
			script = script.join('');
			fun = new Function(script);
			fun.call(this);
		};
	},
	
	// 自动切换定位类型
	_autoPositionType: function () {
		this[this.config.fixed ? '_setFixed' : '_setAbsolute']();/////////////
	},
	
	
	// 设置静止定位
	// IE6 Fixed @see: http://www.planeart.cn/?p=877
	_setFixed: (function () {
		_isIE6 && $(function () {
			var bg = 'backgroundAttachment';
			if (_$html.css(bg) !== 'fixed' && $('body').css(bg) !== 'fixed') {
				_$html.css({
					zoom: 1,// 避免偶尔出现body背景图片异常的情况
					backgroundImage: 'url(about:blank)',
					backgroundAttachment: 'fixed'
				});
			};
		});
		
		return function () {
			var $elem = this.DOM.wrap,
				style = $elem[0].style;
			
			if (_isIE6) {
				var left = parseInt($elem.css('left')),
					top = parseInt($elem.css('top')),
					sLeft = _$document.scrollLeft(),
					sTop = _$document.scrollTop(),
					txt = '(document.documentElement)';
				
				this._setAbsolute();
				style.setExpression('left', 'eval(' + txt + '.scrollLeft + '
					+ (left - sLeft) + ') + "px"');
				style.setExpression('top', 'eval(' + txt + '.scrollTop + '
					+ (top - sTop) + ') + "px"');
			} else {
				style.position = 'fixed';
			};
		};
	}()),
	
	// 设置绝对定位
	_setAbsolute: function () {
		var style = this.DOM.wrap[0].style;
			
		if (_isIE6) {
			style.removeExpression('left');
			style.removeExpression('top');
		};
		style.position = 'absolute';
	},
	
	// 按钮回调函数触发
	_click: function (name) {
		var that = this,
			fn = that._listeners[name] && that._listeners[name].callback;
		return typeof fn !== 'function' || fn.call(that, window) !== false ?
			that.close() : that;
	},
	
	// 重置位置与尺寸
	_reset: function (test) {
		var newSize,
			that = this,
			oldSize = that._winSize || _$window.width() * _$window.height(),
			elem = that._follow,
			width = that._width,
			height = that._height,
			left = that._left,
			top = that._top;
		
		if (test) {
			// IE6~7 window.onresize bug
			newSize = that._winSize =  _$window.width() * _$window.height();
			if (oldSize === newSize) return;
		};
		
		if (width || height) that.size(width, height);
		
		if (elem) {
			that.follow(elem);
		} else if (left || top) {
			that.position(left, top);
		};
	},
	
	// 事件代理
	_addEvent: function () {
		var resizeTimer,
			that = this,
			config = that.config,
			isIE = 'CollectGarbage' in window,
			DOM = that.DOM;
		
		// 窗口调节事件
		that._winResize = function () {
			resizeTimer && clearTimeout(resizeTimer);
			resizeTimer = setTimeout(function () {
				that._reset(isIE);
			}, 40);
		};
		_$window.bind('resize', that._winResize);
		
		// 监听点击
		DOM.wrap
		.bind('click', function (event) {
			var target = event.target, callbackID;
			
			if (target.disabled) return false; // IE BUG
			
			if (target === DOM.close[0]) {
				that._click(config.cancelVal);
				return false;
			} else {
				callbackID = target[_expando + 'callback'];
				callbackID && that._click(callbackID);
			};
			
			that._ie6SelectFix();
		})
		.bind('mousedown', function () {
			that.zIndex();
		});
	},
	
	// 卸载事件代理
	_removeEvent: function () {
		var that = this,
			DOM = that.DOM;
		
		DOM.wrap.unbind();
		_$window.unbind('resize', that._winResize);
	}
	
};
artDialog.fn._init.prototype = artDialog.fn;
$.fn.dialog = $.fn.artDialog = function () {
	var config = arguments;
	this[this.live ? 'live' : 'bind']('click', function () {
		artDialog.apply(this, config);
		return false;
	});
	return this;
};
/** 最顶层的对话框API */
artDialog.focus = null;
/** 获取某对话框API */
artDialog.get = function (id) {
	return id === undefined
	? artDialog.list
	: artDialog.list[id];
};
artDialog.list = {};
// 全局快捷键
_$document.bind('keydown', function (event) {
	var target = event.target,
		nodeName = target.nodeName,
		rinput = /^INPUT|TEXTAREA$/,
		api = artDialog.focus,
		keyCode = event.keyCode;
	if (!api || !api.config.esc || rinput.test(nodeName)) return;
		
	keyCode === 27 && api._click(api.config.cancelVal);
});
// 获取artDialog路径
_path = window['_artDialog_path'] || (function (script, i, me) {
	for (i in script) {
		// 如果通过第三方脚本加载器加载本文件,请保证文件名含有"artDialog"字符
		if (script[i].src && script[i].src.indexOf('artDialog') !== -1) me = script[i];
	};
	
	_thisScript = me || script[script.length - 1];
	me = _thisScript.src.replace(/\\/g, '/');
	return me.lastIndexOf('/') < 0 ? '.' : me.substring(0, me.lastIndexOf('/'));
}(document.getElementsByTagName('script')));
// 无阻塞载入CSS (如"artDialog.js?skin=aero")
_skin = _thisScript.src.split('skin=')[1];
if (_skin) {
	var link = document.createElement('link');
	link.rel = 'stylesheet';
	link.href = _path + '/skins/' + _skin + '.css?' + artDialog.fn.version;
	_thisScript.parentNode.insertBefore(link, _thisScript);
};
// 触发浏览器预先缓存背景图片
_$window.bind('load', function () {
	setTimeout(function () {
		if (_count) return;
		//artDialog({left: '-9999em',time: 0,fixed: false,lock: false,focus: false});
	}, 150);
});
// 开启IE6 CSS背景图片缓存
try {
	document.execCommand('BackgroundImageCache', false, true);
} catch (e) {};
// 使用uglifyjs压缩能够预先处理"+"号合并字符串
// uglifyjs: http://marijnhaverbeke.nl/uglifyjs
artDialog._templates =
'<div class="aui_outer">'
+	'<table class="aui_border">'
+		'<tbody>'
+			'<tr>'
+				'<td class="aui_nw"></td>'
+				'<td class="aui_n"></td>'
+				'<td class="aui_ne"></td>'
+			'</tr>'
+			'<tr>'
+				'<td class="aui_w"></td>'
+				'<td class="aui_c">'
+					'<div class="aui_inner">'
+					'<table class="aui_dialog">'
+						'<tbody>'
+							'<tr id="aui_dialog_title">'
+								'<td colspan="2" class="aui_header">'
+									'<div class="aui_titleBar">'
+										'<div class="aui_title"></div>'
+										'<a class="aui_close" href="javascript:/*artDialog*/;">'
+											'\xd7'
+										'</a>'
+									'</div>'
+								'</td>'
+							'</tr>'
+							'<tr>'
+								'<td class="aui_icon">'
+									'<div class="aui_iconBg"></div>'
+								'</td>'
+								'<td class="aui_main">'
+									'<div class="aui_content"></div>'
+								'</td>'
+							'</tr>'
+							'<tr>'
+								'<td colspan="2" class="aui_footer">'
+									'<div class="aui_buttons"></div>'
+								'</td>'
+							'</tr>'
+						'</tbody>'
+					'</table>'
+					'</div>'
+				'</td>'
+				'<td class="aui_e"></td>'
+			'</tr>'
+			'<tr>'
+				'<td class="aui_sw"></td>'
+				'<td class="aui_s"></td>'
+				'<td class="aui_se"></td>'
+			'</tr>'
+		'</tbody>'
+	'</table>'
+'</div>';
/**
 * 默认配置
 */
artDialog.defaults = {
								// 消息内容
	content: '<div class="aui_loading"><span>loading..</span></div>',
	title: '\u6d88\u606f',		// 标题. 默认'消息'
	button: null,				// 自定义按钮
	ok: null,					// 确定按钮回调函数
	cancel: null,				// 取消按钮回调函数
	init: null,					// 对话框初始化后执行的函数
	close: null,				// 对话框关闭前执行的函数
	okVal: '\u786E\u5B9A',		// 确定按钮文本. 默认'确定'
	cancelVal: '\u53D6\u6D88',	// 取消按钮文本. 默认'取消'
	width: 'auto',				// 内容宽度
	height: 'auto',				// 内容高度
	minWidth: 96,				// 最小宽度限制
	minHeight: 32,				// 最小高度限制
	padding: '20px 25px',		// 内容与边界填充距离
	skin: '',					// 皮肤名(预留接口,尚未实现)
	icon: null,					// 消息图标名称
	time: null,					// 自动关闭时间
	esc: true,					// 是否支持Esc键关闭
	focus: true,				// 是否支持对话框按钮自动聚焦
	show: true,					// 初始化后是否显示对话框
	follow: null,				// 跟随某元素(即让对话框在元素附近弹出)
	path: _path,				// artDialog路径
	lock: false,				// 是否锁屏
	background: '#000',			// 遮罩颜色
	opacity: .7,				// 遮罩透明度
	duration: 300,				// 遮罩透明度渐变动画速度
	fixed: false,				// 是否静止定位
	left: '50%',				// X轴坐标
	top: '38.2%',				// Y轴坐标
	zIndex: 1987,				// 对话框叠加高度值(重要:此值不能超过浏览器最大限制)
	resize: true,				// 是否允许用户调节尺寸
	drag: true,				// 是否允许用户拖动位置
	artIcon: '',        //标题旁边的图标,
	tips: false
	
};
window.artDialog = $.dialog = $.artDialog = artDialog;
}(this.art || this.jQuery && (this.art = jQuery), this));
//------------------------------------------------
// 对话框模块-拖拽支持(可选外置模块)
//------------------------------------------------
;(function ($) {
var _dragEvent, _use,
	_$window = $(window),
	_$document = $(document),
	_elem = document.documentElement,
	_isIE6 = !('minWidth' in _elem.style),
	_isLosecapture = 'onlosecapture' in _elem,
	_isSetCapture = 'setCapture' in _elem;
// 拖拽事件
artDialog.dragEvent = function () {
	var that = this,
		proxy = function (name) {
			var fn = that[name];
			that[name] = function () {
				return fn.apply(that, arguments);
			};
		};
		
	proxy('start');
	proxy('move');
	proxy('end');
};
artDialog.dragEvent.prototype = {
	// 开始拖拽
	onstart: $.noop,
	start: function (event) {
		_$document
		.bind('mousemove', this.move)
		.bind('mouseup', this.end);
			
		this._sClientX = event.clientX;
		this._sClientY = event.clientY;
		this.onstart(event.clientX, event.clientY);
		return false;
	},
	
	// 正在拖拽
	onmove: $.noop,
	move: function (event) {		
		this._mClientX = event.clientX;
		this._mClientY = event.clientY;
		this.onmove(
			event.clientX - this._sClientX,
			event.clientY - this._sClientY
		);
		
		return false;
	},
	
	// 结束拖拽
	onend: $.noop,
	end: function (event) {
		_$document
		.unbind('mousemove', this.move)
		.unbind('mouseup', this.end);
		
		this.onend(event.clientX, event.clientY);
		return false;
	}
	
};
_use = function (event) {
	var limit, startWidth, startHeight, startLeft, startTop, isResize,
		api = artDialog.focus,
		//config = api.config,
		DOM = api.DOM,
		wrap = DOM.wrap,
		title = DOM.title,
		main = DOM.main;
	// 清除文本选择
	var clsSelect = 'getSelection' in window ? function () {
		window.getSelection().removeAllRanges();
	} : function () {
		try {
			document.selection.empty();
		} catch (e) {};
	};
	
	// 对话框准备拖动
	_dragEvent.onstart = function (x, y) {
		if (isResize) {
			startWidth = main[0].offsetWidth;
			startHeight = main[0].offsetHeight;
		} else {
			startLeft = wrap[0].offsetLeft;
			startTop = wrap[0].offsetTop;
		};
		
		_$document.bind('dblclick', _dragEvent.end);
		!_isIE6 && _isLosecapture ?
			title.bind('losecapture', _dragEvent.end) :
			_$window.bind('blur', _dragEvent.end);
		_isSetCapture && title[0].setCapture();
		
		wrap.addClass('aui_state_drag');
		api.focus();
	};
	
	// 对话框拖动进行中
	_dragEvent.onmove = function (x, y) {
		if (isResize) {
			var wrapStyle = wrap[0].style,
				style = main[0].style,
				width = x + startWidth,
				height = y + startHeight;
			
			wrapStyle.width = 'auto';
			style.width = Math.max(0, width) + 'px';
			wrapStyle.width = wrap[0].offsetWidth + 'px';
			
			style.height = Math.max(0, height) + 'px';
			
		} else {
			var style = wrap[0].style,
				left = Math.max(limit.minX, Math.min(limit.maxX, x + startLeft)),
				top = Math.max(limit.minY, Math.min(limit.maxY, y + startTop));
			style.left = left  + 'px';
			style.top = top + 'px';
		};
			
		clsSelect();
		api._ie6SelectFix();
	};
	
	// 对话框拖动结束
	_dragEvent.onend = function (x, y) {
		_$document.unbind('dblclick', _dragEvent.end);
		!_isIE6 && _isLosecapture ?
			title.unbind('losecapture', _dragEvent.end) :
			_$window.unbind('blur', _dragEvent.end);
		_isSetCapture && title[0].releaseCapture();
		
		_isIE6 && !api.closed && api._autoPositionType();
		
		wrap.removeClass('aui_state_drag');
	};
	
	isResize = event.target === DOM.se[0] ? true : false;
	limit = (function () {
		var maxX, maxY,
			wrap = api.DOM.wrap[0],
			fixed = wrap.style.position === 'fixed',
			ow = wrap.offsetWidth,
			oh = wrap.offsetHeight,
			ww = _$window.width(),
			wh = _$window.height(),
			dl = fixed ? 0 : _$document.scrollLeft(),
			dt = fixed ? 0 : _$document.scrollTop(),
			
		// 坐标最大值限制
		maxX = ww - ow + dl;
		maxY = wh - oh + dt;
		
		return {
			minX: dl,
			minY: dt,
			maxX: maxX,
			maxY: maxY
		};
	})();
	
	_dragEvent.start(event);
};
// 代理 mousedown 事件触发对话框拖动
_$document.bind('mousedown', function (event) {
	var api = artDialog.focus;
	if (!api) return;
	var target = event.target,
		config = api.config,
		DOM = api.DOM;
	
	if (config.drag !== false && target === DOM.title[0]
	|| config.resize !== false && target === DOM.se[0]) {
		_dragEvent = _dragEvent || new artDialog.dragEvent();
		_use(event);
		return false;// 防止firefox与chrome滚屏
	};
});
})(this.art || this.jQuery && (this.art = jQuery));

+ 58 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/css/doc.css

@ -0,0 +1,58 @@
.doc-line {
	height: 3px;
}
.doc-gotop {
	position: fixed;
	bottom: 5px;
	right: 5px;
	z-index: 9;
}
h1 span[id],
h2 span[id],
h3 span[id],
h4 span[id],
h5 span[id],
h6 span[id] {
	cursor: pointer;
}
/*避免对话框样式被工具生成的全局样式污染*/
.ui-dialog table,
.ui-dialog table tr,
.ui-dialog tr td,
.ui-dialog tr:nth-child(2n) {
	border: 0 none;
	background: transparent;
}
.ui-dialog td.ui-dialog-header {
	border-bottom: 1px solid #E5E5E5;
}
code.sh_sourceCode { color: #000000; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_keyword { color: #009; font-weight: bold; font-style: normal; }
code.sh_sourceCode .sh_type { color: #0000ff; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_string { color: #00F; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_regexp { color: #060; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_specialchar { color: #C42DA8; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_comment { color: #999; font-weight: normal; font-style: italic; }
code.sh_sourceCode .sh_number { color: #F00; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_codeproc { color: #00b800; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_symbol { color: #009; font-weight: bold; font-style: normal; }
code.sh_sourceCode .sh_function { color: #000; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_cbracket { color: #009; font-weight: bold; font-style: normal; }
code.sh_sourceCode .sh_url { color: #ff0000; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_date { color: #0000ff; font-weight: bold; font-style: normal; }
code.sh_sourceCode .sh_time { color: #0000ff; font-weight: bold; font-style: normal; }
code.sh_sourceCode .sh_file { color: #0000ff; font-weight: bold; font-style: normal; }
code.sh_sourceCode .sh_ip { color: #ff0000; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_name { color: #ff0000; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_variable { color: #ec7f15; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_oldfile { color: #C42DA8; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_newfile { color: #ff0000; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_difflines { color: #0000ff; font-weight: bold; font-style: normal; }
code.sh_sourceCode .sh_selector { color: #ec7f15; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_property { color: #0000ff; font-weight: bold; font-style: normal; }
code.sh_sourceCode .sh_value { color: #ff0000; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_codedef_var { color: #909; font-weight: normal; font-style: normal; }
code.sh_sourceCode .sh_codedef_func { color: #099; font-weight: normal; font-style: normal; }

+ 435 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/css/ui-dialog.css

@ -0,0 +1,435 @@
/*!
 * ui-dialog.css
 * Date: 2014-07-03
 * https://github.com/aui/artDialog
 * (c) 2009-2014 TangBin, http://www.planeArt.cn
 *
 * This is licensed under the GNU LGPL, version 2.1 or later.
 * For details, see: http://www.gnu.org/licenses/lgpl-2.1.html
*/
.ui-popup-full{
    width:100%;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    padding:0 15px !important;
    left:0 !important;
}
.ui-dialog {
    *zoom:1;
    _float: left;
    position: relative;
    background-color: #FFF;
    border: 1px solid #999;
    border-radius: 6px;
    outline: 0;
    background-clip: padding-box;
    font-family: Helvetica, arial, sans-serif;
    font-size: 14px;
    line-height: 1.428571429;
    color: #333;
    opacity: 0;
    -webkit-transform: scale(0);
    transform: scale(0);
    -webkit-transition: -webkit-transform .15s ease-in-out, opacity .15s ease-in-out;
    transition: transform .15s ease-in-out, opacity .15s ease-in-out;
	padding:0 10px;
}
.ui-popup-show .ui-dialog {
    opacity: 1;
    -webkit-transform: scale(1);
    transform: scale(1);
}
.ui-popup-focus .ui-dialog {
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
}
.ui-popup-modal .ui-dialog {
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.1), 0 0 256px rgba(255, 255, 255, .3);
}
.ui-dialog-grid {
    width: 100%;
    margin: 0;
    border: 0 none;
    border-collapse:collapse;
    border-spacing: 0;
    background: transparent;
}
.ui-dialog-header,
.ui-dialog-body,
.ui-dialog-footer {
    padding: 0;
    border: 0 none;
    text-align: left;
    background: transparent;
}
.ui-dialog-header {
    white-space: nowrap;
    border-bottom: 1px solid #E5E5E5;
}
.ui-dialog-close {
    position: relative;
    _position: absolute;
    float: right;
    top: 13px;
    right: 13px;
    _height: 26px;
    padding: 0 4px;
    font-size: 21px;
    font-weight: bold;
    line-height: 1;
    color: #000;
    text-shadow: 0 1px 0 #FFF;
    opacity: .2;
    filter: alpha(opacity=20);
    cursor: pointer;
    background: transparent;
    _background: #FFF;
    border: 0;
    -webkit-appearance: none;
}
.ui-dialog-close:hover,
.ui-dialog-close:focus {
    color: #000000;
    text-decoration: none;
    cursor: pointer;
    outline: 0;
    opacity: 0.5;
    filter: alpha(opacity=50);
}
.ui-dialog-title {
    margin: 0;
    line-height: 1.428571429;
    min-height: 16.428571429px;
    padding: 15px;
    overflow:hidden; 
    white-space: nowrap;
    text-overflow: ellipsis;
    font-weight: bold;
    cursor: default;
}
.ui-dialog-body {
    padding: 20px;
    text-align: center;
}
.ui-dialog-content {
    display: inline-block;
    position: relative;
    vertical-align: middle;
    *zoom: 1;
    *display: inline;
    text-align: left;
}
.ui-dialog-footer {
    padding: 0 20px 20px 20px;
}
.ui-dialog-statusbar {
    float: left;
    margin-right: 20px;
    padding: 6px 0;
    line-height: 1.428571429;
    font-size: 14px;
    color: #888;
    white-space: nowrap;
}
.ui-dialog-statusbar label:hover {
    color: #333;
}
.ui-dialog-statusbar input,
.ui-dialog-statusbar .label {
    vertical-align: middle;
}
.ui-dialog-button {
    float: right;
    white-space: nowrap;
}
.ui-dialog-footer button+button {
    margin-bottom: 0;
    margin-left: 5px;
}
.ui-dialog-footer button {
    width:auto;
    overflow:visible;
    display: inline-block;
    padding: 6px 12px;
    _margin-left: 5px;
    margin-bottom: 0;
    font-size: 14px;
    font-weight: normal;
    line-height: 1.428571429;
    text-align: center;
    white-space: nowrap;
    vertical-align: middle;
    cursor: pointer;
    background-image: none;
    border: 1px solid transparent;
    border-radius: 4px;
    -webkit-user-select: none;
     -moz-user-select: none;
      -ms-user-select: none;
       -o-user-select: none;
          user-select: none;
}
.ui-dialog-footer button:focus {
  outline: thin dotted #333;
  outline: 5px auto -webkit-focus-ring-color;
  outline-offset: -2px;
}
.ui-dialog-footer button:hover,
.ui-dialog-footer button:focus {
  color: #333333;
  text-decoration: none;
}
.ui-dialog-footer button:active {
  background-image: none;
  outline: 0;
  -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
          box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
}
.ui-dialog-footer button[disabled] {
  pointer-events: none;
  cursor: not-allowed;
  opacity: 0.65;
  filter: alpha(opacity=65);
  -webkit-box-shadow: none;
          box-shadow: none;
}
.ui-dialog-footer button {
  color: #333333;
  background-color: #ffffff;
  border-color: #cccccc;
}
.ui-dialog-footer button:hover,
.ui-dialog-footer button:focus,
.ui-dialog-footer button:active {
  color: #333333;
  background-color: #ebebeb;
  border-color: #adadad;
}
.ui-dialog-footer button:active{
  background-image: none;
}
.ui-dialog-footer button[disabled],
.ui-dialog-footer button[disabled]:hover,
.ui-dialog-footer button[disabled]:focus,
.ui-dialog-footer button[disabled]:active {
  background-color: #ffffff;
  border-color: #cccccc;
}
.ui-dialog-footer button.ui-dialog-autofocus {
  color: #ffffff;
  background-color: #428bca;
  border-color: #357ebd;
}
.ui-dialog-footer button.ui-dialog-autofocus:hover,
.ui-dialog-footer button.ui-dialog-autofocus:focus,
.ui-dialog-footer button.ui-dialog-autofocus:active {
  color: #ffffff;
  background-color: #3276b1;
  border-color: #285e8e;
}
.ui-dialog-footer button.ui-dialog-autofocus:active {
  background-image: none;
}
.ui-popup-top-left .ui-dialog,
.ui-popup-top .ui-dialog,
.ui-popup-top-right .ui-dialog {
    top: -8px;
}
.ui-popup-bottom-left .ui-dialog,
.ui-popup-bottom .ui-dialog,
.ui-popup-bottom-right .ui-dialog {
    top: 8px;
}
.ui-popup-left-top .ui-dialog,
.ui-popup-left .ui-dialog,
.ui-popup-left-bottom .ui-dialog {
    left: -8px;
}
.ui-popup-right-top .ui-dialog,
.ui-popup-right .ui-dialog,
.ui-popup-right-bottom .ui-dialog {
    left: 8px;
}
.ui-dialog-arrow-a,
.ui-dialog-arrow-b {
    position: absolute;
    display: none;
    width: 0;
    height: 0;
    overflow:hidden;
    _color:#FF3FFF;
    _filter:chroma(color=#FF3FFF);
    border:8px dashed transparent;
}
.ui-popup-follow .ui-dialog-arrow-a,
.ui-popup-follow .ui-dialog-arrow-b{
    display: block;
}
.ui-popup-top-left .ui-dialog-arrow-a,
.ui-popup-top .ui-dialog-arrow-a,
.ui-popup-top-right .ui-dialog-arrow-a {
    bottom: -16px;
    border-top:8px solid #7C7C7C;
}
.ui-popup-top-left .ui-dialog-arrow-b,
.ui-popup-top .ui-dialog-arrow-b,
.ui-popup-top-right .ui-dialog-arrow-b {
    bottom: -15px;
    border-top:8px solid #fff;
}
.ui-popup-top-left .ui-dialog-arrow-a,
.ui-popup-top-left .ui-dialog-arrow-b  {
    left: 15px;
}
.ui-popup-top .ui-dialog-arrow-a,
.ui-popup-top .ui-dialog-arrow-b  {
    left: 50%;
    margin-left: -8px;
}
.ui-popup-top-right .ui-dialog-arrow-a,
.ui-popup-top-right .ui-dialog-arrow-b {
    right: 15px;
}
.ui-popup-bottom-left .ui-dialog-arrow-a,
.ui-popup-bottom .ui-dialog-arrow-a,
.ui-popup-bottom-right .ui-dialog-arrow-a {
    top: -16px;
    border-bottom:8px solid #7C7C7C;
}
.ui-popup-bottom-left .ui-dialog-arrow-b,
.ui-popup-bottom .ui-dialog-arrow-b,
.ui-popup-bottom-right .ui-dialog-arrow-b {
    top: -15px;
    border-bottom:8px solid #fff;
}
.ui-popup-bottom-left .ui-dialog-arrow-a,
.ui-popup-bottom-left .ui-dialog-arrow-b {
    left: 15px;
}
.ui-popup-bottom .ui-dialog-arrow-a,
.ui-popup-bottom .ui-dialog-arrow-b {
    margin-left: -8px;
    left: 50%;
}
.ui-popup-bottom-right .ui-dialog-arrow-a,
.ui-popup-bottom-right .ui-dialog-arrow-b {
    right: 15px;
}
.ui-popup-left-top .ui-dialog-arrow-a,
.ui-popup-left .ui-dialog-arrow-a,
.ui-popup-left-bottom .ui-dialog-arrow-a {
    right: -16px;
    border-left:8px solid #7C7C7C;
}
.ui-popup-left-top .ui-dialog-arrow-b,
.ui-popup-left .ui-dialog-arrow-b,
.ui-popup-left-bottom .ui-dialog-arrow-b {
    right: -15px;
    border-left:8px solid #fff;
}
.ui-popup-left-top .ui-dialog-arrow-a,
.ui-popup-left-top .ui-dialog-arrow-b {
    top: 15px;
}
.ui-popup-left .ui-dialog-arrow-a,
.ui-popup-left .ui-dialog-arrow-b {
    margin-top: -8px;
    top: 50%;
}
.ui-popup-left-bottom .ui-dialog-arrow-a,
.ui-popup-left-bottom .ui-dialog-arrow-b {
    bottom: 15px;
}
.ui-popup-right-top .ui-dialog-arrow-a,
.ui-popup-right .ui-dialog-arrow-a,
.ui-popup-right-bottom .ui-dialog-arrow-a {
    left: -16px;
    border-right:8px solid #7C7C7C;
}
.ui-popup-right-top .ui-dialog-arrow-b,
.ui-popup-right .ui-dialog-arrow-b,
.ui-popup-right-bottom .ui-dialog-arrow-b {
    left: -15px;
    border-right:8px solid #fff;
}
.ui-popup-right-top .ui-dialog-arrow-a,
.ui-popup-right-top .ui-dialog-arrow-b {
    top: 15px;
}
.ui-popup-right .ui-dialog-arrow-a,
.ui-popup-right .ui-dialog-arrow-b {
    margin-top: -8px;
    top: 50%;
}
.ui-popup-right-bottom .ui-dialog-arrow-a,
.ui-popup-right-bottom .ui-dialog-arrow-b {
    bottom: 15px;
}
@-webkit-keyframes ui-dialog-loading {
    0% {
        -webkit-transform: rotate(0deg);
    }
    100% {
        -webkit-transform: rotate(360deg);
    }
}
@keyframes ui-dialog-loading {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}
.ui-dialog-loading {
    vertical-align: middle;
    position: relative;
    display: block;
    *zoom: 1;
    *display: inline;
    overflow: hidden;
    width: 32px;
    height: 32px;
    top: 50%;
    margin: -16px auto 0 auto;
    font-size: 0;
    text-indent: -999em;
    color: #666;
}
.ui-dialog-loading {
    width: 100%\9;
    text-indent: 0\9;
    line-height: 32px\9;
    text-align: center\9;
    font-size: 12px\9;
}
.ui-dialog-loading::after {
    position: absolute;
    content: '';
    width: 3px;
    height: 3px;
    margin: 14.5px 0 0 14.5px;
    border-radius: 100%;
    box-shadow: 0 -10px 0 1px #ccc, 10px 0px #ccc, 0 10px #ccc, -10px 0 #ccc, -7px -7px 0 0.5px #ccc, 7px -7px 0 1.5px #ccc, 7px 7px #ccc, -7px 7px #ccc;
    -webkit-transform: rotate(360deg);
    -webkit-animation: ui-dialog-loading 1.5s infinite linear;
    transform: rotate(360deg);
    animation: ui-dialog-loading 1.5s infinite linear;
    display: none\9;
}

Разлика између датотеке није приказан због своје велике величине
+ 1314 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/index.html


+ 1648 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/js/dialog-plus.js

@ -0,0 +1,1648 @@
/*! artDialog v6.0.5 | https://github.com/aui/artDialog */
!(function () {
var __modules__ = {};
function require (id) {
    var mod = __modules__[id];
    var exports = 'exports';
    if (typeof mod === 'object') {
        return mod;
    }
    if (!mod[exports]) {
        mod[exports] = {};
        mod[exports] = mod.call(mod[exports], require, mod[exports], mod) || mod[exports];
    }
    return mod[exports];
}
function define (path, fn) {
    __modules__[path] = fn;
}
define("jquery", function () {
	return jQuery;
});
/*!
 * PopupJS
 * Date: 2014-11-09
 * https://github.com/aui/popupjs
 * (c) 2009-2014 TangBin, http://www.planeArt.cn
 *
 * This is licensed under the GNU LGPL, version 2.1 or later.
 * For details, see: http://www.gnu.org/licenses/lgpl-2.1.html
 */
define("popup", function (require) {
var $ = require("jquery");
var _count = 0;
var _isIE6 = !('minWidth' in $('html')[0].style);
var _isFixed = !_isIE6;
function Popup () {
    this.destroyed = false;
    this.__popup = $('<div />')
    /*使用 <dialog /> 元素可能导致 z-index 永远置顶的问题(chrome)*/
    .css({
        display: 'none',
        position: 'absolute',
        /*
        left: 0,
        top: 0,
        bottom: 'auto',
        right: 'auto',
        margin: 0,
        padding: 0,
        border: '0 none',
        background: 'transparent'
        */
        outline: 0
    })
    .attr('tabindex', '-1')
    .html(this.innerHTML)
    .appendTo('body');
    this.__backdrop = this.__mask = $('<div />')
    .css({
        opacity: .7,
        background: '#000'
    });
    // 使用 HTMLElement 作为外部接口使用,而不是 jquery 对象
    // 统一的接口利于未来 Popup 移植到其他 DOM 库中
    this.node = this.__popup[0];
    this.backdrop = this.__backdrop[0];
    _count ++;
}
$.extend(Popup.prototype, {
    
    /**
     * 初始化完毕事件,在 show()、showModal() 执行
     * @name Popup.prototype.onshow
     * @event
     */
    /**
     * 关闭事件,在 close() 执行
     * @name Popup.prototype.onclose
     * @event
     */
    /**
     * 销毁前事件,在 remove() 前执行
     * @name Popup.prototype.onbeforeremove
     * @event
     */
    /**
     * 销毁事件,在 remove() 执行
     * @name Popup.prototype.onremove
     * @event
     */
    /**
     * 重置事件,在 reset() 执行
     * @name Popup.prototype.onreset
     * @event
     */
    /**
     * 焦点事件,在 foucs() 执行
     * @name Popup.prototype.onfocus
     * @event
     */
    /**
     * 失焦事件,在 blur() 执行
     * @name Popup.prototype.onblur
     * @event
     */
    /** 浮层 DOM 素节点[*] */
    node: null,
    /** 遮罩 DOM 节点[*] */
    backdrop: null,
    /** 是否开启固定定位[*] */
    fixed: false,
    /** 判断对话框是否删除[*] */
    destroyed: true,
    /** 判断对话框是否显示 */
    open: false,
    /** close 返回值 */
    returnValue: '',
    /** 是否自动聚焦 */
    autofocus: true,
    /** 对齐方式[*] */
    align: 'bottom left',
    /** 内部的 HTML 字符串 */
    innerHTML: '',
    /** CSS 类名 */
    className: 'ui-popup',
    /**
     * 显示浮层
     * @param   {HTMLElement, Event}  指定位置(可选)
     */
    show: function (anchor) {
        if (this.destroyed) {
            return this;
        }
        var that = this;
        var popup = this.__popup;
        var backdrop = this.__backdrop;
        this.__activeElement = this.__getActive();
        this.open = true;
        this.follow = anchor || this.follow;
        // 初始化 show 方法
        if (!this.__ready) {
            popup
            .addClass(this.className)
            .attr('role', this.modal ? 'alertdialog' : 'dialog')
            .css('position', this.fixed ? 'fixed' : 'absolute');
            if (!_isIE6) {
                $(window).on('resize', $.proxy(this.reset, this));
            }
            // 模态浮层的遮罩
            if (this.modal) {
                var backdropCss = {
                    position: 'fixed',
                    left: 0,
                    top: 0,
                    width: '100%',
                    height: '100%',
                    overflow: 'hidden',
                    userSelect: 'none',
                    zIndex: this.zIndex || Popup.zIndex
                };
                popup.addClass(this.className + '-modal');
                if (!_isFixed) {
                    $.extend(backdropCss, {
                        position: 'absolute',
                        width: $(window).width() + 'px',
                        height: $(document).height() + 'px'
                    });
                }
                backdrop
                .css(backdropCss)
                .attr({tabindex: '0'})
                .on('focus', $.proxy(this.focus, this));
                // 锁定 tab 的焦点操作
                this.__mask = backdrop
                .clone(true)
                .attr('style', '')
                .insertAfter(popup);
                backdrop
                .addClass(this.className + '-backdrop')
                .insertBefore(popup);
                this.__ready = true;
            }
            if (!popup.html()) {
                popup.html(this.innerHTML);
            }
        }
        popup
        .addClass(this.className + '-show')
        .show();
        backdrop.show();
        this.reset().focus();
        this.__dispatchEvent('show');
        return this;
    },
    /** 显示模态浮层。参数参见 show() */
    showModal: function () {
        this.modal = true;
        return this.show.apply(this, arguments);
    },
    
    
    /** 关闭浮层 */
    close: function (result) {
        
        if (!this.destroyed && this.open) {
            
            if (result !== undefined) {
                this.returnValue = result;
            }
            
            this.__popup.hide().removeClass(this.className + '-show');
            this.__backdrop.hide();
            this.open = false;
            this.blur();// 恢复焦点,照顾键盘操作的用户
            this.__dispatchEvent('close');
        }
    
        return this;
    },
    /** 销毁浮层 */
    remove: function () {
        if (this.destroyed) {
            return this;
        }
        this.__dispatchEvent('beforeremove');
        
        if (Popup.current === this) {
            Popup.current = null;
        }
        // 从 DOM 中移除节点
        this.__popup.remove();
        this.__backdrop.remove();
        this.__mask.remove();
        if (!_isIE6) {
            $(window).off('resize', this.reset);
        }
        this.__dispatchEvent('remove');
        for (var i in this) {
            delete this[i];
        }
        return this;
    },
    /** 重置位置 */
    reset: function () {
        var elem = this.follow;
        if (elem) {
            this.__follow(elem);
        } else {
            this.__center();
        }
        this.__dispatchEvent('reset');
        return this;
    },
    /** 让浮层获取焦点 */
    focus: function () {
        var node = this.node;
        var popup = this.__popup;
        var current = Popup.current;
        var index = this.zIndex = Popup.zIndex ++;
        if (current && current !== this) {
            current.blur(false);
        }
        // 检查焦点是否在浮层里面
        if (!$.contains(node, this.__getActive())) {
            var autofocus = popup.find('[autofocus]')[0];
            if (!this._autofocus && autofocus) {
                this._autofocus = true;
            } else {
                autofocus = node;
            }
            this.__focus(autofocus);
        }
        // 设置叠加高度
        popup.css('zIndex', index);
        //this.__backdrop.css('zIndex', index);
        Popup.current = this;
        popup.addClass(this.className + '-focus');
        this.__dispatchEvent('focus');
        return this;
    },
    /** 让浮层失去焦点。将焦点退还给之前的元素,照顾视力障碍用户 */
    blur: function () {
        var activeElement = this.__activeElement;
        var isBlur = arguments[0];
        if (isBlur !== false) {
            this.__focus(activeElement);
        }
        this._autofocus = false;
        this.__popup.removeClass(this.className + '-focus');
        this.__dispatchEvent('blur');
        return this;
    },
    /**
     * 添加事件
     * @param   {String}    事件类型
     * @param   {Function}  监听函数
     */
    addEventListener: function (type, callback) {
        this.__getEventListener(type).push(callback);
        return this;
    },
    /**
     * 删除事件
     * @param   {String}    事件类型
     * @param   {Function}  监听函数
     */
    removeEventListener: function (type, callback) {
        var listeners = this.__getEventListener(type);
        for (var i = 0; i < listeners.length; i ++) {
            if (callback === listeners[i]) {
                listeners.splice(i--, 1);
            }
        }
        return this;
    },
    // 获取事件缓存
    __getEventListener: function (type) {
        var listener = this.__listener;
        if (!listener) {
            listener = this.__listener = {};
        }
        if (!listener[type]) {
            listener[type] = [];
        }
        return listener[type];
    },
    // 派发事件
    __dispatchEvent: function (type) {
        var listeners = this.__getEventListener(type);
        if (this['on' + type]) {
            this['on' + type]();
        }
        for (var i = 0; i < listeners.length; i ++) {
            listeners[i].call(this);
        }
    },
    // 对元素安全聚焦
    __focus: function (elem) {
        // 防止 iframe 跨域无权限报错
        // 防止 IE 不可见元素报错
        try {
            // ie11 bug: iframe 页面点击会跳到顶部
            if (this.autofocus && !/^iframe$/i.test(elem.nodeName)) {
                elem.focus();
            }
        } catch (e) {}
    },
    // 获取当前焦点的元素
    __getActive: function () {
        try {// try: ie8~9, iframe #26
            var activeElement = document.activeElement;
            var contentDocument = activeElement.contentDocument;
            var elem = contentDocument && contentDocument.activeElement || activeElement;
            return elem;
        } catch (e) {}
    },
    // 居中浮层
    __center: function () {
    
        var popup = this.__popup;
        var $window = $(window);
        var $document = $(document);
        var fixed = this.fixed;
        var dl = fixed ? 0 : $document.scrollLeft();
        var dt = fixed ? 0 : $document.scrollTop();
        var ww = $window.width();
        var wh = $window.height();
        var ow = popup.width();
        var oh = popup.height();
        var left = (ww - ow) / 2 + dl;
        var top = (wh - oh) * 382 / 1000 + dt;// 黄金比例
        var style = popup[0].style;
        
        style.left = Math.max(parseInt(left), dl) + 'px';
        style.top = Math.max(parseInt(top), dt) + 'px';
    },
    
    
    // 指定位置 @param    {HTMLElement, Event}  anchor
    __follow: function (anchor) {
        
        var $elem = anchor.parentNode && $(anchor);
        var popup = this.__popup;
        
        if (this.__followSkin) {
            popup.removeClass(this.__followSkin);
        }
        // 隐藏元素不可用
        if ($elem) {
            var o = $elem.offset();
            if (o.left * o.top < 0) {
                return this.__center();
            }
        }
        
        var that = this;
        var fixed = this.fixed;
        var $window = $(window);
        var $document = $(document);
        var winWidth = $window.width();
        var winHeight = $window.height();
        var docLeft =  $document.scrollLeft();
        var docTop = $document.scrollTop();
        var popupWidth = popup.width();
        var popupHeight = popup.height();
        var width = $elem ? $elem.outerWidth() : 0;
        var height = $elem ? $elem.outerHeight() : 0;
        var offset = this.__offset(anchor);
        var x = offset.left;
        var y = offset.top;
        var left =  fixed ? x - docLeft : x;
        var top = fixed ? y - docTop : y;
        var minLeft = fixed ? 0 : docLeft;
        var minTop = fixed ? 0 : docTop;
        var maxLeft = minLeft + winWidth - popupWidth;
        var maxTop = minTop + winHeight - popupHeight;
        var css = {};
        var align = this.align.split(' ');
        var className = this.className + '-';
        var reverse = {top: 'bottom', bottom: 'top', left: 'right', right: 'left'};
        var name = {top: 'top', bottom: 'top', left: 'left', right: 'left'};
        var temp = [{
            top: top - popupHeight,
            bottom: top + height,
            left: left - popupWidth,
            right: left + width
        }, {
            top: top,
            bottom: top - popupHeight + height,
            left: left,
            right: left - popupWidth + width
        }];
        var center = {
            left: left + width / 2 - popupWidth / 2,
            top: top + height / 2 - popupHeight / 2
        };
        
        var range = {
            left: [minLeft, maxLeft],
            top: [minTop, maxTop]
        };
        // 超出可视区域重新适应位置
        $.each(align, function (i, val) {
            // 超出右或下边界:使用左或者上边对齐
            if (temp[i][val] > range[name[val]][1]) {
                val = align[i] = reverse[val];
            }
            // 超出左或右边界:使用右或者下边对齐
            if (temp[i][val] < range[name[val]][0]) {
                align[i] = reverse[val];
            }
        });
        // 一个参数的情况
        if (!align[1]) {
            name[align[1]] = name[align[0]] === 'left' ? 'top' : 'left';
            temp[1][align[1]] = center[name[align[1]]];
        }
        //添加follow的css, 为了给css使用
        className += align.join('-') + ' '+ this.className+ '-follow';
        
        that.__followSkin = className;
        if ($elem) {
            popup.addClass(className);
        }
        
        css[name[align[0]]] = parseInt(temp[0][align[0]]);
        css[name[align[1]]] = parseInt(temp[1][align[1]]);
        popup.css(css);
    },
    // 获取元素相对于页面的位置(包括iframe内的元素)
    // 暂时不支持两层以上的 iframe 套嵌
    __offset: function (anchor) {
        var isNode = anchor.parentNode;
        var offset = isNode ? $(anchor).offset() : {
            left: anchor.pageX,
            top: anchor.pageY
        };
        anchor = isNode ? anchor : anchor.target;
        var ownerDocument = anchor.ownerDocument;
        var defaultView = ownerDocument.defaultView || ownerDocument.parentWindow;
        
        if (defaultView == window) {// IE <= 8 只能使用两个等于号
            return offset;
        }
        // {Element: Ifarme}
        var frameElement = defaultView.frameElement;
        var $ownerDocument = $(ownerDocument);
        var docLeft =  $ownerDocument.scrollLeft();
        var docTop = $ownerDocument.scrollTop();
        var frameOffset = $(frameElement).offset();
        var frameLeft = frameOffset.left;
        var frameTop = frameOffset.top;
        
        return {
            left: offset.left + frameLeft - docLeft,
            top: offset.top + frameTop - docTop
        };
    }
    
});
/** 当前叠加高度 */
Popup.zIndex = 1024;
/** 顶层浮层的实例 */
Popup.current = null;
return Popup;
});
// artDialog - 默认配置
define("dialog-config", {
    /* -----已注释的配置继承自 popup.js,仍可以再这里重新定义它----- */
    // 对齐方式
    //align: 'bottom left',
    
    // 是否固定定位
    //fixed: false,
    
    // 对话框叠加高度值(重要:此值不能超过浏览器最大限制)
    //zIndex: 1024,
    // 设置遮罩背景颜色
    backdropBackground: '#000',
    // 设置遮罩透明度
    backdropOpacity: 0.7,
    // 消息内容
    content: '<span class="ui-dialog-loading">Loading..</span>',
    
    // 标题
    title: '',
    // 对话框状态栏区域 HTML 代码
    statusbar: '',
    
    // 自定义按钮
    button: null,
    
    // 确定按钮回调函数
    ok: null,
    
    // 取消按钮回调函数
    cancel: null,
    // 确定按钮文本
    okValue: 'ok',
    
    // 取消按钮文本
    cancelValue: 'cancel',
    cancelDisplay: true,
    
    // 内容宽度
    width: '',
    
    // 内容高度
    height: '',
    
    // 内容与边界填充距离
    padding: '',
    
    // 对话框自定义 className
    skin: '',
    // 对话框最外层自定义 className
    boxSkin: '',
    // 是否支持快捷关闭(点击遮罩层自动关闭)
    quickClose: false,
    // css 文件路径,留空则不会使用 js 自动加载样式
    // 注意:css 只允许加载一个
    cssUri: '../css/ui-dialog.css',
    // 模板(使用 table 解决 IE7 宽度自适应的 BUG)
    // js 使用 i="***" 属性识别结构,其余的均可自定义
    innerHTML:
        '<div i="dialog" class="ui-dialog">'
        +       '<div class="ui-dialog-arrow-a"></div>'
        +       '<div class="ui-dialog-arrow-b"></div>'
        +       '<table class="ui-dialog-grid">'
        +           '<tr>'
        +               '<td i="header" class="ui-dialog-header">'
        +                   '<button i="close" class="ui-dialog-close">&#215;</button>'
        +                   '<div i="title" class="ui-dialog-title"></div>'
        +               '</td>'
        +           '</tr>'
        +           '<tr>'
        +               '<td i="body" class="ui-dialog-body">'
        +                   '<div i="content" class="ui-dialog-content"></div>'
        +               '</td>'
        +           '</tr>'
        +           '<tr>'
        +               '<td i="footer" class="ui-dialog-footer">'
        +                   '<div i="statusbar" class="ui-dialog-statusbar"></div>'
        +                   '<div i="button" class="ui-dialog-button"></div>'
        +               '</td>'
        +           '</tr>'
        +       '</table>'
        +'</div>'
    
});
/*!
 * artDialog
 * Date: 2014-11-09
 * https://github.com/aui/artDialog
 * (c) 2009-2014 TangBin, http://www.planeArt.cn
 *
 * This is licensed under the GNU LGPL, version 2.1 or later.
 * For details, see: http://www.gnu.org/licenses/lgpl-2.1.html
 */
define("dialog", function (require) {
var $ = require("jquery");
var Popup = require("popup");
var defaults = require("dialog-config");
var css = defaults.cssUri;
// css loader: RequireJS & SeaJS
if (css) {
    var fn = require[require.toUrl ? 'toUrl' : 'resolve'];
    if (fn) {
        css = fn(css);
        css = '<link rel="stylesheet" href="' + css + '" />';
        if ($('base')[0]) {
            $('base').before(css);
        } else {
            $('head').append(css);
        } 
    }
}
var _count = 0;
var _expando = new Date() - 0; // Date.now()
var _isIE6 = !('minWidth' in $('html')[0].style);
var _isMobile = 'createTouch' in document && !('onmousemove' in document)
    || /(iPhone|iPad|iPod)/i.test(navigator.userAgent);
var _isFixed = !_isIE6 && !_isMobile;
var artDialog = function (options, ok, cancel) {
    var originalOptions = options = options || {};
    
    if (typeof options === 'string' || options.nodeType === 1) {
    
        options = {content: options, fixed: !_isMobile};
    }
    
    options = $.extend(true, {}, artDialog.defaults, options);
    options.original = originalOptions;
    var id = options.id = options.id || _expando + _count;
    var api = artDialog.get(id);
    
    
    // 如果存在同名的对话框对象,则直接返回
    if (api) {
        return api.focus();
    }
    
    
    // 目前主流移动设备对fixed支持不好,禁用此特性
    if (!_isFixed) {
        options.fixed = false;
    }
    // 快捷关闭支持:点击对话框外快速关闭对话框
    if (options.quickClose) {
        options.modal = true;
        options.backdropOpacity = 0;
    }
    
    // 按钮组
    if (!$.isArray(options.button)) {
        options.button = [];
    }
    // 取消按钮
    if (cancel !== undefined) {
        options.cancel = cancel;
    }
    
    if (options.cancel) {
        options.button.push({
            id: 'cancel',
            value: options.cancelValue,
            callback: options.cancel,
            display: options.cancelDisplay
        });
    }
    
    
    // 确定按钮
    if (ok !== undefined) {
        options.ok = ok;
    }
    
    if (options.ok) {
        options.button.push({
            id: 'ok',
            value: options.okValue,
            callback: options.ok,
            autofocus: true
        });
    }
    
    return artDialog.list[id] = new artDialog.create(options);
};
var popup = function () {};
popup.prototype = Popup.prototype;
var prototype = artDialog.prototype = new popup();
artDialog.create = function (options) {
    var that = this;
    $.extend(this, new Popup());
    var originalOptions = options.original;
    var $popup = $(this.node).html(options.innerHTML);
    var $backdrop = $(this.backdrop);
    this.options = options;
    this._popup = $popup;
    
    $.each(options, function (name, value) {
        if (typeof that[name] === 'function') {
            that[name](value);
        } else {
            that[name] = value;
        }
    });
    // 更新 zIndex 全局配置
    if (options.zIndex) {
        Popup.zIndex = options.zIndex;
    }
    // 设置 ARIA 信息
    $popup.attr({
        'aria-labelledby': this._$('title')
            .attr('id', 'title:' + this.id).attr('id'),
        'aria-describedby': this._$('content')
            .attr('id', 'content:' + this.id).attr('id')
    });
    // 关闭按钮
    this._$('close')
    .css('display', this.cancel === false ? 'none' : '')
    .attr('title', this.cancelValue)
    .on('click', function (event) {
        that._trigger('cancel');
        event.preventDefault();
    });
    
    // 添加视觉参数
    this._$('dialog').addClass(this.skin);
    $popup.addClass(this.boxSkin);
    this._$('body').css('padding', this.padding);
    // 点击任意空白处关闭对话框
    if (options.quickClose) {
        $backdrop
        .on(
            'onmousedown' in document ? 'mousedown' : 'click',
            function () {
            that._trigger('cancel');
            return false;// 阻止抢夺焦点
        });
    }
    // 遮罩设置
    this.addEventListener('show', function () {
        $backdrop.css({
            opacity: 0,
            background: options.backdropBackground
        }).animate(
            {opacity: options.backdropOpacity}
        , 150);
    });
    // ESC 快捷键关闭对话框
    this._esc = function (event) {
        var target = event.target;
        var nodeName = target.nodeName;
        var rinput = /^input|textarea$/i;
        var isTop = Popup.current === that;
        var keyCode = event.keyCode;
        // 避免输入状态中 ESC 误操作关闭
        if (!isTop || rinput.test(nodeName) && target.type !== 'button') {
            return;
        }
        
        if (keyCode === 27) {
            that._trigger('cancel');
        }
    };
    $(document).on('keydown', this._esc);
    this.addEventListener('remove', function () {
        $(document).off('keydown', this._esc);
        delete artDialog.list[this.id];
    });
    _count ++;
    
    artDialog.oncreate(this);
    return this;
};
artDialog.create.prototype = prototype;
$.extend(prototype, {
    /**
     * 显示对话框
     * @name artDialog.prototype.show
     * @param   {HTMLElement Object, Event Object}  指定位置(可选)
     */
    
    /**
     * 显示对话框(模态)
     * @name artDialog.prototype.showModal
     * @param   {HTMLElement Object, Event Object}  指定位置(可选)
     */
    /**
     * 关闭对话框
     * @name artDialog.prototype.close
     * @param   {String, Number}    返回值,可被 onclose 事件收取(可选)
     */
    /**
     * 销毁对话框
     * @name artDialog.prototype.remove
     */
    /**
     * 重置对话框位置
     * @name artDialog.prototype.reset
     */
    /**
     * 让对话框聚焦(同时置顶)
     * @name artDialog.prototype.focus
     */
    /**
     * 让对话框失焦(同时置顶)
     * @name artDialog.prototype.blur
     */
    /**
     * 添加事件
     * @param   {String}    事件类型
     * @param   {Function}  监听函数
     * @name artDialog.prototype.addEventListener
     */
    /**
     * 删除事件
     * @param   {String}    事件类型
     * @param   {Function}  监听函数
     * @name artDialog.prototype.removeEventListener
     */
    /**
     * 对话框显示事件,在 show()、showModal() 执行
     * @name artDialog.prototype.onshow
     * @event
     */
    /**
     * 关闭事件,在 close() 执行
     * @name artDialog.prototype.onclose
     * @event
     */
    /**
     * 销毁前事件,在 remove() 前执行
     * @name artDialog.prototype.onbeforeremove
     * @event
     */
    /**
     * 销毁事件,在 remove() 执行
     * @name artDialog.prototype.onremove
     * @event
     */
    /**
     * 重置事件,在 reset() 执行
     * @name artDialog.prototype.onreset
     * @event
     */
    /**
     * 焦点事件,在 foucs() 执行
     * @name artDialog.prototype.onfocus
     * @event
     */
    /**
     * 失焦事件,在 blur() 执行
     * @name artDialog.prototype.onblur
     * @event
     */
    
    /**
     * 设置内容
     * @param    {String, HTMLElement}   内容
     */
    content: function (html) {
    
        var $content = this._$('content');
        // HTMLElement
        if (typeof html === 'object') {
            html = $(html);
            $content.empty('').append(html.show());
            this.addEventListener('beforeremove', function () {
                $('body').append(html.hide());
            });
        // String
        } else {
            $content.html(html);
        }
                
        return this.reset();
    },
    
    
    /**
     * 设置标题
     * @param    {String}   标题内容
     */
    title: function (text) {
        this._$('title').html(text);
        this._$('header')[text ? 'show' : 'hide']();
        return this;
    },
    /** 设置宽度 */
    width: function (value) {
        this._$('content').css('width', value);
        return this.reset();
    },
    /** 设置高度 */
    height: function (value) {
        this._$('content').css('height', value);
        return this.reset();
    },
    /**
     * 设置按钮组
     * @param   {Array, String}
     * Options: value, callback, autofocus, disabled 
     */
    button: function (args) {
        args = args || [];
        var that = this;
        var html = '';
        var number = 0;
        this.callbacks = {};
        
           
        if (typeof args === 'string') {
            html = args;
            number ++;
        } else {
            $.each(args, function (i, val) {
                var id = val.id = val.id || val.value;
                var style = '';
                that.callbacks[id] = val.callback;
                if (val.display === false) {
                    style = ' style="display:none"';
                } else {
                    number ++;
                }
                html +=
                  '<button'
                + ' type="button"'
                + ' i-id="' + id + '"'
                + style
                + (val.disabled ? ' disabled' : '')
                + (val.autofocus ? ' autofocus class="ui-dialog-autofocus"' : '')
                + '>'
                +   val.value
                + '</button>';
                that._$('button')
                .on('click', '[i-id=' + id +']', function (event) {                
                    var $this = $(this);
                    if (!$this.attr('disabled')) {// IE BUG
                        that._trigger(id);
                    }
                
                    event.preventDefault();
                });
            });
        }
        this._$('button').html(html);
        this._$('footer')[number ? 'show' : 'hide']();
        return this;
    },
    statusbar: function (html) {
        this._$('statusbar')
        .html(html)[html ? 'show' : 'hide']();
        return this;
    },
    _$: function (i) {
        return this._popup.find('[i=' + i + ']');
    },
    
    
    // 触发按钮回调函数
    _trigger: function (id) {
        var fn = this.callbacks[id];
            
        return typeof fn !== 'function' || fn.call(this) !== false ?
            this.close().remove() : this;
    }
    
});
artDialog.oncreate = $.noop;
/** 获取最顶层的对话框API */
artDialog.getCurrent = function () {
    return Popup.current;
};
/**
 * 根据 ID 获取某对话框 API
 * @param    {String}    对话框 ID
 * @return   {Object}    对话框 API (实例)
 */
artDialog.get = function (id) {
    return id === undefined
    ? artDialog.list
    : artDialog.list[id];
};
artDialog.list = {};
/**
 * 默认配置
 */
artDialog.defaults = defaults;
return artDialog;
});
/*!
 * drag.js
 * Date: 2013-12-06
 * https://github.com/aui/artDialog
 * (c) 2009-2014 TangBin, http://www.planeArt.cn
 *
 * This is licensed under the GNU LGPL, version 2.1 or later.
 * For details, see: http://www.gnu.org/licenses/lgpl-2.1.html
 */
define("drag", function (require) {
var $ = require("jquery");
var $window = $(window);
var $document = $(document);
var isTouch = 'createTouch' in document;
var html = document.documentElement;
var isIE6 = !('minWidth' in html.style);
var isLosecapture = !isIE6 && 'onlosecapture' in html;
var isSetCapture = 'setCapture' in html;
var types = {
    start: isTouch ? 'touchstart' : 'mousedown',
    over: isTouch ? 'touchmove' : 'mousemove',
    end: isTouch ? 'touchend' : 'mouseup'
};
var getEvent = isTouch ? function (event) {
    if (!event.touches) {
        event = event.originalEvent.touches.item(0);
    }
    return event;
} : function (event) {
    return event;
};
var DragEvent = function () {
    this.start = $.proxy(this.start, this);
    this.over = $.proxy(this.over, this);
    this.end = $.proxy(this.end, this);
    this.onstart = this.onover = this.onend = $.noop;
};
DragEvent.types = types;
DragEvent.prototype = {
    start: function (event) {
        event = this.startFix(event);
        $document
        .on(types.over, this.over)
        .on(types.end, this.end);
        
        this.onstart(event);
        return false;
    },
    over: function (event) {
        event = this.overFix(event);
        this.onover(event);
        return false;
    },
    end: function (event) {
        event = this.endFix(event);
        $document
        .off(types.over, this.over)
        .off(types.end, this.end);
        this.onend(event);
        return false;
    },
    startFix: function (event) {
        event = getEvent(event);
        this.target = $(event.target);
        this.selectstart = function () {
            return false;
        };
        $document
        .on('selectstart', this.selectstart)
        .on('dblclick', this.end);
        if (isLosecapture) {
            this.target.on('losecapture', this.end);
        } else {
            $window.on('blur', this.end);
        }
        if (isSetCapture) {
            this.target[0].setCapture();
        }
        return event;
    },
    overFix: function (event) {
        event = getEvent(event);
        return event;
    },
    endFix: function (event) {
        event = getEvent(event);
        $document
        .off('selectstart', this.selectstart)
        .off('dblclick', this.end);
        if (isLosecapture) {
            this.target.off('losecapture', this.end);
        } else {
            $window.off('blur', this.end);
        }
        if (isSetCapture) {
            this.target[0].releaseCapture();
        }
        return event;
    }
    
};
/**
 * 启动拖拽
 * @param   {HTMLElement}   被拖拽的元素
 * @param   {Event} 触发拖拽的事件对象。可选,若无则监听 elem 的按下事件启动
 */
DragEvent.create = function (elem, event) {
    var $elem = $(elem);
    var dragEvent = new DragEvent();
    var startType = DragEvent.types.start;
    var noop = function () {};
    var className = elem.className
        .replace(/^\s|\s.*/g, '') + '-drag-start';
    var minX;
    var minY;
    var maxX;
    var maxY;
    var api = {
        onstart: noop,
        onover: noop,
        onend: noop,
        off: function () {
            $elem.off(startType, dragEvent.start);
        }
    };
    dragEvent.onstart = function (event) {
        var isFixed = $elem.css('position') === 'fixed';
        var dl = $document.scrollLeft();
        var dt = $document.scrollTop();
        var w = $elem.width();
        var h = $elem.height();
        minX = 0;
        minY = 0;
        maxX = isFixed ? $window.width() - w + minX : $document.width() - w;
        maxY = isFixed ? $window.height() - h + minY : $document.height() - h;
        var offset = $elem.offset();
        var left = this.startLeft = isFixed ? offset.left - dl : offset.left;
        var top = this.startTop = isFixed ? offset.top - dt  : offset.top;
        this.clientX = event.clientX;
        this.clientY = event.clientY;
        $elem.addClass(className);
        api.onstart.call(elem, event, left, top);
    };
    
    dragEvent.onover = function (event) {
        var left = event.clientX - this.clientX + this.startLeft;
        var top = event.clientY - this.clientY + this.startTop;
        var style = $elem[0].style;
        left = Math.max(minX, Math.min(maxX, left));
        top = Math.max(minY, Math.min(maxY, top));
        style.left = left + 'px';
        style.top = top + 'px';
        
        api.onover.call(elem, event, left, top);
    };
    
    dragEvent.onend = function (event) {
        var position = $elem.position();
        var left = position.left;
        var top = position.top;
        $elem.removeClass(className);
        api.onend.call(elem, event, left, top);
    };
    dragEvent.off = function () {
        $elem.off(startType, dragEvent.start);
    };
    if (event) {
        dragEvent.start(event);
    } else {
        $elem.on(startType, dragEvent.start);
    }
    return api;
};
return DragEvent;
});
/*!
 * artDialog-plus
 * Date: 2013-11-09
 * https://github.com/aui/artDialog
 * (c) 2009-2014 TangBin, http://www.planeArt.cn
 *
 * This is licensed under the GNU LGPL, version 2.1 or later.
 * For details, see: http://www.gnu.org/licenses/lgpl-2.1.html
 */
define("dialog-plus", function (require) {
var $ = require("jquery");
var dialog = require("dialog");
var drag = require("drag");
dialog.oncreate = function (api) {
    var options = api.options;
    var originalOptions = options.original;
    // 页面地址
    var url = options.url;
    // 页面加载完毕的事件
    var oniframeload = options.oniframeload;
    var $iframe;
    if (url) {
        this.padding = options.padding = 0;
        $iframe = $('<iframe />');
        $iframe.attr({
            src: url,
            name: api.id,
            width: '100%',
            height: '100%',
            allowtransparency: 'yes',
            frameborder: 'no',
            scrolling: 'no'
        })
        .on('load', function () {
            var test;
            
            try {
                // 跨域测试
                test = $iframe[0].contentWindow.frameElement;
            } catch (e) {}
            if (test) {
                if (!options.width) {
                    api.width($iframe.contents().width());
                }
                
                if (!options.height) {
                    api.height($iframe.contents().height());
                }
            }
            if (oniframeload) {
                oniframeload.call(api);
            }
        });
        api.addEventListener('beforeremove', function () {
            // 重要!需要重置iframe地址,否则下次出现的对话框在IE6、7无法聚焦input
            // IE删除iframe后,iframe仍然会留在内存中出现上述问题,置换src是最容易解决的方法
            $iframe.attr('src', 'about:blank').remove();
        }, false);
        api.content($iframe[0]);
        api.iframeNode = $iframe[0];
    }
    // 对于子页面呼出的对话框特殊处理
    // 如果对话框配置来自 iframe
    if (!(originalOptions instanceof Object)) {
        var un = function () {
            api.close().remove();
        };
        // 找到那个 iframe
        for (var i = 0; i < frames.length; i ++) {
            try {
                if (originalOptions instanceof frames[i].Object) {
                    // 让 iframe 刷新的时候也关闭对话框,
                    // 防止要执行的对象被强制收回导致 IE 报错:“不能执行已释放 Script 的代码”
                    $(frames[i]).one('unload', un);
                    break;
                }
            } catch (e) {} 
        }
    }
    // 拖拽支持
    $(api.node).on(drag.types.start, '[i=title]', function (event) {
        // 排除气泡类型的对话框
        if (!api.follow) {
            api.focus();
            drag.create(api.node, event);
        }
    });
};
dialog.get = function (id) {
    // 从 iframe 传入 window 对象
    if (id && id.frameElement) {
        var iframe = id.frameElement;
        var list = dialog.list;
        var api;
        for (var i in list) {
            api = list[i];
            if (api.node.getElementsByTagName('iframe')[0] === iframe) {
                return api;
            }
        }
    // 直接传入 id 的情况
    } else if (id) {
        return dialog.list[id];
    }
};
return dialog;
});
window.dialog = require("dialog-plus");
})();

+ 67 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/js/doc.js

@ -0,0 +1,67 @@
!(function () {
	window.console = window.console || {
		log: $.noop
	};
	var codes = {};
	var debug = location.href.indexOf('Users/tangbin') !== -1;
	$(function () {
		console.log('你可以在调试器中粘贴本页示例代码运行');
		var RE = /[\n\s\t]*?\/\/\.\.[\r\n]/;
		$('pre code').each(function (index) {
			var $this = $(this);
			var code = $this.text();
			// 忽略不完整的代码片段
			// 开头使用"//.."表示
			if (RE.test(code)) {
				$this.text(code.replace(RE, ''));
				return;
			}
			try {
				codes[index] = new Function(code);
			} catch (e) {
				return;
			}
			$this
			.after('<div class="doc-line"></div>'
				+'<button data-code="' + index + '">运行</button>');
		});
		// 回到顶部
		var $top = $('<a class="doc-gotop" href="javascript:;">TOP</a>')
		.on('click', function () {
			$(window).scrollTop(0);
			return false;
		});
		$('body').append($top);
	});
	var runCode = function (id) {
		codes[id]();
		var api = dialog.getCurrent();
		if (debug && api) {
			console.log(api);
		}
	};
	$(document).on('click', 'button[data-code]', function () {
		var id = $(this).data('code');
		runCode(id);
		return false;
	}).on('click', 'h1 [id], h2 [id], h3 [id], h4 [id], h5 [id], h6 [id]', function () {
		var id = this.id;
		location.hash = id;
	});
}());

Разлика између датотеке није приказан због своје велике величине
+ 5 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/js/jquery.js


Разлика између датотеке није приказан због своје велике величине
+ 9 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/api/js/sh_languages.js


+ 435 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/css/ui-dialog.css

@ -0,0 +1,435 @@
/*!
 * ui-dialog.css
 * Date: 2014-07-03
 * https://github.com/aui/artDialog
 * (c) 2009-2014 TangBin, http://www.planeArt.cn
 *
 * This is licensed under the GNU LGPL, version 2.1 or later.
 * For details, see: http://www.gnu.org/licenses/lgpl-2.1.html
*/
.ui-popup-full{
    width:100%;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    padding:0 15px !important;
    left:0 !important;
}
.ui-dialog {
    *zoom:1;
    _float: left;
    position: relative;
    background-color: #FFF;
    border: 1px solid #999;
    border-radius: 6px;
    outline: 0;
    background-clip: padding-box;
    font-family: Helvetica, arial, sans-serif;
    font-size: 14px;
    line-height: 1.428571429;
    color: #333;
    opacity: 0;
    -webkit-transform: scale(0);
    transform: scale(0);
    -webkit-transition: -webkit-transform .15s ease-in-out, opacity .15s ease-in-out;
    transition: transform .15s ease-in-out, opacity .15s ease-in-out;
	padding:0 10px;
}
.ui-popup-show .ui-dialog {
    opacity: 1;
    -webkit-transform: scale(1);
    transform: scale(1);
}
.ui-popup-focus .ui-dialog {
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
}
.ui-popup-modal .ui-dialog {
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.1), 0 0 256px rgba(255, 255, 255, .3);
}
.ui-dialog-grid {
    width: 100%;
    margin: 0;
    border: 0 none;
    border-collapse:collapse;
    border-spacing: 0;
    background: transparent;
}
.ui-dialog-header,
.ui-dialog-body,
.ui-dialog-footer {
    padding: 0;
    border: 0 none;
    text-align: left;
    background: transparent;
}
.ui-dialog-header {
    white-space: nowrap;
    border-bottom: 1px solid #E5E5E5;
}
.ui-dialog-close {
    position: relative;
    _position: absolute;
    float: right;
    top: 13px;
    right: 13px;
    _height: 26px;
    padding: 0 4px;
    font-size: 21px;
    font-weight: bold;
    line-height: 1;
    color: #000;
    text-shadow: 0 1px 0 #FFF;
    opacity: .2;
    filter: alpha(opacity=20);
    cursor: pointer;
    background: transparent;
    _background: #FFF;
    border: 0;
    -webkit-appearance: none;
}
.ui-dialog-close:hover,
.ui-dialog-close:focus {
    color: #000000;
    text-decoration: none;
    cursor: pointer;
    outline: 0;
    opacity: 0.5;
    filter: alpha(opacity=50);
}
.ui-dialog-title {
    margin: 0;
    line-height: 1.428571429;
    min-height: 16.428571429px;
    padding: 15px;
    overflow:hidden; 
    white-space: nowrap;
    text-overflow: ellipsis;
    font-weight: bold;
    cursor: default;
}
.ui-dialog-body {
    padding: 20px;
    text-align: center;
}
.ui-dialog-content {
    display: inline-block;
    position: relative;
    vertical-align: middle;
    *zoom: 1;
    *display: inline;
    text-align: left;
}
.ui-dialog-footer {
    padding: 0 20px 20px 20px;
}
.ui-dialog-statusbar {
    float: left;
    margin-right: 20px;
    padding: 6px 0;
    line-height: 1.428571429;
    font-size: 14px;
    color: #888;
    white-space: nowrap;
}
.ui-dialog-statusbar label:hover {
    color: #333;
}
.ui-dialog-statusbar input,
.ui-dialog-statusbar .label {
    vertical-align: middle;
}
.ui-dialog-button {
    float: right;
    white-space: nowrap;
}
.ui-dialog-footer button+button {
    margin-bottom: 0;
    margin-left: 5px;
}
.ui-dialog-footer button {
    width:auto;
    overflow:visible;
    display: inline-block;
    padding: 6px 12px;
    _margin-left: 5px;
    margin-bottom: 0;
    font-size: 14px;
    font-weight: normal;
    line-height: 1.428571429;
    text-align: center;
    white-space: nowrap;
    vertical-align: middle;
    cursor: pointer;
    background-image: none;
    border: 1px solid transparent;
    border-radius: 4px;
    -webkit-user-select: none;
     -moz-user-select: none;
      -ms-user-select: none;
       -o-user-select: none;
          user-select: none;
}
.ui-dialog-footer button:focus {
  outline: thin dotted #333;
  outline: 5px auto -webkit-focus-ring-color;
  outline-offset: -2px;
}
.ui-dialog-footer button:hover,
.ui-dialog-footer button:focus {
  color: #333333;
  text-decoration: none;
}
.ui-dialog-footer button:active {
  background-image: none;
  outline: 0;
  -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
          box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
}
.ui-dialog-footer button[disabled] {
  pointer-events: none;
  cursor: not-allowed;
  opacity: 0.65;
  filter: alpha(opacity=65);
  -webkit-box-shadow: none;
          box-shadow: none;
}
.ui-dialog-footer button {
  color: #333333;
  background-color: #ffffff;
  border-color: #cccccc;
}
.ui-dialog-footer button:hover,
.ui-dialog-footer button:focus,
.ui-dialog-footer button:active {
  color: #333333;
  background-color: #ebebeb;
  border-color: #adadad;
}
.ui-dialog-footer button:active{
  background-image: none;
}
.ui-dialog-footer button[disabled],
.ui-dialog-footer button[disabled]:hover,
.ui-dialog-footer button[disabled]:focus,
.ui-dialog-footer button[disabled]:active {
  background-color: #ffffff;
  border-color: #cccccc;
}
.ui-dialog-footer button.ui-dialog-autofocus {
  color: #ffffff;
  background-color: #428bca;
  border-color: #357ebd;
}
.ui-dialog-footer button.ui-dialog-autofocus:hover,
.ui-dialog-footer button.ui-dialog-autofocus:focus,
.ui-dialog-footer button.ui-dialog-autofocus:active {
  color: #ffffff;
  background-color: #3276b1;
  border-color: #285e8e;
}
.ui-dialog-footer button.ui-dialog-autofocus:active {
  background-image: none;
}
.ui-popup-top-left .ui-dialog,
.ui-popup-top .ui-dialog,
.ui-popup-top-right .ui-dialog {
    top: -8px;
}
.ui-popup-bottom-left .ui-dialog,
.ui-popup-bottom .ui-dialog,
.ui-popup-bottom-right .ui-dialog {
    top: 8px;
}
.ui-popup-left-top .ui-dialog,
.ui-popup-left .ui-dialog,
.ui-popup-left-bottom .ui-dialog {
    left: -8px;
}
.ui-popup-right-top .ui-dialog,
.ui-popup-right .ui-dialog,
.ui-popup-right-bottom .ui-dialog {
    left: 8px;
}
.ui-dialog-arrow-a,
.ui-dialog-arrow-b {
    position: absolute;
    display: none;
    width: 0;
    height: 0;
    overflow:hidden;
    _color:#FF3FFF;
    _filter:chroma(color=#FF3FFF);
    border:8px dashed transparent;
}
.ui-popup-follow .ui-dialog-arrow-a,
.ui-popup-follow .ui-dialog-arrow-b{
    display: block;
}
.ui-popup-top-left .ui-dialog-arrow-a,
.ui-popup-top .ui-dialog-arrow-a,
.ui-popup-top-right .ui-dialog-arrow-a {
    bottom: -16px;
    border-top:8px solid #7C7C7C;
}
.ui-popup-top-left .ui-dialog-arrow-b,
.ui-popup-top .ui-dialog-arrow-b,
.ui-popup-top-right .ui-dialog-arrow-b {
    bottom: -15px;
    border-top:8px solid #fff;
}
.ui-popup-top-left .ui-dialog-arrow-a,
.ui-popup-top-left .ui-dialog-arrow-b  {
    left: 15px;
}
.ui-popup-top .ui-dialog-arrow-a,
.ui-popup-top .ui-dialog-arrow-b  {
    left: 50%;
    margin-left: -8px;
}
.ui-popup-top-right .ui-dialog-arrow-a,
.ui-popup-top-right .ui-dialog-arrow-b {
    right: 15px;
}
.ui-popup-bottom-left .ui-dialog-arrow-a,
.ui-popup-bottom .ui-dialog-arrow-a,
.ui-popup-bottom-right .ui-dialog-arrow-a {
    top: -16px;
    border-bottom:8px solid #7C7C7C;
}
.ui-popup-bottom-left .ui-dialog-arrow-b,
.ui-popup-bottom .ui-dialog-arrow-b,
.ui-popup-bottom-right .ui-dialog-arrow-b {
    top: -15px;
    border-bottom:8px solid #fff;
}
.ui-popup-bottom-left .ui-dialog-arrow-a,
.ui-popup-bottom-left .ui-dialog-arrow-b {
    left: 15px;
}
.ui-popup-bottom .ui-dialog-arrow-a,
.ui-popup-bottom .ui-dialog-arrow-b {
    margin-left: -8px;
    left: 50%;
}
.ui-popup-bottom-right .ui-dialog-arrow-a,
.ui-popup-bottom-right .ui-dialog-arrow-b {
    right: 15px;
}
.ui-popup-left-top .ui-dialog-arrow-a,
.ui-popup-left .ui-dialog-arrow-a,
.ui-popup-left-bottom .ui-dialog-arrow-a {
    right: -16px;
    border-left:8px solid #7C7C7C;
}
.ui-popup-left-top .ui-dialog-arrow-b,
.ui-popup-left .ui-dialog-arrow-b,
.ui-popup-left-bottom .ui-dialog-arrow-b {
    right: -15px;
    border-left:8px solid #fff;
}
.ui-popup-left-top .ui-dialog-arrow-a,
.ui-popup-left-top .ui-dialog-arrow-b {
    top: 15px;
}
.ui-popup-left .ui-dialog-arrow-a,
.ui-popup-left .ui-dialog-arrow-b {
    margin-top: -8px;
    top: 50%;
}
.ui-popup-left-bottom .ui-dialog-arrow-a,
.ui-popup-left-bottom .ui-dialog-arrow-b {
    bottom: 15px;
}
.ui-popup-right-top .ui-dialog-arrow-a,
.ui-popup-right .ui-dialog-arrow-a,
.ui-popup-right-bottom .ui-dialog-arrow-a {
    left: -16px;
    border-right:8px solid #7C7C7C;
}
.ui-popup-right-top .ui-dialog-arrow-b,
.ui-popup-right .ui-dialog-arrow-b,
.ui-popup-right-bottom .ui-dialog-arrow-b {
    left: -15px;
    border-right:8px solid #fff;
}
.ui-popup-right-top .ui-dialog-arrow-a,
.ui-popup-right-top .ui-dialog-arrow-b {
    top: 15px;
}
.ui-popup-right .ui-dialog-arrow-a,
.ui-popup-right .ui-dialog-arrow-b {
    margin-top: -8px;
    top: 50%;
}
.ui-popup-right-bottom .ui-dialog-arrow-a,
.ui-popup-right-bottom .ui-dialog-arrow-b {
    bottom: 15px;
}
@-webkit-keyframes ui-dialog-loading {
    0% {
        -webkit-transform: rotate(0deg);
    }
    100% {
        -webkit-transform: rotate(360deg);
    }
}
@keyframes ui-dialog-loading {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}
.ui-dialog-loading {
    vertical-align: middle;
    position: relative;
    display: block;
    *zoom: 1;
    *display: inline;
    overflow: hidden;
    width: 32px;
    height: 32px;
    top: 50%;
    margin: -16px auto 0 auto;
    font-size: 0;
    text-indent: -999em;
    color: #666;
}
.ui-dialog-loading {
    width: 100%\9;
    text-indent: 0\9;
    line-height: 32px\9;
    text-align: center\9;
    font-size: 12px\9;
}
.ui-dialog-loading::after {
    position: absolute;
    content: '';
    width: 3px;
    height: 3px;
    margin: 14.5px 0 0 14.5px;
    border-radius: 100%;
    box-shadow: 0 -10px 0 1px #ccc, 10px 0px #ccc, 0 10px #ccc, -10px 0 #ccc, -7px -7px 0 0.5px #ccc, 7px -7px 0 1.5px #ccc, 7px 7px #ccc, -7px 7px #ccc;
    -webkit-transform: rotate(360deg);
    -webkit-animation: ui-dialog-loading 1.5s infinite linear;
    transform: rotate(360deg);
    animation: ui-dialog-loading 1.5s infinite linear;
    display: none\9;
}

+ 126 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/css/ui-dialog.min.css

@ -0,0 +1,126 @@
.ui-popup-full { width: 100%; box-sizing: border-box; -webkit-box-sizing: border-box; padding: 0 25px !important; left: 0 !important }
.ui-dialog {
 *zoom: 1; _float: left; position: relative; background-color: #FFF; border: 1px solid #999; border-radius: 6px; outline: 0; background-clip: padding-box; font-family: Helvetica, arial, sans-serif; font-size: 14px; line-height: 1.428571429; color: #333; opacity: 0; -webkit-transform: scale(0); transform: scale(0); -webkit-transition: -webkit-transform .15s ease-in-out, opacity .15s ease-in-out; transition: transform .15s ease-in-out, opacity .15s ease-in-out; padding: 0 10px }
.ui-popup-show .ui-dialog { opacity: 1; -webkit-transform: scale(1); transform: scale(1) }
.ui-popup-focus .ui-dialog { box-shadow: 0 0 8px rgba(0, 0, 0, 0.1) }
.ui-popup-modal .ui-dialog { box-shadow: 0 0 8px rgba(0, 0, 0, 0.1), 0 0 256px rgba(255, 255, 255, .3) }
.ui-dialog-grid { width: 100%; margin: 0; border: 0 none; border-collapse: collapse; border-spacing: 0; background: transparent }
.ui-dialog-header, .ui-dialog-body, .ui-dialog-footer { padding: 0; border: 0 none; text-align: left; background: transparent }
.ui-dialog-header { white-space: nowrap; border-bottom: 1px solid #e5e5e5 }
.ui-dialog-close { position: relative; _position: absolute; float: right; top: 13px; right: 13px; _height: 26px; padding: 0 4px; font-size: 21px; font-weight: bold; line-height: 1; color: #000; text-shadow: 0 1px 0 #FFF; opacity: .2; filter: alpha(opacity=20); cursor: pointer; background: transparent; _background: #FFF; border: 0; -webkit-appearance: none }
.ui-dialog-close:hover, .ui-dialog-close:focus { color: #000; text-decoration: none; cursor: pointer; outline: 0; opacity: .5; filter: alpha(opacity=50) }
.ui-dialog-title { margin: 0; line-height: 1.428571429; min-height: 16.428571429px; padding: 15px; overflow: hidden; white-space: pre-wrap;font-weight: bold; cursor: default }
.ui-dialog-body { padding: 20px; text-align: center }
.ui-dialog-content { display: inline-block; position: relative; vertical-align: middle;  *zoom: 1; *display: inline;text-align: left }
.ui-dialog-footer { padding: 0 20px 20px 20px }
.ui-dialog-statusbar { float: left; margin-right: 20px; padding: 6px 0; line-height: 1.428571429; font-size: 14px; color: #888; white-space: nowrap }
.ui-dialog-statusbar label:hover { color: #333 }
.ui-dialog-statusbar input, .ui-dialog-statusbar .label { vertical-align: middle }
.ui-dialog-button { float: right; white-space: nowrap }
.ui-dialog-footer button + button { margin-bottom: 0; margin-left: 5px }
.ui-dialog-footer button { width: auto; overflow: visible; display: inline-block; padding: 6px 12px; _margin-left: 5px; margin-bottom: 0; font-size: 14px; font-weight: normal; line-height: 1.428571429; text-align: center; white-space: nowrap; vertical-align: middle; cursor: pointer; background-image: none; border: 1px solid transparent; border-radius: 4px; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; -o-user-select: none; user-select: none }
.ui-dialog-footer button:focus { outline: thin dotted #333; outline: 5px auto -webkit-focus-ring-color; outline-offset: -2px }
.ui-dialog-footer button:hover, .ui-dialog-footer button:focus { color: #333; text-decoration: none }
.ui-dialog-footer button:active { background-image: none; outline: 0; -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125) }
.ui-dialog-footer button[disabled] { pointer-events: none; cursor: not-allowed; opacity: .65; filter: alpha(opacity=65); -webkit-box-shadow: none; box-shadow: none }
.ui-dialog-footer button { color: #333; background-color: #fff; border-color: #ccc }
.ui-dialog-footer button:hover, .ui-dialog-footer button:focus, .ui-dialog-footer button:active { color: #333; background-color: #ebebeb; border-color: #adadad }
.ui-dialog-footer button:active { background-image: none }
.ui-dialog-footer button[disabled], .ui-dialog-footer button[disabled]:hover, .ui-dialog-footer button[disabled]:focus, .ui-dialog-footer button[disabled]:active { background-color: #fff; border-color: #ccc }
.ui-dialog-footer button.ui-dialog-autofocus { color: #fff; background-color: #428bca; border-color: #357ebd }
.ui-dialog-footer button.ui-dialog-autofocus:hover, .ui-dialog-footer button.ui-dialog-autofocus:focus, .ui-dialog-footer button.ui-dialog-autofocus:active { color: #fff; background-color: #3276b1; border-color: #285e8e }
.ui-dialog-footer button.ui-dialog-autofocus:active { background-image: none }
.ui-popup-top-left .ui-dialog, .ui-popup-top .ui-dialog, .ui-popup-top-right .ui-dialog { top: -8px }
.ui-popup-bottom-left .ui-dialog, .ui-popup-bottom .ui-dialog, .ui-popup-bottom-right .ui-dialog { top: 8px }
.ui-popup-left-top .ui-dialog, .ui-popup-left .ui-dialog, .ui-popup-left-bottom .ui-dialog { left: -8px }
.ui-popup-right-top .ui-dialog, .ui-popup-right .ui-dialog, .ui-popup-right-bottom .ui-dialog { left: 8px }
.ui-dialog-arrow-a, .ui-dialog-arrow-b { position: absolute; display: none; width: 0; height: 0; overflow: hidden; _color: #ff3fff; _filter: chroma(color=#FF3FFF); border: 8px dashed transparent }
.ui-popup-follow .ui-dialog-arrow-a, .ui-popup-follow .ui-dialog-arrow-b { display: block }
.ui-popup-top-left .ui-dialog-arrow-a, .ui-popup-top .ui-dialog-arrow-a, .ui-popup-top-right .ui-dialog-arrow-a { bottom: -16px; border-top: 8px solid #7c7c7c }
.ui-popup-top-left .ui-dialog-arrow-b, .ui-popup-top .ui-dialog-arrow-b, .ui-popup-top-right .ui-dialog-arrow-b { bottom: -15px; border-top: 8px solid #fff }
.ui-popup-top-left .ui-dialog-arrow-a, .ui-popup-top-left .ui-dialog-arrow-b { left: 15px }
.ui-popup-top .ui-dialog-arrow-a, .ui-popup-top .ui-dialog-arrow-b { left: 50%; margin-left: -8px }
.ui-popup-top-right .ui-dialog-arrow-a, .ui-popup-top-right .ui-dialog-arrow-b { right: 15px }
.ui-popup-bottom-left .ui-dialog-arrow-a, .ui-popup-bottom .ui-dialog-arrow-a, .ui-popup-bottom-right .ui-dialog-arrow-a { top: -16px; border-bottom: 8px solid #7c7c7c }
.ui-popup-bottom-left .ui-dialog-arrow-b, .ui-popup-bottom .ui-dialog-arrow-b, .ui-popup-bottom-right .ui-dialog-arrow-b { top: -15px; border-bottom: 8px solid #fff }
.ui-popup-bottom-left .ui-dialog-arrow-a, .ui-popup-bottom-left .ui-dialog-arrow-b { left: 15px }
.ui-popup-bottom .ui-dialog-arrow-a, .ui-popup-bottom .ui-dialog-arrow-b { margin-left: -8px; left: 50% }
.ui-popup-bottom-right .ui-dialog-arrow-a, .ui-popup-bottom-right .ui-dialog-arrow-b { right: 15px }
.ui-popup-left-top .ui-dialog-arrow-a, .ui-popup-left .ui-dialog-arrow-a, .ui-popup-left-bottom .ui-dialog-arrow-a { right: -16px; border-left: 8px solid #7c7c7c }
.ui-popup-left-top .ui-dialog-arrow-b, .ui-popup-left .ui-dialog-arrow-b, .ui-popup-left-bottom .ui-dialog-arrow-b { right: -15px; border-left: 8px solid #fff }
.ui-popup-left-top .ui-dialog-arrow-a, .ui-popup-left-top .ui-dialog-arrow-b { top: 15px }
.ui-popup-left .ui-dialog-arrow-a, .ui-popup-left .ui-dialog-arrow-b { margin-top: -8px; top: 50% }
.ui-popup-left-bottom .ui-dialog-arrow-a, .ui-popup-left-bottom .ui-dialog-arrow-b { bottom: 15px }
.ui-popup-right-top .ui-dialog-arrow-a, .ui-popup-right .ui-dialog-arrow-a, .ui-popup-right-bottom .ui-dialog-arrow-a { left: -16px; border-right: 8px solid #7c7c7c }
.ui-popup-right-top .ui-dialog-arrow-b, .ui-popup-right .ui-dialog-arrow-b, .ui-popup-right-bottom .ui-dialog-arrow-b { left: -15px; border-right: 8px solid #fff }
.ui-popup-right-top .ui-dialog-arrow-a, .ui-popup-right-top .ui-dialog-arrow-b { top: 15px }
.ui-popup-right .ui-dialog-arrow-a, .ui-popup-right .ui-dialog-arrow-b { margin-top: -8px; top: 50% }
.ui-popup-right-bottom .ui-dialog-arrow-a, .ui-popup-right-bottom .ui-dialog-arrow-b { bottom: 15px }
 @-webkit-keyframes ui-dialog-loading {
 0% {
 -webkit-transform: rotate(0deg)
}
 100% {
 -webkit-transform: rotate(360deg)
}
}
 @keyframes ui-dialog-loading {
 0% {
 transform: rotate(0deg)
}
 100% {
 transform: rotate(360deg)
}
}
.ui-dialog-loading { vertical-align: middle; position: relative; display: block;  *zoom: 1;
 *display: inline;
overflow: hidden; width: 32px; height: 32px; top: 50%; margin: -16px auto 0 auto; font-size: 0; text-indent: -999em; color: #666 }
.ui-dialog-loading { width: 100% \9; text-indent: 0 \9; line-height: 32px \9; text-align: center \9; font-size: 12px \9 }
.ui-dialog-loading::after { position: absolute; content: ''; width: 3px; height: 3px; margin: 14.5px 0 0 14.5px; border-radius: 100%; box-shadow: 0 -10px 0 1px #ccc, 10px 0 #ccc, 0 10px #ccc, -10px 0 #ccc, -7px -7px 0 .5px #ccc, 7px -7px 0 1.5px #ccc, 7px 7px #ccc, -7px 7px #ccc; -webkit-transform: rotate(360deg); -webkit-animation: ui-dialog-loading 1.5s infinite linear; transform: rotate(360deg); animation: ui-dialog-loading 1.5s infinite linear; display: none \9 }
.ax-popup { padding: 0; border: 0; border-radius: 10px; outline: 0; font-size: 14px; line-height: 1.428571429; color: #333; overflow: hidden; }
.ax-popup .ui-dialog-header { font-size: 17px; font-weight: 700; border: 0; text-align: center; }
.ax-popup .ui-dialog-close { display: none; }
.ax-popup .ui-dialog-title { padding: 15px 20px 0 20px; border-top-left-radius: 10px; border-top-right-radius: 10px; overflow: hidden; }
.fat-title .ui-dialog-title { padding: 25px 15px 0 15px; }
.ax-popup .ui-dialog-body, .ax-popup .ui-dialog-content { text-align: center; color: #5b5b5b; }
.ui-popup-modal .ui-dialog { -webkit-box-shadow: none; box-shadow: none; }
.ax-popup .ui-dialog-body { padding: 15px; line-height:1.8; }
.ax-popup .ui-dialog-footer { border-top: 1px solid #e1e1e1; padding: 0; text-align: center; border-radius: 0 0 10px 10px; overflow: hidden; }
.ax-popup .ui-dialog-button { float: none; width: 100%; white-space: nowrap; display: -webkit-box; display: box; }
.ax-popup .ui-dialog-footer button { display: box; display: -webkit-box; -webkit-box-flex: 1; box-flex: 1; box-sizing: border-box; -webkit-box-sizing: border-box; padding: 0; margin: 0; height: 44px; font-size: 17px; font-weight: normal; color: #167efb; cursor: pointer; background: none; border: 0; text-align: center !important; border-left: 1px solid #e1e1e1; border-radius: 0; outline: 0; }
.ax-popup .ui-dialog-footer button span { display: block; width: 100%; text-align: center; }
.ax-popup .ui-dialog-footer button + button { margin-bottom: 0; margin-left: 0; }
.ax-popup .ui-dialog-footer button.ui-dialog-autofocus { color: #167efb; background-color: #fff; border: 0; border-left: 1px solid #e1e1e1; }
.ax-popup .ui-dialog-footer button:first-child { border: 0; border-bottom-left-radius: 10px; }
.ax-popup .ui-dialog-footer button:last-child { border-bottom-right-radius: 10px; }
.ax-popup .ui-dialog-footer button:active { background-image: none; outline: 0; -webkit-box-shadow: none; box-shadow: none; background: #efefef; }
.bk-popup { padding: 0 10px; border: 0; border-radius: 10px; outline: 0; font-size: 14px; line-height: 1.428571429; color: #fff; overflow: hidden; border:0; background:rgba(0,0,0,.8);}
.ui-popup-focus .bk-popup{ box-shadow:none; }
.bk-popup .ui-dialog-header { font-size: 17px; font-weight: 700; border: 0; text-align: center;}
.bk-popup .ui-dialog-close { display: none; }
.bk-popup .ui-dialog-title { padding: 15px 20px 0 20px; border-top-left-radius: 10px; border-top-right-radius: 10px; overflow: hidden; }
.fat-title .ui-dialog-title { padding: 25px 15px 0 15px; }
.bk-popup .ui-dialog-body, .bk-popup .ui-dialog-content { text-align: center; color: #5b5b5b; font-size:17px; line-height:1.5; background:rgba(0,0,0,0); }
.ui-popup .bk-popup tr, .ui-popup  .bk-popup tr {background:none}
.ui-popup-modal .ui-dialog { -webkit-box-shadow: none; box-shadow: none; }
.bk-popup .ui-dialog-content, .bk-popup tr{ background:transparent; color:#fff;}
.thin-con .ui-dialog-body { padding: 9px 10px; }
.bk-popup .ui-dialog-footer { border-top: 1px solid rgba(255,255,255,.3); padding: 10px 0; text-align: center; border-radius: 0 0 10px 10px; overflow: hidden; }
.bk-popup .ui-dialog-button { float: none; width: 100%; white-space: nowrap; display: -webkit-box; display: box; }
.bk-popup .ui-dialog-footer button { display: box; display: -webkit-box; -webkit-box-flex: 1; box-flex: 1; box-sizing: border-box; -webkit-box-sizing: border-box; padding: 0; margin: 0; height: 28px; font-size: 17px; font-weight: normal; color: #fff; cursor: pointer; background: none; border: 0; text-align: center !important; border-left: 1px solid rgba(255,255,255,.3); border-radius: 0; outline: 0; }
.bk-popup .ui-dialog-footer button span { display: block; width: 100%; text-align: center; }
.bk-popup .ui-dialog-footer button + button { margin-bottom: 0; margin-left: 0; }
.bk-popup .ui-dialog-footer button.ui-dialog-autofocus { color: #fff; background-color:transparent; border: 0; border-left: 1px solid rgba(255,255,255,.3); }
.bk-popup .ui-dialog-footer button:first-child { border: 0; border-bottom-left-radius: 10px; }
.bk-popup .ui-dialog-footer button:last-child { border-bottom-right-radius: 10px; }
.bk-popup .ui-dialog-footer button:active { background-image: none; outline: 0; color:#167efb; -webkit-box-shadow: none; box-shadow:none;}
.ui-dialog-loading{ text-align:left;}
.smallTips .ui-dialog-grid{margin:15px 0;}
.ui-popup p,.ui-popup blockquote,.ui-popup ul,.ui-popup ol,.ui-popup dl,.ui-popup li, .ui-popup pre { margin: 15px 0; }
.ui-popup table { padding: 0; border-collapse: collapse; }
.ui-popup tr { background-color: white; margin: 0; padding: 0; }
.ui-popup th { font-weight: bold; text-align: left; margin: 0; padding: 6px 13px; }
.ui-popup td { text-align: left; margin: 0; padding: 6px 13px; }
.ui-popup th :first-child,.ui-popup td :first-child { margin-top: 0; }
.ui-popup th :last-child,.ui-popup td :last-child { margin-bottom: 0; }

Разлика између датотеке није приказан због своје велике величине
+ 930 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/js/dialog-plus.js


Разлика између датотеке није приказан због своје велике величине
+ 1 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/artDialog/6.0.5/js/dialog-plus.min.js


+ 1597 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/css/chatRoom.css

@ -0,0 +1,1597 @@
@charset "utf-8";
/* CSS Document */
body,
html {
	background: #f3f3f3;
}
.c-ccc {
	color: #ccc;
}
.ax-naills span.axills-boxer {
	display: inline-block;
	padding: 3px 5px;
	background: #f5f5f5;
	color: #999999;
	font-size: 10px;
	border-radius: 5px;
}
.ax-naills span.axills-right {
	background: #fff;
	color: #17b3ec;
	border: 1px solid #17b3ec;
	padding: 3px 5px;
	border-radius: 5px;
	font-size: 10px;
}
.ax-naills .c-btn-tiny {
	padding: 3px 15px;
	border-color: #17b3ec;
	color: #17b3ec;
}
.ax-naills .c-btn-tiny-grey {
	padding: 3px 15px;
	border-color: #C0C0C0;
	color: #C0C0C0;
	background-color: #E5E5E5;
}
.ax-naills span.ax-longboxer {
	background: #f5f5f5;
	color: #999999;
	font-size: 10px;
	padding: 3px 10px;
	display: inline-block;
	max-width: 100%;
	box-sizing: border-box;
	border-radius: 5px;
}
.c-17b3ec {
	color: #17b3ec;
}
.ax-naills span.ax-qybox {
	display: inline-block;
	font-size: 10px;
	padding: 2px 5px;
	border-radius: 5px;
	font-size: 10px;
}
.ax-naills span.ax-qybox.b-ff9555 {
	color: #ff9555;
	border: 1px solid #ff9555;
}
.ax-naills span.ax-qybox.b-2ddc46 {
	color: #2ddc46;
	border: 1px solid #2ddc46;
}
.ax-naills span.ax-qybox.b-2d8cdc {
	color: #2d8cdc;
	border: 1px solid #2d8cdc;
}
.c-4bd663 {
	color: #4bd663;
}
.tioper-hd {
	line-height: 33px;
}
.bgc-f7f7f7 {
	background: #f7f7f7;
}
.bgc-ebebeb {
	background: #ebebeb;
}
#serv-liang th {
	background: #f4f7fa;
	vertical-align: middle;
	text-align: center;
	border-right: 1px solid #e1e1e1;
	border-bottom: 1px solid #e1e1e1;
	padding: 10px 5px;
}
#serv-liang td {
	background: #fff;
	vertical-align: middle;
	text-align: center;
	border-right: 1px solid #e1e1e1;
	border-bottom: 1px solid #e1e1e1;
	padding: 10px 5px;
	color: #5b5b5b;
}
#serv-liang td.first {
	color: #909090;
}
.c-list .c-list-info > p.c-f12 {
	font-size: 12px;
}
.tanper .c-btn {
	padding: 5px 5px;
}
.tanper {
	background: #fbfcfc;
}
/* 医患沟通开始 */
.c-chat-box {
	border: none;
	padding-left: 2%;
	padding-right: 2%;
}
.time-tips {
	margin: 10px 0 0 0;
	text-align: center;
	clear: both;
}
.time-tips span {
	position: relative;
	display: inline-block;
	padding: 0 60px;
	color: #aeaeae;
	font-size: 15px;
}
.time-tips span:before,
.time-tips span:after {
	position: absolute;
	content: "";
	display: block;
	width: 50px;
	height: 1px;
	background: #e6e4e1;
	top: 50%;
}
.time-tips span:before {
	left: 0;
}
.time-tips span:after {
	right: 0;
}
.chat-left,
.chat-right {
	clear: both;
	overflow: hidden;
	padding: 10px 0;
}
.chat-left > dt,
.chat-right > dt {
	width: 40px;
	height: 40px;
}
.chat-left > dt {
	float: left;
	margin-right: 15px;
}
.chat-right > dt {
	float: right;
	margin-left: 15px;
}
.chat-left > dt img,
.chat-right > dt img {
	width: 40px;
	height: 40px;
	border-radius: 50%;
}
.chat-left > dd,
.chat-right > dd {
	position: relative;
	min-height: 18px;
	font-size: 15px;
	display: inline-block;
	max-width: 80%;
	background: #fff;
	border: 1px solid #e1e1e1;
	border-radius: 6px;
	padding: 8px 10px;
	box-shadow: 1px 1px 1px rgba(0, 0, 0, .1);
}
.chat-left > dd {
	float: left;
	white-space: pre-wrap;
	word-wrap: break-word;
}
.chat-right > dd {
	float: right;
	background: #bce0ff;
	border: 1px solid #81bdf7;
	white-space: pre-wrap;
	word-wrap: break-word;
}
.chat-left > dd:after {
	content: "";
	position: absolute;
	top: 14px;
	left: -6px;
	display: block;
	width: 8px;
	height: 8px;
	background: #fff;
	border-color: #e1e1e1;
	border-style: solid;
	border-width: 1px 0 0 1px;
	-webkit-transform: rotate(-45deg);
	-moz-transform: rotate(-45deg);
	transform: rotate(-45deg);
}
.chat-right > dd:after {
	content: "";
	position: absolute;
	top: 14px;
	right: -6px;
	display: block;
	width: 8px;
	height: 8px;
	background: #bce0ff;
	border-color: #81bdf7;
	border-style: solid;
	border-width: 1px 0 0 1px;
	-webkit-transform: rotate(135deg);
	-moz-transform: rotate(135deg);
	transform: rotate(135deg);
}
.chat-left > dd p img,
.chat-right > dd p img {
	max-width: 150px;
	max-height: 150px;
	margin: 5px 0;
}
.chat-msg-box {
	bottom: 0;
	left: 0
}
.chat-msg-box .input-group .form-control {
	height: 32px;
}
.pull-more {
	text-align: center;
	color: #5b5b5b;
	font-size: 14px;
	padding: 14px 0;
}
/* 医患沟通结束 */
.pt13 {
	padding-top: 13px;
}
.jt-boradius {
	border-radius: 5px;
}
.bot-pper a.c-btn {
	border: 1px dashed #999999;
	text-align: center;
	display: block;
	color: #666666;
	font-size: 16px;
	border-radius: 5px;
}
.c-999999 {
	color: #999999;
}
.lh40 {
	line-height: 40px;
}
/***/
.call-con {
	clear: both;
	overflow: hidden;
}
.phone-book,
.doctor-list,
.ill-case {
	width: 100%;
	background: #fff;
}
.phone-book li,
.doctor-list li,
.ill-case li {
	width: 100%;
	overflow: hidden;
	border-bottom: 1px solid #e1e1e1;
}
.contacts {
	position: relative;
	height: 65px;
	transform: translateX(0);
	transition: all 0.3s;
	-webkit-transform: translateX(0);
	-webkit-transition: all 0.3s;
	-moz-transform: translateX(0);
	-moz-transition: all 0.3s;
}
.contact-sin {
	position: absolute;
	top: 50%;
	padding: 0 15px 0 15px;
	width: 100%;
	box-sizing: border-box;
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
	transform: translateY(50%);
	-webkit-transform: translateY(-50%);
	-moz-transform: translateY(-50%);
}
.contact-sin dt {
	position: absolute;
	width: 40px;
}
.contact-sin dd {
	float: left;
	min-height: 40px;
	width: 100%;
}
.contact-sin dd h4 {
	font-size: 15px;
	display: inline-block;
	padding-right: 20px;
	line-height: normal;
	vertical-align: middle;
	position: relative;
	box-sizing: border-box;
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
}
.contact-sin h4 .iconfont {
	position: absolute;
	top: 50%;
	right: 0;
	margin-top: -9px;
	font-size: 14px;
}
.contact-sin dt a,
.doctor-sin dt a {
	display: block;
}
.doctors {
	position: relative;
	height: 90px;
	padding-right: 60px;
	box-sizing: border-box;
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
}
.doctor-sin {
	position: absolute;
	top: 50%;
	padding: 0 60px 0 15px;
	width: 100%;
	box-sizing: border-box;
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
	transform: translateY(50%);
	-webkit-transform: translateY(-50%);
	-moz-transform: translateY(-50%);
}
.doctors:after {
	position: absolute;
	top: 50%;
	right: 60px;
	content: "";
	display: block;
	width: 1px;
	height: 54px;
	background: #e1e1e1;
	z-index: 100;
	margin-top: -27px;
}
.apply:after {
	right: 75px;
	background: rgba(0, 0, 0, 0);
}
.apply .doctor-sin {
	padding-right: 70px;
}
@media screen and (min-width:360px) {
	.apply .doctor-sin {
		padding-right: 75px;
	}
}
.doctor-sin dt {
	position: absolute;
	width: 54px;
	top: 50%;
	transform: translateY(-50%);
	-webkit-transform: translateY(-50%);
	-moz-transform: translateY(-50%);
}
.doctor-sin dd {
	float: left;
	margin-left: 69px;
	padding: 5px 0;
	min-height: 54px;
	box-sizing: border-box;
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
}
.doctor-sin dd h4 {
	font-size: 18px;
	display: inline-block;
	padding: 0 0 4px 0;
	line-height: normal;
	vertical-align: middle;
	position: relative;
	box-sizing: border-box;
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
}
.doctor-sin dd p {
	white-space: pre-wrap;
	word-wrap: break-word;
	max-height: 40px;
	overflow: hidden;
}
.scrollLeft {
	transform: translateX(-72px);
	transition: all 0.3s;
	-webkit-transform: translateX(-72px);
	-webkit-transition: all 0.3s;
	-moz-transform: translateX(-72px);
	-moz-transition: all 0.3s;
}
.call-phone {
	position: absolute;
	display: inline-block;
	width: 40px;
	height: 40px;
	right: 10px;
	top: 50%;
	margin-top: -20px;
	text-align: center;
	line-height: 40px;
}
.call-phone .iconfont {
	font-size: 30px;
	color: #4dcd70;
}
.apply-btn {
	position: absolute;
	display: inline-block;
	width: 50px;
	right: 15px;
	top: 50%;
	margin-top: -14px;
	text-align: center;
	line-height: 40px;
}
.del-contact {
	position: absolute;
	display: inline-block;
	width: 72px;
	height: 100%;
	background: #ff3b2f;
	left: 100%;
	top: 0;
	text-align: center;
	line-height: 65px;
	color: #fff;
	font-size: 18px;
}
.call-tips {
	list-style: decimal;
	list-style-position: outside;
	padding-left: 15px;
}
.call-tips li {
	padding-bottom: 5px;
}
.no-data {
	width: 100%;
	font-size: 12px;
	color: #909090;
	text-align: center;
	padding: 30px 0;
}
.no-data-img {
	width: 40%;
	max-width: 320px;
	margin: 0 auto;
}
.no-data-icon {
	width: 100%;
	height: 0;
	padding-bottom: 100%;
	background: url(http://ued.yihu.cn/htmlCode/健康之路APP/诊间咨询/images/nodata.png) no-repeat 0 0;
	background-size: 100% auto;
}
.no-data p {
	font-size: 14px;
	padding-top: 10px;
}
em.online,
em.offline {
	display: inline-block;
	font-size: 12px;
	background: #4dcd70;
	color: #fff;
	border-radius: 2px;
	padding: 0 2px;
	line-height: 14px;
	vertical-align: middle;
}
em.offline {
	background: #909090;
}
/**/
.header-menus {
	right: 15px;
	top: 0;
	position: absolute;
}
.header-menus a {
	color: #5cb4ff;
}
.referral-pop {
	width: 250px;
	position: fixed;
	left: 50%;
	margin-left: -125px;
	top: 50%;
	margin-top: -80px;
	z-index: 600;
}
.referral-pop-hold {
	position: relative;
	z-index: 631;
	background: #fff;
	border-radius: 7px;
	overflow: hidden;
}
.referral-pop-hold a {
	display: block;
	line-height: 55px;
	text-align: center;
	color: #666;
	border-bottom: 1px solid #f2f2f2;
	font-size: 16px;
}
.referral-pop-hold a.cancle {
	color: #999;
	border-bottom: none;
}
.referral-pop-mb {
	width: 100%;
	height: 100%;
	position: fixed;
	left: 0;
	top: 0;
	background: rgba(0, 0, 0, .5);
	z-index: 600;
}
.juris-close {
	position: absolute;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, .7);
	left: 0;
	top: 0;
	z-index: 600;
	color: #fff;
	text-align: center;
	display: box;
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-box-pack: center;
	font-size: 18px;
}
.seval-hold {
	position: relative;
	padding-left: 33px;
	font-size: 12px;
	color: #999;
	margin-top: 6px;
}
.seval-tit {
	position: absolute;
	left: 0;
	top: 5px;
}
.seval-con {
	background: #eee;
	padding: 7px 10px;
	border-radius: 5px;
}
.star-img {
	vertical-align: middle;
	margin-bottom: 4px;
}
.tw-add {
	margin: 0 7px 0 2px;
	text-align: center;
}
.tw-add-detail {
	padding: 7px 15px;
	border-top: 1px solid #e1e1e1;
	margin-top: 10px;
}
.tw-add-detail li {
	display: block;
	width: 25%;
	text-align: center;
	float: left;
	color: #909090;
}
.tw-add-detail li img {
	margin: 5px;
}
.ask-lab-lage {
	width: 100%;
	overflow: auto;
	border-bottom: 1px solid #e1e1e1;
}
.ask-lab-lage ul {
	display: block;
	width: 400px;
	background: #fff;
}
.ask-lab-lage li {
	display: block;
	width: auto;
	padding: 0 2px;
	float: left;
	line-height: 40px;
	text-align: center;
	position: relative;
	margin: 0 12px;
}
.ask-lab-lage li a {
	margin-top: 5px;
	color: #333;
}
.ask-lab-lage li.curr a {
	color: #17b3ec;
}
.ask-lab-lage li.curr:before {
	content: '';
	display: block;
	width: 100%;
	height: 2px;
	background: #17b3ec;
	position: absolute;
	left: 0;
	bottom: 0;
}
.appeal-texa {
	background: #fff;
	border: none;
	width: 100%;
	padding: 10px;
	height: 150px;
	font-size: 14px;
}
.mui-toast-container {
	position: fixed;
	z-index: 9999;
	bottom: 50px;
	width: 100%;
	-webkit-transition: opacity .8s;
	transition: opacity .8s;
	opacity: 0
}
.mui-toast-container.mui-active {
	opacity: 1
}
.mui-toast-message {
	font-size: 14px;
	width: 270px;
	margin: 5px auto;
	padding: 5px;
	text-align: center;
	color: #000;
	border-radius: 7px;
	background-color: #d8d8d8
}
.win-broadcast {
	position: fixed;
	outline: 0px;
	top: 50%;
	left: 50%;
	margin: -113px 0 0 -135px;
	width: 269px;
	height: 226px;
	border-radius: 5px;
	z-index: 100;
}
.win-broadcast .bg {
	background-color: #fff;
	width: 269px;
	height: 226px;
	border-radius: 5px;
	display: block;
}
.win-broadcast .broadcast {
	background: url(../images/broadcast.png) no-repeat 0 -2px;
	width: 85px;
	height: 85px;
	display: block;
	background-size: 100%;
	position: absolute;
	top: 67px;
	left: 34%;
	border-radius: 50%;
	z-index: 99;
}
.win-broadcast .word {
	position: absolute;
	bottom: 0;
	border-radius: 5px;
	border-top: 1px solid #e1e1e1;
	border-top-right-radius: 0;
	border-top-left-radius: 0;
	color: #666;
	background-color: #fff;
	height: 35px;
	width: 100%;
	line-height: 35px;
}
.win-broadcast .word.title {
	top: 0;
	border-top-left-radius: 5px;
	border-top-right-radius: 5px;
}
.delete {
	display: block;
	position: absolute;
	height: 12px;
	width: 12px;
	border-radius: 50%;
	background-color: #fff;
	right: 6px;
	top: 6px;
	z-index: 10;
	text-align: center;
	line-height: 9px;
	color: #919191;
	font-size: 12px;
}
.broadcast-shadow-panel {
	width: 100%;
	position: absolute;
	overflow: hidden;
	z-index: 10;
	top: 0;
	background-color: rgba(0, 0, 0, .35);
}
/*动画*/
.win-broadcast .broadcast {
	animation: broadcast 2s infinite;
	-webkit-animation: broadcast 2s infinite;
	/* Safari 和 Chrome */
}
@-webkit-keyframes broadcast {
	0% {
		background-color: #ccf5ff;
		box-shadow: 0 0 0 0px #ccf5ff, 0 0 0 0 #c3e9f2, 0 0 0 0px #e9fffe, 0 0 0 0 #ddf5f4;
	}
	25% {
		background-color: #ccf5ff;
		box-shadow: 0 0 0 5px #ccf5ff, 0 0 0 1px #c3e9f2, 0 0 0 20px #e9fffe, 0 0 0 1px #ddf5f4;
	}
	50% {
		background-color: #ccf5ff;
		box-shadow: 0 0 0 10px #ccf5ff, 0 0 0 1px #c3e9f2, 0 0 0 25px #e9fffe, 0 0 0 1px #ddf5f4;
	}
	100% {
		background-color: #ccf5ff;
		box-shadow: 0 0 0 15px #ccf5ff, 0 0 0 1px #c3e9f2, 0 0 0 30px #e9fffe, 0 0 0 1px #ddf5f4;
	}
}
/* 12-18 */
.nxz-voice {
	line-height: 21px;
	text-align: right;
}
.nzx-tb {
	display: inline-block;
	width: 15px;
	height: 21px;
	background: url(../images/icon-broadcast.png) no-repeat;
	background-size: 100% auto;
	-webkit-background-size: 100% auto;
	-moz-background-size: 100% auto;
	-ms-background-size: 100% auto;
	vertical-align: middle;
}
.win-broadcast-mb {
	width: 100%;
	height: 100%;
	position: fixed;
	left: 0;
	top: 0;
	z-index: 10;
	background: rgba(0, 0, 0, .35);
	display: none;
}
.myorder li .vlname {
	line-height: 20px;
	border-bottom: 1px solid #f2f2f2;
	position: relative;
	padding-right: 15px;
	padding-top: 10px;
	padding-bottom: 10px;
}
.pa-icon-dagou {
	width: 20px;
	height: 20px;
	font-size: 13px;
	display: block;
	text-align: center;
	border-radius: 100%;
	border: 1px solid #e1e1e1;
}
.pa-icon-dagou.on {
	background: #17b3ec;
	color: #fff;
}
.ask-record li {
	background: #fff;
	position: relative;
	padding: 10px 35px 10px 45px;
	border-top: 1px solid #f2f2f2;
	color: #909090;
}
.ask-record li .ar-check {
	position: absolute;
	left: 10px;
	top: 50%;
	margin-top: -10px;
}
.ask-record li .ar-check i {
	display: block;
	width: 18px;
	height: 18px;
	border: 1px solid #e1e1e1;
	border-radius: 50%;
}
.ask-record li .ar-check i.checked {
	background: #17b3ec;
	border: 1px solid #17b3ec;
}
.ask-record li .ar-check i.checked:before {
	content: "\d61a";
	position: absolute;
	top: -12px;
	left: 3px;
	color: #fff;
	font-size: 12px;
}
.ask-record li .arrow-right {
	position: absolute;
	right: 12px;
	top: 50%;
	margin-top: -6px;
	transform: rotate(135deg);
	-webkit-transform: rotate(135deg);
	transition: all .3s ease;
}
.ask-record li .arrow-right.ashow {
	transform: rotate(-45deg);
	-webkit-transform: rotate(-45deg);
	margin-top: -3px;
}
.view-more {
	display: inline-block;
	width: 100%;
	text-align: center;
	padding: 15px 0 10px 0;
}
.view-more a {
	/*color: #5b5b5b;*/
	color: #17b3ec;
}
.time-tips span{
	padding: 2px 10px;
	border-radius: 15px;
	color: #aaa;
	/*background-color: #E1E1E1;*/
	font-size: 12px;
}
.chat-left, .chat-right {
	display: -webkit-box;
	clear: both;
	overflow: hidden;
	padding: 10px 0;
}
.chat-right{
	-webkit-box-direction: reverse;
}
.chat-left > dt{
	float: none;
}
.chat-right > dt {
	float: none;
}
.chat-right .word-bread{
	text-align: left;
	/*float: right;*/
	background: #17b3ec;
	border: 1px solid #17b3ec;
	white-space: pre-wrap;
	word-wrap: break-word;
	
	position: relative;
	min-height: 18px;
	font-size: 15px;
	display: inline-block;
	max-width: 80%;
	border-radius: 6px;
	padding: 8px 10px;
	box-shadow: 1px 1px 1px rgba(0, 0, 0, .1);
}
.chat-right > div.c-content{
	-webkit-box-flex: 1;
	text-align: right;
}
.chat-right .word-bread:after{
	content: "";
	position: absolute;
	top: 5px;
	right: -5px;
	display: block;
	width: 8px;
	height: 8px;
	background: #17b3ec;
	border-color: #E1E1E1;
	border-style: solid;
	border-width: 1px 0 0 1px;
	-webkit-transform: rotate(135deg);
	-moz-transform: rotate(135deg);
	transform: rotate(135deg);
}
.chat-left .word-bread{
	/*float: left;*/
	white-space: pre-wrap;
	word-wrap: break-word;
	
	position: relative;
	min-height: 18px;
	font-size: 15px;
	display: inline-block;
	max-width: 80%;
	background: #fff;
	border: 1px solid #e1e1e1;
	border-radius: 6px;
	padding: 8px 10px;
	box-shadow: 1px 1px 1px rgba(0, 0, 0, .1);
}
.chat-left > div.c-content{
	-webkit-box-flex: 1;
	text-align: left;
}
.chat-left .word-bread:after{
	content: "";
	position: absolute;
	top: 5px;
	left: -5px;
	display: block;
	width: 8px;
	height: 8px;
	background: #fff;
	border-color: #e1e1e1;
	border-style: solid;
	border-width: 1px 0 0 1px;
	-webkit-transform: rotate(-45deg);
	-moz-transform: rotate(-45deg);
	transform: rotate(-45deg);
}
.chat-left span.name, .chat-right span.name{
	display: block;
	height: 24px;
}
.time-tips span:before, .time-tips span:after{
	height: 0!important;
}
.zi2{
	z-index: 2;	
}
.doc-name {
	font-size: 15px;
}
/*#contain{position: absolute; width: 95%; top:45px; bottom: 52px; overflow-y: auto;}*/
@media only screen and (max-width: 640px) {
	.doc-name {
		font-size: 13px; 
	}
}
.chat-right.checkbox:after, .chat-left.checkbox:before{
	display: block;
	content: '√';
	line-height: 24px;
	width: 22px;
	height: 22px;
	border: 1px solid #ccc;
	border-radius: 50%;
	margin-right: 10px;
	color: #f3f3f3;
	text-align: center;
	font-size: 16px;
	box-sizing: border-box;
}
.chat-right.checked:after, .chat-left.checked:before{
	background: #17b3ec;
	border: none;
}
.log-oper{
	position: absolute;
	background: rgba(20, 20, 20, .8);
	border-radius: 8px;
	color: #fff;
	z-index: 10000;
	display: -webkit-box;
	display: none;
}
.log-oper li{
	margin: 8px 0px;
	padding: 0px 8px;
	font-size: 14px;
	border-left: 1px solid #fff;
}
.log-oper li:first-child{
	border-left:none ;
}
.log-oper div{
	position: absolute;
	/*width: 10px;
	height: 10px;
	background: transparent;*/
	/*-webkit-transform: rotate(45deg);*/
	top: 37px;
	
	border-left: 8px solid transparent;
	border-right: 8px solid transparent;
	border-top: 8px solid rgba(20, 20, 20, .8);
	border-bottom: 8px solid transparent;
}
.footer-bar{
	z-index: 2;
	bottom: 0;
	left: 0;
	width: 100%;
	position: fixed;
	border-top-width: 1px;
	border-color: #e1e1e1;
	border-style: solid;
	background-color: #fff;
	display: -webkit-box;
}
.c-hide{
	display: none;	
}
.footer-bar li{
	margin: 10px 0px;
	-webkit-box-flex: 1;
	text-align: center;
	line-height: 27px;
	font-size: 16px;
	color: #333;
}
.footer-bar li:first-child{
	border-right: 1px solid #e1e1e1;	
}
.footer-bar li > img{
	width: 22px;
	margin-right: 10px;
}
.header-group{
	line-height: 20px;
}
.btn-cancel{
	color: #fff;
	font-size: 16px;
	display: none;
}
.tw-add{
	width: 50px;
	margin: 3px 5px 3px 0;
}
.input-group input{
	margin-bottom: 0;
}
.c-main .c-btn{
	padding-top: 5px;
	padding-bottom: 5px;
}
.chat-right  .wb-img{
	padding: 2px;
}
.wb-img img{
	position: relative;
	z-index: 2;
	border-radius: 6px;
}
.xt-xiaoxi{
	background: #888;
    color: #fff!important;
    padding: 4px 10px!important;
    border-radius: 8px!important;
}
.yy-hold{
	background: #ccc;
}
.rprogress {
	position: absolute;
	left: 50%;
	top: 50%;
	width: 140px;
	height: 140px;
	margin-left: -70px;
	margin-top: -70px;
	background-repeat: no-repeat;
	background-position: center center;
	background-size: 30px 30px;
	background-color: rgba(0, 0, 0, 0.7);
	border-radius: 5px;
	display: none;
	-webkit-transition: .15s;
	z-index: 100;
}
.rschedule {
	background: url("../images/yuying_icon5.png");
	background-repeat: no-repeat;
	background-position: center center;
	background-size: 30px 50px;
	width: 46px;
	height: 50px;
	position: absolute;
	left: 30px;
	top: 40px;
}
.r-sigh{
	display: none;
	border-radius: 50px;
	box-shadow: 0 0 15px #2187e7;
	width: 46px;
	height: 46px;
	position: absolute;
	left: 50%;
	top: 50%;
	margin-left: -23px;
	margin-top: -23px;
	text-align: center;
	line-height: 46px;
	font-size: 40px;
	font-weight: bold;
	color: #2187e7;
}
.rprogress-sigh{
	background-image: none !important;
}
.rprogress-sigh .rschedule{
	display: none !important;
}
.rprogress-sigh .r-sigh{
	display: block !important;
}
.rsalert {
	font-size: 12px;
	color: #bbb;
	text-align: center;
	position: absolute;
	border-radius: 5px;
	width: 130px;
	margin: 5px 5px;
	padding: 5px;
	left: 0px;
	bottom: 0px;
}
.chat-right .audio{
	padding-right: 30px;
	background: url("../images/yuyin4_icon.png") no-repeat -20px 0 #17b3ec;
	background-size: 18px;
	-webkit-background-size: 18px;
	-moz-background-size: 18px;
	-o-background-size: 18px;
	background-position:  90% 50%;
}
.chat-right .audio.active{
	background: url("../images/yuyin3.gif") no-repeat -20px 0 #17b3ec;
	background-size: 18px;
	-webkit-background-size: 18px;
	-moz-background-size: 18px;
	-o-background-size: 18px;
	background-position:  90% 50%;
}
.chat-right .soundWav{
	height: 20px;display: -webkit-box;-webkit-box-direction: normal;
}
.chat-right .soundWavT{
	display: block;margin-left: 10px;
}
.chat-right .soundWav img{
	position: relative;
	width: 40px;
	height: 30px;
	top: -5px;
}
.chat-left .audio{
	padding-left: 30px;
	background: url("../images/yuyin_icon.png") no-repeat #fff;
	background-size: 18px;
	-webkit-background-size: 18px;
	-moz-background-size: 18px;
	-o-background-size: 18px;
	background-position:  10% 50%;
}
.chat-left .audio.active{
	background: url("../images/yuyin-2.gif") no-repeat #fff;
	background-size: 18px;
	-webkit-background-size: 18px;
	-moz-background-size: 18px;
	-o-background-size: 18px;
	background-position:  10% 50%;
}
.chat-left .soundWav{
	height: 20px;display: -webkit-box;-webkit-box-direction: reverse;
}
.chat-left .soundWavT{
	display: block;margin-right: 10px;
}
.chat-left .soundWav img{
	position: relative;
	width: 40px;
	height: 30px;
	top: -5px;
}
.volumn {
    display: inline-block;
    height: 30px;
    line-height: 40px;
    text-align: center;
    position: relative;
    vertical-align: bottom;
    left: 84px;
	top: 60px;
}
.volumn div {
    height: 3px;
    margin-bottom: 0;
    background-color: white;
    margin-right: -12px;
    margin-bottom: 6px;
}
.volumn .line1 {
	width: 10px;
    -webkit-animation: line1 2s infinite ease-in-out alternate;
}
.volumn .line2 {
	width: 14px;
    -webkit-animation: line2 2s infinite ease-in-out alternate;
}
.volumn .line3 {
	width: 18px;
    -webkit-animation: line3 2s infinite ease-in-out alternate;
}
.volumn .line4 {
	width: 22px;
    /*-webkit-animation: line 0.6s infinite 1.8s ease-in-out alternate;*/
    /*-webkit-animation-delay: 3.6s;*/
}
@-webkit-keyframes line1 {
    0% {
         opacity: 0;
    }
    41%{
    	 opacity: 0;
    }
    42%{
    	 opacity: 1;
    }
    55% {
         opacity: 1;
    }
    56% {
         opacity: 0;
    }
    100% {
         opacity: 0;
    }
}
@-webkit-keyframes line2 {
    0% {
         opacity: 0;
    }
    27%{
    	 opacity: 0;
    }
    28%{
    	 opacity: 1;
    }
    73% {
         opacity: 1;
    }
    74% {
         opacity: 0;
    }
    100% {
         opacity: 0;
    }
}
@-webkit-keyframes line3 {
    0% {
         opacity: 0;
    }
    13%{
    	 opacity: 0;
    }
    14%{
    	 opacity: 1;
    }
    84% {
         opacity: 1;
    }
    85% {
         opacity: 0;
    }
    100% {
         opacity: 0;
    }
}
.input-msg{
    min-height: 32px;
    width: 100%;
    line-height: 22px;
    overflow-x: hidden;
    overflow-y: auto;
    /*_overflow-y: visible;
    _height: 32px;*/
    max-height: 120px;
    background-color: #fff;
    background-image: none;
    border: 1px solid #e1e1e1;
    padding: 5px 10px;
    font-size: 14px;
    border-radius: 4px;
    -webkit-user-select: auto;
    user-modify: read-write-plaintext-only;
    -webkit-user-modify: read-write-plaintext-only
}
.preview-video{padding: 6px 0px;max-height: 100px;position: relative;}
.preview-video .video-img-right{width: 135px !important;height: 100px;border-radius: 15px;border-bottom-right-radius: 0px;border-top-right-radius: 0px;}
.preview-video .video-img-left{width: 135px !important;height: 100px;border-radius: 15px;border-bottom-left-radius: 0px;border-top-left-radius: 0px;}
.preview-video .bofang-icon-right{position: absolute;right: 65px;bottom: 50%;width: 25px !important;height: 25px;margin-right: -12px;top: 40px;z-index: 100;}
.preview-video .bofang-icon-left{position: absolute;left: 65px;bottom: 50%;width: 25px !important;height: 25px;margin-right: -12px;top: 40px;z-index: 100;}
.preview-video .shichang-time-right{position: absolute;right: 27px;bottom: 50%;width: auto;height: 18px;margin-right: -12px;top: 82px;font-size: 12px;color: #fff;}
.preview-video .shichang-time-left{position: absolute;left: 5px;bottom: 50%;width: auto;height: 18px;margin-left: 90px;top: 82px;font-size: 12px;color: #fff}
.preview-video .jianjiao-icon-right{top: 6px;z-index: 20;position: absolute;right: 12px;width: 20px !important;height: 100px;margin-right: -12px;}
.preview-video .jianjiao-icon-left{top: 6px;z-index: 20;position: absolute;left: 12px;width: 20px !important;height: 100px;margin-left: -12px;}
/*添加文章类消息显示样式*/
.chat-left .word-article{
    width: 82%;
    max-width: 82%;
    text-align: left;
}
.chat-left .word-article:after{background: #fff;}
.chat-left .article-content{
    -webkit-box-direction: reverse;
    display: -webkit-box;
    height: 80px;
    padding: 5px 0px;
    overflow: hidden;
}
.chat-left .article-content>img{
    width: 60px !important;
    height: 60px;
    margin-top: 3px;
}
.chat-left .article-content>div{
    -webkit-box-flex: 1;
    overflow: hidden;
    padding: 1px 0px 0px 5px;
}
.xzzx{
    position: fixed;
    bottom: 0;
    left:0;
    width: 100%;
    height: 60px;
    padding:10px;
    text-align: center;
}
.xzzx span{
    display: inline-block;
    color: #fff;
    font-size: 16px;
    background-color: #74bf00;
    width: 100%;
    border-radius: 5px;
    height: 40px;
    line-height: 40px;
}
.xzzx img{
    vertical-align: middle;
    margin-bottom: 3px;
    margin-right: 5px;
}

Разлика између датотеке није приказан због своје велике величине
+ 342 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/css/cross.css


Разлика између датотеке није приказан због своје велике величине
+ 496 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/css/cross.ui.css


+ 61 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/css/prescription-consulting.css

@ -0,0 +1,61 @@
.div-top-content{
    position: fixed;
    width: 100%;
    z-index: 20;
    background: #FFFFFF;
}
.c-main{
    position: absolute;
    width: 100%;
    top: 75px;
    z-index: 10;
}
.h34{
    height: 34px;
}
.lh34{
    line-height: 34px;
}
.c-inline-block{
    display: inline-block;
}
.div-xf-status{
    /*width: 70px;*/
    height: 22px;
    /*line-height: 22px;*/
    padding: 0 10px;
    border:1px solid #74bf00;
    color:#74BF00;
    text-align: center;
    font-size: 12px;
    border-radius: 20px;
}
.chat-right .word-bread.sys-msg{
    background-color: #fff;
    
}
.chat-right .word-bread.sys-msg:after{
    background-color: #fff;
    border-color: #17b3ec;
}
.chat-left .word-bread.sys-msg{
    background-color: #fff;
    border-color: #17b3ec;
}
.chat-left .word-bread.sys-msg:after{
    background-color: #fff;
    border-color: #17b3ec;
}
.sys-header{
    display: inline-block;
    background-color: #17b3ec;
    height: 20px;
    line-height: 20px;
    padding: 0 10px;
    border-radius: 10px;
    color: #fff
}
.sys-header img{
    vertical-align: middle;
    margin-right: 5px;
}

BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/bofang_icon.png


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/loading2.gif


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/logo_dibu_img.png


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/xitongtixing_im_icon.png


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/youshanjiao_bg.png


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin-2.gif


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin.gif


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin2_icon.png


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin3.gif


BIN
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin4_icon.png


+ 0 - 0
patient-co-service/wlyy_service/src/main/webapp/prescription_consulting/images/yuyin_icon.png


Неке датотеке нису приказане због велике количине промена