yz3456
2024-06-07 220aadf733212c6397cf93790f9a24c14f510d39
ruoyi-ui/src/views/meeting/index.vue
@@ -1,5 +1,5 @@
<template>
  <div class="app-container">
  <div class="app-container" style="opacity: 1;">
    <el-backtop :bottom="150" :right="30">
      <el-button type="primary" circle class="el-icon-top"></el-button>
@@ -10,12 +10,12 @@
      <span>会议申请</span>
      <div class="button-container"></div>
      <div style="display: flex; align-items: center;">
        <el-button @click="newRequest" size="mini" type="text" v-hasPermi="['person:information:memo']" style="margin-left: 200px">
        <!-- <el-button @click="newRequest" size="mini" type="text" v-hasPermi="['person:information:memo']" style="margin-left: 200px">
          <div class="form"><el-icon style="padding-right:100px;"></el-icon>
            <span class="text" style="width: 69px;height: 26px;font-size: 16px;
            font-family: Microsoft YaHei-Regular, Microsoft YaHei; color: #EBA4AA;">新申请</span>
          </div>
        </el-button>
        </el-button> -->
      </div>
    </h1>
@@ -44,7 +44,7 @@
                   height: 35px;
                   border-radius: 16px 16px 16px 16px;
                   opacity: 0.5;"
          value-format="yyyy-MM-dd"
          value-format="yyyy-MM-dd HH:mm:ss"
          type="daterange"
          range-separator="-"
          start-placeholder="开始日期"
@@ -99,16 +99,16 @@
    </el-form>
    <el-row :gutter="10" class="mb8">
      <!-- <el-col :span="1.5">
      <el-col :span="1.5">
        <el-button
          type="primary"
          plain
          icon="el-icon-plus"
          size="mini"
          @click="handleAdd"
          v-hasPermi="['system:role:add']"
          @click="newRequest"
          v-hasPermi="['person:information:memo']"
        >新增</el-button>
      </el-col> -->
      </el-col>
      <el-col :span="1.5">
        <el-button
@@ -177,52 +177,54 @@
      scope.row.place ? scope.row.place : '————' }}</template>
      </el-table-column>
      <el-table-column label="可容纳人数" prop="conPeople" sortable align="center">
      <el-table-column label="可容纳人数" prop="conPeople" sortable align="center" min-width="150">
        <template slot-scope="scope">{{
      scope.row.conPeople ? scope.row.conPeople : '————' }}</template>
      </el-table-column>
      <el-table-column label="参与人数" prop="partPeople" sortable align="center">
      <el-table-column label="参与人数" prop="partPeople" sortable align="center" min-width="120">
        <template slot-scope="scope">{{
      scope.row.partPeople ? scope.row.partPeople : '————' }}</template>
      </el-table-column>
      <el-table-column label="申请人" prop="applyPerson" sortable align="center">
      <el-table-column label="申请人" prop="applyPerson" sortable align="center" min-width="120">
        <template slot-scope="scope">{{
      scope.row.applyPerson ? scope.row.applyPerson : '————' }}</template>
      </el-table-column>
      <el-table-column label="申请部门或家庭" prop="applyApart" sortable align="center">
      <el-table-column label="申请部门或家庭" prop="applyApart" sortable align="center" min-width="150">
        <template slot-scope="scope">{{
      scope.row.applyApart ? scope.row.applyApart : '————' }}</template>
      </el-table-column>
      <el-table-column label="开始时间" prop="startTime" sortable align="center">
      <el-table-column label="开始时间" prop="startTime" sortable align="center"min-width="120">
        <template slot-scope="scope">{{ scope.row.startTime
      ? scope.row.startTime : '————' }}</template>
      </el-table-column>
      <el-table-column label="结束时间" prop="endTime" sortable align="center">
      <el-table-column label="结束时间" prop="endTime" sortable align="center" min-width="120">
        <template slot-scope="scope">{{ scope.row.endTime ?
      scope.row.endTime : '————' }}</template>
      </el-table-column>
      <el-table-column label="是否摆放水牌" prop="isPlacebrand" sortable align="center">
      <el-table-column label="是否摆放水牌" prop="isPlacebrand" sortable align="center" min-width="150">
        <template slot-scope="scope">{{scope.row.isPlacebrand===1? '是': '否'}}</template>
      </el-table-column>
      <el-table-column label="联系人" prop="connPerson" sortable align="center">
      <el-table-column label="联系人" prop="connPerson" sortable align="center" min-width="100">
        <template slot-scope="scope">{{ scope.row.connPerson ?
      scope.row.connPerson : '————' }}</template>
      </el-table-column>
      <el-table-column label="联系电话" prop="connPhone" sortable align="center">
      <el-table-column label="联系电话" prop="connPhone" sortable align="center" min-width="100">
        <template slot-scope="scope">{{ scope.row.connPhone
      ? scope.row.connPhone : '————' }}</template>
      </el-table-column>
      <el-table-column label="状态" prop="statu" sortable align="center">
        <template slot-scope="scope">{{scope.row.statu===1? '同意': '拒绝'}}</template>
        <!-- <template slot-scope="scope">{{scope.row.statu===1? '同意': '拒绝'}}</template> -->
        <template slot-scope="scope">{{scope.row.statu ===3 ? '待审批' : (scope.row.statu===1? '同意': '拒绝')}}</template>
        <!-- scope.row.statu ==='待审批' ? '待审批' : (scope.row.statu===1? '同意': '拒绝') -->
      </el-table-column>
      <el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
