selfMeetingInfo.vue 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. <template>
  2. <van-nav-bar
  3. fixed
  4. title="私设聚会点"
  5. left-text=""
  6. left-arrow
  7. @click-left="onClickLeft"
  8. />
  9. <van-loading size="16px" v-if="isLoading">加载中...</van-loading>
  10. <div class="main" v-if="!isLoading">
  11. <div class="banner">
  12. <h2>扎实提升“三力”</h2>
  13. <h2>深入推进“三化”</h2>
  14. <h2>坚持“三个思维”</h2>
  15. </div>
  16. <div class="info">
  17. <p>地点:{{ inputForm.placeSelectName }}</p>
  18. <p>详细地点:{{ inputForm.placeDel }}</p>
  19. <p>频次:{{ inputForm.frequency }}</p>
  20. <p>时间:{{ inputForm.partyTime }}</p>
  21. <p>相关人:{{ inputForm.relatedPersons.name }}</p>
  22. <p>内容:{{ inputForm.content }}</p>
  23. </div>
  24. <van-button type="primary" class="btn-sub" @click="update">审核</van-button>
  25. </div>
  26. </template>
  27. <script>
  28. import { ref } from "vue";
  29. import { useRoute } from "vue-router";
  30. import PrivatePartyPointService from "@/api/privateparty/PrivatePartyPointService";
  31. import UserManage from "@/api/user/UserManage";
  32. export default {
  33. setup() {
  34. const onClickLeft = () => {
  35. history.back();
  36. };
  37. // 加载
  38. let isLoading = ref(true);
  39. // 私设聚会点信息
  40. let inputForm = ref({
  41. id: "",
  42. place: "320900",
  43. placeSelectName: "盐城市",
  44. placeSelectType3: "320900",
  45. placeSelectType4: "",
  46. placeSelectType5: "",
  47. placeSelectType6: "",
  48. placeDel: "",
  49. frequency: "",
  50. partyTime: "",
  51. relatedPersons: {
  52. id: "",
  53. name: "",
  54. },
  55. content: "",
  56. state: "0",
  57. assessment: "0",
  58. });
  59. // 获取信息
  60. let route = useRoute();
  61. new PrivatePartyPointService().queryById(route.query.id).then((data) => {
  62. inputForm.value = data;
  63. let ids = data.relatedPersons.id.split(",");
  64. inputForm.value.relatedPersons.name = "";
  65. ids.forEach((item) => {
  66. new UserManage().queryById(item).then((data) => {
  67. inputForm.value.relatedPersons.name += data.name + ",";
  68. });
  69. });
  70. isLoading.value = false;
  71. });
  72. // 审核通过
  73. const update = () => {
  74. isLoading.value = true;
  75. inputForm.value.assessment = 1;
  76. new PrivatePartyPointService().save(inputForm.value).then((res) => {
  77. console.log(res);
  78. onClickLeft();
  79. isLoading.value = false;
  80. });
  81. };
  82. return {
  83. onClickLeft,
  84. inputForm,
  85. isLoading,
  86. update,
  87. };
  88. },
  89. };
  90. </script>
  91. <style lang="less">
  92. .main {
  93. background: #fff;
  94. position: relative;
  95. top: 40px;
  96. }
  97. .banner {
  98. background-color: #36a7f3;
  99. padding: 20px 50px 40px 50px;
  100. color: #fff;
  101. h2 {
  102. &:nth-child(1) {
  103. margin-top: 0px;
  104. text-align: left;
  105. }
  106. &:nth-child(2) {
  107. text-align: center;
  108. }
  109. &:nth-child(3) {
  110. text-align: right;
  111. }
  112. }
  113. }
  114. .info {
  115. position: relative;
  116. width: 86vw;
  117. // height: 120px;
  118. margin: 10px auto;
  119. padding: 10px;
  120. background: #fff;
  121. border-radius: 20px;
  122. top: -50px;
  123. font-size: 14px;
  124. }
  125. .btn-sub {
  126. width: 90%;
  127. border-radius: 20px;
  128. margin-left: 5%;
  129. }
  130. .van-loading {
  131. text-align: center;
  132. margin-top: 80px;
  133. }
  134. </style>