Browse Source

修改个人资料相关页面

lulihong 6 years ago
parent
commit
61eea7b4a8

+ 1 - 1
html/grzx/html/account-safe.html

@ -72,7 +72,7 @@
				<img src="../images/qiehuanjiaren02_icon.png" width="18" height="18" class="vam mr5">
				<span class="c-f17 c-333">切换家人账号</span>
			</div>
			<div class="mt20 div-logout">
			<div class="mt20 div-logout" onclick="logout()">
				<img src="../images/tuichu_icon.png" width="18" height="18" class="vam mr5">
				<span class="c-f17 c-ff5e6c">退出当前账号</span>
			</div>

+ 1 - 1
html/grzx/html/my-detail.html

@ -31,7 +31,7 @@
						<img src="../images/yuyuehao_icon.png" width="40">
						<div class="mt10">预约号</div>
					</li>
					<li onclick="goPage('../../payment/html/PatientIDCards.html')">
					<li onclick="goPage('../../payment/html/patientIDCards.html')">
						<img src="../images/jiuzhenka_icon.png" width="40">
						<div class="mt10">我的卡包</div>
					</li>

+ 39 - 0
html/grzx/js/account-safe.js

@ -1,5 +1,8 @@
var userAgent = window.localStorage.getItem(agentName);
var firstUid = window.localStorage.getItem("firstUid");
var d1 = dialog({contentType:'load', skin:'bk-popup',content:'退出中..'});
var jsonstr = $.parseJSON(userAgent);
var openid = jsonstr.openid;
if(firstUid == null || firstUid == undefined){
	$('.div-qiehuan-account').hide()
}
@ -22,3 +25,39 @@ appendFamilyMember($('#memberContainer'), function() {
function goPage(url){
	window.location.href = url
}
function logout(){
	dialog({
            content:'您确定继续退出登录吗?',
            ok: function (){
                d1.show()
                sendPost("patient/wxloginout",{},"JSON","POST",function(res){
                    d1.close()
                    if (res && res.msg) {
                        dialog({contentType:'tipsbox',bottom:true, skin:'bk-popup' , content:res.msg}).show();      
                    } else {
                        dialog({contentType:'tipsbox',bottom:true, skin:'bk-popup' , content:'退出登录失败!'}).show(); 
                    }
                },function(res){
                    d1.close()
                    if(res.status==200){
                        clearAgent();
                        window.localStorage.removeItem("isTiXingVideoFaSong");//清除咨询详情移动网络下,用户点击不再提醒后的处理,换账号登陆后,还可以重新提醒
                        var url = window.location.href;
                        saveAgentPage(url);
                        location.replace("../../home/html/login.html?openid="+openid+"&loginType=password");
                    }else{
                        if (res && res.msg) {
                            dialog({contentType:'tipsbox',bottom:true, skin:'bk-popup' , content:res.msg}).show();      
                        } else {
                            dialog({contentType:'tipsbox',bottom:true, skin:'bk-popup' , content:'退出登录失败!'}).show(); 
                        }   
                    }
                })
            
            },
            cancel: function () {
                return;
            }
        }).showModal();
}

+ 13 - 1
html/yszx/html/add-consult.html

@ -17,6 +17,14 @@
		.c-333333{color:#333333}
		.s-bc-DCDCDC{background-color:#dcdcdc;}
		#commit.active{background-color:#74bf00;}
		.dw-bf,.dw-i{
			font-size: 18px;
		}
		.c-arrow-r{position: absolute;top: 50%;right: 10px;margin-top: -5px;content: "";display: block;width: 8px;height: 8px;border: solid #cdcdcd;border-width: 2px 2px 0 0;-webkit-transform: rotate(45deg);-moz-transform: rotate(45deg);-ms-transform: rotate(45deg);transform: rotate(45deg);}
		#lbl_patient_dummy{
			text-align: right;
			margin-right: 10px;
		}
	</style>
	</head>
	<body>
@ -34,7 +42,9 @@
				<li class="ptb12">
					<div class="n-list-key pr15 c-f16">咨询人员</div>
					<div class="n-list-info c-t-right">
						<label id="lbl_patient" class="c-f14 c-909090"></label>
						<select id="lbl_patient" class="c-t-right c-hide" placeholder="请选择咨询人员"></select>
                    	<div class="c-arrow-r"></div>
						<!--<label id="lbl_patient" class="c-f14 c-909090"></label>-->
					</div>
				</li>
			</ul>
@ -132,6 +142,8 @@
        <script type="text/javascript" src="../../../js/weixin_common.js" ></script>
        <script src="../../../widget/artDialog/6.0.5/js/dialog-plus.min.js"></script>
        <script type="text/javascript" src="../../../js/commit_validate.js" ></script>
          <link rel="stylesheet" type="text/css" href="../../../widget/mobiscroll/2.17.1/css/mobiscroll.css"/>
        <script src="../../../widget/mobiscroll/2.17.1/js/mobiscroll.js" type="text/javascript" charset="utf-8"></script>
        <script src="../js/add-consult.js" type="text/javascript" charset="utf-8"></script>                
	</body>
</html>

+ 36 - 1
html/yszx/js/add-consult.js

@ -10,13 +10,14 @@ $(function(){
    if(patientInfo){
        patientInfo = JSON.parse(patientInfo);
    }
    $("#lbl_patient").text(patientInfo.name);
//  $("#lbl_patient").text(patientInfo.name);
    
    //获取医生信息
    getDoctorInfo();
    
    bindEvents();
    getWxSign();
    getFamilyMembers();
})
function getDoctorInfo(){
@ -72,6 +73,40 @@ function bindEvents(){
    });
}
function getFamilyMembers(){
	sendPost("patient/family/authorize_members", {}, "json", "get", function(res){
		dialog({contentType:'tipsbox',bottom:true, skin:'bk-popup' , content:res.msg}).show();
	}, function(res){
		if (res.status == 200) {
			if (res.data.length > 0) {
				var html = '';
				for(i=0; i<res.data.length; i++){
					var item = res.data[i];
					html += '<option value="'+item.code+'">'+item.name+'</option>';
				}
				$('#lbl_patient').html(html);
	            $('#lbl_patient').mobiscroll().select({
	                theme: 'ios',
	                lang: 'zh',
	                display: 'bottom',
	                rows:5,
	                placeholder:'请选择咨询人员',
	                onSelect: function ( valueText, inst) {
	                	var wlyyAgent = localStorage.getItem("wlyyAgent");
	                	JSON.parse(wlyyAgent).uid = inst._tempValue;
	                	localStorage.setItem("wlyyAgent",wlyyAgent)
	                }
	            })
	            $("#patientInfo").val(patientInfo.uid).show()
			}else{
				dialog({contentType:'tipsbox',bottom:true, skin:'bk-popup' , content:'加载家庭成员失败'}).show(); 
			}
		}else{
			dialog({contentType:'tipsbox',bottom:true, skin:'bk-popup' , content:res.msg}).show(); 
		}	
	});
}
//验证信息
function validate(data) {   
    if (data.symptoms.length < 10) {