Ver código fonte

Merge branch 'dev' of http://192.168.1.220:10080/Amoy/patient-co-management into dev

zd_123 7 anos atrás
pai
commit
bfbd0ef567
15 arquivos alterados com 1357 adições e 21 exclusões
  1. 9 0
      common/common-entity/src/main/java/com/yihu/wlyy/entity/login/LoginLog.java
  2. 11 4
      patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/controller/manager/datastatic/PrescriptionStaticController.java
  3. 246 0
      patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_info.jsp
  4. 163 0
      patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_info_js.jsp
  5. 27 8
      patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_list_js.jsp
  6. 221 0
      patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_order.jsp
  7. 163 0
      patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_order_js.jsp
  8. 105 1
      patient-co/patient-co-wlyy-job/src/main/java/com/yihu/wlyy/service/app/prenatalInspector/PrenatalInspectorPreCardService.java
  9. 308 0
      patient-co/patient-co-wlyy-job/src/main/java/com/yihu/wlyy/service/third/jw/JwMaternalChildService.java
  10. 17 0
      patient-co/patient-co-wlyy-job/src/main/java/com/yihu/wlyy/util/DateUtil.java
  11. 24 0
      patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/team/AdminTeamService.java
  12. 1 0
      patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/common/account/LoginController.java
  13. 46 6
      patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/jimeiJkEdu/DoctorJMJkEduArticleController.java
  14. 11 0
      patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/team/AdminTeamController.java
  15. 5 2
      patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/third/jkEduArticle/ThirdJkEduArticleController.java

+ 9 - 0
common/common-entity/src/main/java/com/yihu/wlyy/entity/login/LoginLog.java

