dischargeMedicationDetails.vue 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. <template>
  2. <view class="container">
  3. <view class="content">
  4. <view class="floot" v-if="showCont" v-for="(item, index) in details" :key="index">
  5. <view class="floot_title colorCustom">{{item.PrescribeTypeName}}</view>
  6. <view class="floot_box">
  7. <view class="flootBox_item border_top" v-for="(detailsItem, subIndex) in item.Data_1" :key="subIndex">
  8. <view class="name">{{detailsItem.Project}}</view>
  9. <view>
  10. <text class="text">用药计量:{{detailsItem.OneDose}}{{detailsItem.OneDoseUnit}}</text>
  11. <text class="text">用药天数:{{detailsItem.DosageDays}}天</text>
  12. <text class="text">用药频次:{{detailsItem.UsageName}}</text>
  13. </view>
  14. </view>
  15. </view>
  16. </view>
  17. </view>
  18. </view>
  19. </template>
  20. <script setup lang="ts">
  21. import { ref, getCurrentInstance } from 'vue';
  22. import { useOnLoad } from '@dcloudio/uni-app';
  23. import { common } from '@/utils';
  24. import { queryInpatientDocAdviceList } from '@/pagesPatient/service/record';
  25. const { proxy } = getCurrentInstance() as any;
  26. const app = getApp();
  27. const showCont = ref(false);
  28. const details = ref<any[]>([]);
  29. useOnLoad((options: any) => {
  30. let currentUser = app.globalData.currentUser;
  31. let queryBean: any = {};
  32. if (options.queryBean) {
  33. try {
  34. queryBean = JSON.parse(options.queryBean);
  35. } catch (e) {
  36. console.error('JSON parse error:', e);
  37. }
  38. }
  39. main(currentUser, queryBean);
  40. });
  41. const main = async (currentUser: any, queryBean: any) => {
  42. let reqData = {
  43. hosId: app.globalData.districtId || app.globalData.hosId,
  44. CardNo: queryBean.CardNo,
  45. CardType: currentUser.cardType,
  46. MemberId: currentUser.memberId,
  47. Store: {
  48. cardEncryptionStore: currentUser.encryptionStore || '',
  49. baseMemberEncryptionStore: currentUser.baseMemberEncryptionStore
  50. }
  51. };
  52. let { resp } = await queryInpatientDocAdviceList(reqData);
  53. if (common.isNotEmpty(resp)) {
  54. details.value = resp;
  55. showCont.value = true;
  56. }
  57. };
  58. </script>
  59. <style lang="scss">
  60. .floot {
  61. border-radius: 24upx;
  62. background: #fff;
  63. padding: 0 30upx;
  64. margin: 30upx;
  65. }
  66. .floot_title {
  67. font-size: 36upx;
  68. padding: 32upx 0;
  69. }
  70. .flootBox_item {
  71. padding: 35upx 0;
  72. }
  73. .name {
  74. font-size: 32upx;
  75. color: #333;
  76. margin-bottom: 18upx;
  77. }
  78. .text {
  79. font-size: 24upx;
  80. color: #999;
  81. margin-right: 15upx;
  82. }
  83. </style>