123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744 |
- var idCardReg = /^(^[1-9]\d{7}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}$)|(^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])((\d{4})|\d{3}[Xx])$)$/,
- mobileReg = /^[1][3578][0-9]{9}$/,
- doctorCode,name, idCard, ssc, mobile, emerMobile, key, encyIdCard,
- healthManagementCode=[],
- healthManagementName=[],
- diseaseCode=[],
- diseaseName=[],
- currHealthManagement,currHealthManagementName,
- self,
- encryURL = "login/public_key",
- docInfo =null,
- userAgent,
- docType;
-
- // 登录者相关信息(包括userAgent)
- var loginerInfo = null,
- // 基础环境信息(包括当前webview、encry相关)
- baseEnv = null;
- // 专科医生li容器
- var $doctorZK = $('#doctor_zk'),
- // 慢病类别li容器
- $disease = $("#disease"),
- // 添加附件图标按钮
- $imgArea = $('.add-img'),
- // 提交按钮
- $upload = $('#upload'),
- // 姓名
- $nameInput = $("#name").find("input"),
- // 身份证
- $idcardInput = $("#idcard").find("input"),
- // 医保卡号
- $sscInput = $("#ssc").find("input"),
- // 手机号码
- $mobileInput = $("#mobile").find("input"),
- // 应急人联系电话
- $emerMoblieInput = $("#emerMoblie").find("input"),
- // 居民分组
- $groupInput = $("#li_group input"),
- // 是否慢病
- $chronicDiseaseSwitch = $(".tag_cyc"),
- // 慢病类别
- $diseaseInput = $("#disease input"),
- // 全科医生
- $doctorQKInput = $('#dortor_qke input[data-val=dortor_qke]'),
- // 健康管理师
- $doctorJGInput = $('#healthManagement input[data-val=healthManagement]'),
- // 专科医生
- $doctorZKInput = $("#doctor_zk input"),
- // 政府补贴费
- $expensesInput: $("#li_expenses input"),
- // 家庭医生签约协议(勾选框)
- $agree = $(".input-group-pack");
-
- var getLoginerInfo = function() {
- // 登录的相关信息
- var userAgent = JSON.parse(plus.storage.getItem("userAgent")),
- // 登录的医生类别
- docType = plus.storage.getItem("docType"),
- // 登录的医生信息
- docInfo= plus.storage.getItem("docInfo"),
- // 该医生(登录者)所在社区(机构)编码
- hospital = plus.storage.getItem("hospital");
- return {
- userAgent: userAgent,
- docInfo: $.extend(docInfo,{docType:docType},{hospital: hospital})
- }
- },
- getBaseEnvPromise = function () {
-
- var env = {
- webview: plus.webview.currentWebview(),
- encryURL: "login/public_key",
- encryKey: ""
- };
- return new Promise(function(resolve, reject) {
- RSAUtils.getKeyFromServer(encryURL, function(res) {
- if(res.status == 200) {
- var mod = res.data.modulus;
- var exp = res.data.exponent;
- // key = RSAUtils.getKeyPair(exp, "", mod);
- env.encryKey = RSAUtils.getKeyPair(exp, "", mod);
- resolve(env);
- }
- });
- });
- },
- // 打开协议书页面
- toXieYiShu = function() {
- mui.openWindow('../../qygl/html/xieyishu.html', 'xieyishu', {});
- },
- // 获取全科医生
- qke = function (){
- var userAgent = loginerInfo.userAgent,
- hospital =userAgent.hospital;
-
- getReqPromise("/doctor/findDoctorByLevelAndHospital",{hospital:hospital,level:2})
- .then(function(res) {
- if(res.status == 200) {
- var doctors = res.doctors,
- qkeCodes=[],
- qkeNames=[];
- // 萃取数组对象中code、name,返回一个数组
- qkeCodes = _.pluck(doctors, 'code');
- qkeNames = _.pluck(doctors, 'name');
- qkeSelect(qkeCodes,qkeNames);
- }
- }).catch(function(e) {
- console && console.error(e);
- });
- }
- // 设置全科医生下拉框
- qkeSelect = function (qkeCodes,qkeNames) {
- $doctorQKInput.mobiscroll({
- theme: 'ios',
- lang: 'zh',
- customWheels: true,
- wheels: [
- [{
- keys: qkeCodes,
- values: qkeNames
- }]
- ],
- onSelect: function(valueText, inst) {
- var dd = eval("[" + valueText + "]"),
- name=dd[0].values,
- currExpenses = dd[0].keys;
-
- $(this).val(name);
- $doctorQKInput.attr("data-code",currExpenses);
- }
- });
- },
- // 获取健康管理医生列表
- reqDoctorJG = function() {
- var docInfo = loginerInfo.docInfo,
- // 登录医生的类别。1:专科医生,2:全科医生,3:健康管理师
- docType = docInfo.docInfo,
- // 请求路径,根据医生类别不同而不同
- url,
- // 请求参数
- params,
- // 所在机构(社区)
- hospital = docInfo.hospital;
-
- if(docType==2){
- url = "/doctor/doctor_combobox";
- params={type:3,hospital:hospital}
- }else{
- url = "/doctor/findDoctorByLevelAndHospital";
- params={hospital:hospital,level:docType}
- }
-
- getReqPromise(url,params).then(function(res) {
- var doctors, healthManagementCodes, healthManagementNames;
- if(res.status == 200) {
- // 如果是健康管理师 取res.doctors,如果是全科医生取res.list
- doctors = (docType==3)? res.doctors: ((docType==2)? res.list: []);
- // 萃取数组对象中code、name,返回一个数组
- healthManagementCodes = _.pluck(doctors, 'code');
- healthManagementNames = _.pluck(doctors, 'name');
- activHealthM(healthManagementCodes, healthManagementNames);
- };
- }).catch(function(e) { console && console.error(e); });
- },
- // 健康管理师下拉框
- function activHealthM(codes,names) {
- $doctorJGInput.mobiscroll({
- theme: 'ios',
- lang: 'zh',
- customWheels: true,
- wheels: [
- [{
- keys: codes,
- values: names
- }]
- ],
- onSelect: function(valueText, inst) {
- var dd = eval("[" + valueText + "]");
- $(this).val(dd[0].values);
- currHealthManagement = dd[0].keys;
- currHealthManagementName = dd[0].values;
- }
- });
- },
- // 获取政府补贴数据
- setExpenses = function (){
- var expensesCodes=[],expensesNames=[];
-
- getReqPromise("/common/getDictByDictName?name=SIGN_EXPENSES",null, "GET")
- .then(function(res) {
- if(res.status == 200) {
- var expensesList = res.list;
- // 萃取数组对象中code、value属性值,返回一个数组
- expensesCodes = _.pluck(expensesList, 'code');
- expensesNames = _.pluck(expensesList, 'value');
- activExpensesM(expensesCodes,expensesNames);
- };
- }).catch(function(e) {
- console && console.error(e);
- });
- },
- // 设置政府补贴下拉框
- activExpensesM = function (expensesCodes,expensesNames) {
- $expensesInput.mobiscroll({
- theme: 'ios',
- lang: 'zh',
- customWheels: true,
- wheels: [
- [{
- keys: expensesCodes,
- values: expensesNames
- }]
- ],
- onSelect: function(valueText, inst) {
- var dd = eval("[" + valueText + "]"),
- name=dd[0].values,
- currExpenses = dd[0].keys;
-
- $(this).val(name);
- $expensesInput.attr("data-code",currExpenses);
- }
- });
- },
- // 请求慢病类别列表数据
- reqDiseaseTypes = function() {
- // TODO 慢病类别列表数据(此版本先固定)
- var diseaseData= {"msg":"查询成功!","list":[{"code":"1","name":"高血压",},{"code":"2","name":"糖尿病",}],"status":200} ;
- // 萃取数组对象中code、value属性值,返回一个数组
- var codes = _.pluck(expensesList, 'code'),
- names = _.pluck(expensesList, 'value');
- initDiseaseTypes(codes, names);
- },
- // 初始化慢病类别列表
- initDiseaseTypes = function(codes, names) {
- $diseaseInput.mobiscroll({
- theme: 'ios',
- lang: 'zh',
- customWheels: true,
- wheels: [
- [{
- keys: codes,
- values: names
- }]
- ],
- onSelect: function(valueText, inst) {
- var dd = eval("[" + valueText + "]"),
- currdiseaseCode = dd[0].keys;
-
- $(this).val(dd[0].values);
- $diseaseInput.attr("data-code",currdiseaseCode);
- }
- });
- },
- getSSCNoByIdcard = function(idcard) {
- var checkUrl = "doctor/patient_cardno";
- getReqPromise(checkUrl,{idcard:idcard}).then(function(res) {
- if(res.status=='200'){
- $sscInput.val(res.data);
- if(res.data){
- $sscInput.attr("readonly","readonly");
- } else {
- $sscInput.removeAttr("readonly");
- }
- } else {
- mui.toast(res.msg);
- }
- });
- },
- // 慢病输入显示控制
- showChronicDiseaseInput = function(isShow) {
- if(true) {
- $chronicDiseaseSwitch.addClass("on");
- $doctorZK.css("display","-webkit-box");
- $disease.css("display","-webkit-box");
- } else {
- $chronicDiseaseSwitch.addClass("on");
- $doctorZK.css("display","-webkit-box");
- $disease.css("display","-webkit-box");
- }
- },
- // 图片缩放
- scaleRefresh = function (dom) {
- ImagesZoom.init({
- "elem": dom,
- "delBack": function(index) {
- $(".pic-count").text($(".pic-count").text() - 1); //删除图片后的回调
- $(dom).find("li").eq(index).remove();
- }
- });
- },
- getImagesPromise = function() {
- return new Promise(function(resolve, reject) {
- var uploadImgUrl = getCompressImg();
- if(uploadImgUrl) {
- uploadImg(uploadImgUrl, function(uploadObj) {
- var res = JSON.parse(uploadObj.responseText);
- resolve(res);
- });
- }
- });
-
- },
- // 获取表单数据
- getInputs = function() {
- var data = {
- name: $nameInput.val().trim(), // 姓名
- idcard: $idcardInput.val().trim(), // 身份证
- ssc: $sscInput.val().trim(), // 医保卡号
- mobile: $mobileInput.val().trim(), // 手机号码
- emerMoblie: $emerMoblieInput.val().trim(), // 应急人联系电话
- group: $groupInput.attr("data-code"), // 居民分组
- ismb: $chronicDiseaseSwitch.hasClass('on'), // 是否慢病,
- disease: $diseaseInput.attr("data-code") || 0, // 慢病类别code
- doctorQK: $doctorQKInput.attr("data-code"), // 全科医生code
- doctorNameQK: $doctorQKInput.val(), // 全科医生名字
- doctorJG: $doctorJGInput.attr("data-code"), // 健康管理师code
- doctorNameJG: $doctorJGInput.val(), // 健康管理师名字
- doctorZK: $doctorZKInput.attr("data-code"), // 专科医生code
- doctorNameZK: $doctorZKInput.val(), // 专科医生名字
- expenses: $expensesInput.attr("data-code"), // 政府补贴费
- uploadImgUrls: getCompressImg(), // 附件
- images: null,// 附件
- agree: $agree.hasClass("checked") // 家庭医生签约协议(是否勾选)
- };
-
- getImagesPromise().then(function(res) {
- if(res) {
- data.images = res.urls
- }
- });
- return data;
- },
- // 必输验证
- validRequired: function(data) {
- var fieldsStr = "name,idcard,ssc,mobile,doctorQK,doctorJG,agree",
- fieldsStr += data.ismb? ',doctorZK,disease': '',
- fieldMap = {
- name: "姓名",idcard:"身份证",ssc:"医保卡号",mobile:"手机号码",doctorQK:"全科医生",doctorJG:"健康管理师",doctorZK:"专科医生",disease:"疾病类型"
- },
- fields = fieldsStr.split(","),
- invalidField;
-
- invalidField = _.find(fields,function(key) {
- return !!data[key];
- });
- if(invalidField) {
- if(invalidField=="agree") {
- mui.toast("您还未接受签约协议");
- } else {
- mui.toast(fieldMap[invalidField]+'不能为空');
- }
-
- return false;
- } else {
- return true;
- }
- },
- // 输入格式验证
- validFormat: function(data) {
- var idCardReg = /^(^[1-9]\d{7}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}$)|(^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])((\d{4})|\d{3}[Xx])$)$/,
- mobileReg = /^[1][3578][0-9]{9}$/,
- sscReg = /^[a-zA-Z0-9]+$/;
- if(!idCardReg.test(data.idCard)) {
- $idcardInput.css("color","red")
- mui.toast("请填写有效身份证号");
- return false;
- }
- if(!sscReg.test(data.ssc)) {
- $sscInput.css("color","red")
- mui.toast("请填写有效的医保卡卡号");
- return false;
- }
- if(!mobileReg.test(data.mobile)) {
- $mobileInput.css("color","red");
- mui.toast("请填写有效的手机号码");
- return false;
- }
- if(data.emerMoblie && !mobileReg.test(data.emerMoblie)) {
- $emerMoblieInput.css("color","red")
- mui.toast("请填写有效的应急人联系方式");
- return false;
- }
- return true;
- },
- validInputByDBPromise = function(data) {
- var checkUrl = "doctor/family_contract/checkMoblie";
- return getReqPromises([{url: checkUrl,data:{mobile: data.mobile}}]).then(function(res) {
- var checkRes = res[0];
- if(checkRes.status==200) {
- if(checkRes.data.islive == "false") {
- dialog({
- content: "该手机号已签约!",
- ok: function() {
- $mobileInput.val("");
- }
- }).showModal();
- return false;
- } else {
- return true;
- }
-
- } else {
- mui.toast("手机号验证失败!");
- // $mobileInput.val("");
- return false;
- }
- });
- },
- // 所有输入验证
- validInputsPromise = function() {
- plus.nativeUI.showWaiting();
- // 表单数据
- var data = getInputs();
- return Promise.resolve()
- .then(function() {
- var flag = validRequired(data);
- if(!flag) throw new Error("必输校验失败");
- return flag;
- })
- .then(function(flag) {
- var flag = validFormat(data);
- if(!flag) throw new Error("格式校验失败");
- return flag;
- })
- .then(function() {
- return validInputByDBPromise(data);
- })
- .then(function(flag) {
-
- if(flag) return data;
- });
- },
- sendData = function (data) {
- var submitUrl = "doctor/family_contract/agent",
- docInfo = loginerInfo.docInfo,
- params = $.extend({},data,{
- doctor: data.doctorQK, //全科医生code
- doctorName: data.doctorNameQK, //全科医生名字
- signDoctorCode: docInfo.code, // 签约人code
- signDoctorName: docInfo.name, // 签约人名字
- signDoctorLevel: docInfo.docType, // 签约人等级
- idcard: RSAUtils.encryStr(baseEnv.encryKey, data.idcard),
- healthDoctor: data.doctorJG,
- healthDoctorName: data.doctorNameJG
- });
-
- //如果选择慢病
- if(data.ismb) {
- params.majorDoctor = data.doctorZK;
- params.majorDoctorName = data.doctorNameZK;
- }
-
- getReqPromise(submitUrl, params).then(function() {
- plus.nativeUI.closeWaiting();
- if(res.status == 200) {
- mui.confirm("代理签约成功, 是否继续代理签约?", "提示", ['是', '否'], function(e){
- if(e.index==0){
- baseEnv.webview.reload();
- } else{
- mui.fire(baseEnv.webview.opener(), 'updatePatiAmount');
- mui.later(function() {
- var hzWv = plus.webview.getWebviewById("huanzhe.html");
- if(hzWv) {
- mui.fire(hzWv, "update");
- }
- var syWv = plus.webview.getWebviewById("home2.html");
- if(syWv) {
- mui.fire(syWv, "refreshPatCount");
- }
- mui.back();
- }, 500);
- }
- })
-
- } else {
- mui.toast(res.msg);
- }
- });
- },
- bindEvents = function() {
- // 添加附件
- $imgArea.on('tap', '.add', function() {
- showActionSheet($imgArea[0], this);
- });
- // 提交
- $upload.on('tap', function() {
- plus.nativeUI.showWaiting();
- validInputsPromise().then(function(data) {
- if(data) {
- sendData(data);
- }
- });
-
- });
- // 选择分组
- $("body").on("click","#li_group",function(){
- mui.openWindow({
- url:"../../qygl/html/xiaoxichuli_fzgl.html",
- id:"xiaoxichuli_fzgl.html"
- })
- })
- // 点击家庭医生签约协议(勾选框)
- .on('click', '.input-group-pack', function() {
- $(this).toggleClass("checked");
- });
-
- $doctorZKInput.on("click",function(){
- mui.openWindow('hospital_list.html', 'hospital_list', {
- extras: {
- hosptialType: 1,
- callbackview:"dailiqianyue",
- callbackmethod:"getDoctor"
- }
- });
- })
-
- // 删除图片
- mui(".add-img").on("tap", ".icon-del", function() {
- var oli = this.parentElement;
- var oul = this.parentElement.parentElement;
- oul.removeChild(oli);
- });
-
- window.addEventListener('getDoctor', function(event) {
- $doctorZKInput.val(event.detail.name);
- $doctorZKInput.attr("data-code",event.detail.code);
- });
-
- /*分组事件*/
- window.addEventListener("group", function group(e) {
- var groupcode=e.detail.code
- var groupName=e.detail.name
- $groupInput.val(groupName).attr("data-code",groupcode)
- });
- };
- // 页面业务处理流程开始
- new Promise(function(resolve, reject) {
-
- mui.plusReady(function() {
- // plus已经准备好,可以往下执行
- resolve(true);
- })
- }).then(function() {
- // 获取基础环境信息
- getBaseEnvPromise().then(function(env) {
- baseEnv = env;
- }).then(function() {
- // 获取登录医生信息
- loginerInfo = getLoginerInfo();
- // 请求并初始化全科医生下拉框数据
- qke();
- // 请求并初始化健康管理师下拉框数据
- reqDoctorJG();
- // 请求并初始化政府补贴下拉框数据
- setExpenses();
- // 请求并初始化慢病类别下拉框数据
- reqDiseaseTypes();
- //图片缩放( 动态添加了上传的图片后运行一下下面这条这个)
- scaleRefresh(".upload-img-list");
- // 绑定页面事件
- bindEvents();
- }).catch(function(e) {
- console && console.error(e);
- })
- });
- mui.plusReady(function() {}
- mui.plusReady(function() {
-
- userAgent = JSON.parse(plus.storage.getItem("userAgent"));//登录的意思信息
- docType = JSON.parse(plus.storage.getItem("docType"));//登录的医生类别
- $("#doctor_zk").hide();
- docInfo= plus.storage.getItem("docInfo");
- docInfo = JSON.parse(docInfo);
- self = plus.webview.currentWebview();
- RSAUtils.getKeyFromServer(encryURL, function(res) {
- if(res.status == 200) {
- var mod = res.data.modulus;
- var exp = res.data.exponent;
- key = RSAUtils.getKeyPair(exp, "", mod);
- }
- });
- if(docType==2)//全科医生登录不显示 选择全科医生选项
- {
- $("#dortor_qke").hide()
- }else if(docType==3){//健康医生登录的时候 健康医生那个地方不能让选
- $("#healthManagement .no").show();
- }
- var hospital = plus.storage.getItem("hospital");
- //console.log(hospital);
- //健康管理师查询
- var healthManagementUrl//查询接口
- var params//参数
- if(docType==2){
- healthManagementUrl = "/doctor/doctor_combobox";
- params={type:3,hospital:hospital}
- }else{
- healthManagementUrl = "/doctor/findDoctorByLevelAndHospital";
- params={hospital:hospital,level:docType}
- }
-
- sendPost(healthManagementUrl, params, function(){
- mui.toast("健康管理师查询失败!");
- }, function(res) {
-
- if(res.status == 200) {
- if(docType==1){//专科
- }else if(docType==3){//健康管理师
- currHealthManagement=docInfo.code
- currHealthManagementName=docInfo.name
- $('#healthManagement input[data-val=healthManagement]').val(currHealthManagementName).attr("data-code",currHealthManagement);
-
- var healthManagementList = res.doctors;
- for(var i = 0; i < healthManagementList.length; i++) {
- healthManagementCode[i] = healthManagementList[i].code;
- healthManagementName[i] = healthManagementList[i].name;
- }
-
- }else{//全科
- //console.log(JSON.stringify(res))
- var healthManagementList = res.list;
-
- for(var i = 0; i < healthManagementList.length; i++) {
- healthManagementCode[i] = healthManagementList[i].code;
- healthManagementName[i] = healthManagementList[i].name;
- }
- }
-
- activHealthM();
- };
- });
-
- /* 签约三师 */
- function validIdCard(data) {
- // 该医生(登录者)所在社区(机构)编码
- var hospital = plus.storage.getItem("hospital"),
- // 该医生(登录者)基础信息
- docInfo = plus.storage.getItem("docInfo"),
- // 该医生(登录者)所在社区主编码(截取前8位,后两位是服务站)
- communityCode = hospital.slice(0,8),
- // 三师中全科医生所在社区主编码(截取前8位,后两位是服务站)
- qkCommunityCode = data.hospital.slice(0,8),
- // 该医生(登录者)编码
- doctor = docInfo.code,
- // 三师中全科医生编码
- qkDoctor = data.doctor,
- // 三师中全科医生是否在本社区
- isInCommunity = data.hospital,
- // 全科医生是否是该医生
- isSameDoctor = doctor == qkDoctor
-
- // ①三师中全科医生不在本社区,则弹窗提示“该居民已签约三师,无法继续签约”,点击“我知道了”,关闭弹窗,退出代理签约
-
- }
- // $("#idcard input").on("blur", function() {
- // $("#disease input").css("pointer-events", "");
- // $("#healthManagement input").css("pointer-events","");
- // $("#doctor_zk input").css("pointer-events", "");
- //// $("#ssc input").removeAttr("readonly");
- //
- // var $this = $(this);
- // var card = $this.val().trim();
- // if(!idCardReg.test(card) || !card) {
- // $("#idcard input").css("color","red")
- // mui.toast("请输入正确的身份证号!");
- // $("#ssc input").val("")
- // //$this.val("");
- //
- // return;
- // }else{
- // $("#idcard input").css("color","")
- // }
- // var checkUrl = "doctor/family_contract/patient_sanshi_signinfo";
- // sendPost(checkUrl,{idCard:card},null,function(res){
- // //console.log(JSON.stringify(res));
- // if(res.status=='200'){
- // var resultData =res.data;
- // //是三师签约,团队保持一致
- //
- // if(resultData.signStatus==1){
- // //如果当前登录是健康管理师
- // var qkcode="";
- // if(docType==2){
- // qkcode=docInfo.code;
- // }else if(docType==3){
- // qkcode=$('#dortor_qke input[data-val=dortor_qke]').attr("data-code");
- // }
- //
- //
- // //有三师签约,且全科医生不一致的情况下,不能进行签约
- // if(qkcode=="0" || qkcode==""){
- // mui.alert("请先选择全科医生,在填写身份证号");
- // $("#idcard input").val("")
- // $("#ssc input").val("")
- // return false;
- // }else if(qkcode!=resultData.doctor){
- //
- // //清空人员身份证
- // $('#idcard input').val("").attr("data-code","");
- // /*$("#info_list input").val("");
- // $("#info_list input").attr("data-code","");*/
- // mui.alert("存在三师签约,由于团队不一致无法进行签约!");
- // return false;
- // }else{
- // $("#doctor_zk").show();
- // $("#doctor_zk input").val(resultData.majorDoctorName);
- // $("#doctor_zk input").attr("data-code",resultData.majorDoctor);
- // $("#healthManagement input").val(resultData.healthDoctorName);
- // currHealthManagement = resultData.healthDoctor;
- // currHealthManagementName = resultData.healthDoctorName;
- // $("#healthManagement input").attr("data-code",resultData.healthDoctor);
- // $("#disease input").val(resultData.diseaseName);
- // $("#disease input").attr("data-code",resultData.disease);
- // $("#disease input").css("pointer-events","none");
- // $("#healthManagement input").css("pointer-events","none");
- // $("#doctor_zk input").css("pointer-events","none");
- // }
- //
- // }else if(resultData.signStatus==2){
- // alert(resultData.msg);
- // $("#info_list input").val("");
- // $("#info_list input").attr("data-code","");
- // return false;
- // } else {
- // activHealthM();
- // disease() ;
- // }
- // }
- //
- // getSSCNoByIdcard(card);
- //
- // });
-
|