zc.vue 1.7 KB
<template>
  <dialogBox title="转出" @submitForm="submitForm" saveButton="确认转出" width="45%" height='30%' @closeDialog="closeDialog"
    v-model="value">
    <div class="from-clues">
      <!-- 表单部分 -->
      <div class="from-clues-header">
        <el-form :model="queryForm" ref="queryForm" label-width="120px">
          <el-form-item label="下一环节名称:">
            {{this.tableData.taskName}}
          </el-form-item>
          <el-form-item label="下一环节办理人:">
            {{this.usernames}}
          </el-form-item>

        </el-form>
      </div>
    </div>
  </dialogBox>
</template>

<script>
import { completeTask, getNextLinkInfo } from "@/api/fqsq.js"
export default {
  components: {
  },
  props: {
    value: { type: Boolean, default: false },
    queryForm: { type: Object, default: false }
  },
  data () {
    return {
      tableData: {},
      usernames: '',
    }
  },
  methods: {
    tablelistFn () {
      getNextLinkInfo(this.queryForm).then(res => {
        if (res.code === 200) {
          this.tableData = res.result
          if (res.result.usernames) {
            this.usernames = String(res.result.usernames)
          }
        }
      })
    },
    submitForm () {
      completeTask(this.queryForm).then(res => {
        if (res.code === 200) {
          this.$message.success('转件成功')
          setTimeout(() => {
            window.opener = null;
            window.open("about:blank", "_self");
            window.close();
            this.$emit('input', false)
          }, 1000);
        }
      })
    },
    closeDialog () {
      this.$emit("input", false);
    },
  }
}
</script>
<style scoped lang="scss">
@import "~@/styles/mixin.scss";
</style>