综合办公系统
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

flowNote.vue 2.3KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. <!--
  2. * @Author: ysh
  3. * @Date: 2025-03-17 10:04:51
  4. * @LastEditors: Please set LastEditors
  5. * @LastEditTime: 2025-03-28 14:29:11
  6. -->
  7. <template>
  8. <view>
  9. <uv-steps :current="currentNum">
  10. <uv-steps-item :error="item.comment && item.comment.type == '退回意见'" v-for="item, index in flowRecordList"
  11. :key="'f' + index" :title="item.taskName" :desc="item.finishTime"></uv-steps-item>
  12. </uv-steps>
  13. <view class="custom-block danger" v-if="isRetrun">
  14. <uni-title type="h3" title="任务被退回,请修改后重新提交" color="#900"></uni-title>
  15. <view>
  16. <p>退回意见:{{ reBackDescription }}</p>
  17. <p>办理人:{{ assigneeName }}</p>
  18. </view>
  19. </view>
  20. <uv-divider></uv-divider>
  21. </view>
  22. </template>
  23. <script>
  24. import { flowRecord, flowRecordFull } from "@/api/flowable/finished";
  25. export default {
  26. props: {
  27. taskForm: Object,
  28. },
  29. data() {
  30. return {
  31. flowRecordList: [],
  32. currentNum: 0,
  33. isRetrun: false,
  34. reBackDescription: '',
  35. assigneeName: ''
  36. }
  37. },
  38. created() {
  39. this.getFlowRecordList(this.taskForm.procInsId, this.taskForm.deployId);
  40. },
  41. methods: {
  42. /** 流程流转记录 */
  43. getFlowRecordList(procInsId, deployId) {
  44. this.currentNum = 0;
  45. const params = { procInsId: procInsId, deployId: deployId }
  46. flowRecordFull(params).then(res => {
  47. if (res.data.flowList.length > 1 && res.data.flowList[1].comment && res.data.flowList[1].comment.type == '退回意见') {
  48. this.reBackDescription = res.data.flowList[1].comment.comment
  49. this.assigneeName = res.data.flowList[1].assigneeName
  50. this.isRetrun = true
  51. } else {
  52. this.isRetrun = false
  53. }
  54. this.flowRecordList = res.data.flowList.reverse();
  55. for (let i = 0; i < this.flowRecordList.length; i++) {
  56. if (!this.flowRecordList[i].finishTime) {
  57. this.currentNum = i
  58. }
  59. }
  60. if (this.currentNum == 0) {
  61. this.currentNum = this.flowRecordList.length
  62. }
  63. })
  64. },
  65. },
  66. }
  67. </script>
  68. <style lang="scss" scoped>
  69. .custom-block {
  70. padding: 10px;
  71. border-left-width: 2px;
  72. border-left-style: solid;
  73. margin: 5px 0;
  74. }
  75. .danger {
  76. background-color: #ffe6e6;
  77. border-color: #c00;
  78. color: #4d0000;
  79. }
  80. </style>