index.html 3.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <meta http-equiv="X-UA-Compatible" content="ie=edge">
  7. <title>Document</title>
  8. </head>
  9. <body>
  10. <script src="../../js/jquery-2.2.4.js" type="text/javascript" charset="utf-8"></script>
  11. <script src="../../plugins/toastr/toastr.min.js"></script>
  12. <script src="../../js/util.js" type="text/javascript" charset="utf-8"></script>
  13. <script src="../../api/http-request.js" type="text/javascript" charset="utf-8"></script>
  14. <script src="../../api/fangshi-api.js"></script>
  15. <script>
  16. //随访类别,type多类别“,”分割【1.高血压 2.糖尿病 3.肿瘤 4.精神分裂症 5.产后 6.新生儿
  17. // 7.严重精神病 8.80岁以上老人 9.肺结核】
  18. // 多次肺结核-n
  19. var Request = GetRequest();
  20. var version;
  21. var isAdd = Request.isEdit//是否为新增 1新增 0查看
  22. var followupId = Request.id
  23. var lastedVersion = 'v1'//最新版本
  24. if (Request.userAgent) {
  25. window.localStorage.setItem(httpRequest.agentName, decodeURIComponent(Request.userAgent))
  26. }
  27. if (Request.type == '5' || Request.type == '6') {
  28. fangshiAPI.getPostpartumVisitDetails({ followupId: followupId || '3' }).then(function (res) {
  29. if (res.status == 200) {
  30. version = isAdd != 1 ? res.data.version : lastedVersion
  31. location.replace('../../app/followup/' + version + '/html/fangshi-detail-5,6.html?id=' + followupId + "&version=" + version)
  32. } else {
  33. top.toastr.error(res.msg);
  34. }
  35. })
  36. } if (Request.type == '7') {
  37. fangshiAPI.getFollowupSevereMentalDisorder({ followupId: followupId || '1' }).then(function (res) {
  38. if (res.status == 200) {
  39. version = res.data != null ? res.data.version : lastedVersion
  40. location.replace('../../app/followup/' + version + '/html/fangshi-detail-7.html?id=' + followupId + "&version=" + version)
  41. } else {
  42. top.toastr.error(res.msg);
  43. }
  44. })
  45. } if (Request.type == '8') {
  46. fangshiAPI.getOlderPeopleHealthCheckRecord({ followupId: followupId || '1' }).then(function (res) {
  47. if (res.status == 200) {
  48. version = res.data != null ? res.data.version : lastedVersion
  49. location.replace('../../app/followup/' + version + '/html/fangshi-detail-8.html?id=' + followupId + "&version=" + version)
  50. } else {
  51. top.toastr.error(res.msg);
  52. }
  53. })
  54. } if (Request.type == '9') {
  55. fangshiAPI.getPhthisisFirstCheckRecord({ followupId: this.followupId }).then(function (res) {
  56. if (res.status == 200) {
  57. if (res.data == null) {//第一次肺结核
  58. version = isAdd != 1 ? res.data.version : lastedVersion
  59. location.replace('../../app/followup/' + version + '/html/fangshi-detail-9.html?id=' + followupId + "&version=" + version)
  60. } else {
  61. version =res.data.version
  62. location.replace('../../app/followup/' + version + '/html/fangshi-detail-10.html?id=' + followupId + "&version=" + version)
  63. }
  64. } else {
  65. top.toastr.error(res.msg);
  66. }
  67. })
  68. }
  69. </script>
  70. </body>
  71. </html>