dialog.approve.letter.detail.vue 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169
  1. <template>
  2. <DialogCom
  3. :title="title"
  4. @close="onHide"
  5. :visible.sync="isShow"
  6. width="1000px"
  7. >
  8. <div class="page-body">
  9. <el-descriptions
  10. :column="2"
  11. border
  12. size="medium"
  13. :label-style="labelStyle"
  14. :contentStyle="content_style">
  15. <el-descriptions-item label="介绍信类型">
  16. <dict-tag :options="dict.type.out_in_type" :value="formData.type"/>
  17. </el-descriptions-item>
  18. <!-- <el-descriptions-item label="当前状态">-->
  19. <!-- <dict-tag :options="dict.type.letter_status" :value="formData.status"/>-->
  20. <!-- </el-descriptions-item>-->
  21. <el-descriptions-item label="介绍信编号">{{formData.letterNo}}</el-descriptions-item>
  22. <el-descriptions-item label="接待机构">{{formData.receptionOrgNames}}</el-descriptions-item>
  23. <el-descriptions-item label="来访事由">{{formData.reasons}}</el-descriptions-item>
  24. <el-descriptions-item label="开具日期">{{formData.startTimeStr}}</el-descriptions-item>
  25. <el-descriptions-item label="有效天数">{{formData.effectiveDays}}</el-descriptions-item>
  26. <el-descriptions-item label="介绍信附件">
  27. <K-file-upload
  28. ref="upload"
  29. :isShowUploadBtn="false"
  30. :defaultValue="formData.letterFile"
  31. />
  32. </el-descriptions-item>
  33. <el-descriptions-item label="备注">{{formData.description}}</el-descriptions-item>
  34. </el-descriptions >
  35. <el-row :gutter="10">
  36. <el-col :span="12">
  37. <h3>
  38. <i class="el-icon-collection-tag"></i>
  39. 人员信息
  40. </h3>
  41. </el-col>
  42. </el-row>
  43. <el-table border :data="formData.userInfos" height="300">
  44. <el-table-column label="序号" align="center" type="index" width="70" />
  45. <el-table-column label="来访单位" width="100" align="center" prop="companyName" />
  46. <el-table-column label="来访人员" width="100" align="center" prop="userName" />
  47. <el-table-column label="证件类型" width="100" align="center" prop="idType">
  48. <template slot-scope="scope">
  49. <dict-tag :options="dict.type.letter_id_type" :value="scope.row.idType"/>
  50. </template>
  51. </el-table-column>
  52. <el-table-column label="证件号码" width="200" align="center" prop="idCard">
  53. </el-table-column>
  54. <el-table-column label="证件图片" align="center" prop="imgFile">
  55. <template slot-scope="scope">
  56. <ImageListPreview v-model="scope.row.imgFile"></ImageListPreview>
  57. </template>
  58. </el-table-column>
  59. </el-table>
  60. <el-row :gutter="10">
  61. <el-col :span="12">
  62. <h3>
  63. <i class="el-icon-collection-tag"></i>
  64. 审批信息
  65. </h3>
  66. </el-col>
  67. </el-row>
  68. <el-descriptions
  69. :column="2"
  70. border
  71. size="medium"
  72. :label-style="labelStyle"
  73. :contentStyle="content_style">
  74. <el-descriptions-item label="审批状态">
  75. <dict-tag :options="dict.type.out_in_approve_status" :value="formData.approveLog.approveStatus"/>
  76. </el-descriptions-item>
  77. <el-descriptions-item label="审批时间"> {{formData.approveLog.approveTime}}</el-descriptions-item>
  78. <el-descriptions-item label="审批说明"> {{formData.approveLog.approveRemark}}</el-descriptions-item>
  79. </el-descriptions >
  80. </div>
  81. <div slot="footer" class="dialog-footer">
  82. <!-- <el-button type="primary" @click="submitForm">确 定</el-button> -->
  83. <el-button @click="onHide">关 闭</el-button>
  84. </div>
  85. </DialogCom>
  86. </template>
  87. <script>
  88. import { mapState, mapMutations } from "vuex";
  89. import {
  90. getLetter,
  91. approveLetter,
  92. } from "@/api/core/letter";
  93. import KFileUpload from "@/components/K-FileUpload/index.vue";
  94. import dayjs from "dayjs";
  95. import imgUpload from "@/components/ImageUpload";
  96. import DataRangePicker from "@/components/dateTime/daterange.picker.vue";
  97. export default {
  98. components: { KFileUpload, imgUpload,DataRangePicker },
  99. data() {
  100. const params = this.$route.params;
  101. return {
  102. labelStyle: {
  103. color: "#000",
  104. "text-align": "center",
  105. height: "40px",
  106. "min-width": "150px",
  107. "word-break": "keep-all",
  108. },
  109. content_style: {
  110. "text-align": "left",
  111. "min-width": "300px",
  112. "word-break": "break-all",
  113. },
  114. id: params ? params.id : null,
  115. isShow: false,
  116. title: "来访事项审批详情",
  117. formData: this.reset(),
  118. formFileListDefualtValue: [],
  119. };
  120. },
  121. dicts: ['out_in_type','out_in_approve_status','letter_id_type'],
  122. props: {},
  123. watch: {},
  124. created() {},
  125. computed: {
  126. ...mapState(["loginUser", "org"]),
  127. },
  128. methods: {
  129. ...mapMutations([]),
  130. reset(other = {}) {
  131. return {
  132. reasons: null,
  133. letterNo:null,
  134. receptionOrgIds: [],
  135. range:[],
  136. description: null,
  137. letterFile: [],
  138. userInfos: [],
  139. type:null,
  140. approveLog:{
  141. approveStatus:null,
  142. approveRemark:null
  143. },
  144. ...other,
  145. };
  146. },
  147. async show(id) {
  148. this.title = "来访事项审批详情";
  149. this.isShow = true;
  150. getLetter(id).then((response) => {
  151. this.formData = response.data;
  152. this.formFileListDefualtValue=this.formData.letterFile;
  153. });
  154. },
  155. onHide() {
  156. this.isShow = false;
  157. this.formData = this.reset();
  158. // this.$refs["upload"].clearFiles();
  159. },
  160. },
  161. mounted() {},
  162. };
  163. </script>