Files
doneit-web/.angular/cache/14.2.12/babel-webpack/827fdba3f52cd78a23d46cba06ad2407.json
T

1 line
18 KiB
JSON
Raw Normal View History

2023-06-30 09:54:21 +01:00
{"ast":null,"code":"import _asyncToGenerator from \"C:/Users/eudes.inacio/GabineteDigital/gabinete-digital-fo/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js\";\nimport { __decorate } from \"tslib\";\nimport __NG_CLI_RESOURCE__0 from \"./chat-options-features.page.html?ngResource\";\nimport __NG_CLI_RESOURCE__1 from \"./chat-options-features.page.scss?ngResource\";\nimport { Component } from '@angular/core';\nimport { ModalController, NavParams, PopoverController } from '@ionic/angular';\nimport { NewEventPage } from 'src/app/pages/agenda/new-event/new-event.page';\nimport { SearchPage } from 'src/app/pages/search/search.page';\nimport { AlertService } from 'src/app/services/alert.service';\nimport { ChatService } from 'src/app/services/chat.service';\nimport { FileLoaderService } from 'src/app/services/file/file-loader.service';\nimport { FileToBase64Service } from 'src/app/services/file/file-to-base64.service';\nimport { environment } from 'src/environments/environment';\nimport { ThemeService } from 'src/app/services/theme.service';\nlet ChatOptionsFeaturesPage = class ChatOptionsFeaturesPage {\n constructor(popoverController, modalController, alertService, navParams, fileLoaderService, fileToBase64Service, chatService, ThemeService) {\n this.popoverController = popoverController;\n this.modalController = modalController;\n this.alertService = alertService;\n this.navParams = navParams;\n this.fileLoaderService = fileLoaderService;\n this.fileToBase64Service = fileToBase64Service;\n this.chatService = chatService;\n this.ThemeService = ThemeService;\n this.documents = [];\n this.attendees = [];\n this.members = this.navParams.get('members');\n this.attendees = this.members.map(val => {\n return {\n Name: val.name,\n EmailAddress: val.username + \"@\" + environment.domain,\n IsRequired: \"true\"\n };\n });\n }\n ngOnInit() {\n // this.chatService.refreshtoken();\n }\n notImplemented() {\n this.alertService.presentAlert('Funcionalidade em desenvolvimento');\n }\n close() {\n if (window.innerWidth < 701) {\n this.popoverController.dismiss();\n } else {\n this.modalController.dismiss();\n }\n }\n attachDocument() {}\n addDocument() {\n this.modalController.dismiss('add-document');\n }\n takePicture() {\n if (window.innerWidth < 701) {\n this.popoverController.dismiss('take-picture');\n } else {\n this.modalController.dismiss('take-picture');\n }\n }\n addPicture() {\n this.modalController.dismiss('add-picture');\n }\n addDocGestaoDocumental() {\n this.modalController.dismiss('documentoGestaoDocumental');\n }\n laodPicture() {\n var _this = this;\n const input = this.fileLoaderService.createInput({\n accept: ['image/apng', 'image/jpeg', 'image/png']\n });\n input.onchange = /*#__PURE__*/_asyncToGenerator(function* () {\n const file = _this.fileLoaderService.getFirstFile(input);\n let imageData;\n try {\n imageData = yield _this.fileToBase64Service.convert(file);\n } catch (error) {\n console.error('load picture chat', error);\n }\n _this.capturedImage = imageData;\n _this.capturedImageTitle = file.name;\n let body = {\n \"message\": {\n \"rid\": \"J5WDHyrYWHQrybbno\",\n \"msg\": \"this.message\",\n \"attachments\": [{\n \"title\": _this.capturedImageTitle,\n \"text\": \"description\",\n \"title_link_download\": false,\n \"image_url\": _this.capturedImage\n }]\n }\n };\n _this.chatService.sendMessage(body).subscribe(res => {\n // \n });\n //\n });\n }\n\n sendMessage() {\n let body = {\n \"message\": {\n \"rid\": \"J5WDHyrYWHQrybbno\",\n \"msg\": \"this.message\"\n /* \"attachments\": [{\r\n \"color\": \"#ff0000\",\r\n \"text\": \"Yay for gruggy!\",\r\n \"title\": \"Attachment Example\",\r\n \"title_link\": \"https: