set member to admin

This commit is contained in:
Peter Maquiran
2024-08-06 11:24:00 +01:00
parent 7e14f55383
commit 2f214e0025
3889 changed files with 581 additions and 1962886 deletions
+38 -39
View File
@@ -20,7 +20,7 @@ export class NewGroupPage implements OnInit{
showLoader: boolean;
displayDuration: any;
showDuration: boolean;
expirationDate:any;
expirationDate:Date = null;
_day:any;
selectedDuration = ['','',''];
countDownTime:any;
@@ -93,7 +93,7 @@ export class NewGroupPage implements OnInit{
this.expirationDate = new Date();
}
else {
this.expirationDate = '';
this.expirationDate = null;
}
}
@@ -123,9 +123,8 @@ export class NewGroupPage implements OnInit{
roomName: this.groupName,
createdBy: SessionStore.user.UserId,
roomType: 0,
expirationDate: null,
expirationDate: this.expirationDate?.toISOString(),
members: []
})
if(result.isOk()) {
@@ -147,44 +146,44 @@ export class NewGroupPage implements OnInit{
}
createGroupWithAttachments(res: any) {
this.ChatSystemService.getGroupRoom(res.result.rid).hasLoadHistory = true;
// this.ChatSystemService.getGroupRoom(res.result.rid).hasLoadHistory = true;
if(this.documents) {
this.documents.forEach(element => {
this.ChatSystemService.getGroupRoom(res.result.rid).send({
file: {
"name": element.Assunto,
"type": "application/webtrix",
"ApplicationId": element.ApplicationId,
"DocId": element.DocId,
"Assunto": element.Assunto,
},
temporaryData: {
data: {
selected: {
Id: element.DocId,
ApplicationType: element.ApplicationId
}
}
},
attachments: [{
"title": element.Assunto,
"description": element.Assunto,
"title_link_download": true,
"type": "webtrix",
"text": element.Assunto,
"thumb_url": "https://static.ichimura.ed.jp/uploads/2017/10/pdf-icon.png",
}],
})
});
}
// if(this.documents) {
// this.documents.forEach(element => {
// this.ChatSystemService.getGroupRoom(res.result.rid).send({
// file: {
// "name": element.Assunto,
// "type": "application/webtrix",
// "ApplicationId": element.ApplicationId,
// "DocId": element.DocId,
// "Assunto": element.Assunto,
// },
// temporaryData: {
// data: {
// selected: {
// Id: element.DocId,
// ApplicationType: element.ApplicationId
// }
// }
// },
// attachments: [{
// "title": element.Assunto,
// "description": element.Assunto,
// "title_link_download": true,
// "type": "webtrix",
// "text": element.Assunto,
// "thumb_url": "https://static.ichimura.ed.jp/uploads/2017/10/pdf-icon.png",
// }],
// })
// });
// }
this.ChatSystemService.getAllRooms();
// this.ChatSystemService.getAllRooms();
setTimeout(() => {
this.groupName = ""
}, 150);
// setTimeout(() => {
// this.groupName = ""
// }, 150);
}
@@ -211,7 +210,7 @@ export class NewGroupPage implements OnInit{
handler:(value:any)=>{
let now = new Date();
this.expirationDate = new Date(now.getFullYear(), now.getMonth(), now.getDate() + value.days.value, now.getHours() + value.hours.value, now.getMinutes() + value.minutes.value, now.getSeconds(), now.getMilliseconds());
this.expirationDate = new Date(now.getFullYear(), now.getMonth(), now.getDate() + value.days.value, now.getHours() + value.hours.value, now.getMinutes() + value.minutes.value, now.getSeconds(), now.getMilliseconds())
this.selectedDuration = [
value.days.value,