@ -18,6 +18,7 @@ public class LoginLog  extends IdEntity {
    private String userType;//1 患者 2医生
    private Long tokenId;//登录的tokenid
    private String type;//登录成功1 成功 2失败
    private Integer platform;//1患者端,2医生端app,3微信公众号wechat,4 IM医生端pc, PC端取药系统,5医生助手公众号
    private Date createTime;//创建时间
    private String errorMessage;//错误信息
    private String phone;//电话号码
@ -94,4 +95,12 @@ public class LoginLog  extends IdEntity {
    public void setAppVersion(String appVersion) {
        this.appVersion = appVersion;
    }
    public Integer getPlatform() {
        return platform;
    }
    public void setPlatform(Integer platform) {
        this.platform = platform;
    }
}

+ 11 - 4
patient-co-manage/wlyy-manage/src/main/java/com/yihu/wlyy/controller/manager/datastatic/PrescriptionStaticController.java

@ -7,10 +7,7 @@ import jxl.Workbook;
import jxl.write.*;
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 javax.servlet.http.HttpServletResponse;
import java.io.IOException;
@ -35,6 +32,16 @@ public class PrescriptionStaticController extends BaseController {
		return "prescription/prescription_list";
	}
	
	@RequestMapping(value = "infoInit/{code}",method = RequestMethod.GET)
	public String infoInit(@PathVariable(value = "code") String code){
		return "prescription/prescription_info";
	}
	
	@RequestMapping(value = "orderInit/{code}",method = RequestMethod.GET)
	public String orderInit(@PathVariable(value = "code") String code){
		return "prescription/prescription_order";
	}
	
	@RequestMapping(value = "list")
	@ResponseBody
	public String searchPatientList(

+ 246 - 0
patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_info.jsp

@ -0,0 +1,246 @@
<%@ page contentType="text/html; charset=UTF-8" language="java" pageEncoding="UTF-8" %>
<%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
    <%@ include file="../head/page_head.jsp"%>
    <title>续方详情</title>
</head>
<style>
    .m-form-group label.label_title {
        width: 100px
    }
    .fd-label{
        font-size: 12px;
        font-weight: bold!important;
    }
    .fd-input{
        width: 150px;
        border: none;
        font-size: 12px;
        height: 30px;
        margin-bottom: 5px;
    }
    .fd-padl{
        margin-left: 24px;
    }
    .fd-autoh{
        height: auto;
    }
    .fd-pd{
        padding: 35px 35px 10px 35px;
    }
    .fd-group{
        display: -webkit-box;
        display: -moz-box;
        display: -ms-flexbox;
        display: flex;
    }
    .fd-img img{
        width: 100px;
        height: 100px;
        margin-right: 20px;
    }
    .fd-img img:last-child{
        margin-right: 0px;
    }
    .fd-file{
        font-size: 12px;
        font-weight: bold;
        padding-left: 35px;
        padding-right: 10px;
        display: -webkit-box;
        -webkit-box-align: center;
        display: -moz-box;
        -moz-box-align: center;
        display: -ms-flexbox;
        -ms-flex-align: center;
        display: flex;
        align-items: center;
    }
    .no-img{
        display: -webkit-box;
        -webkit-box-align: center;
        display: -moz-box;
        -moz-box-align: center;
        display: -ms-flexbox;
        -ms-flex-align: center;
        display: flex;
        align-items: center;
    }
    .fd-bttn{
        width: 100px;
        height: 35px;
        display: block;
        margin:40px auto 0px;
        background-color: #b9c8d2;
        color: #fff;
        line-height: 35px;
        text-align: center;
    }
    .ad-padd{
        height: 280px;
        width: 100%;
        padding: 10px;
        border: solid 1px #dcdcdc;
        border-radius: 2px;
        font-size: 12px;
    }
    .ad-padd::-webkit-input-placeholder{
        color:#ccc;
    }
    .ad-padd::-moz-placeholder{
        color:#ccc;
    }
    .ad-padd:-moz-placeholder{
        color:#ccc;
    }
    .ad-padd:-ms-input-placeholder{
        color:#ccc;
    }
    .ad-result{
        margin: 20px 35px 0px 35px;
        border-top: solid 1px #ccc;
        padding-top:10px ;
    }
    .ad-label{
        text-align: left!important;
        padding-left: 0px!important;
        font-weight: bold!important;
    }
    .ad-pd{
        padding-top: 35px;
    }
</style>
<body>
<div id="div_roles_info_form" class="m-form-inline f-mt20" data-role-form>
    <div id="detail">
        <div style="margin-left:10px;">
            <label class="label_title fd-label">原处方记录</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">开方时间:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">开方医生:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="min-length-6 validate-special-char" />
            </div>
        </div>
        <div class="m-form-group" style="">
            <label class="label_title fd-label">科室/医生</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="ajax min-length-2 validate-special-char"  />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">居民信息</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">续方居民:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">医保卡号:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="min-length-6 validate-special-char" />
            </div>
        </div>
        <div class="m-form-group" style="">
            <label class="label_title fd-label">身份证号</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="ajax min-length-2 validate-special-char"  />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">临床诊断</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">续方居民:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">RP.</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">药品名称1 </label>
            <label class="label_title fd-label"> 用法:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">总量:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">规格:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">续方信息</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">续方状态:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">续方说明:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">审核记录</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">申请时间:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">审核医生:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="min-length-6 validate-special-char" />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">审核机构:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="ajax min-length-2 validate-special-char"  />
            </div>
            <label class="label_title fd-label">审核医生:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="ajax min-length-2 validate-special-char"  />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">结果:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="ajax min-length-2 validate-special-char"  />
            </div>
        </div>
    </div>
</div>
</body>
<%@ include file="../head/page_foot.jsp" %>
<%@ include file="prescription_info_js.jsp" %>
</html>

+ 163 - 0
patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_info_js.jsp

@ -0,0 +1,163 @@
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="utf-8" %>
<%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags" %>
<script>
    (function ($, win) {
        $(function () {
            /* ************************** 变量定义 ******************************** */
            var Util = $.Util;
            var rolesInfo = null;
            // 表单校验工具类
            var jValidation = $.jValidation;
            var dialog = frameElement.dialog;
            /* *************************** 函数定义 ******************************* */
            function pageInit() {
                rolesInfo.init();
                $('#image').on('click','img',function(){
                    var imgSrc = $(this).attr('src');
                    var html = '<img src="'+imgSrc+'" alt="."/>';
                    var imgView =  $('#fd-img-view', parent.document);
                    imgView.find('.fd-img-show').html(html);
                    imgView.show();
                })
            }
            /* *************************** 模块初始化 ***************************** */
            rolesInfo = {
                dealDialog:null,
                $type: $("#type"),//申诉类型
                $name: $("#name"),//姓名
                $identity:$("#identity"),//身份
                $phone:$("#phone"),//联系方式
                $createTime:$("#createTime"),//时间
                $idcard:$("#idcard"),//身份证
                $description:$("#description"),//申诉详情
                $result:$("#result1"),//处理结果
                $btndeal: $("#deal"),//处理按钮
                $btnclose: $("#close"),//关闭按钮
                $image:$("#image"),
                init: function () {
                    _this = this;
                    var id = $("#id").val();
                    //id不为空,初始化数据
                    if (isNoEmpty(id)) {
                        $.ajax({
                            url: ctx + "/admin/appeal/getAppealById",
                            method: "post",
                            dataType: "json",
                            data: {id: id},
                            success: function (result) {
                                if (result.status == '200') {
                                    var data = result.data;
                                    if(data.type==1){
                                        _this.$type.val("手机号变更");
                                    }else if(data.type==2){
                                        _this.$type.val("重置密码");
                                    }else{
                                        _this.$type.val("其他");
                                    }
                                    _this.$name.val(data.name);
                                    if(data.identity==1){
                                        _this.$identity.val("患者")
                                    }else{
                                        _this.$identity.val("医生")
                                    }
                                    _this.$phone.val(data.phone);
                                    _this.$idcard.val(data.idcard);
                                    _this.$createTime.val(data.createTime);
                                    _this.$description.val(data.description);
                                    if (isNoEmpty(data.result)) {
                                        _this.$result.val(data.result);
                                        $("#dealResult").show();
                                        $("#deal").hide();
                                    }
                                    if(data.images){
                                        var arr = data.images.split(',');
                                        var html="";
                                        for(var i=0;i<arr.length;i++){
                                            html += '<img src="'+data.imgUrlDomain+arr[i]+'" alt="."/>';
                                        }
                                        _this.$image.html(html);
                                    }else{
                                        var html='<span class="no-img">没有上传图片</span>';
                                        _this.$image.html(html);
                                    }
                                }else{
                                    $.Notice.error(result.msg);
                                }
                            },
                        })
                    }
                    this.bindEvents();
                },
                bindEvents: function () {
                    $("#deal").click(function () {
                        $("#dealDiv").show();
                        dialog.set('title', '处理结果');
                        $("#detail").hide();
                    });
                    $("#close").click(function () {
                        parent.window.closeParentInfoDialog();
                    });
                    $("#sure").click(function () {
                        $("#sure").css("pointer-events", "none");
                        var result = $("#result").val();
                        var id = $("#id").val();
                        if (isNoEmpty(result)) {
                            if(result.length>400){
                                $.Notice.error("最多只能填写400个字");
                                $("#sure").css("pointer-events", "");
                            }else {
                                $.ajax({
                                    url: ctx + "/admin/appeal/dealAppeal",
                                    method: "post",
                                    dataType: "json",
                                    data: {id: id,
                                        result:result
                                    },
                                    success: function (result) {
                                        if (result.status == '200') {
                                            //todo  操作成功后的处理
                                            alert("操作成功");
                                            parent.window.closeParentInfoDialog();
                                        }else{
                                            $.Notice.error(result.msg);
                                            $("#sure").css("pointer-events", "");
                                        }
                                    },
                                })
                            }
                        }else{
                            //todo
                            $.Notice.error("请输入处理结果");
                            $("#sure").css("pointer-events", "");
                        }
                    });
                    $("#cancle").click(function () {
                        $("#dealDiv").hide();
                        dialog.set('title', '查看');
                        $("#detail").show();
                    });
                }
            };
            /* ************************* Dialog页面回调接口 ************************** */
            win.reloadRolesInfoGrid = function (msg) {
                if (isNoEmpty(msg)) {
                    $.Notice.success(msg);
                }
                rolesInfo.reloadGrid(msg);
            };
            win.closeInfoDialog = function () {
                rolesInfo.dealDialog.close();
            };
            win.closeParentDealDialog = function () {
                rolesInfo.dealDialog.close();
                rolesInfo.reloadGrid();
            };
            /* *************************** 页面初始化 **************************** */
            pageInit();
        })
    })(jQuery, window);
</script>

+ 27 - 8
patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_list_js.jsp

@ -26,11 +26,8 @@
            retrieve = {
                $element: $('.m-retrieve-area'),
                patientInfoDialog: null,
                remindInfoDialog:null,
                $noReply: $('#noReply'),
                $count: $('#count'),
                $rate: $('#rate'),
                prescriptionInfoDialog: null,
                prescriptionOrderDialog: null,
                grid: null,
                url: {
                    //接口链接
@ -128,7 +125,7 @@
                            {text: '支付成功/待配药', statusId: '50'},
                            {text: '配药成功/待配送', statusId: '60'},
                            {text: '配送中', statusId: '65'},
                            {text: '药品已配送', statusId: '69'},
                            {text: '药品到服务站', statusId: '69'},
                            {text: '配送到患者手中/已完成', statusId: '100'},
                            {text: '线下退费', statusId: '-4'},
                            {text: '支付超时', statusId: '-3'},
@ -223,10 +220,11 @@
                            {display: '配送方式', name: 'pay', align: "center"},
                            {display: '时间', name: 'create_time', width: '12%', align: "center"},
                            {
                                display: '操作', name: 'operator', width: '15%', align: "center", isSort: false,
                                display: '操作', name: 'operator', width: '20%', align: "center", isSort: false,
                                render: function (row) {
                                    var html = '';
                                    html += '<a  href="javascript:void(0)" onclick="javascript:' + Util.format("$.publish('{0}',['{1}'])", "patient:info:view", row.id) + '">查看</a>';
                                    html += '<a  href="javascript:void(0)" onclick="javascript:' + Util.format("$.publish('{0}',['{1}'])", "prescription:info:view", row.prescription_code) + '">续方详情</a>';
                                    html += '<a  style="margin-left:10px;" href="javascript:void(0)" onclick="javascript:' + Util.format("$.publish('{0}',['{1}'])", "prescription:order:view", row.prescription_code) + '">订单跟踪</a>';
                                    return html;
                                }
                            }
@ -303,6 +301,27 @@
                },
                bindEvents: function () {
                    var me = this;
                    $.subscribe('prescription:info:view', function (event, code) {
                        var title = '续方详情';
                        me.prescriptionInfoDialog = $.ligerDialog.open({
                            height: 600,
                            width: 900,
                            title: title,
                            url: ctx + '/admin/static/prescription/infoInit/' + code
                        })
                    });
                    $.subscribe('prescription:order:view', function (event, code) {
                        var title = '订单跟踪';
                        me.prescriptionOrderDialog = $.ligerDialog.open({
                            height: 600,
                            width: 900,
                            title: title,
                            url: ctx + '/admin/static/prescription/orderInit/' + code
                        })
                    });
                    //城市下拉
                    me.$inpDeviceName.on( 'change', function () {
                        me.setCityFun(me);

+ 221 - 0
patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_order.jsp

@ -0,0 +1,221 @@
<%@ page contentType="text/html; charset=UTF-8" language="java" pageEncoding="UTF-8" %>
<%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
    <%@ include file="../head/page_head.jsp"%>
    <title>订单跟踪</title>
</head>
<style>
    .m-form-group label.label_title {
        width: 100px
    }
    .fd-label{
        font-size: 12px;
        font-weight: bold!important;
    }
    .fd-input{
        width: 150px;
        border: none;
        font-size: 12px;
        height: 30px;
        margin-bottom: 5px;
    }
    .fd-padl{
        margin-left: 24px;
    }
    .fd-autoh{
        height: auto;
    }
    .fd-pd{
        padding: 35px 35px 10px 35px;
    }
    .fd-group{
        display: -webkit-box;
        display: -moz-box;
        display: -ms-flexbox;
        display: flex;
    }
    .fd-img img{
        width: 100px;
        height: 100px;
        margin-right: 20px;
    }
    .fd-img img:last-child{
        margin-right: 0px;
    }
    .fd-file{
        font-size: 12px;
        font-weight: bold;
        padding-left: 35px;
        padding-right: 10px;
        display: -webkit-box;
        -webkit-box-align: center;
        display: -moz-box;
        -moz-box-align: center;
        display: -ms-flexbox;
        -ms-flex-align: center;
        display: flex;
        align-items: center;
    }
    .no-img{
        display: -webkit-box;
        -webkit-box-align: center;
        display: -moz-box;
        -moz-box-align: center;
        display: -ms-flexbox;
        -ms-flex-align: center;
        display: flex;
        align-items: center;
    }
    .fd-bttn{
        width: 100px;
        height: 35px;
        display: block;
        margin:40px auto 0px;
        background-color: #b9c8d2;
        color: #fff;
        line-height: 35px;
        text-align: center;
    }
    .ad-padd{
        height: 280px;
        width: 100%;
        padding: 10px;
        border: solid 1px #dcdcdc;
        border-radius: 2px;
        font-size: 12px;
    }
    .ad-padd::-webkit-input-placeholder{
        color:#ccc;
    }
    .ad-padd::-moz-placeholder{
        color:#ccc;
    }
    .ad-padd:-moz-placeholder{
        color:#ccc;
    }
    .ad-padd:-ms-input-placeholder{
        color:#ccc;
    }
    .ad-result{
        margin: 20px 35px 0px 35px;
        border-top: solid 1px #ccc;
        padding-top:10px ;
    }
    .ad-label{
        text-align: left!important;
        padding-left: 0px!important;
        font-weight: bold!important;
    }
    .ad-pd{
        padding-top: 35px;
    }
</style>
<body>
<div class="m-form-inline f-mt20" data-role-form>
    <div id="detail">
        <div style="margin-left:10px;">
            <label class="label_title fd-label">续方记录</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">申请时间:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">审核医生:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="min-length-6 validate-special-char" />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">收药信息</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">配送方式:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">配送地点:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="min-length-6 validate-special-char" />
            </div>
        </div>
        <div class="m-form-group" style="">
            <label class="label_title fd-label">居民姓名</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="ajax min-length-2 validate-special-char"  />
            </div>
            <label class="label_title fd-label">居民电话</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="ajax min-length-2 validate-special-char"  />
            </div>
        </div>
        <div class="m-form-group" style="">
            <label class="label_title fd-label">配送员</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="ajax min-length-2 validate-special-char"  />
            </div>
            <label class="label_title fd-label">服务站地址</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text"  class="ajax min-length-2 validate-special-char"  />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">订单记录</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">订单状态:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">订单号:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">订单跟踪:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">出药机构:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
        </div>
        <div style="margin-left:10px;">
            <label class="label_title fd-label">药品信息.</label>
        </div>
        <div class="m-form-group" style="border-top: solid 1px #ccc;">
            <label class="label_title fd-label">药品名称1 </label>
            <label class="label_title fd-label"> 用法:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">总量:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
            <label class="label_title fd-label">规格:</label>
            <div class="l-text-wrapper m-form-control">
                <input class="fd-input" type="text" class="useTitle min-length-6 validate-special-char"  />
            </div>
        </div>
    </div>
</div>
</body>
<%@ include file="../head/page_foot.jsp" %>
<%@ include file="prescription_order_js.jsp" %>
</html>

+ 163 - 0
patient-co-manage/wlyy-manage/src/main/webapp/WEB-INF/views/prescription/prescription_order_js.jsp

@ -0,0 +1,163 @@
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="utf-8" %>
<%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags" %>
<script>
    (function ($, win) {
        $(function () {
            /* ************************** 变量定义 ******************************** */
            var Util = $.Util;
            var rolesInfo = null;
            // 表单校验工具类
            var jValidation = $.jValidation;
            var dialog = frameElement.dialog;
            /* *************************** 函数定义 ******************************* */
            function pageInit() {
                rolesInfo.init();
                $('#image').on('click','img',function(){
                    var imgSrc = $(this).attr('src');
                    var html = '<img src="'+imgSrc+'" alt="."/>';
                    var imgView =  $('#fd-img-view', parent.document);
                    imgView.find('.fd-img-show').html(html);
                    imgView.show();
                })
            }
            /* *************************** 模块初始化 ***************************** */
            rolesInfo = {
                dealDialog:null,
                $type: $("#type"),//申诉类型
                $name: $("#name"),//姓名
                $identity:$("#identity"),//身份
                $phone:$("#phone"),//联系方式
                $createTime:$("#createTime"),//时间
                $idcard:$("#idcard"),//身份证
                $description:$("#description"),//申诉详情
                $result:$("#result1"),//处理结果
                $btndeal: $("#deal"),//处理按钮
                $btnclose: $("#close"),//关闭按钮
                $image:$("#image"),
                init: function () {
                    _this = this;
                    var id = $("#id").val();
                    //id不为空,初始化数据
                    if (isNoEmpty(id)) {
                        $.ajax({
                            url: ctx + "/admin/appeal/getAppealById",
                            method: "post",
                            dataType: "json",
                            data: {id: id},
                            success: function (result) {
                                if (result.status == '200') {
                                    var data = result.data;
                                    if(data.type==1){
                                        _this.$type.val("手机号变更");
                                    }else if(data.type==2){
                                        _this.$type.val("重置密码");
                                    }else{
                                        _this.$type.val("其他");
                                    }
                                    _this.$name.val(data.name);
                                    if(data.identity==1){
                                        _this.$identity.val("患者")
                                    }else{
                                        _this.$identity.val("医生")
                                    }
                                    _this.$phone.val(data.phone);
                                    _this.$idcard.val(data.idcard);
                                    _this.$createTime.val(data.createTime);
                                    _this.$description.val(data.description);
                                    if (isNoEmpty(data.result)) {
                                        _this.$result.val(data.result);
                                        $("#dealResult").show();
                                        $("#deal").hide();
                                    }
                                    if(data.images){
                                        var arr = data.images.split(',');
                                        var html="";
                                        for(var i=0;i<arr.length;i++){
                                            html += '<img src="'+data.imgUrlDomain+arr[i]+'" alt="."/>';
                                        }
                                        _this.$image.html(html);
                                    }else{
                                        var html='<span class="no-img">没有上传图片</span>';
                                        _this.$image.html(html);
                                    }
                                }else{
                                    $.Notice.error(result.msg);
                                }
                            },
                        })
                    }
                    this.bindEvents();
                },
                bindEvents: function () {
                    $("#deal").click(function () {
                        $("#dealDiv").show();
                        dialog.set('title', '处理结果');
                        $("#detail").hide();
                    });
                    $("#close").click(function () {
                        parent.window.closeParentInfoDialog();
                    });
                    $("#sure").click(function () {
                        $("#sure").css("pointer-events", "none");
                        var result = $("#result").val();
                        var id = $("#id").val();
                        if (isNoEmpty(result)) {
                            if(result.length>400){
                                $.Notice.error("最多只能填写400个字");
                                $("#sure").css("pointer-events", "");
                            }else {
                                $.ajax({
                                    url: ctx + "/admin/appeal/dealAppeal",
                                    method: "post",
                                    dataType: "json",
                                    data: {id: id,
                                        result:result
                                    },
                                    success: function (result) {
                                        if (result.status == '200') {
                                            //todo  操作成功后的处理
                                            alert("操作成功");
                                            parent.window.closeParentInfoDialog();
                                        }else{
                                            $.Notice.error(result.msg);
                                            $("#sure").css("pointer-events", "");
                                        }
                                    },
                                })
                            }
                        }else{
                            //todo
                            $.Notice.error("请输入处理结果");
                            $("#sure").css("pointer-events", "");
                        }
                    });
                    $("#cancle").click(function () {
                        $("#dealDiv").hide();
                        dialog.set('title', '查看');
                        $("#detail").show();
                    });
                }
            };
            /* ************************* Dialog页面回调接口 ************************** */
            win.reloadRolesInfoGrid = function (msg) {
                if (isNoEmpty(msg)) {
                    $.Notice.success(msg);
                }
                rolesInfo.reloadGrid(msg);
            };
            win.closeInfoDialog = function () {
                rolesInfo.dealDialog.close();
            };
            win.closeParentDealDialog = function () {
                rolesInfo.dealDialog.close();
                rolesInfo.reloadGrid();
            };
            /* *************************** 页面初始化 **************************** */
            pageInit();
        })
    })(jQuery, window);
</script>

+ 105 - 1
patient-co/patient-co-wlyy-job/src/main/java/com/yihu/wlyy/service/app/prenatalInspector/PrenatalInspectorPreCardService.java

@ -1,5 +1,7 @@
package com.yihu.wlyy.service.app.prenatalInspector;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONArray;
import com.yihu.wlyy.entity.doctor.profile.Doctor;
import com.yihu.wlyy.entity.message.Message;
import com.yihu.wlyy.entity.patient.Patient;
@ -14,6 +16,7 @@ import com.yihu.wlyy.repository.patient.PrenatalInspectorRecordDao;
import com.yihu.wlyy.repository.patient.SignFamilyDao;
import com.yihu.wlyy.service.BaseService;
import com.yihu.wlyy.service.app.sign.FamilyContractService;
import com.yihu.wlyy.service.third.jw.JwMaternalChildService;
import com.yihu.wlyy.task.PushMsgTask;
import com.yihu.wlyy.util.DateUtil;
import com.yihu.wlyy.wechat.util.WeiXinAccessTokenUtils;
@ -50,6 +53,8 @@ public class PrenatalInspectorPreCardService extends BaseService {
    private SignFamilyDao signFamilyDao;
    @Autowired
    private DoctorDao doctorDao;
    @Autowired
    private JwMaternalChildService jwMaternalChildService;
    /**
@ -120,7 +125,7 @@ public class PrenatalInspectorPreCardService extends BaseService {
    /**
     * 向医生发出产检系统消息
     */
    public void sendMessagePrenatal() throws Exception {
    public void sendMessagePrenatalBak() throws Exception {
        try {
            SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
            List<PrenatalInspectorPlan> planList = prenatalInspectorPlanDao.findByTime();
@ -148,6 +153,46 @@ public class PrenatalInspectorPreCardService extends BaseService {
    }
    /**
     * 向医生发出产检系统消息
     */
    public void sendMessagePrenatal() throws Exception {
        try {
            SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
            List<PrenatalInspectorPlan> planList = prenatalInspectorPlanDao.findByTime();
            for (PrenatalInspectorPlan plan : planList) {
                String code = plan.getPatient();
                String pregnancyNo = plan.getInspectionCode();
                Date planTime = plan.getInspectionTime();
                Patient patient = patientDao.findByCode(code);
                Date begin = DateUtil.getPreDays(planTime,-14);
                Date end = DateUtil.getPreDays(planTime,14);
                Long days = DateUtil.getDays(new Date(), planTime);
                String content = "您的签约居民" + patient.getName() + "超期未进行孕检,原计划孕检时间" + format.format(plan.getInspectionTime());
                if (StringUtils.isNotEmpty(pregnancyNo) && (pregnancyNo != null)) {
                    Boolean examStatus = getExamStatus(code, pregnancyNo, begin, end);
                    if (!examStatus) {
                        if (days > 7) {
                            SignFamily signFamily = signFamilyDao.findByPatient(code);
                            String doctor = signFamily.getDoctor();
                            String doctorHealth = signFamily.getDoctorHealth();
                            if (StringUtils.isNotEmpty(doctor)) {
                                saveMessageRecord(plan.getId().toString(), doctor, code, content);
                            }
                            if (StringUtils.isNotEmpty(doctorHealth)) {
                                saveMessageRecord(plan.getId().toString(), doctorHealth, code, content);
                            }
                        }
                    }
                }
            }
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
    /**
     * 保存系统消息及发送记录
     *
@ -209,4 +254,63 @@ public class PrenatalInspectorPreCardService extends BaseService {
        }
    }
    /**
     * 查询待产检计划产检时间在该时间段内是否有过真实产检
     * @param patient 居民code
     * @param pregnancyNo 产检号
     * @param begin  起始时间
     * @param end  截止时间
     * @return
     * @throws Exception
     */
    public Boolean getExamStatus(String patient,String pregnancyNo,Date begin,Date end) throws Exception {
        Boolean flag = false;
        try {
            SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
            JSONArray natals = reExamRecode(patient,pregnancyNo);
            for (Object natal : natals) {
                com.alibaba.fastjson.JSONObject examRecord = JSON.parseObject(natal.toString());
                String exam_time = examRecord.getString("EXAM_TIME");
                Date examTime = format.parse(exam_time);
                if ((examTime.getTime()<= end.getTime()) && (examTime.getTime() >= begin.getTime())){
                    return true;
                }
            }
        } catch (Exception e) {
            e.printStackTrace();
        }
        return flag;
    }
    /**
     * 复检记录
     *
     * @param patientCode
     * @return
     */
    public JSONArray reExamRecode(String patientCode, String pregnancyNo) {
        JSONArray re = new JSONArray();
        try {
            SignFamily signFamily = signFamilyDao.findByPatient(patientCode);
            String hospital = null;
            if (signFamily != null) {
                hospital = signFamily.getHospital();
            }
            Patient patient = patientDao.findByCode(patientCode);
            String response = jwMaternalChildService.getEhrMaternalReExamRecord(patient.getIdcard(), hospital, pregnancyNo);
            com.alibaba.fastjson.JSONObject json = com.alibaba.fastjson.JSONObject.parseObject(response);
            JSONArray data = null;
            if (json.getInteger("status") == 200) {
                data = json.getJSONObject("data").getJSONArray("DATA");
            }
            if (data != null && data.size() > 0) {
                return data;
            }
            return re;
        } catch (Exception e) {
            e.printStackTrace();
        }
        return re;
    }
}

+ 308 - 0
patient-co/patient-co-wlyy-job/src/main/java/com/yihu/wlyy/service/third/jw/JwMaternalChildService.java

@ -0,0 +1,308 @@
package com.yihu.wlyy.service.third.jw;
import com.yihu.wlyy.util.HttpClientUtil;
import org.apache.http.NameValuePair;
import org.apache.http.message.BasicNameValuePair;
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.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Service;
import java.util.ArrayList;
import java.util.List;
/**
 * Created by yeshijie on 2017/9/25.
 */
@Service
public class JwMaternalChildService {
    private static final Logger logger = LoggerFactory.getLogger(JwMaternalChildService.class);
    //基卫服务地址
    @Value("${sign.check_upload}")
    private String jwUrl;
    @Autowired
    private HttpClientUtil httpClientUtil;
    @Autowired
    private JdbcTemplate jdbcTemplate;
    /**
     * 获取孕妇建卡信息
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String getEhrMaternalFirstExamRecord(String idcard,String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalFirstExamRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取非第一次产检记录
     * @param idcard 身份证
     * @param hospital 医院code
     * @param pregnancyNo 产检号
     * @return
     * @throws Exception
     */
    public String getEhrMaternalReExamRecord(String idcard,String hospital,String pregnancyNo) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalReExamRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        params.add(new BasicNameValuePair("pregnancyNo", pregnancyNo));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取产床预约信息
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String getEhrMaternalBedPrecontractRecord(String idcard,String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalBedPrecontractRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取高危产妇信息
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String getEhrMaternalPregnancyHighRecord( String idcard, String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalPregnancyHighRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取孕妇分娩信息
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String getEhrMaternalDeliveryRecord(String idcard, String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalDeliveryRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取新生儿基本信息
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String getEhrMaternalDeliveryChildRecord(String idcard,String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalDeliveryChildRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取儿童健康体检0-6岁记录
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String getEhrMaternalChildMedicalRecord(String idcard,String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalChildMedicalRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取新生儿访视信息
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String getEhrMaternalHomeVisitRecord(String idcard,String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalHomeVisitRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取新生儿免疫记录
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String getEhrMaternalChildImmuneRecord(String idcard,String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalChildImmuneRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取孕妇预建卡信息
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String getEhrMaternalPreFirstExamRecord(String idcard,String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalPreFirstExamRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 上传孕妇预建卡信息
     * @param code 预建卡code
     * @return
     * @throws Exception
     */
    public String SaveEhrMaternalPreFirstExamRecord(String code) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/SaveEhrMaternalPreFirstExamRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("code", code));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 上传新生儿访视信息
     * @param idcard 身份证
     * @param hospital 医院code
     * @return
     * @throws Exception
     */
    public String SaveEhrMaternalHomeVisitRecord(String idcard,String hospital) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/SaveEhrMaternalHomeVisitRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取待产记录
     * @param idcard 身份证
     * @param hospital 医院code
     * @param searchTime 查询时间
     * @return
     * @throws Exception
     */
    public String getEhrMaternalZSPreDeliveryRecord(String idcard,String hospital,String searchTime) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalZSPreDeliveryRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        params.add(new BasicNameValuePair("searchTime", searchTime));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取阴道分娩记录
     * @param idcard 身份证
     * @param hospital 医院code
     * @param searchTime 查询时间
     * @return
     * @throws Exception
     */
    public String getEhrMaternalZSDeliveryRecord(String idcard, String hospital, String searchTime) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalZSDeliveryRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        params.add(new BasicNameValuePair("searchTime", searchTime));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
    /**
     * 获取剖宫产记录
     * @param idcard 身份证
     * @param hospital 医院code
     * @param searchTime 查询时间
     * @return
     * @throws Exception
     */
    public String getEhrMaternalZSCaesareanBirthRecord(String idcard, String hospital, String searchTime) throws Exception{
        String url = jwUrl + "/third/prenatalInspector/getEhrMaternalZSCaesareanBirthRecord";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("idcard", idcard));
        params.add(new BasicNameValuePair("hospital", hospital));
        params.add(new BasicNameValuePair("searchTime", searchTime));
        String response = httpClientUtil.post(url, params, "UTF-8");
        return response;
    }
}

+ 17 - 0
patient-co/patient-co-wlyy-job/src/main/java/com/yihu/wlyy/util/DateUtil.java

@ -368,6 +368,23 @@ public class DateUtil {
		return mydate1;
	}
	/**
	 * 时间前推或后推天数(负数前推正数后推)
	 * date 基准时间
	 */
	public static Date getPreDays(Date date, int days) {
		Date day = null;
		try {
			Calendar c = Calendar.getInstance();
			c.setTime(date);
			c.add(Calendar.DATE, days);
			day = c.getTime();
		} catch (Exception e) {
		}
		return day;
	}
	/**
	 * 得到一个时间延后或前移几分钟的时间,nowdate为时间,delay为前移或后延的分钟数
	 */

+ 24 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/team/AdminTeamService.java

@ -237,6 +237,30 @@ public class AdminTeamService extends BaseService {
        return memberDao.findDoctorTeams(doctorCode);
    }
    /**
     * 获取行政团队,包括团队签约人数
     * @param doctorCode
     * @return
     */
    public com.alibaba.fastjson.JSONArray getAdminTeamSignCount(String doctorCode){
        List<AdminTeam> adminTeams = memberDao.findDoctorTeams(doctorCode);
        com.alibaba.fastjson.JSONArray re = new com.alibaba.fastjson.JSONArray();
        for(AdminTeam one:adminTeams){
            //获取团队签约数
            Integer signCount = signFamilyDao.findByAdminTeamIdAndStatus(one.getId(),0);
            com.alibaba.fastjson.JSONObject json = new com.alibaba.fastjson.JSONObject();
            json.put("id",one.getId());
            json.put("name",one.getName());
            json.put("createTime",one.getCreateTime());
            json.put("leaderCode",one.getLeaderCode());
            json.put("available",one.isAvailable());
            json.put("orgCode",one.getOrgCode());
            json.put("signCount",signCount);
            re.add(json);
        }
        return re;
    }
    /**
     * 获取行政团队
     * @param doctorCode

+ 1 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/common/account/LoginController.java

@ -121,6 +121,7 @@ public class LoginController extends BaseController {
        loginLog.setPhone(mobile);
        loginLog.setType("2");
        loginLog.setUserType("2");
        loginLog.setPlatform(platform);
        loginLog.setAppVersion(super.getAppVersion());
        try {
            if (StringUtils.isEmpty(getIMEI())) {

+ 46 - 6
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/jimeiJkEdu/DoctorJMJkEduArticleController.java

@ -253,7 +253,7 @@ public class DoctorJMJkEduArticleController extends BaseController {
     * @param firstLevelCategoryId
     * @param secondLevelCategoryId
     * @param insertTimeStart
     * @param insertTimeEnd
     * @param insertTimeEnds
     * @param articlelevel
     * @param articleTitle
     * @return
@ -272,10 +272,10 @@ public class DoctorJMJkEduArticleController extends BaseController {
                                      @RequestParam(value = "articlelevel", required = false) String articlelevel,
                                      @ApiParam(name = "articleTitle", value = "文章标题关键字")
                                      @RequestParam(value = "articleTitle", required = false) String articleTitle,
//                                      @ApiParam(name = "currentUserRole", value = "当前登录的角色")
//                                      @RequestParam(value = "currentUserRole", required = true) String currentUserRole,
//                                      @ApiParam(name = "currentUserRoleLevel", value = "当前登录的角色级别")
//                                      @RequestParam(value = "currentUserRoleLevel", required = true )String currentUserRoleLevel,
                                      @ApiParam(name = "currentUserRole", value = "当前登录的角色")
                                      @RequestParam(value = "currentUserRole", required = true) String currentUserRole,
                                      @ApiParam(name = "currentUserRoleLevel", value = "当前登录的角色级别",defaultValue = "4")
                                      @RequestParam(value = "currentUserRoleLevel", required = false ,defaultValue = "4")String currentUserRoleLevel,
                                      @ApiParam(name = "isAuthentication", value = "是否认证")
                                      @RequestParam(value = "isAuthentication", required = false) String isAuthentication,
                                      @ApiParam(name = "isMyArticle", value = "是否过滤我的文章")
@ -287,8 +287,9 @@ public class DoctorJMJkEduArticleController extends BaseController {
        try {
            
            
            JSONObject response = jmJkEduArticleService.queryArticlePcList(firstLevelCategoryId,secondLevelCategoryId,insertTimeStart,insertTimeEnd,articlelevel,articleTitle,
                    getUID(),getCurrentRoleCode(),getCurrentRoleLevel(),isAuthentication,isMyArticle,page,pageSize);
                    getUID(),currentUserRole,currentUserRoleLevel,isAuthentication,isMyArticle,page,pageSize);
            
            return write(200,"查询成功!","data",response);
        } catch (Exception e){
@ -296,6 +297,45 @@ public class DoctorJMJkEduArticleController extends BaseController {
            return error(-1,"查询失败!");
        }
    }
    
    @RequestMapping(value = "saveArticle", method = RequestMethod.POST)
    @ApiOperation("添加文章")
    public  String saveArticle(@ApiParam(name = "articleId", value = "文章Id")
                               @RequestParam(value = "articleId", required = false) String articleId,
                               @ApiParam(name = "articleTitle", value = "文章标题")
                               @RequestParam(value = "articleTitle", required = true) String articleTitle,
                               @ApiParam(name = "articleType", value = "文章类型")
                               @RequestParam(value = "articleType", required = true) String articleType,
                               @ApiParam(name = "articlelevel", value = "文章级别")
                               @RequestParam(value = "articlelevel", required = true) Integer articlelevel,
                               @ApiParam(name = "secondLevelCategoryId", value = "文章二级分类id")
                               @RequestParam(value = "secondLevelCategoryId", required = true) String secondLevelCategoryId,
                               @ApiParam(name = "secondLevelCategoryName", value = "文章二级分类名称")
                               @RequestParam(value = "secondLevelCategoryName", required = true) String secondLevelCategoryName,
                               @ApiParam(name = "firstLevelCategoryId", value = "文章一级分类id")
                               @RequestParam(value = "firstLevelCategoryId", required = true) String firstLevelCategoryId,
                               @ApiParam(name = "firstLevelCategoryName", value = "文章一级分类名称")
                               @RequestParam(value = "firstLevelCategoryName", required = true) String firstLevelCategoryName,
                               @ApiParam(name = "content", value = "文章内容")
                               @RequestParam(value = "content", required = true) String content,
                               @ApiParam(name = "imageUrl", value = "文章封面图片地址")
                               @RequestParam(value = "imageUrl", required = true) String imageUrl,
                               @ApiParam(name = "currentUserRole", value = "当前登录的角色")
                               @RequestParam(value = "currentUserRole", required = true) String currentUserRole,
                               @ApiParam(name = "currentUserRoleLevel", value = "当前登录的角色级别",defaultValue = "4")
                               @RequestParam(value = "currentUserRoleLevel", required = false ,defaultValue = "4")String currentUserRoleLevel,
                               @ApiParam(name = "userScope", value = "使用范围(1、全市使用,2、全区使用,3、全社区使用)")
                               @RequestParam(value = "userScope", required = true) Integer userScope){
        
        try {
            jmJkEduArticleService.saveArticle(getUID(),articleTitle,articleType,articlelevel,secondLevelCategoryId,imageUrl,
                    secondLevelCategoryName,firstLevelCategoryId,firstLevelCategoryName,content,currentUserRole,currentUserRoleLevel,userScope,articleId);
            return success("添加成功!");
        }catch (Exception e){
            e.printStackTrace();
            return error(-1,"添加失败!");
        }
    }
    /*************************************************************************医生角色end***************************************************************************************************/

+ 11 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/team/AdminTeamController.java

@ -273,6 +273,17 @@ public class AdminTeamController extends BaseController {
        }
    }
    @RequestMapping(value = "/team/{doctor_code}/adminteams", method = RequestMethod.GET)
    @ApiOperation(value = "获取医生团队列表(包括团队签约人数)")
    public String getAdminTeamSignCount(@PathVariable("doctor_code") String doctorCode) {
        try {
            return write(200, "OK", "data", teamService.getAdminTeamSignCount(doctorCode));
        } catch (Exception e) {
            error(e);
            return error(-1, e.getMessage());
        }
    }
    @RequestMapping(value = "/team/{doctor_code}/teamsLimit", method = RequestMethod.GET)
    @ApiOperation(value = "获取医生团队列表(获取基位签约上线)")
    public String getDoctorTeamLimit(@PathVariable("doctor_code") String doctorCode){

+ 5 - 2
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/third/jkEduArticle/ThirdJkEduArticleController.java

@ -1,17 +1,16 @@
package com.yihu.wlyy.web.third.jkEduArticle;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import com.yihu.wlyy.aop.ObserverRequired;
import com.yihu.wlyy.service.third.jkEduArticle.ThirdJkEduArticleService;
import com.yihu.wlyy.web.BaseController;
import com.yihu.wlyy.web.third.gateway.service.GcEduArticleService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.jms.core.JmsTemplate;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;
@ -252,6 +251,10 @@ public class ThirdJkEduArticleController extends BaseController {
                }
                if(StringUtils.isNotBlank(cid)){
                    response = thirdJkEduArticleService.getCategoryList(2,cid,"");
                    com.alibaba.fastjson.JSONObject  result =  new JSONObject();
                    result.put("cid",cid);
                    result.put("list",response);
                    return write(200,"查询成功!","data",result);
                }else{
                    response = new JSONArray();
                }