ActivityHandleRecord.vue 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. <template>
  2. <div class="el-row">
  3. <el-table :data="flowData.activityInsRecordList">
  4. <el-table-column type="index" align="center" label="序号" width="50" />
  5. <el-table-column prop="actionTime" align="center" label="处理时间" width="170">
  6. <template v-slot="{row}">
  7. <span><i class="el-icon el-icon-time" />{{ row.actionTime }}</span>
  8. </template>
  9. </el-table-column>
  10. <el-table-column prop="accountAvatar" align="center" label="人员" width="160">
  11. <template v-slot="{row}">
  12. <div class="flex-center">
  13. <el-image style="width: 20px; height: 20px;border-radius:50%" :src="row.accountAvatar" :preview-src-list="[row.accountAvatar]" />
  14. <span class="name">{{ row.accountName }}</span><span>({{ row.positionName }})</span>
  15. </div>
  16. </template>
  17. </el-table-column>
  18. <el-table-column prop="activityInsTitle" align="center" label="处理关卡" width="100">
  19. <template v-slot="{row}">
  20. <span><el-tag type="success" effect="plain" color="rgb(38 69 90)">{{ row.activityInsTitle }}</el-tag></span>
  21. </template>
  22. </el-table-column>
  23. <el-table-column prop="actionTitle" align="center" label="处理动作" width="100">
  24. <template v-slot="{row}">
  25. <span><el-tag type="warning" effect="plain" color="rgb(38 69 90)">{{ row.actionTitle }}</el-tag></span>
  26. </template>
  27. </el-table-column>
  28. <el-table-column prop="actionRemark" label="处理说明">
  29. <template v-slot="{row}">
  30. <div class="task-remark">{{ row.actionRemark }}</div>
  31. </template>
  32. </el-table-column>
  33. <el-table-column prop="attachList" label="附件">
  34. <template v-slot="{row}">
  35. <div v-if="row.attachList&&row.attachList.length>0" class="assess-attachList">
  36. <p v-for="(item,index) in row.attachList" :key="index"><attach-list :uri="item.fileUrl" :name="item.fileTitle" /></p>
  37. </div>
  38. </template>
  39. </el-table-column>
  40. </el-table>
  41. </div>
  42. </template>
  43. <script>
  44. import { getWorkflowById } from '@/api/system/wfApi'
  45. import AttachList from '@/components/AttachList'
  46. export default {
  47. name: 'ActivityHandleRecord',
  48. components: {
  49. AttachList
  50. },
  51. props: {
  52. wfInsId: {
  53. type: [Number],
  54. default: undefined
  55. }
  56. },
  57. data() {
  58. return {
  59. ops: {
  60. bar: {
  61. keepShow: false,
  62. background: 'rgba(144, 147, 153, 0.4)',
  63. onlyShowBarOnScroll: false
  64. }
  65. },
  66. listLoading: false,
  67. flowData: {
  68. wfDefId: 1,
  69. wfInsId: undefined,
  70. wfInsTitle: '',
  71. wfInsStatus: undefined,
  72. activityIns: undefined,
  73. activityInsRecordList: []
  74. },
  75. rules: {}
  76. }
  77. },
  78. methods: {
  79. getData(wfInsId) {
  80. if (!wfInsId) return
  81. this.listLoading = true
  82. getWorkflowById(wfInsId).then((resp) => {
  83. this.listLoading = false
  84. const { code, data, msg } = resp
  85. if (code === 0) {
  86. this.flowData = data
  87. } else {
  88. this.$message.error(msg)
  89. }
  90. })
  91. }
  92. }
  93. }
  94. </script>
  95. <style lang="scss">
  96. </style>
  97. <style lang="scss" scoped>
  98. .assess-attachList{
  99. overflow: hidden;
  100. text-overflow:ellipsis;
  101. white-space: nowrap;
  102. p{
  103. line-height: 1;
  104. }
  105. }
  106. </style>