satisfactionHome.vue 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. <template>
  2. <view class="container">
  3. <view class="content">
  4. <view class="list">
  5. <view class="item" v-for="(item,index) in list" :key="index" @click="itemClick(item)">
  6. <image class="item_img" :src="iconUrl.home_back"></image>
  7. <view class="item_val">{{item.SubjectTitle}}</view>
  8. </view>
  9. <view v-if="list.length == 0" class="noData">
  10. <noData value="暂无数据"></noData>
  11. </view>
  12. </view>
  13. </view>
  14. </view>
  15. </template>
  16. <script lang="ts" setup>
  17. import { reactive, ref } from 'vue';
  18. import { useOnLoad } from '@/hook';
  19. import { useDomain } from '@kasite/uni-app-base';
  20. import { mapGetters } from '@kasite/uni-app-base/store/hook';
  21. import {
  22. QuerySubjectListToChannelTask_V3
  23. } from '../../service';
  24. import icon from '@/utils/icon';
  25. import { common, throttle } from '@/utils';
  26. import fn from './fn';
  27. const app = getApp();
  28. const list = ref([])
  29. const iconUrl = ref(icon)
  30. const objType = ref("")
  31. const cardNo = ref("")
  32. const cardType = ref("")
  33. const type = ref("")
  34. useOnLoad((options) => {
  35. console.log("options===",options,app.globalData)
  36. main(options);
  37. });
  38. const main = async (options) => {
  39. let queryData = {
  40. OrgId: "21054",
  41. // OrgId: app.globalData.hosId,
  42. State: 1,
  43. SubjectWay: 'smallpro',
  44. // 1=面向所有患者、2=面向医院职工、3=面向门诊患者、4=面向住院患者、5=面向体检患者
  45. GroupType: options.objType || "3"
  46. }
  47. let resp = await QuerySubjectListToChannelTask_V3(queryData);
  48. if(!common.isEmpty(resp)) {
  49. objType.value = options.objType || '3'
  50. list.value = resp || []
  51. cardNo.value = options.cardNo
  52. cardType.value = options.cardType
  53. type.value = options.type
  54. }
  55. };
  56. /**
  57. * 满意度点击
  58. */
  59. const itemClick = (item) => {
  60. common.goToUrl(`/pagesAdmin/satisfaction/business/satisfactionQuestions/satisfactionQuestions?subjectId=${item.SubjectId}&taskId=${item.TaskId}&cardNo=${cardNo.value}&cardType=${cardType.value}&type=${type.value}`)
  61. }
  62. </script>
  63. <style lang="scss" scoped>
  64. .list {
  65. padding: 30upx;
  66. }
  67. .item {
  68. margin-bottom: 30upx;
  69. background: rgba(255, 255, 255, 1);
  70. border-radius: 20upx;
  71. overflow: hidden;
  72. }
  73. .item_img {
  74. width: 100%;
  75. height: 340upx;
  76. }
  77. .item_val {
  78. font-size: 32upx;
  79. font-family: Source Han Sans CN;
  80. font-weight: 500;
  81. color: rgba(0, 0, 0, 1);
  82. height: 100upx;
  83. display: flex;
  84. align-items: center;
  85. padding: 0 30upx;
  86. line-height: 1.4em;
  87. }
  88. </style>