religiousConferenceInfo.vue 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167
  1. <template>
  2. <van-nav-bar
  3. fixed
  4. title="负责人会议上报情况"
  5. left-text=""
  6. left-arrow
  7. @click-left="onClickLeft"
  8. :style="{ 'background-color': selectColor }"
  9. />
  10. <van-loading size="16px" v-show="isLoading">加载中...</van-loading>
  11. <div class="main" v-show="!isLoading">
  12. <div class="banner">
  13. <img src="../../../../public/loginbg/banner.jpg" alt="" />
  14. </div>
  15. <div class="info">
  16. <p class="miniTitle">基础信息</p>
  17. <van-cell-group>
  18. <van-field
  19. v-model="info.placeSelectName"
  20. readonly
  21. label="会议地点:"
  22. input-align="right"
  23. />
  24. </van-cell-group>
  25. <van-cell-group>
  26. <van-field
  27. v-model="info.venueDetailed"
  28. center
  29. readonly
  30. label="详细地址:"
  31. input-align="right"
  32. />
  33. </van-cell-group>
  34. <van-cell-group>
  35. <van-field
  36. v-model="info.meetingTime"
  37. center
  38. readonly
  39. label="会议时间:"
  40. input-align="right"
  41. />
  42. </van-cell-group>
  43. <van-cell-group>
  44. <van-field
  45. v-model="info.siteName.name"
  46. center
  47. readonly
  48. label="会议场所:"
  49. input-align="right"
  50. />
  51. </van-cell-group>
  52. <van-cell-group>
  53. <van-field
  54. v-model="info.participants.name"
  55. center
  56. readonly
  57. label="参会人员:"
  58. input-align="right"
  59. />
  60. </van-cell-group>
  61. <p class="miniTitle">会议议题:</p>
  62. <div v-html="info.meetingTopics" class="showhtml"> </div>
  63. </div>
  64. <van-button
  65. v-if="info.assessment == 0"
  66. type="primary"
  67. class="btn-sub"
  68. @click="update"
  69. >审核</van-button
  70. >
  71. </div>
  72. </template>
  73. <script>
  74. import { ref, onMounted } from "vue";
  75. import religiousConferenceService from "@/api/religiousConference/religiousConferenceService";
  76. import UserManage from "@/api/user/UserManage";
  77. import { useRoute } from "vue-router";
  78. import $base from "@/utils/config";
  79. export default {
  80. setup() {
  81. // 导航栏颜色
  82. const selectColor = ref(window.localStorage.getItem("MZ_COLOR"));
  83. const onClickLeft = () => {
  84. history.back();
  85. };
  86. // 加载
  87. let isLoading = ref(true);
  88. // 活动信息
  89. const info = ref({
  90. siteName:{id:"",name:""},
  91. participants:{id:"",name:""},
  92. meetingTopics:"",
  93. });
  94. // 文件
  95. let fileList = ref([]);
  96. let route = useRoute();
  97. onMounted(() => {
  98. new religiousConferenceService().queryById(route.query.id).then((data) => {
  99. info.value = data;
  100. let ids = data.participants.id.split(",");
  101. info.value.participants.name = "";
  102. ids.forEach((item) => {
  103. new UserManage().queryById(item).then((data) => {
  104. info.value.participants.name += data.name + ",";
  105. });
  106. });
  107. isLoading.value = false;
  108. });
  109. });
  110. // 审核通过
  111. const update = () => {
  112. isLoading.value = true;
  113. info.value.assessment = 1;
  114. new religiousConferenceService().save(info.value).then((res) => {
  115. isLoading.value = false;
  116. window.xm.showToast({
  117. message:"审核成功!"
  118. })
  119. history.back();
  120. });
  121. };
  122. return {
  123. // 导航栏颜色
  124. selectColor,
  125. onClickLeft,
  126. info,
  127. fileList,
  128. isLoading,
  129. update,
  130. };
  131. },
  132. };
  133. </script>
  134. <style lang="less">
  135. .van-cell__value .van-field__right-icon .van-icon-location {
  136. color: #36a7f3 !important;
  137. }
  138. .btn-sub {
  139. width: 90%;
  140. border-radius: 20px;
  141. margin-left: 5%;
  142. margin-bottom: 40px;
  143. margin-top: -100px;
  144. }
  145. .van-loading {
  146. text-align: center;
  147. margin-top: 80px;
  148. }
  149. .van-popup--center {
  150. width: 98% !important;
  151. }
  152. .showhtml{
  153. width: 94%;
  154. border: 2px solid #ccc;
  155. border-radius: 10px;
  156. padding: 10px;
  157. }
  158. </style>