RationalDrugUseWindow.vue 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. <template>
  2. <xc-dialog-v2 v-model="dialog" title="合理用药提示"
  3. :manual-shutdown="true">
  4. <div style="width: 100%;height: 500px">
  5. <iframe :src="rationalUse.ShowUrl"/>
  6. </div>
  7. <template #footer>
  8. <el-button type="primary" @click="continueToSubmit">继续提交</el-button>
  9. </template>
  10. </xc-dialog-v2>
  11. </template>
  12. <script setup name='RationalDrugUseWindow'>
  13. import {rationalUseOfMedicine} from "@/api/heliyongyao/rational-use";
  14. import XcDialogV2 from "@/components/xiao-chan/dialog/XcDialogV2.vue";
  15. const emit = defineEmits(['submit'])
  16. let dialog = $ref(false)
  17. let rationalUse = $ref({})
  18. const check = async (patNo, times) => {
  19. rationalUse = await rationalUseOfMedicine(patNo, times)
  20. console.log(rationalUse)
  21. if (rationalUse.result_lv > 0) {
  22. dialog = true
  23. return false
  24. }
  25. return true
  26. }
  27. const continueToSubmit = () => {
  28. emit('submit')
  29. dialog = false
  30. }
  31. defineExpose({
  32. check
  33. })
  34. </script>
  35. <style scoped lang="scss">
  36. iframe {
  37. width: 100%;
  38. height: 100%;
  39. }
  40. </style>