mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
Merge branch 'developer' into developer_mobilefirst
This commit is contained in:
+2
-1
@@ -32,6 +32,7 @@
|
||||
}
|
||||
],
|
||||
"styles": [
|
||||
"./node_modules/@angular/material/prebuilt-themes/pink-bluegrey.css",
|
||||
{
|
||||
"input": "src/theme/variables.scss",
|
||||
"inject": true
|
||||
@@ -99,7 +100,7 @@
|
||||
"polyfills": "src/polyfills.ts",
|
||||
"tsConfig": "tsconfig.spec.json",
|
||||
"karmaConfig": "karma.conf.js",
|
||||
"styles": [],
|
||||
"styles": [ "./node_modules/@angular/material/prebuilt-themes/pink-bluegrey.css"],
|
||||
"scripts": [],
|
||||
"assets": [
|
||||
{
|
||||
|
||||
Generated
+49
-9
@@ -424,6 +424,23 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"@angular/cdk": {
|
||||
"version": "11.2.13",
|
||||
"resolved": "https://registry.npmjs.org/@angular/cdk/-/cdk-11.2.13.tgz",
|
||||
"integrity": "sha512-FkE4iCwoLbQxLDUOjV1I7M/6hmpyb7erAjEdWgch7nGRNxF1hqX5Bqf1lvLFKPNCbx5NRI5K7YVAdIUQUR8vug==",
|
||||
"requires": {
|
||||
"parse5": "^5.0.0",
|
||||
"tslib": "^2.0.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"parse5": {
|
||||
"version": "5.1.1",
|
||||
"resolved": "https://registry.npmjs.org/parse5/-/parse5-5.1.1.tgz",
|
||||
"integrity": "sha512-ugq4DFI0Ptb+WWjAdOK16+u/nHfiIrcE+sh8kZMaM0WllQKLI9rOUq6c2b7cwPkXdzfQESqvoqK6ug7U/Yyzug==",
|
||||
"optional": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"@angular/cli": {
|
||||
"version": "11.2.1",
|
||||
"resolved": "https://registry.npmjs.org/@angular/cli/-/cli-11.2.1.tgz",
|
||||
@@ -785,6 +802,22 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"@angular/material": {
|
||||
"version": "11.2.13",
|
||||
"resolved": "https://registry.npmjs.org/@angular/material/-/material-11.2.13.tgz",
|
||||
"integrity": "sha512-FqFdGSkOtqsmeLyTSousodDGUy2NqbtxCIKv2rwbsIRwHNKB0KpR/UQhA2gMRuGa5hxhMJ0DW0Tf9neMRuLCTg==",
|
||||
"requires": {
|
||||
"tslib": "^2.0.0"
|
||||
}
|
||||
},
|
||||
"@angular/material-moment-adapter": {
|
||||
"version": "12.0.5",
|
||||
"resolved": "https://registry.npmjs.org/@angular/material-moment-adapter/-/material-moment-adapter-12.0.5.tgz",
|
||||
"integrity": "sha512-m09k/hCwyZxUEyg3NwSHbe0JNekSPjW86o9C6nRQkYqeAq/AUVy266U8CY3vyM8LDNsc16lsYsueLdZ421Th9A==",
|
||||
"requires": {
|
||||
"tslib": "^2.1.0"
|
||||
}
|
||||
},
|
||||
"@angular/platform-browser": {
|
||||
"version": "11.2.2",
|
||||
"resolved": "https://registry.npmjs.org/@angular/platform-browser/-/platform-browser-11.2.2.tgz",
|
||||
@@ -4342,12 +4375,6 @@
|
||||
"integrity": "sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ==",
|
||||
"dev": true
|
||||
},
|
||||
"async-limiter": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz",
|
||||
"integrity": "sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ==",
|
||||
"dev": true
|
||||
},
|
||||
"asynckit": {
|
||||
"version": "0.4.0",
|
||||
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
|
||||
@@ -4684,6 +4711,11 @@
|
||||
"integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=",
|
||||
"dev": true
|
||||
},
|
||||
"bootstrap": {
|
||||
"version": "4.6.0",
|
||||
"resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-4.6.0.tgz",
|
||||
"integrity": "sha512-Io55IuQY3kydzHtbGvQya3H+KorS/M9rSNyfCGCg9WZ4pyT/lCxIlpJgG1GXW/PswzC84Tr2fBYi+7+jFVQQBw=="
|
||||
},
|
||||
"boxen": {
|
||||
"version": "4.2.0",
|
||||
"resolved": "https://registry.npmjs.org/boxen/-/boxen-4.2.0.tgz",
|
||||
@@ -20529,12 +20561,20 @@
|
||||
}
|
||||
},
|
||||
"ws": {
|
||||
"version": "6.2.1",
|
||||
"resolved": "https://registry.npmjs.org/ws/-/ws-6.2.1.tgz",
|
||||
"integrity": "sha512-GIyAXC2cB7LjvpgMt9EKS2ldqr0MTrORaleiOno6TweZ6r3TKtoFQWay/2PceJ3RuBasOHzXNn5Lrw1X0bEjqA==",
|
||||
"version": "6.2.2",
|
||||
"resolved": "https://registry.npmjs.org/ws/-/ws-6.2.2.tgz",
|
||||
"integrity": "sha512-zmhltoSR8u1cnDsD43TX59mzoMZsLKqUweyYBAIvTngR3shc0W6aOZylZmq/7hqyVxPdi+5Ud2QInblgyE72fw==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"async-limiter": "~1.0.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"async-limiter": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz",
|
||||
"integrity": "sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ==",
|
||||
"dev": true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,10 +17,13 @@
|
||||
"@angular-devkit/core": "^11.2.1",
|
||||
"@angular-devkit/schematics": "^11.2.1",
|
||||
"@angular/animations": "^11.1.0",
|
||||
"@angular/cdk": "^11.2.13",
|
||||
"@angular/common": "^11.2.2",
|
||||
"@angular/core": "^11.2.2",
|
||||
"@angular/forms": "~11.2.2",
|
||||
"@angular/localize": "^11.2.2",
|
||||
"@angular/material": "^11.2.13",
|
||||
"@angular/material-moment-adapter": "^12.0.5",
|
||||
"@angular/platform-browser": "~11.2.2",
|
||||
"@angular/platform-browser-dynamic": "~11.2.2",
|
||||
"@angular/router": "~11.2.2",
|
||||
@@ -49,6 +52,7 @@
|
||||
"angular-calendar": "^0.28.22",
|
||||
"angular-tag-cloud-module": "^5.2.2",
|
||||
"cordova": "^10.0.0",
|
||||
"bootstrap": "^4.5.0",
|
||||
"cordova-plugin-camera": "^5.0.1",
|
||||
"cordova-plugin-filepath": "^1.5.8",
|
||||
"cordova-plugin-okhttp": "^2.0.0",
|
||||
|
||||
+149
-144
@@ -1,133 +1,134 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { PreloadAllModules, RouterModule, Routes } from '@angular/router';
|
||||
import { ChatPage } from './pages/chat/chat.page';
|
||||
import { MessagesPage } from './pages/chat/messages/messages.page';
|
||||
|
||||
const routes: Routes = [
|
||||
{
|
||||
path: '',
|
||||
loadChildren: () => import('./index/index.module').then(m => m.IndexPageModule)
|
||||
},
|
||||
{
|
||||
path: '',
|
||||
loadChildren: () => import('./home/home.module').then( m => m.HomePageModule)
|
||||
},
|
||||
{
|
||||
path: 'empty-chat',
|
||||
loadChildren: () => import('./shared/chat/empty-chat/empty-chat.module').then( m => m.EmptyChatPageModule)
|
||||
},
|
||||
{
|
||||
path: 'empty-container',
|
||||
loadChildren: () => import('./shared/empty-container/empty-container.module').then( m => m.EmptyContainerPageModule)
|
||||
},
|
||||
{
|
||||
path: 'events-to-approve',
|
||||
loadChildren: () => import('./shared/gabinete-digital/events-to-approve/events-to-approve.module').then( m => m.EventsToApprovePageModule)
|
||||
},
|
||||
{
|
||||
path: 'expedients',
|
||||
loadChildren: () => import('./shared/gabinete-digital/expedients/expedients.module').then( m => m.ExpedientsPageModule)
|
||||
},
|
||||
{
|
||||
path: 'document-detail',
|
||||
loadChildren: () => import('./modals/document-detail/document-detail.module').then( m => m.DocumentDetailPageModule)
|
||||
},
|
||||
{
|
||||
path: 'edit-group',
|
||||
loadChildren: () => import('./shared/chat/edit-group/edit-group.module').then( m => m.EditGroupPageModule)
|
||||
},
|
||||
{
|
||||
path: 'pedidos',
|
||||
loadChildren: () => import('./shared/gabinete-digital/pedidos/pedidos.module').then( m => m.PedidosPageModule)
|
||||
},
|
||||
{
|
||||
path: 'event-list',
|
||||
loadChildren: () => import('./pages/gabinete-digital/event-list/event-list.module').then(m =>m.EventListPageModule)
|
||||
},
|
||||
{
|
||||
path: 'despachos',
|
||||
loadChildren: () => import('./shared/gabinete-digital/despachos/despachos.module').then( m => m.DespachosPageModule)
|
||||
},
|
||||
{
|
||||
path: 'create-process',
|
||||
loadChildren: () => import('./modals/create-process/create-process.module').then( m => m.CreateProcessPageModule)
|
||||
},
|
||||
{
|
||||
path: 'pendentes',
|
||||
loadChildren: () => import('./shared/gabinete-digital/pendentes/pendentes.module').then( m => m.PendentesPageModule)
|
||||
},
|
||||
{
|
||||
path: 'delegar',
|
||||
loadChildren: () => import('./modals/delegar/delegar.module').then( m => m.DelegarPageModule)
|
||||
},
|
||||
{
|
||||
path: 'add-note',
|
||||
loadChildren: () => import('./modals/add-note/add-note.module').then( m => m.AddNotePageModule)
|
||||
},
|
||||
{
|
||||
path: 'dar-parecer',
|
||||
loadChildren: () => import('./modals/dar-parecer/dar-parecer.module').then( m => m.DarParecerPageModule)
|
||||
},
|
||||
{
|
||||
path: 'opts-expediente',
|
||||
loadChildren: () => import('./shared/popover/opts-expediente/opts-expediente.module').then( m => m.OptsExpedientePageModule)
|
||||
},
|
||||
{
|
||||
path: 'despachos-pr',
|
||||
loadChildren: () => import('./shared/gabinete-digital/despachos-pr/despachos-pr.module').then( m => m.DespachosPrPageModule)
|
||||
},
|
||||
{
|
||||
path: 'diplomas',
|
||||
loadChildren: () => import('./shared/gabinete-digital/diplomas/diplomas.module').then( m => m.DiplomasPageModule)
|
||||
},
|
||||
{
|
||||
path: 'expedientes-pr',
|
||||
loadChildren: () => import('./shared/gabinete-digital/expedientes-pr/expedientes-pr.module').then( m => m.ExpedientesPrPageModule)
|
||||
},
|
||||
{
|
||||
path: 'diplomas-assinar',
|
||||
loadChildren: () => import('./shared/gabinete-digital/diplomas-assinar/diplomas-assinar.module').then( m => m.DiplomasAssinarPageModule)
|
||||
},
|
||||
{
|
||||
path: 'opts-expediente-pr',
|
||||
loadChildren: () => import('./shared/popover/opts-expediente-pr/opts-expediente-pr.module').then( m => m.OptsExpedientePrPageModule)
|
||||
},
|
||||
{
|
||||
path: 'despachos-options',
|
||||
loadChildren: () => import('./shared/popover/despachos-options/despachos-options.module').then( m => m.DespachosOptionsPageModule)
|
||||
},
|
||||
{
|
||||
path: 'despachos-pr-options',
|
||||
loadChildren: () => import('./shared/popover/despachos-pr-options/despachos-pr-options.module').then( m => m.DespachosPrOptionsPageModule)
|
||||
},
|
||||
{
|
||||
path: 'deploma-options',
|
||||
loadChildren: () => import('./shared/popover/deploma-options/deploma-options.module').then( m => m.DeplomaOptionsPageModule)
|
||||
},
|
||||
{
|
||||
path: 'pin',
|
||||
loadChildren: () => import('./shared/pin/pin.module').then( m => m.PinPageModule)
|
||||
},
|
||||
{
|
||||
path: 'fingerprint',
|
||||
loadChildren: () => import('./shared/fingerprint/fingerprint.module').then( m => m.FingerprintPageModule)
|
||||
},
|
||||
{
|
||||
path: 'new-event',
|
||||
loadChildren: () => import('./shared/agenda/new-event/new-event.module').then( m => m.NewEventPageModule)
|
||||
},
|
||||
{
|
||||
path: 'edit-event',
|
||||
loadChildren: () => import('./shared/agenda/edit-event/edit-event.module').then( m => m.EditEventPageModule)
|
||||
},
|
||||
{
|
||||
path: 'event-list',
|
||||
loadChildren: () => import('./shared/agenda/event-list/event-list.module').then( m => m.EventListPageModule)
|
||||
},
|
||||
{
|
||||
path: 'approve-event',
|
||||
loadChildren: () => import('./shared/agenda/approve-event/approve-event.module').then( m => m.ApproveEventPageModule)
|
||||
},
|
||||
import { NgModule } from '@angular/core';
|
||||
import { PreloadAllModules, RouterModule, Routes } from '@angular/router';
|
||||
import { ChatPage } from './pages/chat/chat.page';
|
||||
import { MessagesPage } from './pages/chat/messages/messages.page';
|
||||
|
||||
const routes: Routes = [
|
||||
{
|
||||
path: '',
|
||||
loadChildren: () => import('./index/index.module').then(m => m.IndexPageModule)
|
||||
},
|
||||
{
|
||||
path: '',
|
||||
loadChildren: () => import('./home/home.module').then( m => m.HomePageModule)
|
||||
},
|
||||
{
|
||||
path: 'empty-chat',
|
||||
loadChildren: () => import('./shared/chat/empty-chat/empty-chat.module').then( m => m.EmptyChatPageModule)
|
||||
},
|
||||
{
|
||||
path: 'empty-container',
|
||||
loadChildren: () => import('./shared/empty-container/empty-container.module').then( m => m.EmptyContainerPageModule)
|
||||
},
|
||||
{
|
||||
path: 'events-to-approve',
|
||||
loadChildren: () => import('./shared/gabinete-digital/events-to-approve/events-to-approve.module').then( m => m.EventsToApprovePageModule)
|
||||
},
|
||||
{
|
||||
path: 'expedients',
|
||||
loadChildren: () => import('./shared/gabinete-digital/expedients/expedients.module').then( m => m.ExpedientsPageModule)
|
||||
},
|
||||
{
|
||||
path: 'document-detail',
|
||||
loadChildren: () => import('./modals/document-detail/document-detail.module').then( m => m.DocumentDetailPageModule)
|
||||
},
|
||||
{
|
||||
path: 'edit-group',
|
||||
loadChildren: () => import('./shared/chat/edit-group/edit-group.module').then( m => m.EditGroupPageModule)
|
||||
},
|
||||
{
|
||||
path: 'pedidos',
|
||||
loadChildren: () => import('./shared/gabinete-digital/pedidos/pedidos.module').then( m => m.PedidosPageModule)
|
||||
},
|
||||
{
|
||||
path: 'event-list',
|
||||
loadChildren: () => import('./pages/gabinete-digital/event-list/event-list.module').then(m =>m.EventListPageModule)
|
||||
},
|
||||
{
|
||||
path: 'despachos',
|
||||
loadChildren: () => import('./shared/gabinete-digital/despachos/despachos.module').then( m => m.DespachosPageModule)
|
||||
},
|
||||
{
|
||||
path: 'create-process',
|
||||
loadChildren: () => import('./modals/create-process/create-process.module').then( m => m.CreateProcessPageModule)
|
||||
},
|
||||
{
|
||||
path: 'pendentes',
|
||||
loadChildren: () => import('./shared/gabinete-digital/pendentes/pendentes.module').then( m => m.PendentesPageModule)
|
||||
},
|
||||
{
|
||||
path: 'delegar',
|
||||
loadChildren: () => import('./modals/delegar/delegar.module').then( m => m.DelegarPageModule)
|
||||
},
|
||||
{
|
||||
path: 'add-note',
|
||||
loadChildren: () => import('./modals/add-note/add-note.module').then( m => m.AddNotePageModule)
|
||||
},
|
||||
{
|
||||
path: 'dar-parecer',
|
||||
loadChildren: () => import('./modals/dar-parecer/dar-parecer.module').then( m => m.DarParecerPageModule)
|
||||
},
|
||||
{
|
||||
path: 'opts-expediente',
|
||||
loadChildren: () => import('./shared/popover/opts-expediente/opts-expediente.module').then( m => m.OptsExpedientePageModule)
|
||||
},
|
||||
{
|
||||
path: 'despachos-pr',
|
||||
loadChildren: () => import('./shared/gabinete-digital/despachos-pr/despachos-pr.module').then( m => m.DespachosPrPageModule)
|
||||
},
|
||||
{
|
||||
path: 'diplomas',
|
||||
loadChildren: () => import('./shared/gabinete-digital/diplomas/diplomas.module').then( m => m.DiplomasPageModule)
|
||||
},
|
||||
{
|
||||
path: 'expedientes-pr',
|
||||
loadChildren: () => import('./shared/gabinete-digital/expedientes-pr/expedientes-pr.module').then( m => m.ExpedientesPrPageModule)
|
||||
},
|
||||
{
|
||||
path: 'diplomas-assinar',
|
||||
loadChildren: () => import('./shared/gabinete-digital/diplomas-assinar/diplomas-assinar.module').then( m => m.DiplomasAssinarPageModule)
|
||||
},
|
||||
{
|
||||
path: 'opts-expediente-pr',
|
||||
loadChildren: () => import('./shared/popover/opts-expediente-pr/opts-expediente-pr.module').then( m => m.OptsExpedientePrPageModule)
|
||||
},
|
||||
{
|
||||
path: 'despachos-options',
|
||||
loadChildren: () => import('./shared/popover/despachos-options/despachos-options.module').then( m => m.DespachosOptionsPageModule)
|
||||
},
|
||||
{
|
||||
path: 'despachos-pr-options',
|
||||
loadChildren: () => import('./shared/popover/despachos-pr-options/despachos-pr-options.module').then( m => m.DespachosPrOptionsPageModule)
|
||||
},
|
||||
{
|
||||
path: 'deploma-options',
|
||||
loadChildren: () => import('./shared/popover/deploma-options/deploma-options.module').then( m => m.DeplomaOptionsPageModule)
|
||||
},
|
||||
{
|
||||
path: 'pin',
|
||||
loadChildren: () => import('./shared/pin/pin.module').then( m => m.PinPageModule)
|
||||
},
|
||||
{
|
||||
path: 'fingerprint',
|
||||
loadChildren: () => import('./shared/fingerprint/fingerprint.module').then( m => m.FingerprintPageModule)
|
||||
},
|
||||
{
|
||||
path: 'new-event',
|
||||
loadChildren: () => import('./shared/agenda/new-event/new-event.module').then( m => m.NewEventPageModule)
|
||||
},
|
||||
{
|
||||
path: 'edit-event',
|
||||
loadChildren: () => import('./shared/agenda/edit-event/edit-event.module').then( m => m.EditEventPageModule)
|
||||
},
|
||||
{
|
||||
path: 'event-list',
|
||||
loadChildren: () => import('./shared/agenda/event-list/event-list.module').then( m => m.EventListPageModule)
|
||||
},
|
||||
{
|
||||
path: 'approve-event',
|
||||
loadChildren: () => import('./shared/agenda/approve-event/approve-event.module').then( m => m.ApproveEventPageModule)
|
||||
},
|
||||
{
|
||||
path: 'bad-request',
|
||||
loadChildren: () => import('./shared/popover/bad-request/bad-request.module').then( m => m.BadRequestPageModule)
|
||||
},
|
||||
@@ -135,18 +136,22 @@ const routes: Routes = [
|
||||
path: 'success-message',
|
||||
loadChildren: () => import('./shared/popover/success-message/success-message.module').then( m => m.SuccessMessagePageModule)
|
||||
},
|
||||
{
|
||||
path: 'forward',
|
||||
loadChildren: () => import('./modals/forward/forward.module').then( m => m.ForwardPageModule)
|
||||
},
|
||||
|
||||
|
||||
|
||||
/* {
|
||||
path: 'chat',
|
||||
component: ChatPage
|
||||
} */
|
||||
|
||||
];
|
||||
@NgModule({
|
||||
imports: [
|
||||
RouterModule.forRoot(routes, { preloadingStrategy: PreloadAllModules })
|
||||
],
|
||||
exports: [RouterModule]
|
||||
})
|
||||
|
||||
/* {
|
||||
path: 'chat',
|
||||
component: ChatPage
|
||||
} */
|
||||
|
||||
];
|
||||
@NgModule({
|
||||
imports: [
|
||||
RouterModule.forRoot(routes, { preloadingStrategy: PreloadAllModules })
|
||||
],
|
||||
exports: [RouterModule]
|
||||
})
|
||||
export class AppRoutingModule {}
|
||||
|
||||
@@ -30,8 +30,7 @@ import { BrowserAnimationsModule, NoopAnimationsModule } from '@angular/platform
|
||||
import { MessagesPage } from './pages/chat/messages/messages.page';
|
||||
import { WebsocketService } from './services/websocket.service'
|
||||
import { ChatService } from './services/chat.service';
|
||||
import { NgbModule } from '@ng-bootstrap/ng-bootstrap'
|
||||
|
||||
import {MatDatepickerModule} from '@angular/material/datepicker';
|
||||
// import { FCM } from 'cordova-plugin-fcm-with-dependecy-updated/ionic/ngx';
|
||||
|
||||
|
||||
@@ -48,7 +47,10 @@ import { NgbModule } from '@ng-bootstrap/ng-bootstrap'
|
||||
IonicModule.forRoot(),
|
||||
IonicStorageModule.forRoot(),
|
||||
AppRoutingModule,
|
||||
HttpClientModule,
|
||||
HttpClientModule,
|
||||
// NgbModule,
|
||||
NoopAnimationsModule,
|
||||
MatDatepickerModule
|
||||
],
|
||||
providers: [
|
||||
StatusBar,
|
||||
|
||||
@@ -177,6 +177,10 @@ const routes: Routes = [
|
||||
loadChildren: ()=> import('../pages/publications/publications.module').then(m => m.PublicationsPageModule)
|
||||
},
|
||||
{
|
||||
path:':folderId',
|
||||
loadChildren: ()=> import('../pages/publications/view-publications/view-publications.module').then(m => m.ViewPublicationsPageModule)
|
||||
},
|
||||
/* {
|
||||
path:'view-publications',
|
||||
children: [
|
||||
{
|
||||
@@ -194,7 +198,7 @@ const routes: Routes = [
|
||||
|
||||
},
|
||||
]
|
||||
},
|
||||
}, */
|
||||
{
|
||||
path:'new-publication',
|
||||
loadChildren: ()=> import('../shared/publication/new-publication/new-publication.module').then(m => m.NewPublicationPageModule)
|
||||
|
||||
@@ -28,3 +28,4 @@
|
||||
</ion-tab-button>
|
||||
</ion-tab-bar>
|
||||
</ion-tabs>
|
||||
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" rel="stylesheet">
|
||||
@@ -61,72 +61,5 @@ export class AddNotePage implements OnInit {
|
||||
this.documents = this.documents.filter( (e, i) => index != i);
|
||||
}
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
|
||||
let notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
<p class="message d-flex align-center">
|
||||
<ion-icon slot="end" class="title-icon pr-10" src="/assets/images/nofitication-success.svg"></ion-icon>
|
||||
<p class="text">{{ message }}</p>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
`
|
||||
|
||||
document.body.append(notification)
|
||||
notification.querySelector('.text').innerHTML = message || 'Processo efetuado'
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},7000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -98,69 +98,6 @@ export class DarParecerPage implements OnInit {
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
|
||||
var notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
<p class="message d-flex align-center">
|
||||
<ion-icon slot="end" class="title-icon pr-10" src="/assets/images/nofitication-success.svg"></ion-icon>
|
||||
<p class="text">{{ message }}</p>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
`
|
||||
|
||||
document.body.append(notification)
|
||||
notification.querySelector('.text').innerHTML = message || 'Processo efetuado'
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},7000)
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
modal.dismiss()
|
||||
},1000)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -63,8 +63,6 @@ export class DelegarPage implements OnInit {
|
||||
/* Set + 30minutes to seleted datetime */
|
||||
let selectedEndDate = new Date();
|
||||
/* this.postData.EndDate = new Date(selectedEndDate.setMinutes(new Date().getMinutes() + 30)); */
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -85,7 +83,7 @@ export class DelegarPage implements OnInit {
|
||||
|
||||
async saveTask() {
|
||||
if(this.taskParticipants.length > 1){
|
||||
this.alertService.presentErrorMessage("Selecione apenas um destinatário");
|
||||
this.toastService.badRequest("Selecione apenas um destinatário");
|
||||
}
|
||||
else {
|
||||
let body = {
|
||||
@@ -173,71 +171,4 @@ export class DelegarPage implements OnInit {
|
||||
this.taskParticipants = taskParticipants;
|
||||
}
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
var notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
<p class="message d-flex align-center">
|
||||
<ion-icon slot="end" class="title-icon pr-10" src="/assets/images/nofitication-success.svg"></ion-icon>
|
||||
<p class="text">{{ message }}</p>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
`
|
||||
|
||||
document.body.append(notification)
|
||||
notification.querySelector('.text').innerHTML = message || 'Processo efetuado'
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},7000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { Routes, RouterModule } from '@angular/router';
|
||||
|
||||
import { ForwardPage } from './forward.page';
|
||||
|
||||
const routes: Routes = [
|
||||
{
|
||||
path: '',
|
||||
component: ForwardPage
|
||||
}
|
||||
];
|
||||
|
||||
@NgModule({
|
||||
imports: [RouterModule.forChild(routes)],
|
||||
exports: [RouterModule],
|
||||
})
|
||||
export class ForwardPageRoutingModule {}
|
||||
@@ -0,0 +1,22 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { FormsModule } from '@angular/forms';
|
||||
|
||||
import { IonicModule } from '@ionic/angular';
|
||||
|
||||
import { ForwardPageRoutingModule } from './forward-routing.module';
|
||||
|
||||
import { ForwardPage } from './forward.page';
|
||||
import { AttendeeModalPageModule } from 'src/app/shared/event/attendee-modal/attendee-modal.module';
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
CommonModule,
|
||||
FormsModule,
|
||||
IonicModule,
|
||||
ForwardPageRoutingModule,
|
||||
AttendeeModalPageModule
|
||||
],
|
||||
declarations: [ForwardPage]
|
||||
})
|
||||
export class ForwardPageModule {}
|
||||
@@ -0,0 +1,91 @@
|
||||
<ion-content>
|
||||
<div class="main-content d-flex height-100">
|
||||
|
||||
<div class="content d-flex flex-column width-100">
|
||||
<div class="header-content pb-20">
|
||||
<div class="header-title">
|
||||
<label>Delegar</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="overflow-y-auto">
|
||||
|
||||
<div class="container-div">
|
||||
<div class="ion-item-class-2">
|
||||
<div class="ion-icon-class">
|
||||
<ion-icon slot="start" src="assets/images/icons-person.svg"></ion-icon>
|
||||
</div>
|
||||
<div class="ion-input-class-no-height">
|
||||
<div class="list-people">
|
||||
<ion-item lines="none">
|
||||
<ion-list>
|
||||
<ion-label *ngIf="taskParticipants.length == 0" class="list-people-title">Adicionar intervenientes</ion-label>
|
||||
<ion-label *ngFor="let participant of taskParticipants">{{participant.Name}}</ion-label>
|
||||
</ion-list>
|
||||
</ion-item>
|
||||
</div>
|
||||
<div class="add-people" (click)="addParticipants()">
|
||||
<ion-icon slot="start" src="assets/images/icons-arrow-forward.svg"></ion-icon>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container-div">
|
||||
<div class="ion-item-class-2 d-flex">
|
||||
<div class="ion-icon-class">
|
||||
<ion-icon slot="start" src="assets/images/icons-description.svg"></ion-icon>
|
||||
</div>
|
||||
<div class="ion-input-class-no-height width-100">
|
||||
<ion-textarea [(ngModel)]="note" placeholder="Detalhes" rows="6" cols="20"></ion-textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div hidden class="ion-item-container-no-border">
|
||||
<ion-label>
|
||||
<div class="attach-icon">
|
||||
<ion-icon src="assets/images/icons-attach-doc.svg"></ion-icon>
|
||||
</div>
|
||||
<div class="attach-document">
|
||||
<ion-label>Anexar Documentos</ion-label>
|
||||
</div>
|
||||
</ion-label>
|
||||
</div>
|
||||
|
||||
<div *ngIf="loadedAttachments">
|
||||
<ion-item>
|
||||
<ion-label>Documentos Anexados</ion-label>
|
||||
</ion-item>
|
||||
<ion-list>
|
||||
<ion-item *ngFor="let attachment of loadedAttachments">
|
||||
<ion-label>
|
||||
<h4 class="attach-title-item">{{attachment.Description}}</h4>
|
||||
<p><span class="span-left">{{attachment.Stakeholders}}</span><span class="span-right"> {{ attachment.CreateDate | date: 'dd/MM/yyyy' }}</span></p>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
</ion-list>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="aside-righ flex-grow-1">
|
||||
<app-attendee-modal class=" d-flex flex-column height-100"
|
||||
[footer]="false"
|
||||
*ngIf="showAttendees"
|
||||
[taskParticipants]="taskParticipants"
|
||||
[taskParticipantsCc]="taskParticipantsCc"
|
||||
[adding]="adding"
|
||||
(dynamicSetIntervenient)="dynamicSetIntervenient($event)"
|
||||
>
|
||||
</app-attendee-modal>
|
||||
</div>
|
||||
</div>
|
||||
</ion-content>
|
||||
<ion-footer>
|
||||
<div class="buttons">
|
||||
<button class="btn-cancel" shape="round" (click)="cancelTask()">Cancelar</button>
|
||||
<button class="btn-ok" shape="round" (click)="saveTask()">Gravar</button>
|
||||
</div>
|
||||
</ion-footer>
|
||||
|
||||
@@ -0,0 +1,150 @@
|
||||
.content{
|
||||
padding: 30px 20px 0 20px !important;
|
||||
margin: 0;
|
||||
float: left;
|
||||
|
||||
.header-content{
|
||||
margin-bottom: 20px !important;
|
||||
}
|
||||
|
||||
.header-title{
|
||||
font-family: Roboto;
|
||||
font-size: 25px;
|
||||
padding: 0;
|
||||
color:#000;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.ion-item-container{
|
||||
margin: 15px auto;
|
||||
border: 1px solid #ebebeb;
|
||||
border-radius: 5px;
|
||||
padding-left: 10px;
|
||||
|
||||
}
|
||||
.ion-item-container-no-border{
|
||||
margin: 0px auto;
|
||||
padding: 0 !important;
|
||||
overflow: auto;
|
||||
}
|
||||
.container-div{
|
||||
margin-bottom: 15px;
|
||||
overflow: hidden;
|
||||
}
|
||||
.ion-item-class-2{
|
||||
margin: 0px auto;
|
||||
}
|
||||
.ion-icon-class{
|
||||
width: 45px;
|
||||
height: 45px;
|
||||
float: left;
|
||||
padding: 10px;
|
||||
font-size: 25px;
|
||||
}
|
||||
ion-select{
|
||||
padding-left: 5px;
|
||||
margin-left: 0;
|
||||
}
|
||||
.ion-input-class{
|
||||
width: calc(100% - 45px);
|
||||
height: 45px;
|
||||
border: 1px solid #ebebeb;
|
||||
border-radius: 5px;
|
||||
padding-left: 5px;
|
||||
padding-right: 10px;
|
||||
float: left;
|
||||
}
|
||||
.ion-input-class-no-height{
|
||||
border: 1px solid #ebebeb;
|
||||
border-radius: 5px;
|
||||
overflow: auto;
|
||||
}
|
||||
.list-people{
|
||||
width: 256px;
|
||||
float: left;
|
||||
|
||||
}
|
||||
.add-people{
|
||||
width: 45px;
|
||||
float: right;
|
||||
overflow: auto;
|
||||
font-size: 25px;
|
||||
padding: 10px;
|
||||
}
|
||||
.list-people-title{
|
||||
/* font-size: 13px; */
|
||||
color: #797979;
|
||||
}
|
||||
.attach-document{
|
||||
font-size: 15px;
|
||||
color: #0d89d1;
|
||||
margin: 5px 5px 5px 10px;
|
||||
padding: 5px;
|
||||
float: left;
|
||||
}
|
||||
.attach-icon{
|
||||
width: 37px;
|
||||
font-size: 35px;
|
||||
float: left;
|
||||
}
|
||||
.attach-title-item{
|
||||
width: 100%;
|
||||
font-size: 15px;
|
||||
color:#0d89d1;
|
||||
}
|
||||
/* SPAN */
|
||||
.span-left{
|
||||
float: left;
|
||||
font-size: 15x;
|
||||
}
|
||||
.span-right{
|
||||
text-align: right;
|
||||
float: right;
|
||||
font-size: 13px;
|
||||
}
|
||||
}
|
||||
.container-footer{
|
||||
margin:0 auto;
|
||||
overflow: auto;
|
||||
}
|
||||
.button-cancel {
|
||||
width: 170px;
|
||||
height: 44px;
|
||||
border-radius: 22.5px;
|
||||
--background: #e0e9ee;
|
||||
--color: #061b52;
|
||||
margin:10px;
|
||||
}
|
||||
.button-save {
|
||||
width: 170px;
|
||||
height: 44px;
|
||||
border-radius: 22.5px;
|
||||
--background: #42b9fe;
|
||||
--color:#ffffff;
|
||||
margin:10px;
|
||||
}
|
||||
|
||||
.text-input{
|
||||
width: 100%;
|
||||
border: 1px solid #ebebeb;
|
||||
margin: 0px 15px 15px 0px;
|
||||
padding: 0 !important;
|
||||
border-radius: 5px;
|
||||
}
|
||||
|
||||
/* Error Messages */
|
||||
.error{
|
||||
color:red;
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
padding-bottom: 20px;
|
||||
}
|
||||
.span-color{
|
||||
color:red;
|
||||
}
|
||||
.buttons{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
padding: 20px;
|
||||
overflow: auto;
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
|
||||
import { IonicModule } from '@ionic/angular';
|
||||
|
||||
import { ForwardPage } from './forward.page';
|
||||
|
||||
describe('ForwardPage', () => {
|
||||
let component: ForwardPage;
|
||||
let fixture: ComponentFixture<ForwardPage>;
|
||||
|
||||
beforeEach(waitForAsync(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ ForwardPage ],
|
||||
imports: [IonicModule.forRoot()]
|
||||
}).compileComponents();
|
||||
|
||||
fixture = TestBed.createComponent(ForwardPage);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
}));
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,224 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { NavigationExtras, Router } from '@angular/router';
|
||||
import { AlertController, AnimationController, ModalController, NavParams } from '@ionic/angular';
|
||||
import { Event } from 'src/app/models/event.model'
|
||||
import { EventBody } from 'src/app/models/eventbody.model';
|
||||
import { ProcessesService } from 'src/app/services/processes.service';
|
||||
import { EventPerson } from 'src/app/models/eventperson.model';
|
||||
import { EventsService } from 'src/app/services/events.service';
|
||||
import { AttachmentsService } from 'src/app/services/attachments.service';
|
||||
import { AddParticipantsModalPage } from 'src/app/pages/gabinete-digital/expediente/add-participants-modal/add-participants-modal.page';
|
||||
import { AddParticipantsCcModalPage } from 'src/app/pages/gabinete-digital/expediente/add-participants-cc-modal/add-participants-cc-modal.page';
|
||||
import { DiscartExpedientModalPage } from 'src/app/pages/gabinete-digital/discart-expedient-modal/discart-expedient-modal.page';
|
||||
import { AlertService } from 'src/app/services/alert.service';
|
||||
import { BadRequestPage } from 'src/app/shared/popover/bad-request/bad-request.page';
|
||||
import { SuccessMessagePage } from 'src/app/shared/popover/success-message/success-message.page';
|
||||
import { ToastService } from 'src/app/services/toast.service';
|
||||
import { SearchDocument } from 'src/app/models/search-document';
|
||||
import { SearchPage } from 'src/app/pages/search/search.page';
|
||||
|
||||
@Component({
|
||||
selector: 'app-forward',
|
||||
templateUrl: './forward.page.html',
|
||||
styleUrls: ['./forward.page.scss'],
|
||||
})
|
||||
export class ForwardPage implements OnInit {
|
||||
task: any;
|
||||
note:string;
|
||||
|
||||
taskParticipants: EventPerson[] = [];
|
||||
taskParticipantsCc: EventPerson[] = [];
|
||||
|
||||
taskDocId:string;
|
||||
loadedAttachments:any;
|
||||
|
||||
adding: "intervenient" | "CC" = "intervenient";
|
||||
|
||||
postData: Event;
|
||||
eventBody: EventBody;
|
||||
eventAttendees: EventPerson;
|
||||
|
||||
formLocationSatus: boolean = false;
|
||||
showAttendees= false;
|
||||
|
||||
documents:SearchDocument[] = [];
|
||||
|
||||
constructor(
|
||||
private modalController: ModalController,
|
||||
private router:Router,
|
||||
private navParams: NavParams,
|
||||
private processes:ProcessesService,
|
||||
private attachmentsService: AttachmentsService,
|
||||
private calendarService: EventsService,
|
||||
public alertController: AlertController,
|
||||
private alertService: AlertService,
|
||||
private animationController: AnimationController,
|
||||
private toastService: ToastService,
|
||||
) {
|
||||
this.task = this.navParams.get('task');
|
||||
this.postData = new Event();
|
||||
this.eventBody = { BodyType : "1", Text : ""};
|
||||
this.postData.Body = this.eventBody;
|
||||
this.postData.Subject = this.task.Folio;
|
||||
this.postData.CalendarName = "Oficial";
|
||||
let selectedEndDate = new Date();
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
this.adding = "intervenient";
|
||||
console.log(this.task);
|
||||
|
||||
}
|
||||
|
||||
close() {
|
||||
this.router.navigate(['/home/gabinete-digital/expediente']);
|
||||
this.modalController.dismiss(null);
|
||||
}
|
||||
|
||||
cancelTask() {
|
||||
this.modalController.dismiss(null);
|
||||
}
|
||||
goBack() {
|
||||
this.modalController.dismiss(null);
|
||||
if (window.innerWidth <= 800) {
|
||||
this.router.navigate(['/home/gabinete-digital/pedidos']);
|
||||
} else {
|
||||
let navigationExtras: NavigationExtras = {
|
||||
queryParams: {
|
||||
"pedidos": true,
|
||||
}
|
||||
}
|
||||
this.router.navigate(['/home/gabinete-digital'], navigationExtras);
|
||||
}
|
||||
}
|
||||
|
||||
async assignar(note:string, documents:any) {
|
||||
let body = {
|
||||
"serialNumber": this.task.SerialNumber,
|
||||
"action": "Reencaminhar",
|
||||
"ActionTypeId": 98,
|
||||
"dataFields": {
|
||||
"ReviewUserComment": note,
|
||||
},
|
||||
"AttachmentList" :documents,
|
||||
}
|
||||
}
|
||||
|
||||
notImplemented(){
|
||||
this.alertService.presentAlert('Funcionalidade em desenvolvimento');
|
||||
}
|
||||
|
||||
async saveTask() {
|
||||
|
||||
const DocumentToSave = this.documents.map((e) => {
|
||||
return {
|
||||
ApplicationId: e.ApplicationType,
|
||||
SourceId: e.Id,
|
||||
}
|
||||
});
|
||||
let docs = {
|
||||
ProcessInstanceID: "",
|
||||
Attachments: DocumentToSave,
|
||||
}
|
||||
|
||||
if(this.taskParticipants.length < 1){
|
||||
this.toastService.badRequest("Selecione um destinatário");
|
||||
}
|
||||
else {
|
||||
|
||||
let attendees: any = this.taskParticipants.concat(this.taskParticipantsCc);
|
||||
attendees = attendees.map(function(val) {
|
||||
return {
|
||||
UserEmail: val.EmailAddress,
|
||||
UserType: val.IsRequired?"I": "CC"
|
||||
};
|
||||
});
|
||||
|
||||
let body = {
|
||||
"usersSelected": attendees,
|
||||
"serialNumber": this.task.SerialNumber,
|
||||
"action": "Reencaminhar",
|
||||
"actionTypeId": 98,
|
||||
"dataFields": {
|
||||
"ReviewUserComment": this.note,
|
||||
},
|
||||
"FolderId": this.task.FolderId,
|
||||
"AttachmentList" :docs,
|
||||
}
|
||||
console.log(body);
|
||||
this.processes.CompleteParecerPrTask(body).subscribe(res=>{
|
||||
console.log(res);
|
||||
this.toastService.successMessage('Processo delegado');
|
||||
this.goBack();
|
||||
},
|
||||
(error)=>{
|
||||
this.toastService.badRequest("Processo não delegado")
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
async addParticipants(){
|
||||
console.log('HERE');
|
||||
|
||||
this.adding = "intervenient";
|
||||
if(window.innerWidth <= 800){
|
||||
const modal = await this.modalController.create({
|
||||
component: AddParticipantsModalPage,
|
||||
componentProps: {
|
||||
eventPersons: this.eventAttendees
|
||||
},
|
||||
cssClass: 'book-meeting-modal',
|
||||
backdropDismiss: false
|
||||
});
|
||||
|
||||
await modal.present();
|
||||
|
||||
modal.onDidDismiss().then((res) => {
|
||||
});
|
||||
} else {
|
||||
this.showAttendees = true;
|
||||
}
|
||||
}
|
||||
|
||||
validateFormInputs(){
|
||||
let formLocation = this.postData.Location.trim();
|
||||
if(!this.postData.Location && formLocation.length <= 0){
|
||||
this.formLocationSatus=true;
|
||||
}
|
||||
}
|
||||
|
||||
dynamicSetIntervenient({taskParticipants}){
|
||||
this.taskParticipants = taskParticipants;
|
||||
}
|
||||
|
||||
|
||||
async getDoc() {
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
component: SearchPage,
|
||||
cssClass: 'modal-width-100-width-background modal',
|
||||
componentProps: {
|
||||
type: 'AccoesPresidenciais & ArquivoDespachoElect',
|
||||
showSearchInput: true,
|
||||
select: true
|
||||
}
|
||||
});
|
||||
await modal.present();
|
||||
modal.onDidDismiss().then((res)=>{
|
||||
if(res){
|
||||
const data = res.data;
|
||||
this.documents.push(data.selected);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
removeAttachment(index: number){
|
||||
|
||||
this.documents = this.documents.filter( (e, i) => index != i);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -32,7 +32,7 @@ export class EventToApproveEdit {
|
||||
"StartDate": "2021-05-12T10:30:00"
|
||||
"EndDate": "2021-05-12T11:30:00"
|
||||
"Private": false
|
||||
"ReviewerComments": ""
|
||||
"ReviewUserComments": ""
|
||||
"MDName": "Paulo Pinto"
|
||||
"MDEmail": "paulo.pinto@gabinetedigital.local"
|
||||
"Agenda": "Oficial" | "Pessoal"
|
||||
|
||||
@@ -99,12 +99,14 @@
|
||||
|
||||
<!-- Adding a customized ng-template -->
|
||||
<ng-template #template let-view="view" let-row="row" let-col="col">
|
||||
<div [className]="currentDayEventDisplayBorder(view.dates, row*7+col)" class="d-flex justify-center align-center" [class.with-event]="view.dates[row*7+col].events.length">
|
||||
|
||||
<div class="day">
|
||||
{{ view.dates[row*7+col].label }}
|
||||
</div>
|
||||
|
||||
<div class="day-container">
|
||||
<div [className]="currentDayEventDisplayBorder(view.dates, row*7+col)" class="d-flex justify-center align-center" [class.with-event]="view.dates[row*7+col].events.length">
|
||||
|
||||
<div class="day">
|
||||
<div class="number"> {{ view.dates[row*7+col].label }}</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</ng-template>
|
||||
</div>
|
||||
@@ -116,12 +118,12 @@
|
||||
</div>
|
||||
|
||||
<!-- Calendar currente date -->
|
||||
<ion-row class="timeline-header ion-justify-content-between ion-align-items-center currente-date-timelien pb-5">
|
||||
<ion-row class="timeline-header pb-0 ion-justify-content-between ion-align-items-center currente-date-timelien">
|
||||
<ion-row class="timeline-date align-center">
|
||||
<button class="btn-no-color" *ngIf="showCalendar" (click)="calendarHeight='75px';showCalendar=false">
|
||||
<ion-icon class="collaps btn-no-color" src="assets/images/icons-collaps-up.svg" ></ion-icon>
|
||||
</button>
|
||||
<button class="collaps btn-no-color" *ngIf="!showCalendar" (click)="calendarHeight='333px';showCalendar=true">
|
||||
<button class="collaps btn-no-color" *ngIf="!showCalendar" (click)="calendarHeight='317px';showCalendar=true">
|
||||
<ion-icon src="assets/images/icons-collaps-down.svg" ></ion-icon>
|
||||
</button >
|
||||
|
||||
@@ -147,7 +149,7 @@
|
||||
</ion-row>
|
||||
</ion-row>
|
||||
|
||||
<div class="pb-5 d-none d-md-flex" *ngIf="loggeduser.Profile == 'MDGPR'">
|
||||
<div class="d-none d-md-flex" *ngIf="loggeduser.Profile == 'MDGPR'">
|
||||
<div class="flex-grow-1 text-grey d-flex justify-center align-center">
|
||||
<div>Própria</div>
|
||||
</div>
|
||||
@@ -171,7 +173,7 @@
|
||||
|
||||
<!-- Timeline -->
|
||||
<div class="height-100">
|
||||
<div class="timeline-container height-100 d-flex pt-20 pa-20 filter-{{segment}}" >
|
||||
<div class="timeline-container height-100 d-flex pt-20 pl-20 pl-20 filter-{{segment}}" >
|
||||
|
||||
<!-- <div [ngSwitch]="view" class="ss-timeline timeline-mobile flex-grow-1 d-md-none">
|
||||
<mwl-calendar-day-view
|
||||
@@ -213,18 +215,18 @@
|
||||
</div>
|
||||
</div> -->
|
||||
|
||||
<div class="ss-timeline timeline-mobile flex-grow-1 d-md-none text-black height-100 width-100 overflow-y-auto" >
|
||||
<div class="ss-timeline timeline-mobile flex-grow-1 d-md-none text-black height-100 width-100 overflow-y-auto" >
|
||||
<div *ngFor="let events of TimelineMDList | keyvalue;" >
|
||||
|
||||
<div *ngIf="CalendarCurrentDay <= events.key">
|
||||
<div class="EventListBox-container" *ngIf="CalendarCurrentDay <= events.key">
|
||||
<div class="day mt-10">
|
||||
{{ TimelineDayEvent(events.key)}}
|
||||
</div>
|
||||
|
||||
<div *ngFor="let event of events.value" >
|
||||
|
||||
<div *ngFor="let event of events.value" class="EventListBox">
|
||||
|
||||
<div class="d-flex content-{{event.profile}}-{{event.event.CalendarName}} mt-10 cursor-pointer width-100 " (click)="eventClicked(event)" >
|
||||
<div class="d-flex content-{{event.profile}}-{{event.event.CalendarName}} mt-10 cursor-pointer width-100 " (click)="eventClicked(event)"
|
||||
*ngIf="viewEventMonth <= dateMonth(event)">
|
||||
<div class="schedule-time" *ngIf="!event.event.IsAllDayEvent">
|
||||
|
||||
<div *ngIf="!event.endMany && !event.middle" class="time-start">{{event.event.StartDate | date: 'HH:mm'}}</div>
|
||||
@@ -252,22 +254,20 @@
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="fs-timeline flex-grow-1 d-none d-md-block d-md-block text-black pr-20 width-100 height-100 overflow-y-auto" *ngIf="loggeduser.Profile == 'MDGPR'">
|
||||
<div class="fs-timeline flex-grow-1 d-none d-md-block d-md-block text-black pr-20 width-100 height-100 overflow-y-auto" *ngIf="loggeduser.Profile == 'MDGPR'">
|
||||
<div *ngFor="let events of TimelineMDList | keyvalue;" >
|
||||
|
||||
<div *ngIf="CalendarCurrentDay <= events.key">
|
||||
<div class="day mt-10">
|
||||
<div class="EventListBox-container" *ngIf="CalendarCurrentDay <= events.key">
|
||||
<div class="day EventListBox-day mt-10">
|
||||
{{ TimelineDayEvent(events.key)}}
|
||||
</div>
|
||||
|
||||
<div *ngFor="let event of events.value" >
|
||||
|
||||
<div class="d-flex content-mdgpr-{{event.event.CalendarName}} mt-10 cursor-pointer" (click)="eventClicked(event)">
|
||||
|
||||
<div *ngFor="let event of events.value" class="EventListBox" >
|
||||
<div class="d-flex content-mdgpr-{{event.event.CalendarName}} mt-10 cursor-pointer" (click)="eventClicked(event)"
|
||||
*ngIf="viewEventMonth <= dateMonth(event)">
|
||||
|
||||
<div class="schedule-time" *ngIf="!event.event.IsAllDayEvent">
|
||||
<div *ngIf="!event.endMany && !event.middle" class="time-start">{{event.event.StartDate | date: 'HH:mm'}}</div>
|
||||
<div *ngIf="event.endMany && !event.middle" class="time-start">--</div>
|
||||
@@ -290,25 +290,26 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="sd-timeline flex-grow-1 d-none d-md-block timeline-md text-black pl-20 width-100 height-100 overflow-y-auto" >
|
||||
<div class="sd-timeline flex-grow-1 d-none d-md-block timeline-md text-black pl-20 pr-20 width-100 height-100 overflow-y-auto" >
|
||||
<div *ngFor="let events of TimelinePRList | keyvalue;">
|
||||
|
||||
<div *ngIf="CalendarCurrentDay <= events.key">
|
||||
<div class="EventListBox-container" *ngIf="CalendarCurrentDay <= events.key">
|
||||
|
||||
<div class="day mt-10">
|
||||
{{ TimelineDayEvent(events.key)}}
|
||||
</div>
|
||||
|
||||
<div *ngFor="let event of events.value" >
|
||||
<div *ngFor="let event of events.value" class="EventListBox">
|
||||
|
||||
<div class="d-flex content-pr-{{event.event.CalendarName}} mt-10 cursor-pointer" (click)="eventClicked(event)">
|
||||
<div class="d-flex content-pr-{{event.event.CalendarName}} mt-10 cursor-pointer" (click)="eventClicked(event)"
|
||||
*ngIf="viewEventMonth <= dateMonth(event)">
|
||||
|
||||
<div class="schedule-time" *ngIf="!event.event.IsAllDayEvent">
|
||||
<div *ngIf="!event.endMany && !event.middle" class="time-start">{{event.event.StartDate | date: 'HH:mm'}}</div>
|
||||
<div *ngIf="event.endMany && !event.middle" class="time-start">--</div>
|
||||
|
||||
@@ -7,19 +7,6 @@
|
||||
display: table-cell;
|
||||
}
|
||||
|
||||
ion-slide{
|
||||
td{
|
||||
div {
|
||||
padding-left: 7px;
|
||||
border-radius: 28px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
text-align: center;
|
||||
height: 25px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
:host ::ng-deep {
|
||||
.monthview-primary-with-event {
|
||||
@@ -388,11 +375,13 @@ td.monthview-primary-with-event {
|
||||
}
|
||||
|
||||
|
||||
.custom-calendar-header{
|
||||
.custom-calendar-header {
|
||||
width: 100%;
|
||||
margin-bottom: 10px;
|
||||
thead{
|
||||
th{
|
||||
thead {
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
th {
|
||||
font-family: Roboto;
|
||||
font-size: 15px;
|
||||
color: rgba(52, 72, 94, 0.54);
|
||||
@@ -403,8 +392,6 @@ td.monthview-primary-with-event {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
.currente-date-timelien{
|
||||
padding: 10px 20px;
|
||||
.timeline-date{
|
||||
@@ -706,7 +693,7 @@ app-approve-event{
|
||||
|
||||
|
||||
.fs-timeline {
|
||||
border-right: 2px solid #909090;
|
||||
border-right: 1px solid #909090;
|
||||
}
|
||||
|
||||
|
||||
@@ -721,4 +708,5 @@ app-approve-event{
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+269
-315
@@ -162,7 +162,7 @@ export class AgendaPage implements OnInit {
|
||||
|
||||
this.loggeduser = authService.ValidatedUser;
|
||||
|
||||
this.calendarHeight = "333px";
|
||||
this.calendarHeight = "317px";
|
||||
this.showCalendar = true;
|
||||
this.timelineDate = momentG(new Date(),'dd MMMM yyyy');
|
||||
|
||||
@@ -173,8 +173,7 @@ export class AgendaPage implements OnInit {
|
||||
if(this.loggeduser.Profile == 'MDGPR') {
|
||||
this.mobileComponent.showEventList = true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
@@ -194,7 +193,6 @@ export class AgendaPage implements OnInit {
|
||||
window.onresize = (event) => {
|
||||
// if not table remove all component
|
||||
if( window.innerWidth <= 1024){
|
||||
console.log('mobile')
|
||||
this.cloneAllmobileComponent();
|
||||
}
|
||||
};
|
||||
@@ -204,12 +202,10 @@ export class AgendaPage implements OnInit {
|
||||
//Go to the next view of the calendar month/week/day
|
||||
next() {
|
||||
this.myCal.slideNext();
|
||||
this.centralizeTimeline(500);
|
||||
}
|
||||
//Go to the previous view of the calendar
|
||||
back(){
|
||||
this.myCal.slidePrev();
|
||||
this.centralizeTimeline(500);
|
||||
}
|
||||
//Shows the title of your view
|
||||
onViewTitleChanged(title){
|
||||
@@ -254,7 +250,6 @@ export class AgendaPage implements OnInit {
|
||||
//Show information of the event
|
||||
async onEventSelected(ev: { event: Event}){
|
||||
/* this.viewEventDetail(ev.event.EventId); */
|
||||
console.log('DOVE');
|
||||
|
||||
this.router.navigate(["/home/agenda", ev.event.EventId, 'agenda']);
|
||||
}
|
||||
@@ -266,8 +261,6 @@ export class AgendaPage implements OnInit {
|
||||
// calendar change date
|
||||
this.eventSelectedDate = new Date(ev);
|
||||
|
||||
this.centralizeTimeline(500);
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
};
|
||||
|
||||
// changedate
|
||||
@@ -278,7 +271,7 @@ export class AgendaPage implements OnInit {
|
||||
}
|
||||
|
||||
onTimeSelected = (ev: { selectedTime: Date, events: any[] }) => {
|
||||
console.log('Selected time: ' + ev.selectedTime + ', hasEvents: ' + (ev.events !== undefined && ev.events.length !== 0));
|
||||
// console.log('Selected time: ' + ev.selectedTime + ', hasEvents: ' + (ev.events !== undefined && ev.events.length !== 0));
|
||||
this.eventSelectedDate2 = ev.selectedTime;
|
||||
}
|
||||
|
||||
@@ -290,7 +283,7 @@ export class AgendaPage implements OnInit {
|
||||
}
|
||||
|
||||
// for calendar
|
||||
currentDayEventDisplayBorder(day: any, id: any){
|
||||
currentDayEventDisplayBorder(day: any, id: any) {
|
||||
|
||||
const events = day[id].events;
|
||||
|
||||
@@ -318,36 +311,13 @@ export class AgendaPage implements OnInit {
|
||||
}
|
||||
|
||||
// for timeline
|
||||
centralizeTimeline(timeout: number) {
|
||||
// auto scroll timeline
|
||||
|
||||
if(!this.showLoader) {
|
||||
setTimeout(() => {
|
||||
const timelineMarker = document.querySelector('.cal-current-time-marker');
|
||||
const scrollContainer = document.querySelector('.timeline-wrapper');
|
||||
|
||||
try {
|
||||
scrollContainer.scroll({
|
||||
top: parseInt(timelineMarker['style']['top'].replace('px','')) - ((scrollContainer['offsetHeight']/2) - 60),
|
||||
left: 0,
|
||||
behavior: 'smooth'
|
||||
})
|
||||
} catch (error) {
|
||||
//
|
||||
if(!this.showLoader) {
|
||||
//this.selectFirstEventOfTheDay();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}, timeout);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
get CalendarCurrentDay ():any {
|
||||
|
||||
console.log(this.viewDate.getDate(), '0_0')
|
||||
/* console.log(this.viewDate.getDate(), '0_0') */
|
||||
// console.log(this.viewDate.getDate(), '0_0')
|
||||
|
||||
return this.viewDate.getDate()
|
||||
}
|
||||
|
||||
@@ -393,75 +363,6 @@ export class AgendaPage implements OnInit {
|
||||
`
|
||||
}
|
||||
|
||||
// for timeline
|
||||
timelineBoxCorrectHeight(timeout){
|
||||
|
||||
setTimeout(()=>{
|
||||
|
||||
if(window.innerWidth <= 1024){
|
||||
this.events.forEach((el:any, eventIndex)=>{
|
||||
|
||||
const startEvent = new Date(el.startTime| el.start);
|
||||
const endEvent = new Date(el.endTime | el.end);
|
||||
|
||||
var minutes = ((endEvent.getTime() - startEvent.getTime()) / 1000) / 60;
|
||||
// const top = (startEvent.getTime() - (new Date(2020, 1, 3)).getTime()) /60;
|
||||
|
||||
document.querySelectorAll('.ss-timeline .timeline-box').forEach(ele => {
|
||||
|
||||
if(ele.className.indexOf(`timeline-box-event-${eventIndex}`)>=0){
|
||||
|
||||
ele.setAttribute('style',`height:${minutes}px`);
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
} else {
|
||||
this.TimelineMD.forEach((el:any, eventIndex)=>{
|
||||
|
||||
const startEvent = new Date(el.startTime| el.start);
|
||||
const endEvent = new Date(el.endTime | el.end);
|
||||
|
||||
var minutes = ((endEvent.getTime() - startEvent.getTime()) / 1000) / 60;
|
||||
// const top = (startEvent.getTime() - (new Date(2020, 1, 3)).getTime()) /60;
|
||||
|
||||
document.querySelectorAll('.fs-timeline .timeline-box').forEach(ele => {
|
||||
|
||||
if(ele.className.indexOf(`timeline-box-event-${eventIndex}`)>=0){
|
||||
|
||||
ele.setAttribute('style',`height:${minutes}px`);
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
},timeout)
|
||||
|
||||
setTimeout(()=>{
|
||||
this.TimelinePR.forEach((el, eventIndex)=>{
|
||||
|
||||
const startEvent = new Date(el['startTime']);
|
||||
const endEvent = new Date(el['endTime']);
|
||||
|
||||
var minutes = ((endEvent.getTime() - startEvent.getTime()) / 1000) / 60;
|
||||
const top = (startEvent.getTime() - (new Date(2020, 1, 3)).getTime()) /60;
|
||||
|
||||
document.querySelectorAll('.sd-timeline .timeline-box').forEach(ele => {
|
||||
|
||||
if(ele.className.indexOf(`timeline-box-event-${eventIndex}`)>=0){
|
||||
ele.setAttribute('style',`height:${minutes}px`);
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
},timeout)
|
||||
}
|
||||
|
||||
// for timeline
|
||||
timelineFilter(calendarName, eventsList, profile){
|
||||
@@ -515,7 +416,7 @@ export class AgendaPage implements OnInit {
|
||||
return ((new Date(this.timelineDate)).getDate()).toString().padStart(2,'0')
|
||||
}
|
||||
|
||||
async loadRangeEvents(startTime: Date, endTime: Date){
|
||||
loadRangeEvents(startTime: Date, endTime: Date){
|
||||
|
||||
this.eventSelectedDate = new Date(startTime);
|
||||
|
||||
@@ -529,16 +430,17 @@ export class AgendaPage implements OnInit {
|
||||
case "Combinado":
|
||||
//Inicializa o array eventSource
|
||||
//this.eventSource=[];
|
||||
|
||||
|
||||
if(this.profile == "mdgpr" && this.loggeduser.Profile == 'MDGPR' ) {
|
||||
|
||||
let mdOficialEvents = await this.eventService.getAllPrOficialEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).toPromise();
|
||||
let mdPessoalEvents = await this.eventService.getAllPrPessoalEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).toPromise();
|
||||
this.eventService.getAllMdEvents( momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59') ).then(
|
||||
|
||||
(response:any) => {
|
||||
|
||||
// calendar
|
||||
this.eventSource=[];
|
||||
|
||||
this.eventsList = mdOficialEvents.concat(mdPessoalEvents);
|
||||
this.eventsList = response;
|
||||
// loop
|
||||
this.eventsList.forEach((element, eventIndex) => {
|
||||
|
||||
@@ -571,19 +473,18 @@ export class AgendaPage implements OnInit {
|
||||
this.showTimeline = true;
|
||||
|
||||
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
this.centralizeTimeline(500);
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
else {
|
||||
let prOficialEvents= await this.eventService.getAllPrOficialEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).toPromise();
|
||||
let prPessoalEvents= await this.eventService.getAllPrPessoalEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).toPromise();
|
||||
else if(this.profile == "pr" && this.loggeduser.Profile == 'MDGPR'){
|
||||
console.log('HERE PR');
|
||||
this.eventService.getAllSharedEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then(
|
||||
(response:any) => {
|
||||
|
||||
// calendar
|
||||
this.eventSource=[];
|
||||
|
||||
this.eventsList = prOficialEvents.concat(prPessoalEvents);
|
||||
this.eventsList = response;
|
||||
|
||||
// calendar
|
||||
this.eventsList.forEach((element, eventIndex) => {
|
||||
@@ -614,9 +515,53 @@ export class AgendaPage implements OnInit {
|
||||
this.showLoader = false;
|
||||
this.showTimeline = true;
|
||||
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
this.centralizeTimeline(500);
|
||||
|
||||
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
else {
|
||||
this.eventService.getAllPrEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then(
|
||||
(response:any) => {
|
||||
|
||||
// calendar
|
||||
this.eventSource=[];
|
||||
|
||||
this.eventsList = response;
|
||||
|
||||
// calendar
|
||||
this.eventsList.forEach((element, eventIndex) => {
|
||||
this.eventSource.push({
|
||||
title: element.Subject,
|
||||
startTime: new Date(element.StartDate),
|
||||
endTime: new Date(element.EndDate),
|
||||
allDay: false,
|
||||
event: element,
|
||||
calendarName: element.CalendarName,
|
||||
profile: 'pr',
|
||||
id: element.EventId,
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
const list = this.timelineFilter(this.timelineFilterState, this.eventsList, 'pr');
|
||||
|
||||
this.TimelineMDList = this.eventListBox(list)
|
||||
|
||||
this.events = list;
|
||||
|
||||
this.TimelinePR = list;
|
||||
|
||||
this.myCal.update();
|
||||
this.myCal.loadEvents();
|
||||
|
||||
this.showLoader = false;
|
||||
this.showTimeline = true;
|
||||
|
||||
|
||||
|
||||
});
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -624,7 +569,7 @@ export class AgendaPage implements OnInit {
|
||||
//Inicializa o array eventSource
|
||||
|
||||
if(this.profile == "mdgpr" && this.loggeduser.Profile == 'MDGPR') {
|
||||
this.eventService.getAllMdPessoalEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).subscribe(response => {
|
||||
this.eventService.getAllMdEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then((response:any) => {
|
||||
|
||||
this.eventSource=[];
|
||||
this.eventsListPessoal= [];
|
||||
@@ -659,17 +604,14 @@ export class AgendaPage implements OnInit {
|
||||
|
||||
this.showLoader = false;
|
||||
this.showTimeline = true;
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
this.centralizeTimeline(500);
|
||||
});
|
||||
|
||||
}
|
||||
else{
|
||||
let prPessoalEvents= await this.eventService.getAllPrPessoalEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).toPromise();
|
||||
|
||||
this.eventService.getAllPrEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then((response:any) => {
|
||||
this.eventSource=[];
|
||||
|
||||
this.eventsListPessoal = prPessoalEvents.filter(data => data.CalendarName == "Pessoal");
|
||||
this.eventsListPessoal = response.filter(data => data.CalendarName == "Pessoal");
|
||||
this.eventsListPessoal.forEach(element => {
|
||||
this.eventSource.push({
|
||||
title: element.Subject,
|
||||
@@ -697,9 +639,7 @@ export class AgendaPage implements OnInit {
|
||||
this.showLoader = false;
|
||||
this.showTimeline = true;
|
||||
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
this.centralizeTimeline(500);
|
||||
|
||||
});
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -709,7 +649,7 @@ export class AgendaPage implements OnInit {
|
||||
this.eventsListOficial = [];
|
||||
|
||||
if(this.profile == "mdgpr" && this.loggeduser.Profile == 'MDGPR') {
|
||||
this.eventService.getAllMdOficialEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).subscribe(res => {
|
||||
this.eventService.getAllMdEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then((res:any) => {
|
||||
this.eventSource=[];
|
||||
this.eventsListOficial = res.filter(data => data.CalendarName == "Oficial");
|
||||
|
||||
@@ -739,13 +679,11 @@ export class AgendaPage implements OnInit {
|
||||
this.showLoader = false;
|
||||
this.showTimeline = true;
|
||||
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
this.centralizeTimeline(500);
|
||||
});
|
||||
} else {
|
||||
let prOficialEvents= await this.eventService.getAllPrOficialEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).toPromise();
|
||||
this.eventService.getAllPrEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then((res:any) => {
|
||||
this.eventSource=[];
|
||||
this.eventsListOficial = prOficialEvents.filter(data => data.CalendarName == "Oficial");
|
||||
this.eventsListOficial = res.filter(data => data.CalendarName == "Oficial");
|
||||
this.eventsListOficial.forEach(element => {
|
||||
this.eventSource.push({
|
||||
title: element.Subject,
|
||||
@@ -773,8 +711,7 @@ export class AgendaPage implements OnInit {
|
||||
this.showLoader = false;
|
||||
this.showTimeline = true;
|
||||
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
this.centralizeTimeline(500);
|
||||
});
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -788,16 +725,17 @@ export class AgendaPage implements OnInit {
|
||||
let counter = 0;
|
||||
|
||||
if(this.loggeduser.Profile == 'MDGPR') {
|
||||
|
||||
let mdOficialEvents = await this.eventService.getAllPrOficialEvents( momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59') ).toPromise();
|
||||
let mdPessoalEvents = await this.eventService.getAllPrPessoalEvents( momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59') ).toPromise();
|
||||
|
||||
console.log('MDGPR');
|
||||
|
||||
this.eventService.getAllMdEvents( momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59') ).then( (response:any) => {
|
||||
|
||||
|
||||
if(this.segment == 'Oficial') {
|
||||
this.eventsList = mdOficialEvents;
|
||||
this.eventsList = response.filter(data => data.CalendarName == "Oficial");
|
||||
} else if (this.segment == 'Pessoal') {
|
||||
this.eventsList = mdPessoalEvents;
|
||||
this.eventsList = response.filter(data => data.CalendarName == "Pessoal");
|
||||
} else {
|
||||
this.eventsList = mdOficialEvents.concat(mdPessoalEvents);
|
||||
this.eventsList = response;
|
||||
}
|
||||
|
||||
this.eventSource= this.eventSource.filter(e => e.profile != 'md');
|
||||
@@ -821,8 +759,6 @@ export class AgendaPage implements OnInit {
|
||||
|
||||
const MDEventList = this.timelineFilter(this.timelineFilterState, this.eventsList, 'mdgpr');
|
||||
|
||||
|
||||
|
||||
this.TimelineMDList = this.eventListBox(MDEventList, 'md')
|
||||
|
||||
this.events = MDEventList;
|
||||
@@ -836,22 +772,72 @@ export class AgendaPage implements OnInit {
|
||||
counter++;
|
||||
if(counter==2){
|
||||
this.showLoader = false;
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
this.centralizeTimeline(500);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
let prOficialEvents= await this.eventService.getAllPrOficialEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).toPromise();
|
||||
let prPessoalEvents= await this.eventService.getAllPrPessoalEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).toPromise();
|
||||
this.eventService.getAllSharedEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then((response:any) => {
|
||||
|
||||
if(this.segment == 'Oficial') {
|
||||
this.eventsList = response.filter(data => data.CalendarName == "Oficial");
|
||||
} else if (this.segment == 'Pessoal') {
|
||||
this.eventsList = response.filter(data => data.CalendarName == "Pessoal");
|
||||
} else {
|
||||
this.eventsList = response;
|
||||
}
|
||||
|
||||
this.eventSource = this.eventSource.filter(e => e.profile != 'pr');
|
||||
|
||||
this.eventsList.forEach((element, eventIndex) => {
|
||||
|
||||
// calendar
|
||||
this.eventSource.push({
|
||||
index: eventIndex,
|
||||
title: element.Subject,
|
||||
startTime: new Date(element.StartDate),
|
||||
endTime: new Date(element.EndDate),
|
||||
allDay: false,
|
||||
event: element,
|
||||
calendarName: element.CalendarName,
|
||||
profile:'pr',
|
||||
id: element.EventId,
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
this.TimelinePR = this.timelineFilter(this.timelineFilterState, this.eventsList, 'pr');
|
||||
|
||||
|
||||
this.TimelinePRList = this.eventListBox(this.TimelinePR)
|
||||
|
||||
this.myCal.update();
|
||||
this.myCal.loadEvents();
|
||||
|
||||
this.showTimelinePR = true;
|
||||
|
||||
counter++;
|
||||
|
||||
if(counter==2 || this.loggeduser.Profile == 'PR') {
|
||||
this.showLoader = false;
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
}else{
|
||||
console.log('PR');
|
||||
|
||||
|
||||
this.eventService.getAllPrEvents(momentG(new Date(startTime),'yyyy-MM-dd HH:mm:ss'), momentG(new Date(endTime),'yyyy-MM-dd 23:59:59')).then((response:any) => {
|
||||
|
||||
if(this.segment == 'Oficial') {
|
||||
this.eventsList = prOficialEvents;
|
||||
this.eventsList = response.filter(data => data.CalendarName == "Oficial");
|
||||
} else if (this.segment == 'Pessoal') {
|
||||
this.eventsList = prPessoalEvents;
|
||||
this.eventsList = response.filter(data => data.CalendarName == "Pessoal");
|
||||
} else {
|
||||
this.eventsList = prOficialEvents.concat(prPessoalEvents);
|
||||
this.eventsList = response;
|
||||
}
|
||||
|
||||
this.eventSource = this.eventSource.filter(e => e.profile != 'pr');
|
||||
@@ -887,9 +873,11 @@ export class AgendaPage implements OnInit {
|
||||
|
||||
if(counter==2 || this.loggeduser.Profile == 'PR') {
|
||||
this.showLoader = false;
|
||||
this.timelineBoxCorrectHeight(500);
|
||||
this.centralizeTimeline(500);
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -899,193 +887,163 @@ export class AgendaPage implements OnInit {
|
||||
|
||||
list.forEach( (event:any)=> {
|
||||
|
||||
var startDate = new Date(event.start);
|
||||
var endDate = new Date(event.end);
|
||||
var startDate: any = new Date(event.start);
|
||||
var endDate: any = new Date(event.end);
|
||||
|
||||
const day = (((new Date (event.start)).getDate())).toString().padStart(2,'0')
|
||||
|
||||
event.manyDays = false
|
||||
|
||||
if ( (new Date (this.viewDate).getMonth()) == (new Date(event.start).getMonth()) ) {
|
||||
|
||||
if(!days.hasOwnProperty(day)) {
|
||||
days[day] = []
|
||||
}
|
||||
if(!days.hasOwnProperty(day)) {
|
||||
days[day] = []
|
||||
}
|
||||
|
||||
var Difference_In_Days = endDate.getDate() - startDate.getDate()
|
||||
// difference
|
||||
const diffTime = Math.abs(endDate - startDate);
|
||||
const diffDays = Math.ceil(diffTime / (1000 * 60 * 60 * 24));
|
||||
|
||||
if ( endDate.getTime() > startDate.getTime() && Difference_In_Days <= 50 && !event.event.IsAllDayEvent ) {
|
||||
if (Difference_In_Days >= 1) {
|
||||
if (diffDays <= 150 && !event.event.IsAllDayEvent ) {
|
||||
|
||||
if(nice == 'md') {
|
||||
console.log('md', event)
|
||||
}
|
||||
|
||||
const StartEvent = Object.assign({}, {
|
||||
title: event.title,
|
||||
start: event.start,
|
||||
end: event.end,
|
||||
color: event.color,
|
||||
id: event.id,
|
||||
index: event.index,
|
||||
profile: event.profile,
|
||||
CalendarName: event.CalendarName,
|
||||
event: {
|
||||
Subject: event.event.Subject,
|
||||
StartDate: event.event.StartDate,
|
||||
EndDate: event.event.EndDate,
|
||||
Location: event.event.Location,
|
||||
EventId: event.event.EventId,
|
||||
CalendarName: event.event.CalendarName
|
||||
},
|
||||
startMany: true,
|
||||
endMany: false,
|
||||
middle: false
|
||||
})
|
||||
|
||||
days[day].push(StartEvent)
|
||||
|
||||
|
||||
let i = 1;
|
||||
|
||||
while (startDate.getFullYear() != endDate.getFullYear() ||
|
||||
startDate.getMonth() != endDate.getMonth() ||
|
||||
startDate.getDate() != endDate.getDate()) {
|
||||
if (diffDays >= 1) {
|
||||
|
||||
const StartEvent = Object.assign({}, {
|
||||
title: event.title,
|
||||
start: event.start,
|
||||
end: event.end,
|
||||
color: event.color,
|
||||
id: event.id,
|
||||
index: event.index,
|
||||
profile: event.profile,
|
||||
CalendarName: event.CalendarName,
|
||||
event: {
|
||||
Subject: event.event.Subject,
|
||||
StartDate: event.event.StartDate,
|
||||
EndDate: event.event.EndDate,
|
||||
Location: event.event.Location,
|
||||
EventId: event.event.EventId,
|
||||
CalendarName: event.event.CalendarName
|
||||
},
|
||||
startMany: true,
|
||||
endMany: false,
|
||||
middle: false
|
||||
})
|
||||
|
||||
days[day].push(StartEvent)
|
||||
|
||||
let i = 1;
|
||||
|
||||
while (startDate.getFullYear() != endDate.getFullYear() ||
|
||||
startDate.getMonth() != endDate.getMonth() ||
|
||||
startDate.getDate() != endDate.getDate()) {
|
||||
|
||||
const newDate = startDate.setDate(startDate.getDate()+ i)
|
||||
const newDate = startDate.setDate(startDate.getDate()+ i)
|
||||
|
||||
let otherDays = (((new Date (newDate)).getDate())).toString().padStart(2,'0')
|
||||
|
||||
|
||||
event.other = true
|
||||
let otherDays = (((new Date (newDate)).getDate())).toString().padStart(2,'0')
|
||||
|
||||
event.start = newDate
|
||||
if(!days.hasOwnProperty(otherDays)) {
|
||||
event.other = true
|
||||
|
||||
event.start = newDate
|
||||
if(!days.hasOwnProperty(otherDays)) {
|
||||
|
||||
|
||||
days[otherDays] = []
|
||||
}
|
||||
|
||||
|
||||
if (!(startDate.getFullYear() != endDate.getFullYear() ||
|
||||
startDate.getMonth() != endDate.getMonth() ||
|
||||
startDate.getDate() != endDate.getDate())) {
|
||||
// last push
|
||||
|
||||
const EndEvent = Object.assign({}, {
|
||||
title: event.title,
|
||||
start: event.start,
|
||||
end: event.end,
|
||||
color: event.color,
|
||||
id: event.id,
|
||||
index: event.index,
|
||||
profile: event.profile,
|
||||
CalendarName: event.CalendarName,
|
||||
event: {
|
||||
Subject: event.event.Subject,
|
||||
StartDate: event.event.StartDate,
|
||||
EndDate: event.event.EndDate,
|
||||
Location: event.event.Location,
|
||||
EventId: event.event.EventId,
|
||||
CalendarName: event.event.CalendarName
|
||||
},
|
||||
Subject: event.Subject,
|
||||
startMany: false,
|
||||
endMany: true,
|
||||
middle: false
|
||||
})
|
||||
|
||||
days[otherDays].push(EndEvent)
|
||||
|
||||
} else {
|
||||
const EndEvent = Object.assign({}, {
|
||||
title: event.title,
|
||||
start: event.start,
|
||||
end: event.end,
|
||||
color: event.color,
|
||||
id: event.id,
|
||||
index: event.index,
|
||||
profile: event.profile,
|
||||
CalendarName: event.CalendarName,
|
||||
event: {
|
||||
Subject: event.event.Subject,
|
||||
StartDate: event.event.StartDate,
|
||||
EndDate: event.event.EndDate,
|
||||
Location: event.event.Location,
|
||||
EventId: event.event.EventId,
|
||||
CalendarName: event.event.CalendarName
|
||||
},
|
||||
Subject: event.Subject,
|
||||
startMany: false,
|
||||
endMany: true,
|
||||
middle: true
|
||||
})
|
||||
days[otherDays].push(EndEvent)
|
||||
}
|
||||
|
||||
|
||||
days[otherDays] = []
|
||||
}
|
||||
|
||||
if (!(startDate.getFullYear() != endDate.getFullYear() ||
|
||||
startDate.getMonth() != endDate.getMonth() ||
|
||||
startDate.getDate() != endDate.getDate())) {
|
||||
// last push
|
||||
|
||||
} else {
|
||||
days[day].push(event)
|
||||
const EndEvent = Object.assign({}, {
|
||||
title: event.title,
|
||||
start: event.start,
|
||||
end: event.end,
|
||||
color: event.color,
|
||||
id: event.id,
|
||||
index: event.index,
|
||||
profile: event.profile,
|
||||
CalendarName: event.CalendarName,
|
||||
event: {
|
||||
Subject: event.event.Subject,
|
||||
StartDate: event.event.StartDate,
|
||||
EndDate: event.event.EndDate,
|
||||
Location: event.event.Location,
|
||||
EventId: event.event.EventId,
|
||||
CalendarName: event.event.CalendarName
|
||||
},
|
||||
Subject: event.Subject,
|
||||
startMany: false,
|
||||
endMany: true,
|
||||
middle: false
|
||||
})
|
||||
|
||||
days[otherDays].push(EndEvent)
|
||||
|
||||
} else {
|
||||
const EndEvent = Object.assign({}, {
|
||||
title: event.title,
|
||||
start: event.start,
|
||||
end: event.end,
|
||||
color: event.color,
|
||||
id: event.id,
|
||||
index: event.index,
|
||||
profile: event.profile,
|
||||
CalendarName: event.CalendarName,
|
||||
event: {
|
||||
Subject: event.event.Subject,
|
||||
StartDate: event.event.StartDate,
|
||||
EndDate: event.event.EndDate,
|
||||
Location: event.event.Location,
|
||||
EventId: event.event.EventId,
|
||||
CalendarName: event.event.CalendarName
|
||||
},
|
||||
Subject: event.Subject,
|
||||
startMany: false,
|
||||
endMany: true,
|
||||
middle: true
|
||||
})
|
||||
days[otherDays].push(EndEvent)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
} else {
|
||||
days[day].push(event)
|
||||
|
||||
}
|
||||
} else {
|
||||
days[day].push(event)
|
||||
|
||||
}
|
||||
|
||||
|
||||
})
|
||||
|
||||
setTimeout(()=>{
|
||||
document.querySelectorAll('.EventListBox-container .EventListBox').forEach((e)=>{
|
||||
if(e.childElementCount == 0) {
|
||||
e.parentElement.style.display = 'none'
|
||||
} else {
|
||||
e.parentElement.style.display = 'block'
|
||||
}
|
||||
})
|
||||
}, 10)
|
||||
|
||||
return days
|
||||
}
|
||||
|
||||
get viewEventMonth () {
|
||||
return this.viewDate.getMonth()
|
||||
}
|
||||
|
||||
dateMonth(event: any) {
|
||||
return new Date(event.start).getMonth()
|
||||
}
|
||||
|
||||
eventListVisible(event) {
|
||||
return momentG(event,'MMMM yyyy') == momentG(this.calendar.currentDate, 'MMMM yyyy')
|
||||
}
|
||||
|
||||
log(event) {
|
||||
console.log(event)
|
||||
}
|
||||
|
||||
// for timeline select the first event in the timeline
|
||||
selectFirstEventOfTheDay(){
|
||||
|
||||
setTimeout(()=>{
|
||||
|
||||
|
||||
let sortedDate = this.eventSource.sort((a,b) =>{
|
||||
return (b.startTime) -(a.startTime);
|
||||
});
|
||||
|
||||
|
||||
let filterDate = sortedDate.filter((e) => {
|
||||
//console.log( e.startTime.toLocaleDateString('en-US'),' == ',this.eventSelectedDate.toLocaleDateString('en-US'));
|
||||
return e.startTime.toLocaleDateString('en-US') == this.eventSelectedDate.toLocaleDateString('en-US');
|
||||
});
|
||||
|
||||
// console.log('Event -- ',filterDate[filterDate.length - 1], filterDate['startTime']);
|
||||
|
||||
const firstEventStartHours = new Date(filterDate[filterDate.length - 1].startTime).getHours();
|
||||
|
||||
// console.log('firstEventStartHours-- ', firstEventStartHours)
|
||||
|
||||
if(firstEventStartHours) {
|
||||
const scrollContainer = document.querySelector('.timeline-wrapper');
|
||||
|
||||
scrollContainer.scroll({
|
||||
top: firstEventStartHours*60,
|
||||
left: 0,
|
||||
behavior: 'smooth'
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
}, 500);
|
||||
|
||||
}
|
||||
|
||||
actions(){}
|
||||
|
||||
@@ -1103,19 +1061,14 @@ export class AgendaPage implements OnInit {
|
||||
changeProfile() {
|
||||
|
||||
if(this.profile == "mdgpr"){
|
||||
console.log('pr');
|
||||
this.profile ="pr";
|
||||
this.loadRangeEvents(this.rangeStartDate, this.rangeEndDate);
|
||||
}
|
||||
else{
|
||||
console.log('mdgpr');
|
||||
this.profile ="mdgpr";
|
||||
this.loadRangeEvents(this.rangeStartDate, this.rangeEndDate);
|
||||
}
|
||||
|
||||
// change header profile picture
|
||||
// window['header'](this.profile);
|
||||
|
||||
}
|
||||
|
||||
async openAddEvent() {
|
||||
@@ -1359,6 +1312,7 @@ export class AgendaPage implements OnInit {
|
||||
} else {
|
||||
this.timelineFilterState = segments
|
||||
}
|
||||
this.showTimelineFilterState = false;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -177,6 +177,17 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="middle-content">
|
||||
<div *ngIf="postEvent.Body.Text">
|
||||
<h5>Detalhes</h5>
|
||||
<ion-item lines="none" class="ion-no-margin ion-no-padding">
|
||||
<ion-textarea [(ngModel)]="postEvent.Body.Text" placeholder="Detalhes" ></ion-textarea>
|
||||
</ion-item>
|
||||
<div class="line"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="d-flex container-div width-100 ion-item-container-no-border" >
|
||||
<ion-label (click)="getDoc()" class="cursor-pointer">
|
||||
<div class="attach-icon">
|
||||
|
||||
@@ -241,72 +241,4 @@ export class EditEventPage implements OnInit {
|
||||
});
|
||||
}
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
|
||||
var notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
<p class="message d-flex align-center">
|
||||
<ion-icon slot="end" class="title-icon pr-10" src="/assets/images/nofitication-success.svg"></ion-icon>
|
||||
<p class="text">{{ message }}</p>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
`
|
||||
|
||||
document.body.append(notification)
|
||||
notification.querySelector('.text').innerHTML = message || 'Processo efetuado'
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},7000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -9,6 +9,6 @@
|
||||
<button class="btn-ok" shape="round" (click)="approveTask()">Aprovar</button>
|
||||
<div class="solid"></div>
|
||||
<button class="btn-cancel" shape="round" (click)="editTask()">Editar</button>
|
||||
<button class="btn-delete" shape="round" (click)="deleteTask()">Rejeitar</button>
|
||||
<button class="btn-delete" shape="round" (click)="rejeitar()">Rejeitar</button>
|
||||
</div>
|
||||
</ion-content>
|
||||
|
||||
@@ -35,44 +35,53 @@ export class EventActionsPopoverPage implements OnInit {
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
goBack(){
|
||||
this.closePopover();
|
||||
this.router.navigate(['/home/gabinete-digital/event-list']);
|
||||
}
|
||||
|
||||
closePopover(){
|
||||
this.popoverController.dismiss();
|
||||
}
|
||||
|
||||
approveTask() {
|
||||
let body = { "serialNumber": this.serialNumber, "action": "Aprovar" }
|
||||
console.log(body);
|
||||
|
||||
|
||||
|
||||
try {
|
||||
this.processes.PostTaskAction(body).toPromise()
|
||||
this.router.navigate(['/home/gabinete-digital/event-list']);
|
||||
this.modalController.dismiss(null);
|
||||
this.toastService.successMessage()
|
||||
this.toastService.successMessage();
|
||||
this.goBack();
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
emendarTask() {
|
||||
|
||||
let body = { "serialNumber": this.serialNumber, "action": "Rejeitar" }
|
||||
console.log(body);
|
||||
|
||||
|
||||
try {
|
||||
this.processes.PostTaskAction(body).toPromise()
|
||||
this.router.navigate(['/home/gabinete-digital/event-list']);
|
||||
this.modalController.dismiss(null);
|
||||
this.toastService.successMessage()
|
||||
this.processes.PostTaskAction(body).toPromise();
|
||||
this.toastService.successMessage();
|
||||
this.goBack();
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
deleteTask(){
|
||||
|
||||
async rejeitar(){
|
||||
let body = { "serialNumber": this.serialNumber, "action": "Rejeitar" }
|
||||
console.log(body);
|
||||
try {
|
||||
this.processes.PostTaskAction(body).toPromise();
|
||||
await this.toastService.successMessage('Processo rejeitado');
|
||||
this.goBack();
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
}
|
||||
|
||||
async editTask() {
|
||||
console.log(this.serialNumber);
|
||||
console.log(this.instanceId);
|
||||
@@ -93,73 +102,4 @@ export class EventActionsPopoverPage implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
var notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
<p class="message d-flex align-center">
|
||||
<ion-icon slot="end" class="title-icon pr-10" src="/assets/images/nofitication-success.svg"></ion-icon>
|
||||
<p class="text">{{ message }}</p>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
`
|
||||
|
||||
document.body.append(notification)
|
||||
notification.querySelector('.text').innerHTML = message || 'Processo efetuado'
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},7000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@ import { NewEventPage } from './new-event.page';
|
||||
CommonModule,
|
||||
FormsModule,
|
||||
IonicModule,
|
||||
NewEventPageRoutingModule
|
||||
NewEventPageRoutingModule,
|
||||
],
|
||||
declarations: [NewEventPage]
|
||||
})
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
|
||||
<ion-content>
|
||||
<div class="main-content">
|
||||
<!-- <input type="text" ngbDatepicker #d="ngbDatepicker"/> -->
|
||||
|
||||
<div class="ion-item-container">
|
||||
<ion-input placeholder="Assunto" [(ngModel)]="postEvent.Subject"></ion-input>
|
||||
</div>
|
||||
|
||||
@@ -4,7 +4,9 @@ import { EventAttachment } from 'src/app/models/attachment.model';
|
||||
import { EventBody } from 'src/app/models/eventbody.model';
|
||||
import { EventPerson } from 'src/app/models/eventperson.model';
|
||||
import { SearchDocument } from 'src/app/models/search-document';
|
||||
import { User } from 'src/app/models/user.model';
|
||||
import { AttachmentsService } from 'src/app/services/attachments.service';
|
||||
import { AuthService } from 'src/app/services/auth.service';
|
||||
import { EventsService } from 'src/app/services/events.service';
|
||||
import { ToastService } from 'src/app/services/toast.service';
|
||||
import { BadRequestPage } from 'src/app/shared/popover/bad-request/bad-request.page';
|
||||
@@ -36,6 +38,8 @@ export class NewEventPage implements OnInit {
|
||||
|
||||
documents:SearchDocument[] = [];
|
||||
|
||||
loggeduser: User;
|
||||
|
||||
constructor(
|
||||
private modalController: ModalController,
|
||||
private navParams: NavParams,
|
||||
@@ -43,11 +47,13 @@ export class NewEventPage implements OnInit {
|
||||
private attachmentsService: AttachmentsService,
|
||||
private animationController: AnimationController,
|
||||
private toastService: ToastService,
|
||||
userService: AuthService,
|
||||
) {
|
||||
this.loggeduser = userService.ValidatedUser;
|
||||
this.postEvent = new Event();
|
||||
this.eventBody = { BodyType : "1", Text : ""};
|
||||
this.postEvent.Body = this.eventBody;
|
||||
this.profile = this.navParams.get('profile');
|
||||
/* this.profile = this.navParams.get('profile'); */
|
||||
|
||||
this.selectedSegment = this.navParams.get('segment');
|
||||
this.selectedDate = this.navParams.get('eventSelectedDate');
|
||||
@@ -126,14 +132,20 @@ export class NewEventPage implements OnInit {
|
||||
this.postEvent.HasAttachments = true;
|
||||
}
|
||||
|
||||
let eventId: string;
|
||||
let eventId: any;
|
||||
|
||||
try {
|
||||
|
||||
if(this.profile=='mdgpr') {
|
||||
if(this.loggeduser.Profile == 'MDGPR') {
|
||||
console.log(this.loggeduser.Profile);
|
||||
|
||||
eventId = await this.eventService.postEventMd(this.postEvent, this.postEvent.CalendarName).toPromise();
|
||||
console.log(eventId);
|
||||
|
||||
}
|
||||
else if(this.profile=='pr'){
|
||||
else if(this.loggeduser.Profile == 'PR'){
|
||||
console.log(this.loggeduser.Profile);
|
||||
|
||||
eventId = await this.eventService.postEventPr(this.postEvent, this.postEvent.CalendarName).toPromise();
|
||||
}
|
||||
|
||||
@@ -170,74 +182,6 @@ export class NewEventPage implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
var notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
<p class="message d-flex align-center">
|
||||
<ion-icon slot="end" class="title-icon pr-10" src="/assets/images/nofitication-success.svg"></ion-icon>
|
||||
<p class="text">{{ message }}</p>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
`
|
||||
|
||||
document.body.append(notification)
|
||||
notification.querySelector('.text').innerHTML = message || 'Processo efetuado'
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},7000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
async openAttendees() {
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
<button class="btn-no-color" (click)="openNewGroupPage()">
|
||||
<ion-icon slot="end" src="assets/images/icons-chat-new-group.svg" ></ion-icon>
|
||||
</button>
|
||||
<button class="btn-no-color" (click)="doRefresh()">
|
||||
<button *ngIf="hideRefreshBtn" class="btn-no-color" (click)="doRefresh()">
|
||||
<ion-icon class="title-icon" name="reload-circle"></ion-icon>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -91,6 +91,7 @@ export class ChatPage implements OnInit {
|
||||
|
||||
/* Fim websockets variables*/
|
||||
loggedUserChat:any;
|
||||
hideRefreshBtn = true;
|
||||
|
||||
constructor(
|
||||
private http:HttpClient,
|
||||
@@ -120,7 +121,25 @@ export class ChatPage implements OnInit {
|
||||
//this.sendMsg();
|
||||
|
||||
/* Fim websocket functions */
|
||||
this.hideRefreshButton();
|
||||
}
|
||||
|
||||
hideRefreshButton(){
|
||||
window.onresize = (event) => {
|
||||
if( window.innerWidth < 801) {
|
||||
this.hideRefreshBtn = false;
|
||||
}
|
||||
else{
|
||||
this.hideRefreshBtn = true;
|
||||
}
|
||||
}
|
||||
if(window.innerWidth < 801){
|
||||
console.log('YASS');
|
||||
this.hideRefreshBtn = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
loadMessage(){
|
||||
this.chatService.messages.subscribe(msg => {
|
||||
console.log("Response from websocket: " + msg);
|
||||
|
||||
@@ -184,6 +184,9 @@ export class EventDetailModalPage implements OnInit {
|
||||
this.attachamentsService.getAttachmentsById(this.pageId).subscribe(res => {
|
||||
console.log(res);
|
||||
|
||||
},(error) => {
|
||||
console.log(error);
|
||||
|
||||
});
|
||||
}
|
||||
async viewDocument(documenturl:string)
|
||||
|
||||
@@ -123,13 +123,48 @@ export class EventsPage implements OnInit {
|
||||
let start = date.getFullYear()+"-"+ date.getMonth()+"-"+date.getDate()+" "+date.getHours()+":"+date.getMinutes()+ ":"+date.getSeconds();
|
||||
let end = date.getFullYear()+"-"+ date.getMonth()+"-"+date.getDate()+" 23:59:59";
|
||||
|
||||
switch (this.segment)
|
||||
|
||||
if(this.loggeduser.Profile == 'MDGPR'){
|
||||
|
||||
let mdOficialEvents = await this.eventService.getAllMdOficialEvents(start, end).toPromise();
|
||||
let mdPessoalEvents = await this.eventService.getAllMdPessoalEvents(start, end).toPromise();
|
||||
|
||||
this.eventsList = mdOficialEvents.concat(mdPessoalEvents);
|
||||
|
||||
if(this.eventsList.length > 0){
|
||||
this.currentEvent = this.eventsList[0].Subject;
|
||||
this.currentHoursMinutes = this.eventsList[0].StartDate;
|
||||
}
|
||||
|
||||
this.totalEvent = this.eventsList.length;
|
||||
this.showLoader = false;
|
||||
|
||||
}
|
||||
else{
|
||||
|
||||
let prOficialEvents= await this.eventService.getAllPrOficialEvents(start, end).toPromise();
|
||||
let prPessoalEvents= await this.eventService.getAllPrPessoalEvents(start, end).toPromise();
|
||||
this.eventsList = prOficialEvents.concat(prPessoalEvents);
|
||||
console.log(this.eventsList);
|
||||
|
||||
if(this.eventsList.length > 0){
|
||||
this.currentEvent = this.eventsList[0].Subject;
|
||||
this.currentHoursMinutes = this.eventsList[0].StartDate;
|
||||
}
|
||||
|
||||
this.totalEvent = this.eventsList.length;
|
||||
this.showLoader = false;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/* switch (this.segment)
|
||||
{
|
||||
case "Combinada":
|
||||
if(this.loggeduser.Profile == 'MDGPR'){
|
||||
|
||||
let mdOficialEvents = await this.eventService.getAllPrOficialEvents(start, end).toPromise();
|
||||
let mdPessoalEvents = await this.eventService.getAllPrPessoalEvents(start, end).toPromise();
|
||||
let mdOficialEvents = await this.eventService.getAllMdOficialEvents(start, end).toPromise();
|
||||
let mdPessoalEvents = await this.eventService.getAllMdPessoalEvents(start, end).toPromise();
|
||||
|
||||
this.eventsList = mdOficialEvents.concat(mdPessoalEvents);
|
||||
|
||||
@@ -190,7 +225,7 @@ export class EventsPage implements OnInit {
|
||||
});
|
||||
}
|
||||
break;
|
||||
}
|
||||
} */
|
||||
}
|
||||
|
||||
showGreeting(){
|
||||
|
||||
@@ -466,70 +466,5 @@ export class DespachoPrPage implements OnInit {
|
||||
return await popover.present();
|
||||
}
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
var notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
<p class="message d-flex align-center">
|
||||
<ion-icon slot="end" class="title-icon pr-10" src="/assets/images/nofitication-success.svg"></ion-icon>
|
||||
<p class="text">{{ message }}</p>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
`
|
||||
|
||||
document.body.append(notification)
|
||||
notification.querySelector('.text').innerHTML = message || 'Processo efetuado'
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},7000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -446,70 +446,4 @@ export class DespachoPage implements OnInit {
|
||||
return await popover.present();
|
||||
}
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
var notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
<p class="message d-flex align-center">
|
||||
<ion-icon slot="end" class="title-icon pr-10" src="/assets/images/nofitication-success.svg"></ion-icon>
|
||||
<p class="text">{{ message }}</p>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
`
|
||||
|
||||
document.body.append(notification)
|
||||
notification.querySelector('.text').innerHTML = message || 'Processo efetuado'
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},7000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(7000)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
}
|
||||
|
||||
-46
@@ -166,50 +166,4 @@ export class DiplomaAssinarPage implements OnInit {
|
||||
}
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -279,49 +279,5 @@ export class DiplomaPage implements OnInit {
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
-46
@@ -221,50 +221,4 @@ export class ApproveEventModalPage implements OnInit {
|
||||
}
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -76,7 +76,6 @@ export class ApproveEventPage implements OnInit {
|
||||
this.router.navigate(['/home/gabinete-digital'], navigationExtras);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
async getTask() {
|
||||
@@ -97,10 +96,8 @@ export class ApproveEventPage implements OnInit {
|
||||
|
||||
try {
|
||||
await this.processes.PostTaskAction(body).toPromise()
|
||||
this.toastService.successMessage()
|
||||
this.toastService.successMessage('Evento aprovado', ()=>{
|
||||
this.goBack();
|
||||
});
|
||||
this.toastService.successMessage();
|
||||
this.goBack();
|
||||
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
@@ -126,22 +123,23 @@ export class ApproveEventPage implements OnInit {
|
||||
async rejeitar(serialNumber:string){
|
||||
let body = { "serialNumber": serialNumber, "action": "Rejeitar" }
|
||||
console.log(body);
|
||||
this.toastService.successMessage('Process');
|
||||
try {
|
||||
this.processes.PostTaskAction(body).toPromise();
|
||||
await this.toastService.successMessage('Processo rejeitado');
|
||||
await this.toastService.successMessage('Processo rejeitado', ()=>{
|
||||
this.goBack();
|
||||
});
|
||||
|
||||
this.goBack();
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
async getAttachments(instanceId:string){
|
||||
this.loadedAttachments = await this.attachmentsService.getAttachmentsById(instanceId).toPromise();
|
||||
try {
|
||||
this.loadedAttachments = await this.attachmentsService.getAttachmentsById(instanceId).toPromise();
|
||||
|
||||
} catch (error) {
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
viewDocument(sourceId){
|
||||
@@ -242,50 +240,4 @@ export class ApproveEventPage implements OnInit {
|
||||
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
<ion-list>
|
||||
<ion-item-sliding>
|
||||
<ion-item class="Rectangle cursor-pointer" lines="none"
|
||||
*ngFor="let event of eventsMDGPRList" (click)="goToEventDetail(event)">
|
||||
*ngFor="let event of eventsMDGPRList" (click)="goToEventToApproveDetail(event.serialNumber)">
|
||||
|
||||
<div class="content-mdgpr-{{event.workflowInstanceDataFields.Agenda}} width-100">
|
||||
<div class="approve-event-time">
|
||||
@@ -57,7 +57,7 @@
|
||||
<div *ngIf="eventsPRList">
|
||||
<ion-item-sliding>
|
||||
<ion-item class="Rectangle cursor-pointer" lines="none"
|
||||
*ngFor="let event of eventsPRList" (click)="goToEventDetail(event)">
|
||||
*ngFor="let event of eventsPRList" (click)="goToEventToApproveDetail(event.serialNumber)">
|
||||
<div class="content-pr-{{event.workflowInstanceDataFields.Agenda}} width-100">
|
||||
<div class="approve-event-time">
|
||||
<p>{{event.workflowInstanceDataFields.StartDate | date: 'hh:mm'}}</p>
|
||||
|
||||
@@ -37,7 +37,7 @@ export class EventListPage implements OnInit {
|
||||
|
||||
this.router.events.forEach((event) => {
|
||||
if(event instanceof NavigationEnd && event.url == this.router.url) {
|
||||
this.doRefresh();
|
||||
this.LoadToApproveEvents();
|
||||
}
|
||||
});
|
||||
|
||||
@@ -75,27 +75,15 @@ export class EventListPage implements OnInit {
|
||||
await modal.present();
|
||||
}
|
||||
|
||||
goToEventDetail(eventToAprove){
|
||||
let InstanceId;
|
||||
|
||||
if(!eventToAprove.workflowInstanceDataFields.hasOwnProperty('InstanceId')){
|
||||
InstanceId = ''
|
||||
} else {
|
||||
InstanceId =eventToAprove.workflowInstanceDataFields.InstanceId
|
||||
}
|
||||
|
||||
goToEventToApproveDetail(serialNumber:string){
|
||||
let navigationExtras: NavigationExtras = {
|
||||
queryParams: {
|
||||
"serialNumber": eventToAprove.serialNumber,
|
||||
"serialNumber": serialNumber,
|
||||
}
|
||||
};
|
||||
this.router.navigate(['/home/gabinete-digital/event-list/approve-event'], navigationExtras)
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
doRefresh() {
|
||||
this.LoadToApproveEvents();
|
||||
console.log('refresh');
|
||||
|
||||
+1
-1
@@ -192,7 +192,7 @@ export class BookMeetingModalPage implements OnInit {
|
||||
|
||||
modal.onDidDismiss().then((data) => {
|
||||
|
||||
if(data){
|
||||
if(data) {
|
||||
data = data['data'];
|
||||
|
||||
const newAttendees: EventPerson[] = data['taskParticipants'];
|
||||
|
||||
+1
-1
@@ -344,7 +344,7 @@ export class ExpedientTaskModalPage implements OnInit {
|
||||
}
|
||||
this.taskResult = await this.processes.postParecerPr(this.postData).toPromise();
|
||||
|
||||
await this.toastService.badRequest('Processo efetuado');
|
||||
await this.toastService.badRequest('Processo não efetuado');
|
||||
this.modalController.dismiss(action_parecer_pr);
|
||||
|
||||
} catch (error) {
|
||||
|
||||
+2
-2
@@ -35,14 +35,14 @@
|
||||
|
||||
<div class="overflow-y-auto">
|
||||
<div class="middle-content">
|
||||
<h5 *ngIf="intervenientes">Intervenientes</h5>
|
||||
<!-- <h5 *ngIf="intervenientes">Intervenientes</h5>
|
||||
<ion-item class="ion-no-margin ion-no-padding">
|
||||
<ion-label>
|
||||
<div *ngFor="let interveniente of intervenientes">
|
||||
<p>{{interveniente.Name}}</p>
|
||||
</div>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
</ion-item> -->
|
||||
<div *ngIf="cc.length > 0">
|
||||
<h5>Com conhecimento</h5>
|
||||
<ion-item class="ion-no-margin ion-no-padding">
|
||||
|
||||
@@ -361,51 +361,4 @@ export class ExpedienteDetailPage implements OnInit {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -82,28 +82,16 @@ export class ExpedientePage implements OnInit {
|
||||
|
||||
doRefresh() {
|
||||
this.LoadList();
|
||||
|
||||
setTimeout(() => {
|
||||
}, 2000);
|
||||
}
|
||||
|
||||
goBack() {
|
||||
|
||||
this.router.navigate(['/home/gabinete-digital']);
|
||||
|
||||
}
|
||||
|
||||
goToExpediente(serialNumber:any) {
|
||||
|
||||
let navigationExtras: NavigationExtras = {
|
||||
queryParams: {
|
||||
"serialNumber": serialNumber,
|
||||
"caller": "gabinete"
|
||||
}
|
||||
}
|
||||
|
||||
goToExpediente(serialNumber:any){
|
||||
this.router.navigate(['/home/gabinete-digital/expediente',serialNumber,'gabinete-digital']);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -442,51 +442,4 @@ export class ExpedientePrPage implements OnInit {
|
||||
return await popover.present();
|
||||
}
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
modal.dismiss()
|
||||
},1000)
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -3,18 +3,19 @@
|
||||
</ion-header>
|
||||
|
||||
<ion-content class="height-100">
|
||||
<ion-refresher name="refresher" slot="fixed" (ionRefresh)="doRefresh()">
|
||||
<ion-refresher slot="fixed" (ionRefresh)="doRefresh($event)">
|
||||
<ion-progress-bar type="indeterminate" *ngIf="showLoader"></ion-progress-bar>
|
||||
<ion-refresher-content>
|
||||
</ion-refresher-content>
|
||||
</ion-refresher>
|
||||
|
||||
<div class="main-content d-flex height-100">
|
||||
|
||||
<!-- Aside left -->
|
||||
<div class="aside-wrapper d-flex flex-column justify-center width-md-40 flex-grow-1 ">
|
||||
<div class="title-container">
|
||||
<ion-label class="title">Gabinete Digital</ion-label>
|
||||
<button class="btn-no-color btn-refresh" (click)="doRefresh()">
|
||||
<button *ngIf="hideRefreshBtn" class="btn-no-color btn-refresh" (click)="doRefresh($event)">
|
||||
<ion-icon class="title-icon" name="reload-circle"></ion-icon>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -74,6 +74,8 @@ export class GabineteDigitalPage implements OnInit {
|
||||
mdgpr = "MDGPR";
|
||||
pr = "PR";
|
||||
|
||||
hideRefreshBtn = true;
|
||||
|
||||
@ViewChild(ExpedientsPage) expedientesPage: ExpedientsPage;
|
||||
@ViewChild(PendentesPage) pendentesListPage: PendentesPage;
|
||||
@ViewChild(EventsToApprovePage) eventsToApprove: EventsToApprovePage;
|
||||
@@ -124,6 +126,22 @@ export class GabineteDigitalPage implements OnInit {
|
||||
}
|
||||
});
|
||||
|
||||
this.hideRefreshButton();
|
||||
}
|
||||
|
||||
hideRefreshButton(){
|
||||
window.onresize = (event) => {
|
||||
if( window.innerWidth < 801) {
|
||||
this.hideRefreshBtn = false;
|
||||
}
|
||||
else{
|
||||
this.hideRefreshBtn = true;
|
||||
}
|
||||
}
|
||||
if(window.innerWidth < 801){
|
||||
console.log('YASS');
|
||||
this.hideRefreshBtn = false;
|
||||
}
|
||||
}
|
||||
|
||||
checkRoutes(){
|
||||
@@ -260,7 +278,7 @@ export class GabineteDigitalPage implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
doRefresh() {
|
||||
doRefresh(event) {
|
||||
this.closeAllDesktopComponents();
|
||||
switch(this.loggeduser.Profile){
|
||||
case 'MDGPR':
|
||||
@@ -276,8 +294,7 @@ export class GabineteDigitalPage implements OnInit {
|
||||
this.LoadCounts();
|
||||
//this.refreshExpedientes();
|
||||
|
||||
setTimeout(() => {
|
||||
}, 2000);
|
||||
event.target.complete();
|
||||
}
|
||||
|
||||
notImplemented(){
|
||||
|
||||
@@ -107,6 +107,7 @@
|
||||
<div class="buttons" *ngIf="task.activityInstanceName == 'Tarefa de Parecer'">
|
||||
<button (click)="openDarParecer(task)" class="btn-cancel" shape="round" >Dar o meu Parecer</button>
|
||||
<button (click)="openBookMeetingModal(task)" class="btn-cancel" shape="round" >Marcar Reunião</button>
|
||||
<button *ngIf="task.WorkflowName == 'Pedido de Parecer do Presidente'" (click)="openForwardModal(task)" class="btn-cancel" shape="round" >Reencaminhar</button>
|
||||
<button (click)="sendExpedienteToPending()" class="btn-cancel" shape="round" >Enviar para Pendentes</button>
|
||||
</div>
|
||||
<div class="buttons" *ngIf="task.activityInstanceName == 'Concluir Parecer'">
|
||||
|
||||
@@ -3,7 +3,6 @@ import { ProcessesService } from 'src/app/services/processes.service';
|
||||
import { AttachmentsService } from 'src/app/services/attachments.service';
|
||||
import { EventsService } from 'src/app/services/events.service';
|
||||
import { InAppBrowser } from '@ionic-native/in-app-browser/ngx';
|
||||
import { DailyWorkTask } from '../../../../models/dailyworktask.model';
|
||||
import { ActivatedRoute, NavigationExtras, Router } from '@angular/router';
|
||||
import { formatDate } from '@angular/common';
|
||||
import { Event } from '../../../../models/event.model';
|
||||
@@ -12,19 +11,17 @@ import { AlertService } from 'src/app/services/alert.service';
|
||||
import { ViewEventPage } from 'src/app/pages/agenda/view-event/view-event.page';
|
||||
import { momentG } from 'src/plugin/momentG'
|
||||
import { DiscartExpedientModalPage } from '../../discart-expedient-modal/discart-expedient-modal.page';
|
||||
import { ExpedientTaskModalPage } from '../../expediente/expedient-task-modal/expedient-task-modal.page';
|
||||
import { BookMeetingModalPage } from '../../expediente/book-meeting-modal/book-meeting-modal.page';
|
||||
import { CreateProcessPage } from 'src/app/modals/create-process/create-process.page';
|
||||
import { DelegarPage } from 'src/app/modals/delegar/delegar.page';
|
||||
import { DarParecerPage } from 'src/app/modals/dar-parecer/dar-parecer.page';
|
||||
import { AddNotePage } from 'src/app/modals/add-note/add-note.page';
|
||||
import { OptsExpedientePage } from 'src/app/shared/popover/opts-expediente/opts-expediente.page';
|
||||
import { RequestOptionsPage } from 'src/app/shared/popover/request-options/request-options.page';
|
||||
import { AuthService } from 'src/app/services/auth.service';
|
||||
import { User } from 'src/app/models/user.model';
|
||||
import { BadRequestPage } from 'src/app/shared/popover/bad-request/bad-request.page';
|
||||
import { SuccessMessagePage } from 'src/app/shared/popover/success-message/success-message.page';
|
||||
import { ToastService } from 'src/app/services/toast.service';
|
||||
import { ForwardPage } from 'src/app/modals/forward/forward.page';
|
||||
|
||||
@Component({
|
||||
selector: 'app-pedido',
|
||||
@@ -171,7 +168,6 @@ export class PedidoPage implements OnInit {
|
||||
this.modalController.dismiss();
|
||||
}
|
||||
|
||||
|
||||
async openOptions(taskAction?: any) {
|
||||
const popover = await this.popoverController.create({
|
||||
component: RequestOptionsPage,
|
||||
@@ -187,7 +183,6 @@ export class PedidoPage implements OnInit {
|
||||
return await popover.present();
|
||||
}
|
||||
|
||||
|
||||
async repreciar(note:string, documents:any) {
|
||||
let body = {
|
||||
"serialNumber": this.serialnumber,
|
||||
@@ -206,8 +201,6 @@ export class PedidoPage implements OnInit {
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
async arquivar(note:string, documents:any) {
|
||||
@@ -228,9 +221,26 @@ export class PedidoPage implements OnInit {
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
}
|
||||
|
||||
async assignar(note:string, documents:any) {
|
||||
let body = {
|
||||
"serialNumber": this.serialnumber,
|
||||
"action": "Reencaminhar",
|
||||
"ActionTypeId": 98,
|
||||
"dataFields": {
|
||||
"ReviewUserComment": note,
|
||||
},
|
||||
"AttachmentList" :documents,
|
||||
}
|
||||
|
||||
|
||||
try {
|
||||
await this.processes.CompleteTask(body).toPromise()
|
||||
this.toastService.successMessage('Processo arquivado')
|
||||
this.close();
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
}
|
||||
|
||||
sendExpedienteToPending(){
|
||||
@@ -344,6 +354,27 @@ export class PedidoPage implements OnInit {
|
||||
modal.onDidDismiss();
|
||||
}
|
||||
|
||||
async openForwardModal(task: any) {
|
||||
console.log(task);
|
||||
|
||||
let classs;
|
||||
if( window.innerWidth <= 800){
|
||||
classs = 'book-meeting-modal modal modal-desktop'
|
||||
} else {
|
||||
classs = 'modal modal-desktop showAsideOptions'
|
||||
}
|
||||
const modal = await this.modalController.create({
|
||||
component: ForwardPage,
|
||||
componentProps: {
|
||||
task: this.task,
|
||||
},
|
||||
cssClass: classs,
|
||||
backdropDismiss: false
|
||||
});
|
||||
await modal.present();
|
||||
modal.onDidDismiss();
|
||||
}
|
||||
|
||||
async openDarParecer(task: any) {
|
||||
console.log(task);
|
||||
|
||||
@@ -404,65 +435,25 @@ export class PedidoPage implements OnInit {
|
||||
else if(actionName == 'Arquivar'){
|
||||
this.arquivar(res.data.note, docs);
|
||||
}
|
||||
else if(actionName == 'Assignar'){
|
||||
this.assignar(res.data.note, docs);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
goBack() {
|
||||
|
||||
let navigationExtras: NavigationExtras = {
|
||||
queryParams: {
|
||||
"pedidos": true,
|
||||
if (window.innerWidth <= 800) {
|
||||
this.router.navigate(['/home/gabinete-digital/pedidos']);
|
||||
} else {
|
||||
let navigationExtras: NavigationExtras = {
|
||||
queryParams: {
|
||||
"pedidos": true,
|
||||
}
|
||||
}
|
||||
this.router.navigate(['/home/gabinete-digital'], navigationExtras);
|
||||
}
|
||||
|
||||
this.router.navigate(['/home/gabinete-digital'], navigationExtras);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
modal.dismiss()
|
||||
},1000)
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
</ion-header>
|
||||
|
||||
<ion-content>
|
||||
<ion-refresher name="refresher" slot="fixed" (ionRefresh)="doRefresh()">
|
||||
<ion-refresher name="refresher" slot="fixed" (ionRefresh)="doRefresh($event)">
|
||||
<ion-progress-bar type="indeterminate" *ngIf="showLoader"></ion-progress-bar>
|
||||
<ion-refresher-content>
|
||||
</ion-refresher-content>
|
||||
@@ -24,7 +24,7 @@
|
||||
<button class="btn-no-color" (click)="AddPublicationFolder()">
|
||||
<ion-icon slot="icon-only" src='assets/images/icons-add.svg'></ion-icon>
|
||||
</button>
|
||||
<button class="btn-no-color" (click)="doRefresh()">
|
||||
<button *ngIf="hideRefreshBtn" class="btn-no-color" (click)="doRefresh($event)">
|
||||
<ion-icon slot="icon-only" class="title-icon" name="reload-circle" title="Actualizar"></ion-icon>
|
||||
</button>
|
||||
</div>
|
||||
@@ -36,7 +36,7 @@
|
||||
<div class="main-content overflow-auto-y">
|
||||
<div class="item d-flex"
|
||||
*ngFor="let viagem of publicationsTravelFolderList"
|
||||
(click)="viewPublications(viagem.ProcessId)">
|
||||
(click)="goToPublicationsList(viagem.ProcessId)">
|
||||
<div class="item-icon">
|
||||
<ion-icon slot="end" src='assets/images/icons-plane-active.svg'></ion-icon>
|
||||
</div>
|
||||
|
||||
@@ -90,7 +90,7 @@ ion-toolbar{
|
||||
}
|
||||
}
|
||||
.item{
|
||||
padding: 0 0px 0 0px;
|
||||
padding: 0 0px 0 0px !important;
|
||||
margin: 0px auto;
|
||||
border-bottom: 1px solid #ebebeb;
|
||||
}
|
||||
@@ -116,14 +116,20 @@ ion-toolbar{
|
||||
.item-content-date{
|
||||
color: #797979;
|
||||
font-size: 13px;
|
||||
margin: 0 !important;
|
||||
padding: 0 !important;
|
||||
}
|
||||
.item-content-title{
|
||||
color: #0d89d1;
|
||||
font-size: 15px;
|
||||
margin: 0 !important;
|
||||
padding: 0 !important;
|
||||
}
|
||||
.item-content-detail{
|
||||
color: #000000;
|
||||
font-size: 13px;
|
||||
margin: 0 !important;
|
||||
padding: 0 !important;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -48,6 +48,7 @@ export class PublicationsPage implements OnInit {
|
||||
|
||||
// from publication details
|
||||
//publication: object;
|
||||
hideRefreshBtn = true;
|
||||
|
||||
constructor(
|
||||
private router: Router,
|
||||
@@ -67,14 +68,31 @@ export class PublicationsPage implements OnInit {
|
||||
this.getActions();
|
||||
}
|
||||
});
|
||||
|
||||
this.hideRefreshButton();
|
||||
}
|
||||
doRefresh() {
|
||||
/* this.getActions(); */
|
||||
|
||||
hideRefreshButton(){
|
||||
window.onresize = (event) => {
|
||||
if( window.innerWidth < 801) {
|
||||
this.hideRefreshBtn = false;
|
||||
}
|
||||
else{
|
||||
this.hideRefreshBtn = true;
|
||||
}
|
||||
}
|
||||
if(window.innerWidth < 801){
|
||||
console.log('YASS');
|
||||
this.hideRefreshBtn = false;
|
||||
}
|
||||
}
|
||||
|
||||
doRefresh(event) {
|
||||
this.getActions();
|
||||
|
||||
setTimeout(() => {
|
||||
this.getActions();
|
||||
/* event.target.complete(); */
|
||||
}, 2000);
|
||||
event.target.complete();
|
||||
}, 250);
|
||||
}
|
||||
|
||||
get windowInnerWidth(): number {
|
||||
@@ -125,7 +143,7 @@ export class PublicationsPage implements OnInit {
|
||||
});
|
||||
await modal.present();
|
||||
modal.onDidDismiss().then(()=>{
|
||||
this.doRefresh();
|
||||
this.getActions();
|
||||
});
|
||||
} else {
|
||||
this.desktopComponent.showAddActions = true;
|
||||
@@ -134,6 +152,17 @@ export class PublicationsPage implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
goToPublicationsList(folderId: string){
|
||||
if( window.innerWidth <= 800){
|
||||
this.router.navigate(['/home/publications',folderId]);
|
||||
} else {
|
||||
this.closeDesktopComponent();
|
||||
this.folderId = folderId
|
||||
this.desktopComponent.showViewPublication = true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
async viewPublications(folderId: string) {
|
||||
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
|
||||
@@ -8,6 +8,7 @@ import { ViewPublicationsPageRoutingModule } from './view-publications-routing.m
|
||||
|
||||
import { ViewPublicationsPage } from './view-publications.page';
|
||||
import { ComponentsModule } from 'src/app/components/components.module';
|
||||
import { HeaderPageModule } from 'src/app/shared/header/header.module';
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
@@ -15,7 +16,8 @@ import { ComponentsModule } from 'src/app/components/components.module';
|
||||
FormsModule,
|
||||
IonicModule,
|
||||
ComponentsModule,
|
||||
ViewPublicationsPageRoutingModule
|
||||
ViewPublicationsPageRoutingModule,
|
||||
HeaderPageModule,
|
||||
],
|
||||
exports: [ViewPublicationsPage],
|
||||
declarations: [ViewPublicationsPage]
|
||||
|
||||
@@ -1,10 +1,13 @@
|
||||
|
||||
|
||||
<ion-header class="ion-no-border">
|
||||
<ion-toolbar class="bg-blue">
|
||||
<app-header></app-header>
|
||||
</ion-header>
|
||||
|
||||
<ion-header class="ion-no-border">
|
||||
<!-- <ion-toolbar class="bg-blue"> -->
|
||||
<div class="main-header">
|
||||
<div class="title-content d-flex">
|
||||
<div class="back-icon" (click)="close()">
|
||||
<div class="back-icon" (click)="goBack()">
|
||||
<ion-icon slot="end" src='assets/images/icons-arrow-arrow-left.svg'></ion-icon>
|
||||
</div>
|
||||
<div class="div-title flex-grow-1">
|
||||
@@ -18,7 +21,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</ion-toolbar>
|
||||
<!-- </ion-toolbar> -->
|
||||
</ion-header>
|
||||
|
||||
<ion-content>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
}
|
||||
ion-content{
|
||||
--background: transparent;
|
||||
transform: translate3d(0, 5px, 0);
|
||||
//transform: translate3d(0, 5px, 0);
|
||||
--border-radius: 30px;
|
||||
}
|
||||
ion-toolbar{
|
||||
@@ -52,7 +52,6 @@
|
||||
overflow:hidden;
|
||||
padding: 25px 20px 0px 20px;
|
||||
color:#000;
|
||||
|
||||
}
|
||||
.main-content{
|
||||
width: 100%; /* 400px */
|
||||
@@ -60,7 +59,6 @@
|
||||
font-family: Roboto;
|
||||
margin: 0 auto;
|
||||
background-color: #fff;
|
||||
|
||||
padding: 15px 20px 0 20px;
|
||||
}
|
||||
.content-top{
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { ModalController, NavParams } from '@ionic/angular';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { ModalController } from '@ionic/angular';
|
||||
import { Publication } from 'src/app/models/publication';
|
||||
import { PublicationFolder } from 'src/app/models/publicationfolder';
|
||||
import { LoadingService } from 'src/app/services/loading.service';
|
||||
@@ -24,11 +25,20 @@ export class ViewPublicationsPage implements OnInit {
|
||||
private loadingController: LoadingService,
|
||||
private modalController: ModalController,
|
||||
private publications: PublicationsService,
|
||||
private navParams: NavParams,
|
||||
) {
|
||||
private activatedRoute: ActivatedRoute,
|
||||
private router: Router,
|
||||
)
|
||||
{
|
||||
this.item = new PublicationFolder();
|
||||
this.folderId = this.navParams.get('folderId');
|
||||
}
|
||||
this.activatedRoute.paramMap.subscribe(params => {
|
||||
console.log(params);
|
||||
|
||||
if(params["params"]) {
|
||||
this.folderId = params["params"].folderId;
|
||||
console.log(params["params"]);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
console.log(this.folderId);
|
||||
@@ -48,6 +58,9 @@ export class ViewPublicationsPage implements OnInit {
|
||||
close(){
|
||||
this.modalController.dismiss();
|
||||
}
|
||||
goBack(){
|
||||
this.router.navigate(['/home/publications']);
|
||||
}
|
||||
getPublicationDetail(){
|
||||
this.publications.GetPublicationFolderById(this.folderId).subscribe(res=>{
|
||||
console.log(res);
|
||||
|
||||
@@ -16,8 +16,11 @@ export class EventsService {
|
||||
loggeduser: User;
|
||||
headers: HttpHeaders;
|
||||
|
||||
headersOwnerOficial: HttpHeaders;
|
||||
headersOwnerPessoal: HttpHeaders;
|
||||
headersPrOficial: HttpHeaders;
|
||||
headersPrPessoal: HttpHeaders;
|
||||
|
||||
headersMdOficial: HttpHeaders;
|
||||
headersMdPessoal: HttpHeaders;
|
||||
|
||||
headersSharedOficial: HttpHeaders;
|
||||
headersSharedPessoal: HttpHeaders;
|
||||
@@ -26,51 +29,75 @@ export class EventsService {
|
||||
constructor(private http: HttpClient, user: AuthService) {
|
||||
this.loggeduser = user.ValidatedUser;
|
||||
|
||||
this.headersOwnerOficial = new HttpHeaders();
|
||||
this.headersOwnerPessoal = new HttpHeaders();
|
||||
this.headersMdOficial = new HttpHeaders();
|
||||
this.headersMdPessoal = new HttpHeaders();
|
||||
|
||||
|
||||
this.headersPrOficial = new HttpHeaders();
|
||||
this.headersPrPessoal = new HttpHeaders();
|
||||
|
||||
this.headersSharedOficial = new HttpHeaders();
|
||||
this.headersSharedPessoal = new HttpHeaders();
|
||||
|
||||
|
||||
|
||||
if(this.loggeduser.Profile == 'MDGPR'){
|
||||
this.headersOwnerOficial = this.headersOwnerOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersOwnerOficial = this.headersOwnerOficial.set('CalendarId', this.loggeduser.OwnerCalendars[0].CalendarId);
|
||||
this.headersOwnerOficial = this.headersOwnerOficial.set('CalendarRoleId', this.loggeduser.OwnerCalendars[0].CalendarRoleId);
|
||||
|
||||
this.loggeduser.OwnerCalendars.forEach(calendar =>{
|
||||
if(calendar.CalendarName == 'Oficial'){
|
||||
this.headersMdOficial = this.headersMdOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersMdOficial = this.headersMdOficial.set('CalendarId', calendar.CalendarId);
|
||||
this.headersMdOficial = this.headersMdOficial.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||
}
|
||||
else if(calendar.CalendarName == 'Pessoal'){
|
||||
this.headersMdPessoal = this.headersMdPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersMdPessoal = this.headersMdPessoal.set('CalendarId', calendar.CalendarId);
|
||||
this.headersMdPessoal = this.headersMdPessoal.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||
|
||||
this.headersOwnerPessoal = this.headersOwnerPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersOwnerPessoal = this.headersOwnerPessoal.set('CalendarId', this.loggeduser.OwnerCalendars[1].CalendarId);
|
||||
this.headersOwnerPessoal = this.headersOwnerPessoal.set('CalendarRoleId', this.loggeduser.OwnerCalendars[1].CalendarRoleId);
|
||||
}
|
||||
});
|
||||
|
||||
this.headersSharedOficial = this.headersSharedOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersSharedOficial = this.headersSharedOficial.set('CalendarId', this.loggeduser.SharedCalendars[0].CalendarId);
|
||||
this.headersSharedOficial = this.headersSharedOficial.set('CalendarRoleId', this.loggeduser.SharedCalendars[0].CalendarRoleId);
|
||||
|
||||
this.headersSharedPessoal = this.headersSharedPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersSharedPessoal = this.headersSharedPessoal.set('CalendarId', this.loggeduser.SharedCalendars[1].CalendarId);
|
||||
this.headersSharedPessoal = this.headersSharedPessoal.set('CalendarRoleId', this.loggeduser.SharedCalendars[1].CalendarRoleId);
|
||||
this.loggeduser.SharedCalendars.forEach(sharedCalendar =>{
|
||||
if(sharedCalendar.CalendarName == 'Oficial'){
|
||||
this.headersSharedOficial = this.headersSharedOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersSharedOficial = this.headersSharedOficial.set('CalendarId', sharedCalendar.CalendarId);
|
||||
this.headersSharedOficial = this.headersSharedOficial.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
||||
}
|
||||
else if(sharedCalendar.CalendarName == 'Pessoal'){
|
||||
this.headersSharedPessoal = this.headersSharedPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersSharedPessoal = this.headersSharedPessoal.set('CalendarId', sharedCalendar.CalendarId);
|
||||
this.headersSharedPessoal = this.headersSharedPessoal.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
else if(this.loggeduser.Profile == 'PR'){
|
||||
this.headersOwnerOficial = this.headersOwnerOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersOwnerOficial = this.headersOwnerOficial.set('CalendarId', this.loggeduser.OwnerCalendars[0].CalendarId);
|
||||
this.headersOwnerOficial = this.headersOwnerOficial.set('CalendarRoleId', this.loggeduser.OwnerCalendars[0].CalendarRoleId);
|
||||
|
||||
this.headersOwnerPessoal = this.headersOwnerPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersOwnerPessoal = this.headersOwnerPessoal.set('CalendarId', this.loggeduser.OwnerCalendars[1].CalendarId);
|
||||
this.headersOwnerPessoal = this.headersOwnerPessoal.set('CalendarRoleId', this.loggeduser.OwnerCalendars[1].CalendarRoleId);
|
||||
this.loggeduser.OwnerCalendars.forEach(calendar =>{
|
||||
if(calendar.CalendarName == 'Oficial'){
|
||||
this.headersPrOficial = this.headersPrOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersPrOficial = this.headersPrOficial.set('CalendarId', calendar.CalendarId);
|
||||
this.headersPrOficial = this.headersPrOficial.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||
}
|
||||
else if(calendar.CalendarName == 'Pessoal'){
|
||||
this.headersPrPessoal = this.headersPrPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
this.headersPrPessoal = this.headersPrPessoal.set('CalendarId', calendar.CalendarId);
|
||||
this.headersPrPessoal = this.headersPrPessoal.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
this.headers = new HttpHeaders();
|
||||
this.headers = this.headers.set('Authorization', this.loggeduser.BasicAuthKey);
|
||||
/* this.headers = this.headers.set('CalendarId', this.loggeduser.OwnerCalendars[0].CalendarId);
|
||||
this.headers = this.headers.set('CalendarRoleId', this.loggeduser.OwnerCalendars[0].CalendarRoleId); */
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
getAllEvents(startdate:string, enddate:string): Observable<Event[]>{
|
||||
/* getAllEvents(startdate:string, enddate:string): Observable<Event[]>{
|
||||
const geturl = environment.apiURL + 'calendar/GetAllEvents';
|
||||
let params = new HttpParams();
|
||||
|
||||
@@ -82,7 +109,7 @@ export class EventsService {
|
||||
params: params
|
||||
};
|
||||
return this.http.get<Event[]>(`${geturl}`, options);
|
||||
}
|
||||
} */
|
||||
|
||||
|
||||
getAllPrOficialEvents(startdate:string, enddate:string): Observable<Event[]>{
|
||||
@@ -91,9 +118,18 @@ export class EventsService {
|
||||
|
||||
params = params.set("Start", startdate);
|
||||
params = params.set("End", enddate);
|
||||
|
||||
/* switch (this.loggeduser.Profile == 'MDGPR') {
|
||||
case value:
|
||||
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
} */
|
||||
|
||||
let options = {
|
||||
headers: this.headersOwnerOficial,
|
||||
headers: this.headersPrOficial,
|
||||
params: params
|
||||
};
|
||||
return this.http.get<Event[]>(`${geturl}`, options);
|
||||
@@ -107,13 +143,23 @@ export class EventsService {
|
||||
params = params.set("End", enddate);
|
||||
|
||||
let options = {
|
||||
headers: this.headersOwnerPessoal,
|
||||
headers: this.headersPrPessoal,
|
||||
params: params
|
||||
};
|
||||
return this.http.get<Event[]>(`${geturl}`, options);
|
||||
}
|
||||
|
||||
getAllMdOficialEvents(startdate:string, enddate:string): Observable<Event[]>{
|
||||
async getAllPrEvents(startdate:string, enddate:string){
|
||||
let prO = await this.getAllPrOficialEvents(startdate, enddate).toPromise();
|
||||
let prP = await this.getAllPrPessoalEvents(startdate, enddate).toPromise();
|
||||
const resFinal = prO.concat(prP);
|
||||
console.log(resFinal);
|
||||
return new Promise(resolve =>{
|
||||
return resolve(resFinal)
|
||||
})
|
||||
}
|
||||
|
||||
getAllMdOficialEvents(startdate:string, enddate:string): any{
|
||||
const geturl = environment.apiURL + 'calendar/md';
|
||||
let params = new HttpParams();
|
||||
|
||||
@@ -121,13 +167,13 @@ export class EventsService {
|
||||
params = params.set("End", enddate);
|
||||
|
||||
let options = {
|
||||
headers: this.headersOwnerOficial,
|
||||
headers: this.headersMdOficial,
|
||||
params: params
|
||||
};
|
||||
return this.http.get<Event[]>(`${geturl}`, options);
|
||||
return this.http.get<any>(`${geturl}`, options);
|
||||
}
|
||||
|
||||
getAllMdPessoalEvents(startdate:string, enddate:string): Observable<Event[]>{
|
||||
getAllMdPessoalEvents(startdate:string, enddate:string): any{
|
||||
const geturl = environment.apiURL + 'calendar/md';
|
||||
let params = new HttpParams();
|
||||
|
||||
@@ -135,10 +181,20 @@ export class EventsService {
|
||||
params = params.set("End", enddate);
|
||||
|
||||
let options = {
|
||||
headers: this.headersOwnerPessoal,
|
||||
headers: this.headersMdPessoal,
|
||||
params: params
|
||||
};
|
||||
return this.http.get<Event[]>(`${geturl}`, options);
|
||||
return this.http.get<any>(`${geturl}`, options);
|
||||
}
|
||||
|
||||
async getAllMdEvents(startdate:string, enddate:string){
|
||||
let prO = await this.getAllMdOficialEvents(startdate, enddate).toPromise();
|
||||
let prP = await this.getAllMdPessoalEvents(startdate, enddate).toPromise();
|
||||
const resFinal = prO.concat(prP);
|
||||
console.log(resFinal);
|
||||
return new Promise(resolve =>{
|
||||
return resolve(resFinal)
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -171,6 +227,17 @@ export class EventsService {
|
||||
return this.http.get<Event[]>(`${geturl}`, options);
|
||||
}
|
||||
|
||||
async getAllSharedEvents(startdate:string, enddate:string){
|
||||
let prO = await this.getAllSharedOficialEvents(startdate, enddate).toPromise();
|
||||
let prP = await this.getAllSharedPessoalEvents(startdate, enddate).toPromise();
|
||||
const resFinal = prO.concat(prP);
|
||||
console.log(resFinal);
|
||||
|
||||
return new Promise(resolve =>{
|
||||
return resolve(resFinal)
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -239,7 +306,7 @@ export class EventsService {
|
||||
return this.http.put<Event>(`${puturl}`, event, options)
|
||||
}
|
||||
|
||||
postEvent(event:Event, calendarName:string, sharedagenda:string)
|
||||
/* postEvent(event:Event, calendarName:string, sharedagenda:string)
|
||||
{
|
||||
const puturl = environment.apiURL + 'calendar/' + ((sharedagenda != '') ? sharedagenda : 'PostEvent');
|
||||
let params = new HttpParams();
|
||||
@@ -252,7 +319,7 @@ export class EventsService {
|
||||
};
|
||||
|
||||
return this.http.post<Event>(`${puturl}`, event, options)
|
||||
}
|
||||
} */
|
||||
|
||||
postEventMd(event:Event, calendarName:string)
|
||||
{
|
||||
@@ -261,11 +328,25 @@ export class EventsService {
|
||||
|
||||
params = params.set("CalendarName", calendarName);
|
||||
|
||||
let options = {
|
||||
headers: this.headers,
|
||||
params: params
|
||||
};
|
||||
let options:any;
|
||||
switch (calendarName) {
|
||||
case 'Oficial':
|
||||
console.log(calendarName);
|
||||
options = {
|
||||
headers: this.headersMdOficial,
|
||||
params: params
|
||||
};
|
||||
break;
|
||||
|
||||
case 'Pessoal':
|
||||
console.log(calendarName);
|
||||
options = {
|
||||
headers: this.headersMdPessoal,
|
||||
params: params
|
||||
};
|
||||
break;
|
||||
}
|
||||
console.log(options);
|
||||
return this.http.post<string>(`${puturl}`, event, options)
|
||||
}
|
||||
|
||||
@@ -276,10 +357,24 @@ export class EventsService {
|
||||
|
||||
params = params.set("CalendarName", calendarName);
|
||||
|
||||
let options = {
|
||||
headers: this.headers,
|
||||
params: params
|
||||
};
|
||||
let options:any;
|
||||
switch (calendarName) {
|
||||
case 'Oficial':
|
||||
console.log(calendarName);
|
||||
options = {
|
||||
headers: this.headersPrOficial,
|
||||
params: params
|
||||
};
|
||||
break;
|
||||
|
||||
case 'Pessoal':
|
||||
console.log(calendarName);
|
||||
options = {
|
||||
headers: this.headersPrPessoal,
|
||||
params: params
|
||||
};
|
||||
break;
|
||||
}
|
||||
|
||||
return this.http.post<string>(`${puturl}`, event, options)
|
||||
}
|
||||
|
||||
@@ -139,6 +139,7 @@ export class ProcessesService {
|
||||
};
|
||||
return this.http.post<any>(`${geturl}`, body, options)
|
||||
}
|
||||
|
||||
CompleteTask(body:any){
|
||||
const geturl = environment.apiURL + 'Tasks/CompleteTask';
|
||||
|
||||
@@ -148,6 +149,15 @@ export class ProcessesService {
|
||||
return this.http.post<any>(`${geturl}`, body, options)
|
||||
}
|
||||
|
||||
CompleteParecerPrTask(body:any){
|
||||
const geturl = environment.apiURL + 'Tasks/CompleteTaskParecerPr';
|
||||
|
||||
let options = {
|
||||
headers: this.headers,
|
||||
};
|
||||
return this.http.post<any>(`${geturl}`, body, options)
|
||||
}
|
||||
|
||||
UpdateTaskStatus(FolderId:string): Observable<any>{
|
||||
const geturl = environment.apiURL + 'Tasks/UpdateTaskStatus';
|
||||
let params = new HttpParams();
|
||||
|
||||
@@ -25,7 +25,7 @@ export class ToastService {
|
||||
async successMessage(message?: any, callback?) {
|
||||
|
||||
let notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.className = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
@@ -43,15 +43,21 @@ export class ToastService {
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
notification.remove()
|
||||
},7000)
|
||||
|
||||
notification.style.right = "-100%"
|
||||
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},1000)
|
||||
|
||||
},6000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
|
||||
let notification = document.createElement('div')
|
||||
notification.id = 'notification'
|
||||
notification.className = 'notification'
|
||||
notification.innerHTML = `
|
||||
|
||||
<div class="main-content width-100 pa-20">
|
||||
@@ -69,8 +75,14 @@ export class ToastService {
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
notification.remove()
|
||||
},7000)
|
||||
|
||||
notification.style.right = "-100%"
|
||||
|
||||
setTimeout(()=>{
|
||||
notification.remove()
|
||||
},1000)
|
||||
|
||||
},6000)
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -127,10 +127,9 @@ export class ApproveEventPage implements OnInit {
|
||||
try {
|
||||
await this.processes.PostTaskAction(body).toPromise()
|
||||
this.router.navigate(['/home/gabinete-digital/event-list']);
|
||||
this.modalController.dismiss(null);
|
||||
this.toastService.successMessage('Evento rejeitado')
|
||||
} catch (error) {
|
||||
this.toastService.badRequest('Evento não rejeitado')
|
||||
this.toastService.badRequest('Processo não efectuado')
|
||||
}
|
||||
|
||||
}
|
||||
@@ -239,50 +238,4 @@ export class ApproveEventPage implements OnInit {
|
||||
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,19 +1,31 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { FormsModule } from '@angular/forms';
|
||||
import { FormsModule, NgControl } from '@angular/forms';
|
||||
|
||||
import { IonicModule } from '@ionic/angular';
|
||||
|
||||
import { NewEventPageRoutingModule } from './new-event-routing.module';
|
||||
|
||||
import { NewEventPage } from './new-event.page';
|
||||
import { NgbModule } from '@ng-bootstrap/ng-bootstrap';
|
||||
import {MatDatepickerModule} from '@angular/material/datepicker';
|
||||
import {MatInputModule} from '@angular/material/input';
|
||||
|
||||
import { MatNativeDateModule } from '@angular/material/core';
|
||||
import { MatMomentDateModule, MomentDateAdapter } from "@angular/material-moment-adapter";
|
||||
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
CommonModule,
|
||||
FormsModule,
|
||||
IonicModule,
|
||||
NewEventPageRoutingModule
|
||||
NewEventPageRoutingModule,
|
||||
NgbModule,
|
||||
MatDatepickerModule,
|
||||
MatInputModule,
|
||||
MatNativeDateModule,
|
||||
|
||||
],
|
||||
declarations: [NewEventPage],
|
||||
exports: [NewEventPage]
|
||||
|
||||
@@ -12,6 +12,22 @@
|
||||
|
||||
<ion-content>
|
||||
<div class="main-content">
|
||||
|
||||
<!-- <form class="form-inline">
|
||||
<div class="form-group">
|
||||
<div class="input-group">
|
||||
<input class="form-control" placeholder="yyyy-mm-dd"
|
||||
name="dp" ngbDatepicker #d="ngbDatepicker">
|
||||
<div class="input-group-append">
|
||||
<button class="btn btn-outline-secondary calendar" (click)="d.toggle()" type="button"></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form> -->
|
||||
|
||||
<!-- 2. datepicker in the popup -->
|
||||
<!-- <input type="text" ngbDatepicker #d="ngbDatepicker"/> -->
|
||||
|
||||
<div class="ion-item-container">
|
||||
<ion-input type="text" placeholder="Assunto" [(ngModel)]="postEvent.Subject"></ion-input>
|
||||
</div>
|
||||
@@ -75,6 +91,7 @@
|
||||
</div>
|
||||
<div class="ion-input-class flex-grow-1">
|
||||
<ion-datetime
|
||||
class=""
|
||||
placeholder="Início"
|
||||
[(ngModel)]="postEvent.StartDate"
|
||||
displayFormat="D MMM YYYY H:mm"
|
||||
@@ -84,6 +101,18 @@
|
||||
max="2022"
|
||||
>
|
||||
</ion-datetime>
|
||||
|
||||
<input
|
||||
class="d-none width-100"
|
||||
placeholder="Início"
|
||||
[matDatepicker]="picker"
|
||||
(focus)="picker.open()"
|
||||
(click)="picker.open()"
|
||||
[(ngModel)]="postEvent.StartDate"
|
||||
>
|
||||
<mat-datepicker #picker></mat-datepicker>
|
||||
|
||||
|
||||
<!-- <ion-input placeholder="Data início" [(ngModel)]="postData.StartDate"></ion-input> -->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -12,13 +12,50 @@ import { EventAttachment } from 'src/app/models/attachment.model';
|
||||
import { BadRequestPage } from '../../popover/bad-request/bad-request.page';
|
||||
import { SuccessMessagePage} from '../../popover/success-message/success-message.page';
|
||||
import { ToastService } from 'src/app/services/toast.service';
|
||||
import { User } from 'src/app/models/user.model';
|
||||
import { AuthService } from 'src/app/services/auth.service';
|
||||
|
||||
|
||||
import {MomentDateAdapter, MAT_MOMENT_DATE_ADAPTER_OPTIONS} from '@angular/material-moment-adapter';
|
||||
import {DateAdapter, MAT_DATE_FORMATS, MAT_DATE_LOCALE} from '@angular/material/core';
|
||||
import * as _moment from 'moment';
|
||||
import * as _rollupMoment from 'moment';
|
||||
import {FormControl} from '@angular/forms';
|
||||
|
||||
|
||||
const moment = _rollupMoment || _moment;
|
||||
|
||||
export const MY_FORMATS = {
|
||||
parse: {
|
||||
dateInput: 'LL',
|
||||
},
|
||||
display: {
|
||||
dateInput: 'LL',
|
||||
monthYearLabel: 'MMM YYYY',
|
||||
dateA11yLabel: 'LL',
|
||||
monthYearA11yLabel: 'MMMM YYYY',
|
||||
},
|
||||
};
|
||||
|
||||
@Component({
|
||||
selector: 'app-new-event',
|
||||
templateUrl: './new-event.page.html',
|
||||
styleUrls: ['./new-event.page.scss'],
|
||||
providers: [
|
||||
// `MomentDateAdapter` can be automatically provided by importing `MomentDateModule` in your
|
||||
// application's root module. We provide it at the component level here, due to limitations of
|
||||
// our example generation script.
|
||||
{
|
||||
provide: DateAdapter,
|
||||
useClass: MomentDateAdapter,
|
||||
deps: [MAT_DATE_LOCALE, MAT_MOMENT_DATE_ADAPTER_OPTIONS]
|
||||
},
|
||||
|
||||
{provide: MAT_DATE_FORMATS, useValue: MY_FORMATS},
|
||||
]
|
||||
})
|
||||
|
||||
|
||||
export class NewEventPage implements OnInit {
|
||||
|
||||
|
||||
@@ -45,14 +82,22 @@ export class NewEventPage implements OnInit {
|
||||
|
||||
minDate: string;
|
||||
|
||||
loggeduser: User;
|
||||
|
||||
date = new FormControl(moment());
|
||||
// serializedDate = new FormControl((new Date()).toISOString());
|
||||
|
||||
constructor(
|
||||
private modalController: ModalController,
|
||||
private eventService: EventsService,
|
||||
private attachmentsService: AttachmentsService,
|
||||
private animationController: AnimationController,
|
||||
private toastService: ToastService
|
||||
private toastService: ToastService,
|
||||
private userService: AuthService,
|
||||
|
||||
) {}
|
||||
) {
|
||||
this.loggeduser = userService.ValidatedUser;
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
|
||||
@@ -168,16 +213,17 @@ export class NewEventPage implements OnInit {
|
||||
|
||||
this.postEvent.Attendees = this.taskParticipants.concat(this.taskParticipantsCc);
|
||||
|
||||
|
||||
if(this.documents.length >= 0) {
|
||||
this.postEvent.HasAttachments = true;
|
||||
}
|
||||
|
||||
if(this.profile=='mdgpr') {
|
||||
if(this.loggeduser.Profile == 'MDGPR') {
|
||||
console.log('MD - Aqui');
|
||||
console.log(this.postEvent);
|
||||
this.eventService.postEventMd(this.postEvent, this.postEvent.CalendarName).subscribe(
|
||||
async (id) => {
|
||||
|
||||
const eventId: string = id;
|
||||
const eventId: any = id;
|
||||
|
||||
const DocumentToSave: EventAttachment[] = this.documents.map((e) => {
|
||||
return {
|
||||
@@ -215,11 +261,15 @@ export class NewEventPage implements OnInit {
|
||||
this.toastService.badRequest('Evento não criado')
|
||||
});
|
||||
}
|
||||
else if(this.profile=='pr') {
|
||||
else if(this.loggeduser.Profile == 'PR') {
|
||||
console.log('PR - Aqui');
|
||||
console.log(this.postEvent);
|
||||
this.eventService.postEventPr(this.postEvent, this.postEvent.CalendarName).subscribe(
|
||||
(id) => {
|
||||
console.log(id);
|
||||
|
||||
|
||||
const eventId: string = id;
|
||||
const eventId: any = id;
|
||||
|
||||
const DocumentToSave: EventAttachment[] = this.documents.map((e) => {
|
||||
return {
|
||||
@@ -254,7 +304,7 @@ export class NewEventPage implements OnInit {
|
||||
}
|
||||
}
|
||||
|
||||
afterSave(){
|
||||
afterSave() {
|
||||
this.deleteTemporaryData();
|
||||
|
||||
this.onAddEvent.emit(this.postEvent);
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
<ion-header class="ion-no-border px-20">
|
||||
<ion-toolbar class="px-10">
|
||||
<ion-title class="pa-0">Adicionar intervenientes</ion-title>
|
||||
<ion-title>Agenda Desktop</ion-title>
|
||||
</ion-toolbar>
|
||||
<ion-searchbar class="attendee-search-bar" (ionChange)="onChange($event)" placeholder="Insira email para adicionar destinatário"></ion-searchbar><!-- [(ngModel)]="searchCountryString" -->
|
||||
<ion-progress-bar type="indeterminate" *ngIf="showLoader"></ion-progress-bar>
|
||||
|
||||
@@ -69,95 +69,4 @@ export class FingerprintPage implements OnInit {
|
||||
|
||||
}
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: SuccessMessagePage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
|
||||
this.close()
|
||||
modal.dismiss()
|
||||
},3000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -69,7 +69,7 @@ export class EditEventToApproveComponent implements OnInit {
|
||||
// "EndDate":"2021-04-30T15:30:00",
|
||||
// "Participants":"gilson.manuel@gabinetedigital.local;tiago.kayaya@gabinetedigital.local;solange.vandunem@gabinetedigital.local",
|
||||
// "CC":"",
|
||||
// "ReviewerComments":"teste",
|
||||
// "ReviewUserComments":"teste",
|
||||
// "Role":0,
|
||||
// "MDName":"Paulo Pinto",
|
||||
// "MDEmail":"paulo.pinto@gabinetedigital.local",
|
||||
@@ -251,7 +251,7 @@ export class EditEventToApproveComponent implements OnInit {
|
||||
Message: this.eventProcess.workflowInstanceDataFields.Message,
|
||||
ParticipantsList: this.eventProcess.workflowInstanceDataFields.ParticipantsList,
|
||||
Private: false,
|
||||
ReviewerComments: ''
|
||||
ReviewUserComments: ''
|
||||
}
|
||||
|
||||
this.eventsService.postEventToApproveEdit(event).subscribe(()=>{
|
||||
|
||||
@@ -147,71 +147,6 @@ export class DeplomaOptionsPage implements OnInit {
|
||||
}
|
||||
|
||||
|
||||
async successMessage(message?: any, callback?) {
|
||||
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: SuccessMessagePage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
|
||||
}
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const modal = await this.modalController.create({
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
goBack() {
|
||||
this.close()
|
||||
}
|
||||
|
||||
@@ -286,30 +286,7 @@ export class DespachosOptionsPage implements OnInit {
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const modal = await this.modalController.create({
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
async reexecutar(note:string, documents:any){
|
||||
let body = {
|
||||
"serialNumber": this.serialnumber,
|
||||
|
||||
@@ -282,30 +282,6 @@ export class DespachosPrOptionsPage implements OnInit {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const modal = await this.modalController.create({
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
if (callback) {
|
||||
callback()
|
||||
}
|
||||
modal.dismiss()
|
||||
},7000)
|
||||
}
|
||||
|
||||
|
||||
|
||||
async reexecutar(note:string, documents:any){
|
||||
let body = {
|
||||
|
||||
@@ -9,9 +9,6 @@ import { BookMeetingModalPage } from 'src/app/pages/gabinete-digital/expediente/
|
||||
import { ExpedientTaskModalPage } from 'src/app/pages/gabinete-digital/expediente/expedient-task-modal/expedient-task-modal.page';
|
||||
import { ProcessesService } from 'src/app/services/processes.service';
|
||||
import { ToastService } from 'src/app/services/toast.service';
|
||||
import { BadRequestPage } from 'src/app/shared/popover/bad-request/bad-request.page';
|
||||
import { SuccessMessagePage } from 'src/app/shared/popover/success-message/success-message.page';
|
||||
|
||||
|
||||
@Component({
|
||||
selector: 'app-request-options',
|
||||
@@ -45,7 +42,6 @@ export class RequestOptionsPage implements OnInit {
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
this.showEnviarPendentes = this.navParams.get('showEnviarPendentes');
|
||||
|
||||
@@ -243,7 +239,7 @@ export class RequestOptionsPage implements OnInit {
|
||||
}
|
||||
|
||||
async openDarParecer(task: any) {
|
||||
console.log(task);
|
||||
// console.log(task);
|
||||
|
||||
let classs;
|
||||
if( window.innerWidth <= 800){
|
||||
@@ -265,7 +261,7 @@ export class RequestOptionsPage implements OnInit {
|
||||
}
|
||||
|
||||
async openDelegarModal(task: any) {
|
||||
console.log(task);
|
||||
// console.log(task);
|
||||
|
||||
let classs;
|
||||
if( window.innerWidth <= 800){
|
||||
@@ -286,49 +282,4 @@ export class RequestOptionsPage implements OnInit {
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
async badRequest(message?: string, callback?) {
|
||||
const enterAnimation = (baseEl: any) => {
|
||||
const backdropAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('ion-backdrop')!)
|
||||
.fromTo('opacity', '0.01', 'var(--backdrop-opacity)');
|
||||
|
||||
const wrapperAnimation = this.animationController.create()
|
||||
.addElement(baseEl.querySelector('.modal-wrapper')!)
|
||||
.keyframes([
|
||||
{ offset: 0, opacity: '1', right: '-100%' },
|
||||
{ offset: 1, opacity: '1', right: '0px' }
|
||||
]);
|
||||
|
||||
return this.animationController.create()
|
||||
.addElement(baseEl)
|
||||
.easing('ease-out')
|
||||
.duration(500)
|
||||
.addAnimation([backdropAnimation, wrapperAnimation]);
|
||||
}
|
||||
|
||||
const leaveAnimation = (baseEl: any) => {
|
||||
return enterAnimation(baseEl).direction('reverse');
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
enterAnimation,
|
||||
leaveAnimation,
|
||||
component: BadRequestPage,
|
||||
componentProps: {
|
||||
message: message || 'Processo efetuado' ,
|
||||
},
|
||||
cssClass: 'notification-modal'
|
||||
});
|
||||
|
||||
modal.present()
|
||||
|
||||
setTimeout(()=>{
|
||||
modal.dismiss()
|
||||
},1000)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
+47
-28
@@ -33,8 +33,9 @@
|
||||
// calendar current day
|
||||
|
||||
// current day
|
||||
ion-slide{
|
||||
td{
|
||||
|
||||
ion-slide {
|
||||
td {
|
||||
div {
|
||||
padding-left: 7px;
|
||||
border-radius: 28px;
|
||||
@@ -105,19 +106,6 @@ td.monthview-secondary-with-event, td.monthview-secondary-with-event[_ngcontent-
|
||||
|
||||
|
||||
|
||||
.cal-current-time-marker::before{
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
background-color: #42b9fe !important;
|
||||
content: ".";
|
||||
color: transparent;
|
||||
left: 55px;
|
||||
position: absolute;
|
||||
border-radius: 91px;
|
||||
top: -3.5px;
|
||||
|
||||
}
|
||||
|
||||
.cal-time{
|
||||
font-family: Roboto;
|
||||
font-size: 13px;
|
||||
@@ -189,8 +177,6 @@ td.monthview-secondary-with-event, td.monthview-secondary-with-event[_ngcontent-
|
||||
-webkit-transform: rotate(45deg);
|
||||
transform: rotate(45deg);
|
||||
border-radius: 106px;
|
||||
width: 30px !important;
|
||||
height: 30px;
|
||||
padding: 0px !important;
|
||||
div.day{
|
||||
padding: 0px !important;
|
||||
@@ -579,12 +565,26 @@ td.monthview-secondary-with-event, td.monthview-secondary-with-event[_ngcontent-
|
||||
}
|
||||
|
||||
|
||||
.calendar-component {
|
||||
.calendar-component .monthview-container table.table {
|
||||
|
||||
td {
|
||||
padding: 7.5px !important;
|
||||
width: 50px;
|
||||
height: 40px;
|
||||
div {
|
||||
padding-left: 0px;
|
||||
}
|
||||
display: flex;
|
||||
align-content: center;
|
||||
justify-content: center;
|
||||
|
||||
}
|
||||
td div:not(.day, .day-container, .number) {
|
||||
width: 30px !important;
|
||||
height: 30px;
|
||||
}
|
||||
tr {
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -694,7 +694,7 @@ app-header-no-search .ion-toolbar{
|
||||
}
|
||||
|
||||
|
||||
body, .blue-background{ background: #0782C9;}
|
||||
body, .blue-background{ background: #0782C9 !important;}
|
||||
|
||||
@media only screen and (min-width: 1365px) {
|
||||
|
||||
@@ -761,10 +761,9 @@ ion-icon{
|
||||
}
|
||||
|
||||
|
||||
|
||||
::-webkit-scrollbar {
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
width: 7px;
|
||||
height: 7px;
|
||||
}
|
||||
|
||||
/* Track */
|
||||
@@ -798,7 +797,7 @@ background: rgb(92, 92, 92);
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
/* Track */
|
||||
/* Track */
|
||||
.hide-scroll::-webkit-scrollbar-track {
|
||||
display: none !important;
|
||||
}
|
||||
@@ -813,9 +812,7 @@ background: rgb(92, 92, 92);
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#notification{
|
||||
.notification{
|
||||
position: absolute;
|
||||
top: 23px;
|
||||
right: 0px;
|
||||
@@ -840,6 +837,11 @@ background: rgb(92, 92, 92);
|
||||
box-shadow: 0px 2px 10px #0000003d;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
animation-name: example;
|
||||
animation-duration: 1s;
|
||||
animation-timing-function: ease-in;
|
||||
transition: 1s;
|
||||
|
||||
.main-content {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -847,4 +849,21 @@ background: rgb(92, 92, 92);
|
||||
.message {
|
||||
font-size: 12pt;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@keyframes example {
|
||||
from {right: -100%;}
|
||||
to {right: 0px;}
|
||||
}
|
||||
|
||||
|
||||
.calendar-component .monthview-container table.table tbody {
|
||||
tr:nth-child(n+6) {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
.modal {
|
||||
display: flex !important;
|
||||
}
|
||||
@@ -24,6 +24,9 @@
|
||||
<meta name="apple-mobile-web-app-capable" content="yes" />
|
||||
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
|
||||
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com">
|
||||
<link href="https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500&display=swap" rel="stylesheet">
|
||||
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
/***************************************************************************************************
|
||||
* Load `$localize` onto the global scope - used if i18n tags appear in Angular templates.
|
||||
*/
|
||||
import '@angular/localize/init';
|
||||
/**
|
||||
* This file includes polyfills needed by Angular and is loaded before the app.
|
||||
* You can add your own extra polyfills to this file.
|
||||
|
||||
@@ -1,3 +1,38 @@
|
||||
|
||||
// Custom Theming for Angular Material
|
||||
// For more information: https://material.angular.io/guide/theming
|
||||
@import '~@angular/material/theming';
|
||||
// Plus imports for other components in your app.
|
||||
|
||||
// Include the common styles for Angular Material. We include this here so that you only
|
||||
// have to load a single css file for Angular Material in your app.
|
||||
// Be sure that you only ever include this mixin once!
|
||||
@include mat-core();
|
||||
|
||||
// Define the palettes for your theme using the Material Design palettes available in palette.scss
|
||||
// (imported above). For each palette, you can optionally specify a default, lighter, and darker
|
||||
// hue. Available color palettes: https://material.io/design/color/
|
||||
$app-primary: mat-palette($mat-indigo);
|
||||
$app-accent: mat-palette($mat-pink, A200, A100, A400);
|
||||
|
||||
// The warn palette is optional (defaults to red).
|
||||
$app-warn: mat-palette($mat-red);
|
||||
|
||||
// Create the theme object. A theme consists of configurations for individual
|
||||
// theming systems such as "color" or "typography".
|
||||
$app-theme: mat-light-theme((
|
||||
color: (
|
||||
primary: $app-primary,
|
||||
accent: $app-accent,
|
||||
warn: $app-warn,
|
||||
)
|
||||
));
|
||||
|
||||
// Include theme styles for core and each component used in your app.
|
||||
// Alternatively, you can import and @include the theme mixins for each component
|
||||
// that you are using.
|
||||
@include angular-material-theme($app-theme);
|
||||
|
||||
// Ionic Variables and Theming. For more info, please see:
|
||||
// http://ionicframework.com/docs/theming/
|
||||
|
||||
@@ -495,3 +530,9 @@
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* Importing Bootstrap SCSS file. */
|
||||
@import '~bootstrap/scss/bootstrap';
|
||||
|
||||
html, body { height: 100%; }
|
||||
body { margin: 0; font-family: Roboto, "Helvetica Neue", sans-serif; }
|
||||
|
||||
Reference in New Issue
Block a user