VabNoticeDetail.vue 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. <template>
  2. <el-dialog
  3. v-model="dialogFormVisible"
  4. title="信息详情"
  5. width="700px"
  6. @close="close"
  7. >
  8. <div>
  9. <div class="title">
  10. {{ detail.category_1 ? detail.category_1.name : ''
  11. }}{{ detail.category_2 ? '/' + detail.category_2.name : ''
  12. }}{{ detail.category_3 ? '/' + detail.category_3.name : '' }}
  13. {{ detail.category_4 ? '/' + detail.category_4.name : '' }}
  14. {{ detail.category_5 ? '/' + detail.category_5.name : '' }}
  15. </div>
  16. <div class="people">
  17. 反映人员:{{ detail.name || '--' }}
  18. <span class="time">时间:{{ detail.complain_date }}</span>
  19. <!-- <span class="time">
  20. 姓别:{{ detail.sex == 0 ? '未知' : detail.sex == 1 ? '男' : '女' }}
  21. </span> -->
  22. <span class="time">手机号:{{ detail.mobile }}</span>
  23. <span class="time">身份证号:{{ detail.id_card || '--' }}</span>
  24. </div>
  25. <div class="content">
  26. {{ detail.body }}
  27. </div>
  28. <div class="chuli">
  29. <div class="title">办理情况</div>
  30. <div class="people">
  31. 处理部门:{{
  32. detail.deal_department ? detail.deal_department.name : ''
  33. }}
  34. </div>
  35. <div class="content1">
  36. {{ detail.deal_idea || '--' }}
  37. </div>
  38. </div>
  39. <div class="chuli">
  40. <div class="title">投诉目的</div>
  41. <div class="content1">
  42. {{ detail.goal || '--' }}
  43. </div>
  44. </div>
  45. <div class="chuli">
  46. <div class="title">备注</div>
  47. <div class="content1">
  48. {{ detail.remark || '--' }}
  49. </div>
  50. </div>
  51. </div>
  52. <template #footer>
  53. <!-- <el-button @click="close">取 消</el-button> -->
  54. <el-button type="primary" @click="close">确 定</el-button>
  55. </template>
  56. </el-dialog>
  57. </template>
  58. <script>
  59. import { getDetail } from '@/api/notice'
  60. export default defineComponent({
  61. name: 'VabNoticeDetail',
  62. emits: ['fetch-data'],
  63. setup(props, { emit }) {
  64. const $baseMessage = inject('$baseMessage')
  65. const state = reactive({
  66. formRef: null,
  67. title: '',
  68. detail: '',
  69. dialogFormVisible: false,
  70. source_type: '',
  71. })
  72. const showEdit = (row) => {
  73. state.source_type = row.source_type
  74. if (
  75. state.source_type === 'App\\Repositories\\Models\\Manage\\Message'
  76. ) {
  77. getInfoDetail(row.source_id)
  78. }
  79. state.dialogFormVisible = true
  80. }
  81. const getInfoDetail = async (id) => {
  82. const { data } = await getDetail({ id: id })
  83. state.detail = data
  84. }
  85. const close = () => {
  86. state.dialogFormVisible = false
  87. }
  88. onMounted(() => {})
  89. return {
  90. ...toRefs(state),
  91. getInfoDetail,
  92. showEdit,
  93. close,
  94. }
  95. },
  96. })
  97. </script>
  98. <style lang="scss" scoped>
  99. .vab-tree-border {
  100. width: 100%;
  101. height: 250px;
  102. padding: $base-padding;
  103. overflow-y: auto;
  104. border: 1px solid #dcdfe6;
  105. border-radius: $base-border-radius;
  106. }
  107. .title {
  108. font-size: 16px;
  109. font-weight: 550;
  110. padding: 8px 0;
  111. }
  112. .content {
  113. line-height: 26px;
  114. margin-bottom: 20px;
  115. padding: 5px;
  116. background-color: #f7f7f7;
  117. border-radius: 5px;
  118. }
  119. .people {
  120. margin-bottom: 20px;
  121. }
  122. .content1 {
  123. line-height: 26px;
  124. padding: 5px;
  125. background-color: #f7f7f7;
  126. border-radius: 5px;
  127. }
  128. .time {
  129. margin-left: 5px;
  130. }
  131. </style>