sign_detail.js 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425
  1. var httpData=GetRequest(),
  2. doctorInfo = JSON.parse(window.localStorage.getItem('wlyyAgent'))
  3. function showSuccessMessage(msg) {
  4. layer.msg(msg, {
  5. icon: 1
  6. })
  7. }
  8. function showErrorMessage(msg) {
  9. layer.msg(msg, {
  10. icon: 5
  11. })
  12. }
  13. function showWarningMessage(msg) {
  14. layer.msg(msg, {
  15. icon: 2
  16. })
  17. }
  18. function showInfoMessage(msg) {
  19. layer.msg(msg, {
  20. icon: 6
  21. })
  22. }
  23. new Vue({
  24. el: "#app",
  25. data: {
  26. isIjkTo:true,
  27. isLeader: null,
  28. isShowList1: false,
  29. isShowList2: false,
  30. isShowList3: false,
  31. isShowList4:false,
  32. isJudgeHealthDoctor: null,
  33. isJudgezkDoctor:null,
  34. isJudgeDoctor: null,
  35. isJudgeExpense: null,
  36. isSaveBtn: false,
  37. isSaveBtn1: false,
  38. isSaveBtn2: false,
  39. isSaveBtn3:false,
  40. patientInfo: {jtSign:{}},
  41. doctorTeam: {},
  42. patientInfo: null,
  43. doctorTeam: null,
  44. doctorList: null,
  45. memberList: null,
  46. zkDoctorList:null,
  47. dictList: null,
  48. adminTeamCode: null,
  49. fileList: null,
  50. serverName: null,
  51. isShowzkdoctor:false,
  52. },
  53. mounted() {
  54. this.patientSign();
  55. this.patientTeam();
  56. this.getDictByDictName();
  57. this.findPatientSignServerBySignCode()
  58. const url = new URL(window.location.href);
  59. const isTO = url.searchParams.get('isTO')
  60. if (isTO) {
  61. this.isIjkTo = false
  62. }else{
  63. this.isIjkTo = true
  64. }
  65. },
  66. methods: {
  67. patientSign: function() {
  68. var vm = this,
  69. loadding = layer.load(0, {shade: false}),
  70. params = {
  71. code: httpData.patientCode
  72. }
  73. signAPI.patientSign(params).then(function(res) {
  74. layer.close(loadding)
  75. if(res.status == 200) {
  76. vm.patientInfo = res.data
  77. vm.jsJudgeExpense = res.data.jtSign.expensesType
  78. } else {
  79. showErrorMessage(res.msg);
  80. }
  81. })
  82. },
  83. patientTeam: function() {
  84. var vm = this,
  85. loadding = layer.load(0, {shade: false}),
  86. params = {
  87. code: httpData.patientCode
  88. }
  89. signAPI.patientTeam(params).then(function(res) {
  90. layer.close(loadding)
  91. if(res.status == 200) {
  92. vm.doctorTeam = res.data
  93. vm.isJudgeHealthDoctor = vm.doctorTeam.healthDoctorCode
  94. vm.isJudgezkDoctor=vm.doctorTeam.specialist
  95. vm.isJudgeDoctor = vm.doctorTeam.doctorCode
  96. vm.isLeader = vm.doctorTeam.isLeader
  97. if(vm.isLeader) {
  98. vm.teamMember()
  99. }
  100. } else {
  101. showErrorMessage(res.msg);
  102. }
  103. })
  104. },
  105. getDictByDictName: function() {
  106. var vm =this,
  107. loadding = layer.load(0, {shade: false}),
  108. params = {
  109. name: "SIGN_EXPENSES"
  110. }
  111. signAPI.getDictByDictName(params).then(function(res) {
  112. layer.close(loadding)
  113. if(res.status == 200) {
  114. vm.dictList = res.list
  115. } else {
  116. showErrorMessage(res.msg);
  117. }
  118. })
  119. },
  120. findPatientSignServerBySignCode: function() {
  121. var vm =this,
  122. loadding = layer.load(0, {shade: false}),
  123. params = {
  124. signCode: httpData.signCode
  125. };
  126. signAPI.findPatientSignServerBySignCode(params).then(function(res) {
  127. layer.close(loadding)
  128. if(res.status == 200) {
  129. vm.fileList = [];
  130. var len = res.data.length;
  131. if(res.data.length > 0) {
  132. vm.serverName = "";
  133. for(var i = 0; i < len; i++) {
  134. if(i == 0) {
  135. vm.serverName += res.data[i].serverTypeName
  136. } else {
  137. vm.serverName += ',' + res.data[i].serverTypeName
  138. }
  139. }
  140. if(vm.serverName.split(',').indexOf('高血压')>-1 || vm.serverName.split(',').indexOf('糖尿病')>-1){
  141. console.log('服务类型存在高血压,糖尿病')
  142. vm.isShowzkdoctor=true
  143. }else{
  144. vm.isShowzkdoctor=false
  145. }
  146. }
  147. $.each(res.data, function(i, v) {
  148. if(v.serverType == 8 || v.serverType == 9 || v.serverType == 11) {
  149. vm.fileList.push(v);
  150. }
  151. });
  152. } else {
  153. showErrorMessage(res.msg);
  154. }
  155. })
  156. },
  157. teamMember: function() {
  158. var vm = this,
  159. loadding = layer.load(0, {shade: false}),
  160. params = {
  161. teamId: vm.doctorTeam.teamId
  162. }
  163. signAPI.teamMember(params).then(function(res) {
  164. layer.close(loadding)
  165. vm.memberList = []
  166. vm.doctorList = []
  167. vm.zkDoctorList=[]
  168. if(res.status == 200) {
  169. $.each(res.data, function(i, v) {
  170. if(v.available && (v.level == 3 || v.level == 2)) {vm.memberList.push(v);}
  171. if(v.available && v.level == 2) {vm.doctorList.push(v);}
  172. vm.zkDoctorList.push(v)
  173. });
  174. } else {
  175. showErrorMessage(res.msg);
  176. }
  177. })
  178. },
  179. selectStatus: function(num) {
  180. if (num == 1) {
  181. this.isShowList3 = false;
  182. this.isShowList2 = false;
  183. this.isShowList4 = false;
  184. this.isShowList1 = !this.isShowList1;
  185. } else if (num == 2) {
  186. this.isShowList3 = false;
  187. this.isShowList1 = false;
  188. this.isShowList4 = false;
  189. this.isShowList2 = !this.isShowList2;
  190. }else if(num==4){
  191. this.isShowList1=false
  192. this.isShowList2=false
  193. this.isShowList3=false
  194. this.isShowList4=!this.isShowList4
  195. } else {
  196. this.isShowList1 = false;
  197. this.isShowList2 = false;
  198. this.isShowList4 = false;
  199. this.isShowList3 = !this.isShowList3;
  200. }
  201. },
  202. selectLi: function(num, data) {
  203. if(num == 1) {
  204. this.isShowList1 = false;
  205. if(data.code == this.isJudgeDoctor) {
  206. this.isSaveBtn = false
  207. } else {
  208. this.isSaveBtn = true
  209. }
  210. this.doctorTeam.doctorCode = data.code;
  211. this.doctorTeam.doctorName = data.name;
  212. }
  213. if(num == 2) {
  214. this.isShowList2 = false;
  215. if(data.code == this.isJudgeHealthDoctor) {
  216. this.isSaveBtn1 = false
  217. } else {
  218. this.isSaveBtn1 = true
  219. }
  220. this.doctorTeam.healthDoctorCode = data.code;
  221. this.doctorTeam.healthDoctorName = data.name;
  222. }
  223. if(num == 3) {
  224. this.isShowList3 = false;
  225. if(data.code == this.jsJudgeExpense) {
  226. this.isSaveBtn2 = false
  227. } else {
  228. this.isSaveBtn2 = true
  229. }
  230. this.patientInfo.jtSign.expensesType = data.code
  231. }
  232. if(num == 4){
  233. this.isShowList4=false
  234. if(data.code==this.isJudgezkDoctor){
  235. this.isSaveBtn3=false
  236. }else{
  237. this.isSaveBtn3=true
  238. }
  239. this.doctorTeam.specialist = data.code;
  240. this.doctorTeam.specialistName = data.name;
  241. }
  242. },
  243. // 把原来下拉选择框变成可搜索下拉选择框
  244. changeSelect4:function(val){
  245. var obj = {};
  246. obj = this.doctorList.find(function(item){
  247. return item.code === val;
  248. });
  249. this.doctorTeam.doctorName=obj.name
  250. if(val == this.isJudgeDoctor) {
  251. this.isSaveBtn = false
  252. } else {
  253. this.isSaveBtn = true
  254. }
  255. },
  256. changeSelect2:function(val){
  257. var obj = {};
  258. obj = this.memberList.find(function(item){
  259. return item.code === val;
  260. });
  261. this.doctorTeam.healthDoctorName=obj.name
  262. if(val == this.isJudgeHealthDoctor) {
  263. this.isSaveBtn1 = false
  264. } else {
  265. this.isSaveBtn1 = true
  266. }
  267. },
  268. changeSelect5:function(val){
  269. var obj = {};
  270. obj = this.zkDoctorList.find(function(item){
  271. return item.code === val;
  272. });
  273. this.doctorTeam.specialistName=obj.name
  274. if(val==this.isJudgezkDoctor){
  275. this.isSaveBtn3=false
  276. }else{
  277. this.isSaveBtn3=true
  278. }
  279. },
  280. showExpensesName: function(code) {
  281. var expensesName;
  282. if(!this.dictList) {
  283. return "请选择补贴类型";
  284. }
  285. for(var i = 0, len = this.dictList.length; i < len; i++) {
  286. if(code == this.dictList[i].code) {
  287. expensesName = this.dictList[i].value;
  288. }
  289. }
  290. return expensesName
  291. },
  292. handleExpensesStatus: function(status) {
  293. if(status == 0) return "&emsp;未缴费";
  294. if(status == 1) return "&emsp;已缴费";
  295. if(status == 2) return "&emsp;已退费";
  296. if(!status) return "";
  297. },
  298. setPatImg: function(str) {
  299. var imgStr = httpRequest.getImgUrl(str);
  300. if (imgStr == "") {
  301. return '../../../images/p-female.png';
  302. } else {
  303. return imgStr;
  304. }
  305. },
  306. lookPhoto: function(data) {
  307. layer.open({
  308. type: 2,
  309. area: ['100%', '100%'],
  310. title: "凭证预览",
  311. shade: 0.5,
  312. shadeClose: true,
  313. content: '../html/photo_show.html?serverType=' + data.serverType + '&patientCode=' + httpData.patientCode
  314. })
  315. },
  316. saveChange: function() {
  317. if(!this.isSaveBtn && !this.isSaveBtn1 && !this.isSaveBtn2 && !this.isSaveBtn3) {
  318. return false;
  319. }
  320. var vm = this,
  321. loadding = layer.load(0, {shade: false}),
  322. params = {
  323. patient: httpData.patientCode
  324. }
  325. if(this.isSaveBtn) {
  326. params.doctor = this.doctorTeam.doctorCode
  327. }
  328. if(this.isSaveBtn1) {
  329. params.healthDoctor = this.doctorTeam.healthDoctorCode
  330. }
  331. if(this.isSaveBtn3){
  332. params.specialist=this.doctorTeam.specialist
  333. }
  334. if(this.isSaveBtn2) {
  335. params.expensesType = this.patientInfo.jtSign.expensesType
  336. }
  337. signAPI.saveChange(params).then(function(res) {
  338. layer.close(loadding)
  339. if(res.status == 200) {
  340. showSuccessMessage(res.msg);
  341. vm.patientSign();
  342. vm.patientTeam();
  343. vm.isSaveBtn = false
  344. vm.isSaveBtn1 = false
  345. vm.isSaveBtn2 = false
  346. vm.isSaveBtn3 = false
  347. } else {
  348. showErrorMessage(res.msg);
  349. }
  350. })
  351. },
  352. showProject: function() {
  353. layer.open({
  354. type: 1,
  355. area: ['400px', '600px'],
  356. shade: 0.5,
  357. title: '个性化服务项目',
  358. shift: 2,
  359. closeBtn: 1,
  360. shadeClose: true, //点击遮罩关闭层
  361. content: '<div class="p20 pb0">'+
  362. '<h4><b>1、基本医疗服务</b></h4>'+
  363. '<div class="pb15">'+
  364. '<div class="pl20 pt5">'+
  365. '<div class="pb5">1.1 提供一般常见病、多发病、诊断明确的慢性病VIP诊疗服务(相对独立就诊服务区,每次诊疗时间不低于10分钟,个性化健康指导)。 </div>'+
  366. '</div>'+
  367. '</div>'+
  368. '<h4><b>2、免费提供以下基本公共卫生服务</b></h4>'+
  369. '<div class="pb15">'+
  370. '<ol class="pl20 pt5">'+
  371. '<div class="pb5">2.1 居民健康档案的建立和维护;</div>'+
  372. '<div class="pb5">2.2 健康评估、健康促进、健康干预;</div>'+
  373. '<div class="pb5">2.3 0~6岁儿童健康管理;</div>'+
  374. '<div class="pb5">2.4 孕产妇健康管理;</div>'+
  375. '<div class="pb5">2.5 老年人健康管理服务;</div>'+
  376. '<div class="pb5">2.6 预防接种服务;</div>'+
  377. '<div class="pb5">2.7 传染病报告和处理;</div>'+
  378. '<div class="pb5">2.8 高血压患者健康管理;</div>'+
  379. '<div class="pb5">2.9 Ⅱ型糖尿病患者健康管理;</div>'+
  380. '<div class="pb5">2.10 重性精神疾病患者管理;</div>'+
  381. '<div class="pb5">2.11 中医药健康管理。</div>'+
  382. '</ol>'+
  383. '</div>'+
  384. '<h4><b>3、免费提供以下个性化服务</b></h4>'+
  385. '<div class="pb15">'+
  386. '<div class="pl20 pt5">'+
  387. '<div class="pb5">3.1 由专科医师个性化技术指导。根据病情需求,由家庭医生预约,接受三级医院专科医师技术指导。 </div>'+
  388. '<div class="pb5">3.2 由“家庭医生服务团队”提供个性化健康管理、健康评估、健康咨询服务。协助签约居民参与社区自我健康管理团体活动,开展自我健康管理。利用手机APP、或微信公众号服务平台,提供便捷的健康咨询服务。</div>'+
  389. '<div class="pb5">3.3 上级医院专家预约服务及转诊服务。优先提供上级医院专家门诊预约(根据病情优先享受名院、名科、名医预约服务)、大型仪器设备检查预约及根据病情需要的转诊服务。</div>'+
  390. '<div class="pb5">3.4社区门诊预约服务。家庭医生会根据病情有针对性的为签约居民办理下次门诊预约服务。</div>'+
  391. '<div class="pb5">3.5为高血压、糖尿病等慢性病签约对象提供“三师共管”慢病精细化管理服务。重点为高血压、糖尿病等慢性病人提供日常随访、定期检查及全程健康管理等服务。根据病情发展及控制情况提供适时动态转库服务。病情不稳定期纳入强化管理库,由三师提供强化管理服务;病情稳定期纳入常规管理库,在专科医师指导下由全科医生团队提供常规管理服务;强化管理库及常规管理库病人依据病情实行动态流动,需转专科医师时优先及时安排。</div>'+
  392. '<div class="pb5">3.6为65岁以上老人提供日常随访、定期检查及全程健康管理等服务。为80岁以上老年人及失能半失能老人免费提供每年不少于一次上门出诊服务。签约老人可享受包括测血压、体格检查、用药指导、健康咨询等服务。</div>'+
  393. '</div>'+
  394. '</div>'+
  395. '<h4><b>4、参加厦门市基本医疗保险的本市户籍人员可享受以下医保优惠政策:</b></h4>'+
  396. '<div class="pb15">'+
  397. '<div class="pl20 pt5">'+
  398. '<div class="pb5">4.1 根据上级医院用药长期医嘱,向慢性病患者开具4-8周(含慢性病相关辅助用药)的门诊用药处方。</div>'+
  399. '<div class="pb5">4.2 在基层医疗卫生机构或医保定点门诊部就医,门诊医疗费不设起付标准,即参保职工个人医疗账户用完后直接进入社会统筹医疗基金支付段,参保居民直接进入社会统筹医疗基金支付段。</div>'+
  400. '<div class="pb5">4.3 住院医疗费不设二次及以上起付标准。</div>'+
  401. '</div>'+
  402. '</div>'+
  403. '<h4><b>5、签约对象在享受上述签约服务外,还可享受以下服务项目:</b></h4>'+
  404. '<div class="pb15">'+
  405. '<div class="pl20 pt5">'+
  406. '<div class="pb5">5.1 为有康复需求的康复患者免费建立康复、训练档案。提供针对性康复训练和康复治疗服务,相关服务按物价部门制定的标准收取服务费。</div>'+
  407. '<div class="pb5">5.2 为有需要的签约居民提供建立家庭病床、导尿、换药、上门测血糖、上门抽血检验等有偿上门服务。乙方需要甲方提供出诊等上门适宜医疗服务(不提供院外静脉输液),须先通过甲方的医学安全性评估,并签订相关免责申明。</div>'+
  408. '<div class="pb5">5.3优先安排彩超、肿瘤标志物检查、眼底筛查、24小时动态血压监测、糖尿病足筛查、尿微量蛋白检测等基本医疗收费项目及慢性疾病筛查服务项目。</div>'+
  409. '</div>'+
  410. '</div>'+
  411. '</div>',
  412. });
  413. }
  414. }
  415. })