Elizabeth's proactive approach involves introducing urinal toilet attachment , an ingenious concept that optimizes space and functionality.

acceptsTreatmentDialog.vue 24KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773
  1. <template>
  2. <div>
  3. <div>
  4. <el-dialog
  5. title="接诊评估"
  6. class="newDialog"
  7. :modal-append-to-body="false"
  8. :visible.sync="isVisibility"
  9. width="854px"
  10. >
  11. <div class="warnTxt" v-if="showTxt != ''">{{ showTxt }}</div>
  12. <el-form
  13. :model="receiveTreatmentAsses"
  14. ref="receiveTreatmentAsses"
  15. label-width="86px"
  16. >
  17. <el-form-item
  18. label="入室方式 : "
  19. :prop="isName('入室方式')"
  20. :rules="isCheckmust('入室方式')"
  21. v-if="isShow('入室方式')"
  22. >
  23. <el-radio-group v-model="receiveTreatmentAsses.way">
  24. <el-radio
  25. v-for="(item, index) in way_arr"
  26. :key="index"
  27. :label="item.id"
  28. >{{ item.name }}
  29. </el-radio>
  30. </el-radio-group>
  31. </el-form-item>
  32. <el-form-item
  33. label="病人意识 : "
  34. v-if="isShow('病人意识')"
  35. :prop="isName('病人意识')"
  36. :rules="isCheckmust('病人意识')"
  37. >
  38. <el-radio-group v-model="receiveTreatmentAsses.consciousness">
  39. <el-radio
  40. v-for="(item, index) in consciousness_arr"
  41. :key="index"
  42. :label="item.id"
  43. >{{ item.name }}
  44. </el-radio>
  45. </el-radio-group>
  46. <!--<el-radio v-model="receiveTreatmentAsses.consciousness" label="1">清醒</el-radio>-->
  47. <!--<el-radio v-model="receiveTreatmentAsses.consciousness" label="2">嗜睡</el-radio>-->
  48. <!--<el-radio v-model="receiveTreatmentAsses.consciousness" label="3">昏迷</el-radio>-->
  49. <!--<el-radio v-model="receiveTreatmentAsses.consciousness" label="4">模糊</el-radio>-->
  50. </el-form-item>
  51. <el-form-item
  52. label="病人食欲 : "
  53. :prop="isName('病人食欲')"
  54. :rules="isCheckmust('病人食欲')"
  55. v-if="isShow('病人食欲')"
  56. >
  57. <el-radio-group v-model="receiveTreatmentAsses.appetite">
  58. <el-radio
  59. v-for="(item, index) in appetite_arr"
  60. :key="index"
  61. :label="item.id"
  62. >{{ item.name }}
  63. </el-radio>
  64. </el-radio-group>
  65. <!--<el-radio v-model="receiveTreatmentAsses.appetite" label="1">正常</el-radio>-->
  66. <!--<el-radio v-model="receiveTreatmentAsses.appetite" label="2">减退</el-radio>-->
  67. <!--<el-radio v-model="receiveTreatmentAsses.appetite" label="3">恶心</el-radio>-->
  68. <!--<el-radio v-model="receiveTreatmentAsses.appetite" label="4">呕吐</el-radio>-->
  69. <!--<el-radio v-model="receiveTreatmentAsses.appetite" label="5">腹泻</el-radio>-->
  70. </el-form-item>
  71. <el-form-item
  72. label="病人情况 : "
  73. prop="condition"
  74. :rules="isCheckmust('病人情况')"
  75. v-if="isShow('病人情况')"
  76. >
  77. <el-radio-group v-model="receiveTreatmentAsses.condition">
  78. <el-radio label="1"
  79. >住院</el-radio
  80. >
  81. <el-radio label="2"
  82. >门诊</el-radio
  83. >
  84. <el-radio label="3"
  85. >手术期</el-radio
  86. >
  87. <el-radio label="4"
  88. >急诊</el-radio
  89. >
  90. </el-radio-group>
  91. </el-form-item>
  92. <el-form-item
  93. label="住院号 : "
  94. :prop="isName('住院号')"
  95. :rules="isCheckmust('住院号')"
  96. v-if="this.receiveTreatmentAsses.condition == '1'"
  97. >
  98. <el-input v-model="receiveTreatmentAsses.admission_number"></el-input>
  99. </el-form-item>
  100. <el-form-item
  101. label="住院科室 : "
  102. :prop="isName('住院科室')"
  103. :rules="isCheckmust('住院科室')"
  104. v-if="isShow('住院科室') && this.receiveTreatmentAsses.condition == '1'"
  105. >
  106. <el-input v-model="receiveTreatmentAsses.his_department"></el-input>
  107. </el-form-item>
  108. <el-form-item
  109. label="住院床位 : "
  110. :prop="isName('住院床位')"
  111. :rules="isCheckmust('住院床位')"
  112. v-if="isShow('住院床位') && this.receiveTreatmentAsses.condition == '1'"
  113. >
  114. <el-input v-model="receiveTreatmentAsses.his_bed"></el-input>
  115. </el-form-item>
  116. <el-form-item
  117. label="诊断:"
  118. :prop="isName('诊断')"
  119. :rules="isCheckmust('诊断')"
  120. v-if="isShow('诊断') && this.receiveTreatmentAsses.condition == '1'"
  121. >
  122. <el-input v-model="receiveTreatmentAsses.diacrisis"></el-input>
  123. </el-form-item>
  124. <el-form-item
  125. label="体位 : "
  126. :prop="isName('体位')"
  127. :rules="isCheckmust('体位')"
  128. v-if="isShow('体位')"
  129. >
  130. <el-radio-group v-model="receiveTreatmentAsses.posture">
  131. <el-radio
  132. v-for="(item, index) in posture_arr"
  133. :key="index"
  134. :label="item.id"
  135. >{{ item.name }}
  136. </el-radio>
  137. </el-radio-group>
  138. </el-form-item>
  139. <el-form-item
  140. label="病情: "
  141. :prop="isName('病情')"
  142. :rules="isCheckmust('病情')"
  143. v-if="isShow('病情')"
  144. >
  145. <el-radio-group v-model="receiveTreatmentAsses.sick_condition">
  146. <el-radio
  147. v-for="(item, index) in sick_condition_arr"
  148. :key="index"
  149. :label="item.id"
  150. >{{ item.name }}
  151. </el-radio>
  152. </el-radio-group>
  153. <!--<el-radio v-model="receiveTreatmentAsses.sick_condition" label="1">一般</el-radio>-->
  154. <!--<el-radio v-model="receiveTreatmentAsses.sick_condition" label="2">严重</el-radio>-->
  155. <!--<el-radio v-model="receiveTreatmentAsses.sick_condition" label="3">危</el-radio>-->
  156. </el-form-item>
  157. <el-form-item
  158. label-width="100px"
  159. label="其他病情 : "
  160. :prop="isName('其他病情')"
  161. :rules="isCheckmust('其他病情')"
  162. v-if="isShow('其他病情')"
  163. >
  164. <el-input
  165. v-model="receiveTreatmentAsses.sick_condition_other"
  166. ></el-input>
  167. </el-form-item>
  168. <el-form-item
  169. label-width="150px"
  170. label="跌倒风险评估评分 : "
  171. :prop="isName('跌倒风险评估评分')"
  172. :rules="isCheckmust('跌倒风险评估评分')"
  173. v-if="isShow('跌倒风险评估评分')"
  174. >
  175. <el-input
  176. v-model="receiveTreatmentAsses.score"
  177. style="width: 100px"
  178. ></el-input>
  179. </el-form-item>
  180. <el-form-item
  181. label="风险程度: "
  182. :prop="isName('风险程度')"
  183. :rules="isCheckmust('风险程度')"
  184. v-if="isShow('风险程度')"
  185. >
  186. <el-radio-group v-model="receiveTreatmentAsses.danger_level">
  187. <el-radio label="1"
  188. >无</el-radio
  189. >
  190. <el-radio label="2"
  191. >低风险</el-radio
  192. >
  193. <el-radio label="3"
  194. >中度风险</el-radio
  195. >
  196. <el-radio label="4"
  197. >高风险</el-radio
  198. >
  199. </el-radio-group>
  200. </el-form-item>
  201. <div style="position: relative;">
  202. <span v-if="isrequired" style="color: red;position: absolute;top: 10px;">*</span>
  203. <el-form-item
  204. label-width="138px"
  205. label="跌倒风险预防措施: "
  206. prop="precautionTwo"
  207. :rules="isCheckmust('跌倒风险预防措施')"
  208. v-if="isShow('跌倒风险预防措施')"
  209. style="display: inline-block;"
  210. >
  211. <!--v-if="isShow('跌倒风险预防措施')" isFalldown prop="precautionTwo" @change="precautionchange" isCheckmust('跌倒风险预防措施')
  212. :prop="isName('跌倒风险预防措施')" :rules="isCheckmust('跌倒风险预防措施')"
  213. [{required: true, message: '请选择跌倒风险预防措施', trigger: 'change'}]-->
  214. <el-checkbox-group v-model="precautionTwo" @change="precautionchange" >
  215. <el-checkbox
  216. v-for="item in precaution_arr"
  217. :label="item.name"
  218. :key="item.id"
  219. >{{ item.name }}</el-checkbox
  220. >
  221. </el-checkbox-group>
  222. </el-form-item>
  223. </div>
  224. <el-form-item
  225. label-width="200px"
  226. label="其他跌倒风险预防措施 : "
  227. :prop="isName('其他跌倒风险预防措施')"
  228. :rules="isCheckmust('其他跌倒风险预防措施')"
  229. v-if="isShow('其他跌倒风险预防措施')"
  230. >
  231. <el-input v-model="receiveTreatmentAsses.precaution_other"></el-input>
  232. </el-form-item>
  233. <el-form-item
  234. label="摄入量: "
  235. :prop="isName('摄入量')"
  236. :rules="isCheckmust('摄入量')"
  237. v-if="isShow('摄入量')"
  238. >
  239. <!--<el-radio v-model="receiveTreatmentAsses.intake" label="1">正常</el-radio>-->
  240. <!--<el-radio v-model="receiveTreatmentAsses.intake" label="2">减少</el-radio>-->
  241. <el-radio-group v-model="receiveTreatmentAsses.intake">
  242. <el-radio
  243. v-for="(item, index) in intake_arr"
  244. :key="index"
  245. :label="item.id"
  246. >{{ item.name }}
  247. </el-radio>
  248. </el-radio-group>
  249. </el-form-item>
  250. <el-form-item
  251. label="营养状况: "
  252. :prop="isName('营养状况')"
  253. :rules="isCheckmust('营养状况')"
  254. v-if="isShow('营养状况')"
  255. >
  256. <!--<el-radio v-model="receiveTreatmentAsses.nutrition" label="1">正常</el-radio>-->
  257. <!--<el-radio v-model="receiveTreatmentAsses.nutrition" label="2">营养不良</el-radio>-->
  258. <el-radio-group v-model="receiveTreatmentAsses.nutrition">
  259. <el-radio
  260. v-for="(item, index) in nutrition_arr"
  261. :key="index"
  262. :label="item.id"
  263. >{{ item.name }}
  264. </el-radio>
  265. </el-radio-group>
  266. </el-form-item>
  267. <el-form-item
  268. label="心理评估: "
  269. :prop="isName('心理评估')"
  270. :rules="isCheckmust('心理评估')"
  271. v-if="isShow('心理评估')"
  272. >
  273. <el-radio-group v-model="receiveTreatmentAsses.psychological_assessment">
  274. <el-radio
  275. label="1"
  276. >正常</el-radio
  277. >
  278. <el-radio
  279. label="2"
  280. >异常</el-radio
  281. >
  282. </el-radio-group>
  283. </el-form-item>
  284. <el-form-item
  285. label-width="150px"
  286. label="心理评估异常情况 : "
  287. :prop="isName('心理评估异常情况')"
  288. :rules="isCheckmust('心理评估异常情况')"
  289. v-if="
  290. isShow('心理评估异常情况') &&
  291. receiveTreatmentAsses.psychological_assessment == 2
  292. "
  293. >
  294. <el-input
  295. v-model="receiveTreatmentAsses.psychological_assessment_other"
  296. ></el-input>
  297. </el-form-item>
  298. <el-form-item
  299. label-width="150px"
  300. label="其他心理评估 : "
  301. :prop="isName('其他心理评估')"
  302. :rules="isCheckmust('其他心理评估')"
  303. v-if="isShow('其他心理评估')"
  304. >
  305. <el-input
  306. v-model="receiveTreatmentAsses.psychological_other"
  307. ></el-input>
  308. </el-form-item>
  309. <el-form-item
  310. label="是否跌倒: "
  311. :prop="isName('是否跌倒')"
  312. :rules="isCheckmust('是否跌倒')"
  313. v-if="isShow('是否跌倒')"
  314. >
  315. <el-radio-group v-model="receiveTreatmentAsses.tumble">
  316. <el-radio label="1">是</el-radio>
  317. <el-radio label="2">否</el-radio>
  318. </el-radio-group>
  319. </el-form-item>
  320. </el-form>
  321. <div slot="footer" class="dialog-footer">
  322. <el-button @click="handleCancle">取 消</el-button>
  323. <!-- v-if="hasPermission"-->
  324. <el-button type="primary" @click="handleComfirm('receiveTreatmentAsses')"
  325. >保 存</el-button
  326. >
  327. </div>
  328. </el-dialog>
  329. <el-dialog
  330. title="提示"
  331. :visible.sync="infoDialogVisible"
  332. width="30%">
  333. <span>
  334. <el-form>
  335. <el-row>
  336. <span>申请日期:</span>
  337. <span>
  338. <el-date-picker
  339. type="datetime"
  340. format="yyyy-MM-dd HH:mm"
  341. value-format="yyyy-MM-dd HH:mm"
  342. placeholder="选择时间"
  343. v-model="selected_date"
  344. ></el-date-picker>
  345. </span>
  346. </el-row>
  347. <el-row>
  348. <span>备注:</span>
  349. <span>
  350. <el-input v-model="remark" style="width:200px"></el-input>
  351. </span>
  352. </el-row>
  353. </el-form>
  354. </span>
  355. <span slot="footer" class="dialog-footer">
  356. <el-button @click="infoDialogVisible = false">取 消</el-button>
  357. <el-button type="primary" @click="saveInformation">确 定</el-button>
  358. </span>
  359. </el-dialog>
  360. </div>
  361. </template>
  362. <script>
  363. import { postAccepts,saveInformation } from "@/api/dialysis";
  364. import { uParseTime } from "@/utils/tools";
  365. import store from "@/store";
  366. import { getDataConfig } from "@/utils/data";
  367. import { parseTime } from "@/utils";
  368. import request from "@/utils/request";
  369. export default {
  370. name: "acceptsTreatmentDialog",
  371. data() {
  372. return {
  373. isrequired:false,
  374. showTxt: "",
  375. hasPermission: true,
  376. isVisibility: false,
  377. record_date: "",
  378. way_arr: [],
  379. consciousness_arr: [],
  380. appetite_arr: [],
  381. posture_arr: [],
  382. sick_condition_arr: [],
  383. precaution_arr: [],
  384. intake_arr: [],
  385. nutrition_arr: [],
  386. receiveTreatmentAsses: {
  387. way: "1",
  388. consciousness: "1",
  389. appetite: "1",
  390. condition: "1",
  391. posture: "1",
  392. sick_condition: "1",
  393. danger_level: "1",
  394. intake: "1",
  395. nutrition: "1",
  396. psychological_assessment: "1",
  397. psychological_assessment_other: "",
  398. sick_condition_other: "",
  399. score: "",
  400. psychological_other: "",
  401. precaution: "",
  402. precaution_other: "",
  403. admission_number: "",
  404. diacrisis: "",
  405. tumble: "",
  406. his_department: "",
  407. his_bed: "",
  408. falldown:[],
  409. },
  410. precautionTwo: [],
  411. arr:[],
  412. infoDialogVisible:false,
  413. selected_date:"",
  414. remark:""
  415. };
  416. },
  417. methods: {
  418. isShow(name) {
  419. var filedList = store.getters.xt_user.fileds;
  420. for (let i = 0; i < filedList.length; i++) {
  421. if (
  422. filedList[i].module == 2 &&
  423. filedList[i].filed_name_cn == name &&
  424. filedList[i].is_show == 1
  425. ) {
  426. return true;
  427. }
  428. }
  429. return false;
  430. },
  431. show(accepts) {
  432. console.log("accepts333333", accepts);
  433. if (accepts.id > 0) {
  434. accepts.tumble = accepts.tumble.toString();
  435. }
  436. this.accepts = accepts;
  437. // console.log("accepts", accepts);
  438. // var arr = [];
  439. // if (this.accepts.precaution) {
  440. // var precaution = this.accepts.precaution.split(",");
  441. // // console.log("precaution", precaution);
  442. // // console.log("hhh", this.precaution_arr);
  443. // for (let i = 0; i < precaution.length; i++) {
  444. // for (let j = 0; j < this.precaution_arr.length; j++) {
  445. // if (parseInt(precaution[i]) == this.precaution_arr[j].id) {
  446. // // console.log("aaaa");
  447. // this.arr.push(this.precaution_arr[j].name);
  448. // }
  449. // }
  450. // }
  451. // this.precautionTwo = this.arr;
  452. // }
  453. this.getPermission();
  454. for (var index in this.receiveTreatmentAsses) {
  455. if (
  456. index == "condition" ||
  457. index == "danger_level" ||
  458. index == "psychological_assessment"
  459. ) {
  460. this.receiveTreatmentAsses[index] =
  461. this.receiver_treatment_access[index] + "";
  462. } else {
  463. this.receiveTreatmentAsses[index] =
  464. this.receiver_treatment_access[index];
  465. }
  466. }
  467. this.isVisibility = true;
  468. },
  469. hide() {
  470. this.isVisibility = false;
  471. },
  472. handleCancle: function () {
  473. this.isVisibility = false;
  474. },
  475. // 复选框跌倒风险措施
  476. precautionchange(){
  477. if(this.precautionTwo.length>0){
  478. this.$refs.receiveTreatmentAsses.clearValidate('precautionTwo');
  479. }
  480. },
  481. handleComfirm: function (formName) {
  482. // var arr = [];
  483. for (let i = 0; i < this.precaution_arr.length; i++) {
  484. for (let j = 0; j < this.precautionTwo.length; j++) {
  485. if (this.precaution_arr[i].name == this.precautionTwo[j]) {
  486. this.arr.push(this.precaution_arr[i].id);
  487. }
  488. }
  489. }
  490. // this.precautionchange()
  491. var obj = this.arr.join(",");
  492. this.receiveTreatmentAsses.precaution = obj;
  493. let ParamsQuery = this.receiveTreatmentAsses;
  494. console.log("ParamsQuery", ParamsQuery);
  495. ParamsQuery["patient"] = this.patient.id;
  496. ParamsQuery["record_date"] = this.record_date;
  497. //console.log(this.receiver_treatment_access);
  498. ParamsQuery["mode"] = "1";
  499. if (this.receiver_treatment_access.id > 0) {
  500. ParamsQuery["mode"] = "2";
  501. if (
  502. this.$store.getters.xt_user.user.id !=
  503. this.receiver_treatment_access.creater
  504. ) {
  505. ParamsQuery["mode"] = "3";
  506. }
  507. }
  508. console.log("数据", ParamsQuery);
  509. this.$refs[formName].validate((valid) => {
  510. if (valid) {
  511. postAccepts(ParamsQuery).then((response) => {
  512. if (response.data.state == 0) {
  513. this.$message.error(response.data.msg);
  514. if(response.data.code == 600000008){
  515. this.infoDialogVisible = true
  516. }
  517. return false;
  518. } else {
  519. this.$notify({
  520. title: "成功",
  521. message: "提交成功",
  522. type: "success",
  523. duration: 2000,
  524. });
  525. let receive_treatment_asses_resp =
  526. response.data.data.receiveTreatmentAsses;
  527. //pror
  528. var receiver_treatment_access = this.receiver_treatment_access;
  529. for (var index in receive_treatment_asses_resp) {
  530. // receiver_treatment_access[index] = receive_treatment_asses_resp[index];
  531. this.$set(
  532. receiver_treatment_access,
  533. index,
  534. receive_treatment_asses_resp[index]
  535. );
  536. }
  537. this.hide();
  538. }
  539. });
  540. } else {
  541. console.log("error submit!!");
  542. return false;
  543. }
  544. });
  545. },
  546. isName(name) {
  547. let filedList = store.getters.xt_user.fileds;
  548. for (let i = 0; i < filedList.length; i++) {
  549. if (filedList[i].module == 2 && filedList[i].filed_name_cn == name) {
  550. return filedList[i].filed_name;
  551. }
  552. }
  553. },
  554. isCheckmust(name) {
  555. let filedList = store.getters.xt_user.fileds;
  556. for (let i = 0; i < filedList.length; i++) {
  557. if (
  558. filedList[i].module == 2 &&
  559. filedList[i].filed_name_cn == name &&
  560. filedList[i].is_write == 1
  561. ) {
  562. // name == '跌倒风险预防措施' && this.precautionTwo.length<=0
  563. if (name == "风险程度"||name == "病人情况"||name == '心理评估') {
  564. return [
  565. { required: true, message: `请输入${name}`,trigger: ['blur','change'] },
  566. {
  567. required: true,
  568. pattern: /^[1-9]\d*$/,
  569. message: `请输入${name}`,
  570. trigger: ['blur','change']
  571. },
  572. ];
  573. }
  574. else if(name == "跌倒风险预防措施"){
  575. if(this.precautionTwo.length<=0){
  576. this.isrequired=false
  577. return [{ required: true, message: `请输入${name}`,trigger: ['blur','change'] }];
  578. }
  579. this.precautionchange()
  580. this.isrequired=true
  581. // return [{ required: true, message: '',trigger: ['blur','change'] }];
  582. }else{
  583. return [{ required: true, message: `请输入${name}`,trigger: ['blur','change'] }];
  584. }
  585. }
  586. }
  587. },
  588. // isFalldown(name){
  589. // let filedList = store.getters.xt_user.fileds;
  590. // for (let i = 0; i < filedList.length; i++) {
  591. // if (
  592. // filedList[i].module == 2 &&
  593. // filedList[i].filed_name_cn == name &&
  594. // filedList[i].is_write == 1
  595. // ) {
  596. // if (name == "跌倒风险预防措施" && this.precautionTwo.length<=0) {
  597. // return [
  598. // { required: true, message: `请选择${name}`,trigger: ['blur','change'] },
  599. // {
  600. // required: true,
  601. // pattern: /^[1-9]\d*$/,
  602. // message: `请选择${name}`,
  603. // trigger: ['blur','change']
  604. // },
  605. // ];
  606. // }
  607. // }
  608. // }
  609. // },
  610. getPermission() {
  611. request
  612. .get("/api/func_per/get", {
  613. params: {
  614. create_url: "/api/dialysis/accepts?mode=1",
  615. modify_url: "/api/dialysis/accepts?mode=2",
  616. modify_other_url: "/api/dialysis/accepts?mode=3",
  617. module: 2,
  618. },
  619. })
  620. .then((res) => {
  621. // console.log(res);
  622. //console.log("接诊", this.accepts);
  623. if (res.data.state == 0) {
  624. this.hasPermission = false;
  625. } else if (res.data.state == 1) {
  626. if (this.accepts.id != "" && this.accepts.creater != 0) {
  627. //有数据
  628. if (this.accepts.creater == this.$store.getters.xt_user.user.id) {
  629. //创建人是自己
  630. if (res.data.data.is_has_modify == false) {
  631. this.hasPermission = false;
  632. this.showTxt = "你没有修改接诊评估权限";
  633. }
  634. } else {
  635. //创建人不是自己
  636. if (res.data.data.is_has_modify_other == false) {
  637. this.hasPermission = false;
  638. this.showTxt = "你没有修改他人接诊评估权限";
  639. }
  640. }
  641. } else if (this.accepts.id == "" || this.accepts.creater == 0) {
  642. if (res.data.data.is_has_create == false) {
  643. this.hasPermission = false;
  644. this.showTxt = "你没有新增接诊评估权限";
  645. }
  646. }
  647. }
  648. });
  649. },
  650. saveInformation(){
  651. var params = {
  652. selected_date:this.selected_date,
  653. patient_id:this.$route.query.patient_id,
  654. record_date:this.$route.query.date,
  655. module:2,
  656. remark:this.remark,
  657. }
  658. saveInformation(params).then(response=>{
  659. if(response.data.state == 1){
  660. var information = response.data.data.information
  661. this.$message.success("提交成功!")
  662. this.infoDialogVisible = false
  663. }
  664. })
  665. }
  666. },
  667. props: {
  668. receiver_treatment_access: {
  669. // 双人核对
  670. type: Object,
  671. default: () => {
  672. return { id: 0 };
  673. },
  674. },
  675. patient: {
  676. // 患者信息
  677. type: Object,
  678. default: () => {
  679. return { id: 0 };
  680. },
  681. },
  682. },
  683. watch: {
  684. isVisibility(val) {},
  685. "receiver_treatment_access.id": function () {
  686. if (this.receiver_treatment_access.id > 0) {
  687. for (var index in this.receiveTreatmentAsses) {
  688. this.receiveTreatmentAsses[index] =
  689. this.receiver_treatment_access[index];
  690. }
  691. }
  692. },
  693. },
  694. created() {
  695. // console.log("接诊评估", this.receiver_treatment_access);
  696. var date = this.$route.query && this.$route.query.date;
  697. this.record_date = date
  698. ? uParseTime(date, "{y}-{m}-{d}")
  699. : parseTime(new Date(), "{y}-{m}-{d}");
  700. console.log("this.record_date", this.record_date);
  701. this.way_arr = getDataConfig("hemodialysis", "way");
  702. this.consciousness_arr = getDataConfig("hemodialysis", "consciousness");
  703. this.appetite_arr = getDataConfig("hemodialysis", "appetite");
  704. this.posture_arr = getDataConfig("hemodialysis", "posture");
  705. this.sick_condition_arr = getDataConfig("hemodialysis", "sick_condition");
  706. this.precaution_arr = getDataConfig("hemodialysis", "precaution");
  707. // console.log("风险", this.precaution_arr);
  708. this.intake_arr = getDataConfig("hemodialysis", "intake");
  709. this.nutrition_arr = getDataConfig("hemodialysis", "nutrition");
  710. },
  711. };
  712. </script>
  713. <style scoped>
  714. .warnTxt {
  715. text-align: center;
  716. margin: 0 auto;
  717. background: #faa331;
  718. max-width: 240px;
  719. padding: 10px 20px;
  720. border-radius: 4px;
  721. margin-bottom: 10px;
  722. color: #fff;
  723. }
  724. </style>
  725. <style lang="scss">
  726. .newDialog {
  727. .el-dialog__body {
  728. padding: 10px 20px 30px;
  729. }
  730. }
  731. </style>