mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
Merge branch 'developer-prod' of bitbucket.org:equilibriumito/gabinete-digital-fo into chat/labels3
This commit is contained in:
@@ -275,9 +275,9 @@
|
||||
<!-- <ion-fab-button *ngIf="p.userPermission([p.permissionList.Agenda.access])" title="Nova Reunião" (click)="bookMeeting()" color="light">
|
||||
<ion-icon name="calendar"></ion-icon>
|
||||
</ion-fab-button> -->
|
||||
<!-- <ion-fab-button title="Adicionar Documento" (click)="addFile()" color="light">
|
||||
<ion-fab-button title="Adicionar Documento" (click)="addFile()" color="light">
|
||||
<ion-icon name="document"></ion-icon>
|
||||
</ion-fab-button> -->
|
||||
</ion-fab-button>
|
||||
<ion-fab-button title="Anexar Fotografia" (click)="addImage()" color="light">
|
||||
<ion-icon name="image"></ion-icon>
|
||||
</ion-fab-button>
|
||||
|
||||
@@ -907,13 +907,26 @@ export class GroupMessagesPage implements OnInit, OnChanges, AfterViewInit, OnDe
|
||||
const encodedData = btoa(JSON.stringify(await this.getBase64(file).catch ((error) => {
|
||||
console.error(error);
|
||||
})));
|
||||
const blob = this.fileService.base64toBlob(encodedData, file.type)
|
||||
|
||||
let blob;
|
||||
let formData
|
||||
let fileBase64
|
||||
if (this.platform.is("tablet")) {
|
||||
|
||||
const fileBase64 = await this._getBase64(file)
|
||||
blob = this.fileService.base64toBlob(encodedData, file.type)
|
||||
console.log('BLOB BLOB', blob)
|
||||
|
||||
const formData = new FormData();
|
||||
formData.append('blobFile', blob);
|
||||
formData = new FormData();
|
||||
formData.append('blobFile', blob);
|
||||
/* console.log('add file', fileBase64) */
|
||||
|
||||
} else {
|
||||
blob = this.fileService.base64toBlob(encodedData, file.type)
|
||||
|
||||
fileBase64 = await this._getBase64(file)
|
||||
|
||||
formData = new FormData();
|
||||
formData.append('blobFile', blob);
|
||||
}
|
||||
|
||||
this.ChatSystemService.getGroupRoom(roomId).send({
|
||||
file: {
|
||||
|
||||
Reference in New Issue
Block a user