situationDetail.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432
  1. <template>
  2. <view class="detail-page">
  3. <view class="content-info">
  4. <view class="top-box">
  5. <view class="subscript">
  6. <!-- <image class="sub-pic" src="../../static/sDetail-subscript.png"></image> -->
  7. <text class="sub-text">{{topic}}</text>
  8. </view>
  9. <text class="name-text">{{name}}</text>
  10. <text class="time-text">| 情境起止时间:{{startDate}}~{{endDate}}</text>
  11. <text class="nextTime-text">| 下次查核时间:{{nextCheckTime}}</text>
  12. <text class="startEndTime-text" v-show="isStartEndTimeShow">| {{startEndTime}}</text>
  13. <text class="team-text">{{checkGroupName}}</text>
  14. </view>
  15. <view class="list-box">
  16. <view class="check-list" v-show="isCheckImproveShow" @click="gotoCheckPage">
  17. <image class="check-pic" src="../../static/check-list.png"></image>
  18. <text class="list-title">查核列表</text>
  19. <text class="list-info">{{checkStatus}}</text>
  20. </view>
  21. <view class="improve-list" v-show="isCheckImproveShow" @click="gotoImprovePage">
  22. <image class="improve-pic" src="../../static/improve-list.png"></image>
  23. <text class="list-title">改善列表</text>
  24. <text class="list-info">查看改善记录</text>
  25. </view>
  26. <view class="plan-list" v-show="isCheckLeader" @click="gotoPlanPage">
  27. <image class="check-pic" src="../../static/check-list.png"></image>
  28. <text class="list-title">计划列表</text>
  29. <text class="list-info">共{{planCount}}次查核计划,剩余{{toDistribute}}个待分配</text>
  30. </view>
  31. </view>
  32. <view class="info-box">
  33. <view class="text-box">
  34. <text class="info-text">评价医院对医院评审标准与要点的遵从程度,即评价医院对规章、制度、流程、诊疗常规与操作规程的执行力。评价病人在接受诊疗的服务过程品质、环境设施,注重病人的安全、权益及隐私的保护、医院感染的控制。</text>
  35. </view>
  36. </view>
  37. </view>
  38. <view class="button-box">
  39. <view class="btn-left" @click="delSituation" v-show="isAdmin">
  40. <text class="left-text">作废</text>
  41. </view>
  42. <view class="btn-right" @click="editSituation" v-show="isAdmin">
  43. <text class="right-text">编辑</text>
  44. </view>
  45. <view class="btn-center" v-show="isChecker" @click="startUnplanned">
  46. <text class="center-text">开始一次计划外查核</text>
  47. </view>
  48. <view class="btn-left" v-show="isUnplanned">
  49. <text class="left-text">新建一个计划外查核</text>
  50. </view>
  51. <view class="btn-right" v-show="isUnplanned">
  52. <text class="right-text">提前开始一个计划内查核</text>
  53. </view>
  54. </view>
  55. </view>
  56. </template>
  57. <script>
  58. export default {
  59. data() {
  60. return {
  61. nowPermission:'',//用户当前权限
  62. situaionID:'',//情境id
  63. checkGroupName:'',//查核组名
  64. checkStatus:'',//查核状态
  65. name:'',//查核名
  66. startDate:'',//查核开始时间
  67. endDate:'',//查核结束时间
  68. nextCheckTime:'',//下次查核时间
  69. topic:'',//个案或系统
  70. startEndTime:'',//距离情境开始或结束时间
  71. planCount:'',//总查核计划数
  72. toDistribute:'',//待分配计划数
  73. firstCheckTime:'',//首次查核时间
  74. isCheckImproveShow:false,//查核改善列表是否显示
  75. isStartEndTimeShow:false,//距离情境开始或结束时间是否显示
  76. isAdmin:false,//是否为管理员
  77. isCheckLeader:false,//是否为查核组长
  78. isChecker:false,//是否为查核者
  79. isUnplanned:false,//是否计划外查核
  80. }
  81. },
  82. created: function() {
  83. this.nowPermission=uni.getStorageSync('nowPermission');
  84. console.log(this.nowPermission);
  85. this.isAdmin=this.nowPermission==1?true:false;
  86. this.isCheckLeader=this.nowPermission==2?true:false;
  87. this.isChecker=this.nowPermission==3?true:false;
  88. this.isStartEndTimeShow=this.nowPermission==2||this.nowPermission==3?true:false;
  89. this.isCheckImproveShow=this.nowPermission==1||this.nowPermission==4||this.nowPermission==3?true:false;
  90. this.situaionID=uni.getStorageSync('situaionID');
  91. this.$store.dispatch({
  92. type: 'situationDetail/commActions',
  93. payload: {
  94. key: 'situationDetail',
  95. data:{
  96. id:this.situaionID
  97. }
  98. }
  99. }).then((data) => {
  100. if (data) {
  101. this.name=data.name;
  102. this.startDate=data.startDate;
  103. this.endDate=data.endDate;
  104. this.nextCheckTime=data.nextCheckTime;
  105. this.checkGroupName=data.checkGroupName;
  106. this.topic=data.topic==0?'个案':'系统';
  107. this.checkStatus=data.checkStatus;
  108. this.startEndTime=data.startEndTime;
  109. this.planCount=data.planCount;
  110. this.toDistribute=data.toDistribute;
  111. this.firstCheckTime=data.firstCheckTime;
  112. }
  113. });
  114. },
  115. methods: {
  116. delSituation(){
  117. uni.showModal({
  118. title:'提示',
  119. content:'请确认是否作废此情境,作废的情境无法被还原',
  120. success:function(res){
  121. if(res.confirm){
  122. this.$store.dispatch({
  123. type: 'situationDetail/commActions',
  124. payload: {
  125. key: 'situationDelete',
  126. data:{
  127. id:this.situaionID
  128. }
  129. }
  130. }).then((data) => {
  131. if (data) {
  132. uni.showToast({
  133. title:'作废成功',
  134. icon:'none',
  135. duration:1000
  136. });
  137. }
  138. });
  139. }
  140. else if(res.cancel){
  141. return;
  142. }
  143. }
  144. })
  145. },
  146. editSituation(){
  147. let editEnable=this.compareTime();
  148. if(editEnable){
  149. uni.navigateTo({
  150. url: '/pages/creatingSituations/creatingSituations'
  151. });
  152. }
  153. else{
  154. uni.showModal({
  155. title:'提示',
  156. content:'已进行过一次查核,不可编辑',
  157. showCancel:false
  158. })
  159. }
  160. },
  161. compareTime(){
  162. let myDate=new Date();
  163. let firstCheckTime=this.firstCheckTime.replace(/-/g,"/");
  164. firstCheckTime=Date.parse(firstCheckTime);
  165. if(myDate>firstCheckTime){
  166. return false;
  167. }else{
  168. return true;
  169. }
  170. },
  171. gotoCheckPage(){
  172. //跳转到查核列表
  173. uni.navigateTo({
  174. url: '/pages/creatingSituations/creatingSituations'
  175. });
  176. },
  177. gotoImprovePage(){
  178. //跳转到改善列表
  179. uni.navigateTo({
  180. url: '/pages/creatingSituations/creatingSituations'
  181. });
  182. },
  183. gotoPlanPage(){
  184. //跳转到计划列表
  185. uni.navigateTo({
  186. url: '/pages/creatingSituations/creatingSituations'
  187. });
  188. },
  189. startUnplanned(){
  190. this.isUnplanned=true;
  191. this.isChecker=false;
  192. },
  193. }
  194. }
  195. </script>
  196. <style lang="less">
  197. .detail-page{
  198. .content-info{
  199. background-color: #FFFFFF;
  200. .top-box{
  201. width: 750rpx;
  202. height: 300rpx;
  203. background: linear-gradient(270deg, #3071F2 0%, #4C95FC 100%);
  204. .subscript{
  205. width: 84.37rpx;
  206. height: 35rpx;
  207. float: right;
  208. margin-top: 15rpx;
  209. text-align: center;
  210. background-image: url(../../static/sDetail-subscript.png);
  211. .sub-text{
  212. font-size: 17.5rpx;
  213. font-family: SourceHanSansCN-Medium, SourceHanSansCN;
  214. font-weight: 500;
  215. color: #2E6CE6;
  216. line-height: 35rpx;
  217. }
  218. }
  219. .name-text{
  220. font-size: 40rpx;
  221. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  222. font-weight: 400;
  223. color: #FFFFFF;
  224. float: left;
  225. margin-left: 50rpx;
  226. margin-top: 50rpx;
  227. margin-bottom: 31.25rpx;
  228. }
  229. .time-text{
  230. font-size: 20rpx;
  231. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  232. font-weight: 400;
  233. color: #FFFFFF;
  234. position: absolute;
  235. top: 115rpx;
  236. left: 55rpx;
  237. }
  238. .nextTime-text{
  239. font-size: 20rpx;
  240. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  241. font-weight: 400;
  242. color: #FFFFFF;
  243. position: absolute;
  244. left: 55rpx;
  245. top: 155rpx;
  246. }
  247. .startEndTime-text{
  248. font-size: 20rpx;
  249. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  250. font-weight: 400;
  251. color: #FFFFFF;
  252. position: absolute;
  253. left: 55rpx;
  254. top: 195rpx;
  255. }
  256. .team-text{
  257. font-size: 20rpx;
  258. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  259. font-weight: 400;
  260. color: #FFFFFF;
  261. position: absolute;
  262. top: 115rpx;
  263. right: 50rpx;
  264. }
  265. }
  266. .list-box{
  267. width: 687.5rpx;
  268. height: 137.5rpx;
  269. background: #FFFFFF;
  270. box-shadow: 0px 10px 30px 0px rgba(0, 13, 51, 0.1);
  271. border-radius: 16px;
  272. position: absolute;
  273. left: 31.25rpx;
  274. top: 250rpx;
  275. .check-list{
  276. width: 225rpx;
  277. height: 97.5rpx;
  278. float: left;
  279. margin-top: 40rpx;
  280. margin-left: 81.25rpx;
  281. .check-pic{
  282. width: 38.75rpx;
  283. height: 41.87rpx;
  284. margin-top: 8.12rpx;
  285. }
  286. .list-title{
  287. font-size: 25rpx;
  288. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  289. font-weight: 400;
  290. color: #292C33;
  291. position: absolute;
  292. left: 145rpx;
  293. top: 40rpx;
  294. }
  295. .list-info{
  296. font-size: 17.5rpx;
  297. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  298. font-weight: 400;
  299. color: #666F80;
  300. position: absolute;
  301. left: 145rpx;
  302. top: 80rpx;
  303. }
  304. }
  305. .improve-list{
  306. width: 225rpx;
  307. height:97.5rpx;
  308. float: right;
  309. margin-top: 40rpx;
  310. margin-right: 81.25rpx;
  311. .improve-pic{
  312. width: 40rpx;
  313. height: 40rpx;
  314. margin-top: 8.12rpx;
  315. }
  316. .list-title{
  317. font-size: 25rpx;
  318. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  319. font-weight: 400;
  320. color: #292C33;
  321. position: absolute;
  322. top: 40rpx;
  323. left: 458.75rpx;
  324. }
  325. .list-info{
  326. font-size: 17.5rpx;
  327. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  328. font-weight: 400;
  329. color: #666F80;
  330. position: absolute;
  331. top: 80rpx;
  332. left: 458.75rpx;
  333. }
  334. }
  335. .plan-list{
  336. width: 225rpx;
  337. height: 97.5rpx;
  338. float: left;
  339. margin-top: 40rpx;
  340. margin-left: 81.25rpx;
  341. .check-pic{
  342. width: 38.75rpx;
  343. height: 41.87rpx;
  344. margin-top: 8.12rpx;
  345. }
  346. .list-title{
  347. font-size: 25rpx;
  348. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  349. font-weight: 400;
  350. color: #292C33;
  351. position: absolute;
  352. left: 145rpx;
  353. top: 40rpx;
  354. }
  355. .list-info{
  356. font-size: 17.5rpx;
  357. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  358. font-weight: 400;
  359. color: #666F80;
  360. position: absolute;
  361. left: 145rpx;
  362. top: 80rpx;
  363. }
  364. }
  365. }
  366. .info-box{
  367. height: 823.12rpx;
  368. .text-box{
  369. width: 687.5rpx;
  370. margin-top: 116.87rpx;
  371. margin-left: 31.25rpx;
  372. .info-text{
  373. font-size: 22.5rpx;
  374. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  375. font-weight: 400;
  376. color: #292C33;
  377. }
  378. }
  379. }
  380. }
  381. .button-box{
  382. width: 750rpx;
  383. height: 75rpx;
  384. position: absolute;
  385. bottom: 0rpx;
  386. .btn-center{
  387. background: #3377FF;
  388. text-align: center;
  389. .center-text{
  390. font-size: 22.5rpx;
  391. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  392. font-weight: 400;
  393. color: #FFFFFF;
  394. line-height: 75rpx;
  395. }
  396. }
  397. .btn-left{
  398. width: 375rpx;
  399. height: 75rpx;
  400. background: #FFFFFF;
  401. float: left;
  402. text-align: center;
  403. border: 0.62rpx solid #DADEE6;
  404. .left-text{
  405. font-size: 22.5rpx;
  406. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  407. font-weight: 400;
  408. color: #3377FF;
  409. line-height: 75rpx;
  410. }
  411. }
  412. .btn-right{
  413. width: 375rpx;
  414. height: 75rpx;
  415. background: #3377FF;
  416. float: right;
  417. text-align: center;
  418. .right-text{
  419. font-size: 22.5rpx;
  420. font-family: SourceHanSansCN-Normal, SourceHanSansCN;
  421. font-weight: 400;
  422. color: #FFFFFF;
  423. line-height: 75rpx;
  424. }
  425. }
  426. }
  427. }
  428. </style>