yz3456
2024-07-29 fae5df1d3f1ae875ac546cacfb4744b2e8230ca2
ruoyi-ui/src/views/meeting/webcast.vue
@@ -10,12 +10,12 @@
      <span>直播</span>
      <div class="button-container"></div>
      <div style="display: flex; align-items: center;">
        <el-button size="mini" type="text" v-hasPermi="['person:information:memo']" style="margin-left: 200px">
<!--        <el-button size="mini" type="text" v-hasPermi="['person:information:memo']" style="margin-left: 200px">
          <div class="form" @click="newRequest"><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>
@@ -41,9 +41,24 @@
      </el-form-item>
    </el-form>
    <el-row :gutter="10" class="mb8">
      <el-col :span="1.5">
        <el-button
          type="primary"
          plain
          icon="el-icon-plus"
          size="mini"
          @click="newRequest"
          v-hasPermi="['person:information:memo']"
        >新增</el-button>
      </el-col>
      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
    </el-row>
    <el-row :gutter="0" v-loading="loading">
      <el-col :span="4" v-for="(item,i) in webcastList">
        <div class="module" @click="toLook">
        <div class="module" @click="toLook(item.id)">
          <div class="video">
            66666666
          </div>
@@ -76,11 +91,11 @@
            value-format="yyyy-MM-dd HH:mm:ss">
          </el-date-picker>
        </el-form-item>
        <el-form-item label="结束时间" prop="endTime">
<!--        <el-form-item label="结束时间" prop="endTime">
          <el-date-picker v-model="formDat.endTime" type="datetime" placeholder="选择开始时间"
            value-format="yyyy-MM-dd HH:mm:ss">
          </el-date-picker>
        </el-form-item>
        </el-form-item> -->
        <!--        <el-form-item label="开始时间" prop="startTime">
          <el-date-picker v-model="formDat.startTime" type="datetime" placeholder="选择开始时间"
@@ -92,6 +107,16 @@
          <el-input v-model="formDat.meetingTitle" placeholder="请输入会议标题" clearable :style="{width: '100%'}">
          </el-input>
        </el-form-item> -->
        <el-form-item label="房间号" prop="roomId">
          <el-input v-model="formDat.roomId" type="number" :min="1" placeholder="请输入房间号" clearable :style="{width: '100%'}">
          </el-input>
        </el-form-item>
        <el-form-item label="最多人数" prop="maxPerson">
          <el-input v-model="formDat.maxPerson" placeholder="请输入最多人数" clearable :style="{width: '100%'}">
          </el-input>
        </el-form-item>
        <el-form-item label="会议标题" prop="title">
          <el-input v-model="formDat.title" placeholder="请输入会议标题" clearable :style="{width: '100%'}">
@@ -152,22 +177,12 @@
  } from "@/api/meeting/index";
  export default {
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.getList();
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.dateRange = [];
      this.resetForm("queryForm");
      this.handleQuery();
    },
    created() {
      this.getList();
    },
    data() {
      return {
        showSearch: true,
        pageSizes: [12, 24, 36],
        webcastList:[],
        // 总条数
@@ -194,12 +209,25 @@
          applyPerson: undefined,
          contactPerson: undefined,
          contactPhone: undefined,
          createTime: undefined
          createTime: undefined,
          roomId:undefined,
          maxPerson:undefined
        },
      }
    },
    methods: {
      /** 搜索按钮操作 */
      handleQuery() {
        this.queryParams.pageNum = 1;
        this.getList();
      },
      /** 重置按钮操作 */
      resetQuery() {
        this.dateRange = [];
        this.resetForm("queryForm");
        this.handleQuery();
      },
      newRequest() {
        // this.reset();
        this.open = true;
@@ -211,7 +239,7 @@
      },
      submitDataScope: function() {
        this.$refs["elForm"].validate(valid => {
          if (valid) {
          if (valid && this.formDat.roomId > 0) {
            addWebcast(this.formDat).then(response => {
              this.$modal.msgSuccess("新增成功");
              this.open = false;
@@ -228,7 +256,14 @@
              // }
              this.getList();
            });
          }else{
            this.$message.error("新增失败,房间号不能是负数");
            this.open = false;
            Object.keys(this.formDat).forEach(key => {
              this.formDat[key] = '';
            });
          }
        });
      },
@@ -247,8 +282,8 @@
        );
      },
      toLook() {
        this.$router.push('/meeting/webcast/webcastInfo/')
      toLook(id) {
        this.$router.push('/meeting/webcast/Home/' + id)
      }
    }