|
@@ -11,6 +11,7 @@ import * as Parse from 'parse';
|
|
|
import { AuthService } from '../../../services/auth.service';
|
|
|
import { FormsModule } from '@angular/forms';
|
|
|
import { ionicStandaloneModules } from '../../ionic-standalone.modules';
|
|
|
+import { ConnectTaskService } from '../../../services/connectTask.service';
|
|
|
|
|
|
@Component({
|
|
|
selector: 'app-room-manage',
|
|
@@ -36,6 +37,7 @@ export class RoomManageComponent implements OnInit {
|
|
|
private loadingCtrl: LoadingController,
|
|
|
private liveService: LiveService,
|
|
|
private alertController: AlertController,
|
|
|
+ private connectTask: ConnectTaskService,
|
|
|
private authServ: AuthService,
|
|
|
) {}
|
|
|
|
|
@@ -49,9 +51,10 @@ export class RoomManageComponent implements OnInit {
|
|
|
let query = new Parse.Query('Profile');
|
|
|
query.equalTo('user', user?.id);
|
|
|
query.notEqualTo('isDeleted', true);
|
|
|
- query.select('isCheck', 'isCross');
|
|
|
+ // query.select('isCheck', 'isCross');
|
|
|
let r = await query.first();
|
|
|
this.profile = r;
|
|
|
+ localStorage.setItem('profile', JSON.stringify(this.profile?.toJSON()));
|
|
|
}
|
|
|
/* 直播间 */
|
|
|
async getRoom() {
|
|
@@ -114,7 +117,8 @@ export class RoomManageComponent implements OnInit {
|
|
|
this.room && this.liveService.getToken(this.room)
|
|
|
this.loading.dismiss();
|
|
|
this.getRoom();
|
|
|
- this.presentAlert('修改成功');
|
|
|
+ await this.connectTask.anchorOnline();//房间修改或创建后重新初始化连接
|
|
|
+ this.presentAlert('保存成功');
|
|
|
}
|
|
|
async presentAlert(msg: string) {
|
|
|
const alert = await this.alertController.create({
|