@@ -252,13 +254,13 @@
      <el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="100px">
        <el-form-item label="开始时间" prop="startTime">
          <el-date-picker v-model="formDat.startTime" type="date" placeholder="请选择日期"
                          :editable="false" :clearable="false" :style="{width: '100%'}"  value-format="yyyy-MM-dd"
          <el-date-picker v-model="formDat.startTime" type="datetime" placeholder="请选择日期"
                          :editable="false" :clearable="false" :style="{width: '100%'}"  value-format="yyyy-MM-dd HH:mm:ss"
          ></el-date-picker>
        </el-form-item>
        <el-form-item label="结束时间" prop="endTime">
          <el-date-picker v-model="formDat.endTime" type="date" placeholder="请选择日期"
                          :editable="false" :clearable="false" :style="{width: '100%'}"  value-format="yyyy-MM-dd"
          <el-date-picker v-model="formDat.endTime" type="datetime" placeholder="请选择日期"
                          :editable="false" :clearable="false" :style="{width: '100%'}"  value-format="yyyy-MM-dd HH:mm:ss"
          ></el-date-picker>
        </el-form-item>
@@ -271,12 +273,12 @@
          </el-input>
        </el-form-item>
        <el-form-item label="可容纳人数" prop="conPeople">
          <el-input v-model="formDat.conPeople" placeholder="请输入可容纳人数" clearable :style="{width: '100%'}">
          <el-input v-model="formDat.conPeople" type="number" placeholder="请输入可容纳人数" clearable :style="{width: '100%'}">
          </el-input>
        </el-form-item>
        <el-form-item label="参与人数" prop="partPeople">
          <el-input v-model="formDat.partPeople" placeholder="请输入参与人数" clearable :style="{width: '100%'}">
          <el-input v-model="formDat.partPeople" type="number" placeholder="请输入参与人数" clearable :style="{width: '100%'}">
          </el-input>
        </el-form-item>
        <el-form-item label="申请人" prop="applyPerson">
@@ -287,7 +289,7 @@
          <el-input v-model="formDat.applyApart" placeholder="请输入申请家庭或部门" clearable :style="{width: '100%'}">
          </el-input>
        </el-form-item>
        <el-form-item label="是否拜访水牌" prop="isPlacebrand">
        <el-form-item label="是否摆放水牌" prop="isPlacebrand">
          <el-select v-model="formDat.isPlacebrand" placeholder="请选择" clearable :style="{width: '100%'}">
            <el-option v-for="(item, index) in typeOptions" :key="index" :label="item.label" :value="item.value"
            ></el-option>
@@ -301,10 +303,11 @@
          <el-input v-model="formDat.connPhone" placeholder="请输入联系电话" clearable :style="{width: '100%'}"></el-input>
        </el-form-item>
        <el-form-item label="状态" prop="statu">
          <el-select v-model="formDat.statu" placeholder="请选择" clearable :style="{width: '100%'}">
          <!-- <el-select v-model="formDat.statu" placeholder="请选择" clearable :style="{width: '100%'}">
            <el-option v-for="(item, index) in typeOptions2" :key="index" :label="item.label" :value="item.value"
            ></el-option>
          </el-select>
          </el-select> -->
          <el-input placeholder="待审批" :disabled='true'></el-input>
        </el-form-item>
      </el-form>
@@ -373,6 +376,66 @@
      dateRange: [],
      // 表单校验
      rules: {
        startTime: [{
          required: true,
          message: '请输入开始时间',
          trigger: 'blur'
        }],
        endTime: [{
          required: true,
          message: '请输入结束时间',
          trigger: 'blur'
        }],
        title: [{
          required: true,
          message: '请输入标题',
          trigger: 'blur'
        }],
        place: [{
          required: true,
          message: '请输入地点',
          trigger: 'blur'
        }],
        conPeople: [{
          required: true,
          message: '请输入可容纳人数',
          trigger: 'blur'
        }],
        partPeople: [{
          required: true,
          message: '请输入参与人数',
          trigger: 'blur'
        }],
        applyPerson: [{
          required: true,
          message: '请输入申请人',
          trigger: 'blur'
        }],
        applyApart: [{
          required: true,
          message: '请输入申请家庭或部门',
          trigger: 'blur'
        }],
        isPlacebrand: [{
          required: true,
          message: '请选择是否摆放水牌',
          trigger: 'change'
        }],
        connPerson: [{
          required: true,
          message: '请输入联系人',
          trigger: 'blur'
        }],
        connPhone: [{
          required: true,
          message: '请输入联系电话',
          trigger: 'blur'
        }],
        // statu: [{
        //   // required: true,
        //   message: '请选择状态',
        //   trigger: 'blur'
        // }],
      },
        typeOptions: [
@@ -427,6 +490,28 @@
        this.queryParams.pageNum = 1;
        this.getList();
      },
      reset() {
        if (this.$refs.menu != undefined) {
          this.$refs.menu.setCheckedKeys([]);
        }
        this.menuExpand = false,
          this.menuNodeAll = false,
          this.deptExpand = true,
          this.deptNodeAll = false,
          this.form = {
            roleId: undefined,
            roleName: undefined,
            roleKey: undefined,
            roleSort: 0,
            status: "0",
            menuIds: [],
            deptIds: [],
            menuCheckStrictly: true,
            deptCheckStrictly: true,
            remark: undefined
          };
        this.resetForm("elForm");
      },
      /** 重置按钮操作 */
      resetQuery() {
        this.dateRange = [];
@@ -436,17 +521,20 @@
      newRequest(){
        this.reset();
        this.open = true;
        this.title = "新申请"
      },
      cancel() {
        this.open = false;
        // this.reset();
        this.reset();
      },
submitDataScope: function() {
      this.$refs["elForm"].validate(valid => {
        // alert(valid)
        if (valid) {
          // console.log(this.formDat,'formDat')
          this.formDat.statu = 3
          addMeeting(this.formDat).then(response => {
            this.$modal.msgSuccess("新增成功");
            this.open = false;