<!--
 * @Author: ysh
 * @Date: 2024-03-19 09:24:06
 * @LastEditors: Please set LastEditors
 * @LastEditTime: 2024-03-19 11:27:04
-->
<template>
  <div class="app-container">
    <h2 style="text-align: center;">项目登记</h2>
    <el-form :model="form" :rules="rules" label-width="100px" :disable="disable">
      <el-form-item label="承担部门：" prop="undertakingDept">
        <el-select v-model="form.deptId" multiple clearable  style="width:500px">
          <el-option v-for="item in deptList" :key="item.deptId" :label="item.deptName" :value="item.deptId"
            v-if="item.deptName != '四川中水成勘院测绘工程有限责任公司'">
          </el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="部门负责人" prop="deptLeader">
        <el-input v-model="form.deptLeader"></el-input>
      </el-form-item>
      <el-form-item label="项目负责人" prop="projectLeader">
        <el-tag effect="plain" type="warning" style="margin-right: 10px;">{{ form.projectLeader }}</el-tag>
        <el-button type="primary" plain size="mini">更换</el-button>
      </el-form-item>
      <el-form-item label="现场负责人">
        <el-input v-model="form.deptLeader"></el-input>
      </el-form-item>
      <el-form-item label="项目预算">
        <el-input v-model="form.deptLeader"></el-input>
      </el-form-item>
    </el-form>
    
  </div>
</template>

<script>
import { listDept } from '@/api/system/dept'
export default {
  props: {
    disable: {
      type: Boolean,
      require: true
    }
  },
  data() {
    return {
      form: {},
      rules: {},
      deptList: [],
      file:{
        fileList:[]
      }
    }
  },
  created() {
    this.getDeptList();
  },
  methods: {
    getDeptList() {
      listDept({
        deptName: undefined,
        status: undefined
      }).then(res => {
        this.deptList = res.data
      })
    },
  }
}
</script>

<style lang="scss" scoped></style>