zrj
2024-06-07 fa0fc3195858a592d2ad1bdad0fa6126602ebf55
src/views/gzll/process/maintenanceFundApply/handle.vue
@@ -11,7 +11,22 @@
        <div slot="header">
          <span>审批信息</span>
        </div>
        <avue-form :option="option" v-model="form"></avue-form>
        <avue-form :option="option" v-model="form">
          <template slot-scope="{ row, size, index }" slot="vote">
            <div>{{ topicTitle }}</div>
            <el-table :data="topictData" v-if="topictData.length">
              <el-table-column width="300" property="optionContent" label="选项"
                label-class-name="workOrderStyle"></el-table-column>
              <el-table-column width="300" property="number" label="人数" label-class-name="workOrderStyle">
              </el-table-column>
              <el-table-column width="300">
                <template slot-scope="scope">
                  <el-button slot="reference" type="primary" size="mini"
                    @click="openUserPopup(scope.row, 1)">详情</el-button>
                </template>
              </el-table-column>
            </el-table>
          </template></avue-form>
      </el-card>
      <el-card shadow="hover">
@@ -25,7 +40,7 @@
                <p>{{ flow.assigneeName }} 在 [{{ flow.createTime }}] 开始处理 [{{ flow.historyActivityName }}]
                  环节</p>
                <p v-if="flow.historyActivityDurationTime !== ''">任务历时 [{{ flow.historyActivityDurationTime
                                }}]
                }}]
                </p>
                <p v-if="flow.comment !== ''">批复意见: [{{ flow.comment }}]</p>
                <p v-if="flow.endTime !== ''">结束时间: [{{ flow.endTime }}]</p>
@@ -58,6 +73,9 @@
      <el-button type="danger" @click="handleDisagree">驳回</el-button>
    </div>
    <deitDiscussion ref="DeitDiscussion">
    </deitDiscussion>
  </basic-container>
</template>
@@ -65,7 +83,7 @@
  import {
    historyFlowList,
    leaveDetail
  } from "@/api/work/process"
  } from "@/ssoapi/work/process"
  import {
    getList,
@@ -73,13 +91,22 @@
    update,
    add,
    getPropertyCapitalApply
  } from "@/api/property/propertyCapitalApply"
  } from "@/ssoapi/property/propertyCapitalApply"
  import {
    completeTask
  } from "@/api/work/work"
  } from "@/ssoapi/work/work"
  import website from '@/config/website'
  import {
    getLists,
  } from "@/ssoapi/discuss/topics"
  import deitDiscussion from "../../components/deitDiscussion"
  export default {
    components: {
      deitDiscussion
    },
    data() {
      return {
        taskId: '',
@@ -117,7 +144,7 @@
              searchSpan: 5,
              search: true,
              type: 'tree',
              dicUrl: `/api/blade-district/district/getDistrictTree`,
              dicUrl: `/ssoapi/blade-district/district/getDistrictTree`,
              props: {
                label: "name",
                value: "id"
@@ -180,10 +207,10 @@
              disabled: true
            },
            {
              label: "项目分摊方式",
              prop: "allocationWay",
              label: "楼栋",
              prop: "buildingName",
              labelWidth: 140,
              value: '按建筑面积分摊',
              value: '',
              span: 12,
              row: true,
              disabled: true
@@ -258,6 +285,55 @@
              value: '0.00',
              disabled: true
            },
            {
              display: false,
              hide: true,
              parent: false,
              label: "投票结果",
              prop: "articleId",
              search: false,
              viewDisabled: false,
              type: 'select',
              dicUrl: `/ssoapi/blade-article/article/getArticleByDistrictId?type=4&eventType=1&districtId={{districtId}}`,
              // slot: true,
              formslot: true,
              cascader: ['vote'],
              props: {
                label: "title",
                value: "id"
              },
              defaultExpandedKeys: ["361102003"],
              span: 12,
              width: 260,
              rules: [{
                required: true,
                message: "请选择投票结果",
                trigger: "blur",
              }, ],
              change: (val) => {
                console.log("val===>", val)
                // console.log("form===>",this.form)
                if (val.value && !this.form.id) {
                  this.articleRange = val.articleRange;
                  // this.showDialog = true;
                  // this.getDetail(val.value, val.articleRange)
                }
              }
            },
            {
              display: false,
              span: 24,
              hide: true,
              prop: "vote",
              slot: true,
              label: "投票详情",
              labelWidth: 140
            },
            {
              label: "项目摘要",
              span: 24,
@@ -304,7 +380,7 @@
                name: "originalName",
                url: "link"
              },
              action: '/api/blade-resource/oss/endpoint/put-file-attach',
              action: '/ssoapi/blade-resource/oss/endpoint/put-file-attach',
              rules: [{
                required: true,
                message: "请上传施工方案",
@@ -312,9 +388,41 @@
              }, ],
            }
          ],
        }
        },
        topictData: [],
        topicTitle: "",
        articleRange: ""
      }
    },
    watch: {
      'form.districtId': {
        handler(newData) {
          const column = this.findObject(this.option.column, "articleId")
          if (newData && this.form.articleId) {
            column.display = true;
          } else {
            column.display = false
          }
        }
      },
      'form.articleId': {
        handler(newData) {
          this.getVoteDetail(this.form.articleId, this.articleRange)
          const column = this.findObject(this.option.column, "vote")
          if (newData) {
            column.display = true;
          } else {
            column.display = false
          }
        }
      },
    },
    created() {
      this.init()
    },
@@ -399,7 +507,25 @@
        this.$router.push({
          path: `/gzll/todo`
        })
      }
      },
      getVoteDetail(articleId, districtId) {
        let params = {
          level: 1,
          articleId: articleId,
          districtId: districtId
        }
        getLists(1, 10, params).then(res => {
          const data = res.data.data
          if (data.length) {
            this.topictData = data[0].children;
            this.topicTitle = data[0].discussContent;
          }
        })
      },
      openUserPopup(row) {
        this.$refs.DeitDiscussion.openUser(row, 1, [this.form.districtId])
      },
    }
  }
</script>
@@ -416,4 +542,8 @@
    left: 50%;
    transform: translateX(-50%);
  }
</style>
  .workOrderStyle {
    font-weight: normal;
  }
</style>