mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
Merge branch 'feature/viewer-attachment' of https://bitbucket.org/equilibriumito/gabinete-digital-fo into feature/viewer-attachment
This commit is contained in:
@@ -2,6 +2,8 @@
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>aps-environment</key>
|
||||
<string>development</string>
|
||||
<key>com.apple.security.application-groups</key>
|
||||
<array>
|
||||
<string>group.gabinete</string>
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
import UIKit
|
||||
import Capacitor
|
||||
import SendIntent
|
||||
import FirebaseCore
|
||||
import Firebase
|
||||
|
||||
@UIApplicationMain
|
||||
class AppDelegate: UIResponder, UIApplicationDelegate {
|
||||
@@ -10,8 +12,12 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
|
||||
|
||||
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
|
||||
// Override point for customization after application launch.
|
||||
FirebaseApp.configure()
|
||||
|
||||
return true
|
||||
}
|
||||
|
||||
|
||||
|
||||
func applicationWillResignActive(_ application: UIApplication) {
|
||||
// Sent when the application is about to move from active to inactive state.
|
||||
@@ -42,6 +48,15 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
|
||||
// Called when the application is about to terminate.
|
||||
// Save data if appropriate. See also applicationDidEnterBackground:.
|
||||
}
|
||||
func application(_ application: UIApplication, didRegisterForRemoteNotificationsWithDeviceToken deviceToken: Data) {
|
||||
NotificationCenter.default.post(name: .capacitorDidRegisterForRemoteNotifications, object: deviceToken)
|
||||
|
||||
Messaging.messaging().apnsToken = deviceToken
|
||||
}
|
||||
|
||||
func application(_ application: UIApplication, didFailToRegisterForRemoteNotificationsWithError error: Error) {
|
||||
NotificationCenter.default.post(name: .capacitorDidFailToRegisterForRemoteNotifications, object: error)
|
||||
}
|
||||
|
||||
func application(_ app: UIApplication, open url: URL, options: [UIApplication.OpenURLOptionsKey : Any] = [:]) -> Bool {
|
||||
var success = true
|
||||
|
||||
+88
-161
@@ -2,166 +2,93 @@
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>en</string>
|
||||
<key>CFBundleDisplayName</key>
|
||||
<string>Gabinete Digital</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>$(PRODUCT_NAME)</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>$(MARKETING_VERSION)</string>
|
||||
<key>CFBundleURLTypes</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Editor</string>
|
||||
<key>CFBundleURLName</key>
|
||||
<string>com.gpr.gabinetedigital.teste</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>gabinetedigital</string>
|
||||
</array>
|
||||
</dict>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>$(CURRENT_PROJECT_VERSION)</string>
|
||||
<key>LSApplicationCategoryType</key>
|
||||
<string></string>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
<key>NSCameraUsageDescription</key>
|
||||
<string>This app requires access to the camera.</string>
|
||||
<key>NSMicrophoneUsageDescription</key>
|
||||
<string>This app does not require access to the microphone.</string>
|
||||
<key>NSPhotoLibraryAddUsageDescription</key>
|
||||
<string>This app requires access to the photo library.</string>
|
||||
<key>NSPhotoLibraryUsageDescription</key>
|
||||
<string>This app requires access to the photo library.</string>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>LaunchScreen</string>
|
||||
<key>UIMainStoryboardFile</key>
|
||||
<string>Main</string>
|
||||
<key>UIRequiredDeviceCapabilities</key>
|
||||
<array>
|
||||
<string>armv7</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations~ipad</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UIViewControllerBasedStatusBarAppearance</key>
|
||||
<true/>
|
||||
<key>NSAppTransportSecurity</key>
|
||||
<dict>
|
||||
<key>NSAllowsArbitraryLoads</key>
|
||||
<true/>
|
||||
</dict>
|
||||
|
||||
<!-- Firebase Push Notification Configurations -->
|
||||
<key>FirebaseAppDelegateProxyEnabled</key>
|
||||
<true/>
|
||||
<key>UNUserNotificationCenterDelegate</key>
|
||||
<string>YourApp.NotificationDelegate</string>
|
||||
<key>UIBackgroundModes</key>
|
||||
<array>
|
||||
<string>remote-notification</string>
|
||||
</array>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>en</string>
|
||||
<key>CFBundleDisplayName</key>
|
||||
<string>Gabinete Digital</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>$(PRODUCT_NAME)</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>$(MARKETING_VERSION)</string>
|
||||
<key>CFBundleURLTypes</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Editor</string>
|
||||
<key>CFBundleURLName</key>
|
||||
<string>com.gpr.gabinetedigital.teste</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>gabinetedigital</string>
|
||||
</array>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Editor</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>com.googleusercontent.apps.800733765231-5da370m1mntjk7cg8cc2d331sp8cj91d</string>
|
||||
</array>
|
||||
</dict>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>$(CURRENT_PROJECT_VERSION)</string>
|
||||
<key>FirebaseAppDelegateProxyEnabled</key>
|
||||
<false/>
|
||||
<key>LSApplicationCategoryType</key>
|
||||
<string></string>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
<key>NSAppTransportSecurity</key>
|
||||
<dict>
|
||||
<key>NSAllowsArbitraryLoads</key>
|
||||
<true/>
|
||||
</dict>
|
||||
<key>NSCameraUsageDescription</key>
|
||||
<string>This app requires access to the camera.</string>
|
||||
<key>NSMicrophoneUsageDescription</key>
|
||||
<string>This app does not require access to the microphone.</string>
|
||||
<key>NSPhotoLibraryAddUsageDescription</key>
|
||||
<string>This app requires access to the photo library.</string>
|
||||
<key>NSPhotoLibraryUsageDescription</key>
|
||||
<string>This app requires access to the photo library.</string>
|
||||
<key>UIBackgroundModes</key>
|
||||
<array>
|
||||
<string>processing</string>
|
||||
<string>remote-notification</string>
|
||||
</array>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>LaunchScreen</string>
|
||||
<key>UIMainStoryboardFile</key>
|
||||
<string>Main</string>
|
||||
<key>UIRequiredDeviceCapabilities</key>
|
||||
<array>
|
||||
<string>armv7</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations~ipad</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UIViewControllerBasedStatusBarAppearance</key>
|
||||
<true/>
|
||||
<key>UNUserNotificationCenterDelegate</key>
|
||||
<string>YourApp.NotificationDelegate</string>
|
||||
</dict>
|
||||
</plist>
|
||||
|
||||
|
||||
<!-- <?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>en</string>
|
||||
<key>CFBundleDisplayName</key>
|
||||
<string>Gabinete Digital</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>$(PRODUCT_NAME)</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>$(MARKETING_VERSION)</string>
|
||||
<key>CFBundleURLTypes</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Editor</string>
|
||||
<key>CFBundleURLName</key>
|
||||
<string>com.gpr.gabinetedigital.teste</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>gabinetedigital</string>
|
||||
</array>
|
||||
</dict>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>$(CURRENT_PROJECT_VERSION)</string>
|
||||
<key>LSApplicationCategoryType</key>
|
||||
<string></string>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
<key>NSCameraUsageDescription</key>
|
||||
<string>This app requires access to the camera.</string>
|
||||
<key>NSMicrophoneUsageDescription</key>
|
||||
<string>This app does not require access to the microphone.</string>
|
||||
<key>NSPhotoLibraryAddUsageDescription</key>
|
||||
<string>This app requires access to the photo library.</string>
|
||||
<key>NSPhotoLibraryUsageDescription</key>
|
||||
<string>This app requires access to the photo library.</string>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>LaunchScreen</string>
|
||||
<key>UIMainStoryboardFile</key>
|
||||
<string>Main</string>
|
||||
<key>UIRequiredDeviceCapabilities</key>
|
||||
<array>
|
||||
<string>armv7</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations~ipad</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UIViewControllerBasedStatusBarAppearance</key>
|
||||
<true/>
|
||||
<key>NSAppTransportSecurity</key>
|
||||
<dict>
|
||||
<key>NSAllowsArbitraryLoads</key>
|
||||
<true/>
|
||||
</dict>
|
||||
</dict>
|
||||
</plist>
|
||||
-->
|
||||
@@ -68,6 +68,7 @@ iframe {
|
||||
|
||||
.container-img {
|
||||
background-image: url(/assets/gif/theme/gov/Blocks-loader.svg);
|
||||
background-size: 100px;
|
||||
background-repeat: no-repeat;
|
||||
background-position-x: center;
|
||||
background-position-y: center;
|
||||
|
||||
@@ -119,16 +119,16 @@ export class SearchPage implements OnInit {
|
||||
|
||||
if (this.currentPath.includes('/home/agenda')) {
|
||||
this.type = "Agenda"
|
||||
|
||||
|
||||
} else if (this.currentPath.includes('/home/gabinete-digital')) {
|
||||
this.type = "AccoesPresidenciais & ArquivoDespachoElect"
|
||||
|
||||
|
||||
|
||||
} else if (this.currentPath.includes('/home/publications')) {
|
||||
this.type = "AccoesPresidenciais"
|
||||
|
||||
|
||||
} else {
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -381,7 +381,7 @@ export class SearchPage implements OnInit {
|
||||
this.showLoader = true;
|
||||
this.search.basicSearch(this.searchSubject, searchDocumentDate,searchDocumentDateEnd, this.searchSenderId
|
||||
, this.searchOrganicEntiryCode, this.searchDocTypeId, '0').subscribe(res => {
|
||||
|
||||
|
||||
if (!res.Categories.length) {
|
||||
this.searchResult = "Não encontramos o que procura";
|
||||
}
|
||||
@@ -429,7 +429,7 @@ export class SearchPage implements OnInit {
|
||||
console.log('enter text');
|
||||
|
||||
} else {
|
||||
|
||||
|
||||
this.search.searchForDoc(this.searchSubject, searchDocumentDate, this.searchSenderId
|
||||
, this.searchOrganicEntiryCode, this.searchDocTypeId, '8').subscribe(res => {
|
||||
this.showLoader = true;
|
||||
|
||||
@@ -123,12 +123,12 @@
|
||||
<div [ngClass]="{'header-fix': !dropButton}" style="border-radius: 50px;position: relative;top: 3px;left: 25px;">
|
||||
|
||||
<ion-row class="timeline-date align-center pr-10 visionMobile-flex" >
|
||||
<button class="no-color" [ngClass]="{'d-item': !dropButton}" (click)="changeDropButton()" >
|
||||
<button style="z-index: 99;" class="no-color" [ngClass]="{'d-item': !dropButton}" (click)="changeDropButton()" >
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="collaps font-25" src="assets/images/icons-collaps-up.svg" ></ion-icon>
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="collaps font-25" src="assets/images/theme/gov/icons-collaps-up.svg" ></ion-icon>
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'doneIt' " class="collaps font-25" src="assets/images/theme/{{ThemeService.currentTheme}}/icons-collaps-up.svg"></ion-icon>
|
||||
</button>
|
||||
<button class="no-color visionMobile-flex" *ngIf="!dropButton" (click)="changeDropButton()">
|
||||
<button style="z-index: 99;" class="no-color visionMobile-flex" *ngIf="!dropButton" (click)="changeDropButton()">
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'default' " class="collaps font-25" src="assets/images/icons-collaps-down.svg" ></ion-icon>
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'gov' " class="collaps font-25" src="assets/images/theme/gov/icons-collaps-down.svg" ></ion-icon>
|
||||
<ion-icon *ngIf="ThemeService.currentTheme == 'doneIt' " class="collaps font-25" src="assets/images/theme/{{ThemeService.currentTheme}}/icons-collaps-down.svg" ></ion-icon>
|
||||
|
||||
@@ -115,7 +115,7 @@ export class OptsExpedientePage implements OnInit {
|
||||
component: SearchPage,
|
||||
cssClass: 'modal-width-100-width-background modal',
|
||||
componentProps: {
|
||||
type: 'AccoesPresidenciais & ArquivoDespachoElect',
|
||||
type: 'Correspondencia',
|
||||
showSearchInput: true,
|
||||
select: true
|
||||
}
|
||||
|
||||
@@ -214,7 +214,7 @@ export class NewPublicationPage implements OnInit {
|
||||
FileType: 'image'
|
||||
}
|
||||
)
|
||||
newAttachment.needUpload();
|
||||
//newAttachment.needUpload();
|
||||
this.publicationFormMV.form.Files.push(newAttachment)
|
||||
});
|
||||
|
||||
@@ -252,7 +252,7 @@ export class NewPublicationPage implements OnInit {
|
||||
}
|
||||
)
|
||||
|
||||
newAttachment.needUpload()
|
||||
// newAttachment.needUpload()
|
||||
this.publicationFormMV.form.Files.push(newAttachment)
|
||||
this.filecontent = true;
|
||||
|
||||
@@ -368,7 +368,7 @@ export class NewPublicationPage implements OnInit {
|
||||
const publication: any = Object.assign({}, this.publicationFormMV.form)
|
||||
|
||||
publication.Files = publication.Files.map( (e:PublicationAttachmentEntity) => ({
|
||||
FileBase64: e.Base64,
|
||||
FileBase64: e.url,
|
||||
FileExtension: e.FileExtension,
|
||||
OriginalFileName: e.OriginalFileName || 'foto'
|
||||
}))
|
||||
@@ -420,7 +420,7 @@ export class NewPublicationPage implements OnInit {
|
||||
const publication: any = Object.assign({}, this.publicationFormMV.form)
|
||||
|
||||
publication.Files = publication.Files.map( (e:PublicationAttachmentEntity) => ({
|
||||
FileBase64: e.Base64,
|
||||
FileBase64: e.url,
|
||||
FileExtension: e.FileExtension,
|
||||
OriginalFileName: e.OriginalFileName || 'foto'
|
||||
}))
|
||||
@@ -809,13 +809,13 @@ console.log(stringGerada);
|
||||
console.log('', content)
|
||||
let fileObject;
|
||||
if(this.platform.is('desktop')) {
|
||||
|
||||
|
||||
fileObject = new PublicationAttachmentEntity({
|
||||
base64: content.data,
|
||||
extension: 'mp4',
|
||||
OriginalFileName: 'record',
|
||||
FileType: 'video'
|
||||
|
||||
|
||||
})
|
||||
} else {
|
||||
fileObject = new PublicationAttachmentEntity({
|
||||
@@ -823,10 +823,10 @@ console.log(stringGerada);
|
||||
extension: 'mp4',
|
||||
OriginalFileName: 'record',
|
||||
FileType: 'video'
|
||||
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
/* fileObject.needUpload() */
|
||||
this.publicationFormMV.form.Files.push(fileObject)
|
||||
})
|
||||
|
||||
@@ -148,14 +148,14 @@ export class PublicationAttachmentEntity {
|
||||
const sanitizer : DomSanitizer = window["sanitizer"]
|
||||
|
||||
if(this.FileType == 'image' ) {
|
||||
if(!this.Base64.startsWith('data:')) {
|
||||
if(!this.Base64.includes('data:')) {
|
||||
this.url = 'data:image/jpg;base64,' + this.Base64
|
||||
// this.url = sanitizer.bypassSecurityTrustUrl('data:image/jpg;base64,' + this.Base64) as any
|
||||
} else {
|
||||
this.url = this.Base64
|
||||
}
|
||||
} else if (this.FileType == 'video' ) {
|
||||
if(!this.Base64.startsWith('data:') && !this.Base64.startsWith('http')) {
|
||||
if(!this.Base64.includes('data:') && !this.Base64.startsWith('http')) {
|
||||
this.url = 'data:video/mp4;base64,' + this.Base64
|
||||
// this.url = sanitizer.bypassSecurityTrustUrl('data:video/mp4;base64,' + this.Base64) as any
|
||||
} else {
|
||||
|
||||
@@ -4,4 +4,4 @@ import { environment as doneITProd } from './suport/doneIt'
|
||||
import { DevDev } from './suport/dev'
|
||||
|
||||
|
||||
export const environment: Environment = oaprProd;
|
||||
export const environment: Environment = DevDev;
|
||||
|
||||
Reference in New Issue
Block a user