|  | @@ -158,6 +158,26 @@
 | 
	
		
			
				|  |  |            </el-form-item>
 | 
	
		
			
				|  |  |          </el-row>
 | 
	
		
			
				|  |  |          <el-alert
 | 
	
		
			
				|  |  | +          title="直播设备配置"
 | 
	
		
			
				|  |  | +          type="info"
 | 
	
		
			
				|  |  | +          :closable="false"
 | 
	
		
			
				|  |  | +          style="margin-bottom: 20px"
 | 
	
		
			
				|  |  | +        ></el-alert>
 | 
	
		
			
				|  |  | +        <el-row class="row">
 | 
	
		
			
				|  |  | +          <el-form-item
 | 
	
		
			
				|  |  | +            class="mline"
 | 
	
		
			
				|  |  | +            label="直播设备"
 | 
	
		
			
				|  |  | +            prop="os"
 | 
	
		
			
				|  |  | +            label-width="120px"
 | 
	
		
			
				|  |  | +            :rules="[{ required: true, message: '请选择推广类型' }]"
 | 
	
		
			
				|  |  | +          >
 | 
	
		
			
				|  |  | +            <el-radio-group v-model="form.os" >
 | 
	
		
			
				|  |  | +              <el-radio label="pc">电脑</el-radio>
 | 
	
		
			
				|  |  | +              <el-radio label="mobile">手机</el-radio>
 | 
	
		
			
				|  |  | +            </el-radio-group>
 | 
	
		
			
				|  |  | +          </el-form-item>
 | 
	
		
			
				|  |  | +        </el-row>
 | 
	
		
			
				|  |  | +        <el-alert
 | 
	
		
			
				|  |  |            title="观看权限配置"
 | 
	
		
			
				|  |  |            type="info"
 | 
	
		
			
				|  |  |            :closable="false"
 | 
	
	
		
			
				|  | @@ -313,7 +333,7 @@
 | 
	
		
			
				|  |  |              </el-radio-group>
 | 
	
		
			
				|  |  |            </el-form-item>
 | 
	
		
			
				|  |  |          </el-row>
 | 
	
		
			
				|  |  | -        <!-- <el-row class="row">
 | 
	
		
			
				|  |  | +        <el-row class="row">
 | 
	
		
			
				|  |  |            <el-form-item
 | 
	
		
			
				|  |  |              prop="roomConfig.whether_view_shop_cart"
 | 
	
		
			
				|  |  |              label-width="120px"
 | 
	
	
		
			
				|  | @@ -326,7 +346,7 @@
 | 
	
		
			
				|  |  |                <el-radio :label="1">否</el-radio>
 | 
	
		
			
				|  |  |              </el-radio-group>
 | 
	
		
			
				|  |  |            </el-form-item>
 | 
	
		
			
				|  |  | -        </el-row> -->
 | 
	
		
			
				|  |  | +        </el-row>
 | 
	
		
			
				|  |  |        </el-form>
 | 
	
		
			
				|  |  |        <el-row class="row">
 | 
	
		
			
				|  |  |          <el-button type="primary" @click="preLook">预览</el-button>
 | 
	
	
		
			
				|  | @@ -349,7 +369,7 @@
 | 
	
		
			
				|  |  |  import preview from "./modals/preview.vue";
 | 
	
		
			
				|  |  |  import axios from "axios";
 | 
	
		
			
				|  |  |  import { getToken, getTenantId } from "@/utils/auth";
 | 
	
		
			
				|  |  | -import { createLiveBroadcast, resetLiveBroadcastRoomList } from "./api";
 | 
	
		
			
				|  |  | +import { createLiveBroadcast, resetLiveBroadcastRoomList ,getRoomInfo} from "./api";
 | 
	
		
			
				|  |  |  import { queryByOrganId } from "@/api/systemManage";
 | 
	
		
			
				|  |  |  import { getTeamList } from "@/api/teamServer";
 | 
	
		
			
				|  |  |  export default {
 | 
	
	
		
			
				|  | @@ -368,6 +388,7 @@ export default {
 | 
	
		
			
				|  |  |          liveRemark: "",
 | 
	
		
			
				|  |  |          preTemplate: null,
 | 
	
		
			
				|  |  |          popularizeType: "ALL",
 | 
	
		
			
				|  |  | +        os:'pc',
 | 
	
		
			
				|  |  |          roomConfig: {
 | 
	
		
			
				|  |  |            whether_like: 0,
 | 
	
		
			
				|  |  |            whether_chat: 0,
 | 
	
	
		
			
				|  | @@ -388,47 +409,93 @@ export default {
 | 
	
		
			
				|  |  |    mounted() {
 | 
	
		
			
				|  |  |      this.$store.dispatch("setBranchs");
 | 
	
		
			
				|  |  |      if (this.$route.query.id) {
 | 
	
		
			
				|  |  | -      this.name = "修改直播间";
 | 
	
		
			
				|  |  | +      // this.name = "修改直播间";
 | 
	
		
			
				|  |  | +      this.getDetail()
 | 
	
		
			
				|  |  |        // console.log()
 | 
	
		
			
				|  |  | -      this.form = {
 | 
	
		
			
				|  |  | -        ...this.$route.query,
 | 
	
		
			
				|  |  | -        organIds: [],
 | 
	
		
			
				|  |  | -        schoolIds: [],
 | 
	
		
			
				|  |  | -        teamIds: [],
 | 
	
		
			
				|  |  | -      };
 | 
	
		
			
				|  |  | -      this.form.roomConfig = JSON.parse(this.$route.query.roomConfig);
 | 
	
		
			
				|  |  | +      // this.form = {
 | 
	
		
			
				|  |  | +      //   ...this.$route.query,
 | 
	
		
			
				|  |  | +      //   organIds: [],
 | 
	
		
			
				|  |  | +      //   schoolIds: [],
 | 
	
		
			
				|  |  | +      //   teamIds: [],
 | 
	
		
			
				|  |  | +      // };
 | 
	
		
			
				|  |  | +      // this.form.roomConfig = JSON.parse(this.$route.query.roomConfig);
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -      if (this.$route.query.popularizeOrgIds) {
 | 
	
		
			
				|  |  | -        this.form.organIds = this.$route.query.popularizeOrgIds
 | 
	
		
			
				|  |  | -          .split(",")
 | 
	
		
			
				|  |  | -          .map((item) => {
 | 
	
		
			
				|  |  | -            return item * 1;
 | 
	
		
			
				|  |  | -          });
 | 
	
		
			
				|  |  | -      }
 | 
	
		
			
				|  |  | -      this.changeSection(this.form.organIds);
 | 
	
		
			
				|  |  | -      if (this.$route.query.popularizeSchoolIds) {
 | 
	
		
			
				|  |  | -        this.form.schoolIds = this.$route.query.popularizeSchoolIds
 | 
	
		
			
				|  |  | -          .split(",")
 | 
	
		
			
				|  |  | -          .map((item) => {
 | 
	
		
			
				|  |  | -            return item * 1;
 | 
	
		
			
				|  |  | -          });
 | 
	
		
			
				|  |  | -      }
 | 
	
		
			
				|  |  | +      // if (this.$route.query.popularizeOrgIds) {
 | 
	
		
			
				|  |  | +      //   this.form.organIds = this.$route.query.popularizeOrgIds
 | 
	
		
			
				|  |  | +      //     .split(",")
 | 
	
		
			
				|  |  | +      //     .map((item) => {
 | 
	
		
			
				|  |  | +      //       return item * 1;
 | 
	
		
			
				|  |  | +      //     });
 | 
	
		
			
				|  |  | +      // }
 | 
	
		
			
				|  |  | +      // this.changeSection(this.form.organIds);
 | 
	
		
			
				|  |  | +      // if (this.$route.query.popularizeSchoolIds) {
 | 
	
		
			
				|  |  | +      //   this.form.schoolIds = this.$route.query.popularizeSchoolIds
 | 
	
		
			
				|  |  | +      //     .split(",")
 | 
	
		
			
				|  |  | +      //     .map((item) => {
 | 
	
		
			
				|  |  | +      //       return item * 1;
 | 
	
		
			
				|  |  | +      //     });
 | 
	
		
			
				|  |  | +      // }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -      if (this.$route.query.popularizeTeamIds) {
 | 
	
		
			
				|  |  | -        let arr = this.$route.query.popularizeTeamIds.split(",");
 | 
	
		
			
				|  |  | -        this.$set(this.form, "teamIds", arr);
 | 
	
		
			
				|  |  | -        console.log(this.form.teamIds);
 | 
	
		
			
				|  |  | -      }
 | 
	
		
			
				|  |  | +      // if (this.$route.query.popularizeTeamIds) {
 | 
	
		
			
				|  |  | +      //   let arr = this.$route.query.popularizeTeamIds.split(",");
 | 
	
		
			
				|  |  | +      //   this.$set(this.form, "teamIds", arr);
 | 
	
		
			
				|  |  | +      //   console.log(this.form.teamIds);
 | 
	
		
			
				|  |  | +      // }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -      // this.form.popularizeType = "SCHOOL";
 | 
	
		
			
				|  |  | +      // // this.form.popularizeType = "SCHOOL";
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -      this.remoteMethod(this.$route.query.speakerName);
 | 
	
		
			
				|  |  | +      // this.remoteMethod(this.$route.query.speakerName);
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -      this.checkList.push(this.form.preTemplate * 1);
 | 
	
		
			
				|  |  | -      this.isinit = false;
 | 
	
		
			
				|  |  | +      // this.checkList.push(this.form.preTemplate * 1);
 | 
	
		
			
				|  |  | +      // this.isinit = false;
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |    },
 | 
	
		
			
				|  |  |    methods: {
 | 
	
		
			
				|  |  | +        async getDetail() {
 | 
	
		
			
				|  |  | +      try {
 | 
	
		
			
				|  |  | +        const res = await getRoomInfo({ roomUid: this.$route.query.roomUid });
 | 
	
		
			
				|  |  | +        this.name = "修改直播间";
 | 
	
		
			
				|  |  | +        // console.log()
 | 
	
		
			
				|  |  | +        this.form = {
 | 
	
		
			
				|  |  | +          ...res.data,
 | 
	
		
			
				|  |  | +          organIds: [],
 | 
	
		
			
				|  |  | +          schoolIds: [],
 | 
	
		
			
				|  |  | +          teamIds: [],
 | 
	
		
			
				|  |  | +          catIds: [],
 | 
	
		
			
				|  |  | +          studentIds: [],
 | 
	
		
			
				|  |  | +        };
 | 
	
		
			
				|  |  | +        this.form.roomConfig = JSON.parse(res.data.roomConfig);
 | 
	
		
			
				|  |  | +        if (res.data.popularizeOrgIds) {
 | 
	
		
			
				|  |  | +          this.form.organIds = res.data.popularizeOrgIds
 | 
	
		
			
				|  |  | +            .split(",")
 | 
	
		
			
				|  |  | +            .map((item) => {
 | 
	
		
			
				|  |  | +              return item * 1;
 | 
	
		
			
				|  |  | +            });
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +        if (res.data.popularizeSchoolIds) {
 | 
	
		
			
				|  |  | +          this.form.schoolIds = res.data.popularizeSchoolIds
 | 
	
		
			
				|  |  | +            .split(",")
 | 
	
		
			
				|  |  | +            .map((item) => {
 | 
	
		
			
				|  |  | +              return item * 1;
 | 
	
		
			
				|  |  | +            });
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +        if (res.data.popularizeTeamIds) {
 | 
	
		
			
				|  |  | +          let arr = res.data.popularizeTeamIds.split(",");
 | 
	
		
			
				|  |  | +          this.$set(this.form, "teamIds", arr);
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +        // this.form.popularizeType = "SCHOOL";
 | 
	
		
			
				|  |  | +        this.changeSection(this.form.organIds);
 | 
	
		
			
				|  |  | +        this.remoteMethod(res.data.speakerName);
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +        this.checkList.push(this.form.preTemplate * 1);
 | 
	
		
			
				|  |  | +        this.isinit = false;
 | 
	
		
			
				|  |  | +      } catch (e) {
 | 
	
		
			
				|  |  | +        console.log(e);
 | 
	
		
			
				|  |  | +      }
 | 
	
		
			
				|  |  | +    },
 | 
	
		
			
				|  |  |      onCancel() {
 | 
	
		
			
				|  |  |        this.$store.dispatch("delVisitedViews", this.$route);
 | 
	
		
			
				|  |  |        this.$router.push("/liveClassManager");
 | 
	
	
		
			
				|  | @@ -524,7 +591,7 @@ export default {
 | 
	
		
			
				|  |  |        this.form.popularizeOrgIds = this.form.organIds.join(",");
 | 
	
		
			
				|  |  |        this.form.popularizeSchoolIds = this.form.schoolIds.join(",");
 | 
	
		
			
				|  |  |        this.form.popularizeTeamIds = this.form.teamIds.join(",");
 | 
	
		
			
				|  |  | -      this.$refs.form.validate(async(flag) => {
 | 
	
		
			
				|  |  | +      this.$refs.form.validate(async (flag) => {
 | 
	
		
			
				|  |  |          if (!flag) return;
 | 
	
		
			
				|  |  |          if (this.$route.query.id) {
 | 
	
		
			
				|  |  |            // 修改
 |