awf-test-lib 0.1.23 → 0.1.25
Sign up to get free protection for your applications and to get access to all the features.
- package/karma.conf.js +44 -0
- package/ng-package.json +7 -0
- package/package.json +10 -30
- package/src/lib/core/core-routing.module.ts +10 -0
- package/src/lib/core/core.module.ts +35 -0
- package/src/lib/core/menu/menu.component.css +18 -0
- package/src/lib/core/menu/menu.component.html +8 -0
- package/src/lib/core/menu/menu.component.spec.ts +23 -0
- package/src/lib/core/menu/menu.component.ts +28 -0
- package/src/lib/core/menu-consomer/menu-consomer.component.html +20 -0
- package/src/lib/core/menu-consomer/menu-consomer.component.scss +20 -0
- package/src/lib/core/menu-consomer/menu-consomer.component.spec.ts +25 -0
- package/src/lib/core/menu-consomer/menu-consomer.component.ts +21 -0
- package/src/lib/core/menu-ge-portal/menu-ge-portal.component.html +7 -0
- package/src/lib/core/menu-ge-portal/menu-ge-portal.component.scss +17 -0
- package/src/lib/core/menu-ge-portal/menu-ge-portal.component.spec.ts +25 -0
- package/src/lib/core/menu-ge-portal/menu-ge-portal.component.ts +83 -0
- package/src/lib/core/menu-warranty/menu-warranty.component.html +20 -0
- package/src/lib/core/menu-warranty/menu-warranty.component.scss +16 -0
- package/src/lib/core/menu-warranty/menu-warranty.component.spec.ts +25 -0
- package/src/lib/core/menu-warranty/menu-warranty.component.ts +31 -0
- package/src/lib/core/not-found/not-found.component.css +31 -0
- package/src/lib/core/not-found/not-found.component.html +6 -0
- package/src/lib/core/not-found/not-found.component.spec.ts +23 -0
- package/src/lib/core/not-found/not-found.component.ts +15 -0
- package/src/lib/core/top-bar/top-bar.component.css +116 -0
- package/src/lib/core/top-bar/top-bar.component.html +1 -0
- package/src/lib/core/top-bar/top-bar.component.spec.ts +23 -0
- package/src/lib/core/top-bar/top-bar.component.ts +39 -0
- package/{lib/models/account.model.d.ts → src/lib/models/account.model.ts} +6 -3
- package/src/lib/models/alternativeDate.model.ts +6 -0
- package/src/lib/models/applicationName.ts +6 -0
- package/{lib/models/cancelPMMailRequest.model.d.ts → src/lib/models/cancelPMMailRequest.model.ts} +3 -1
- package/src/lib/models/customObject.model.ts +4 -0
- package/src/lib/models/detailedPmJob.model.ts +25 -0
- package/src/lib/models/emailStatus.ts +4 -0
- package/src/lib/models/emailType.ts +19 -0
- package/src/lib/models/eventStatus.ts +8 -0
- package/src/lib/models/field.ts +7 -0
- package/src/lib/models/language.ts +4 -0
- package/{lib/models/mailRequest.model.d.ts → src/lib/models/mailRequest.model.ts} +3 -1
- package/src/lib/models/pMGroupedJob.model.ts +4 -0
- package/{lib/models/pmJob.model.d.ts → src/lib/models/pmJob.model.ts} +7 -6
- package/src/lib/models/pmJobRequest.model.ts +6 -0
- package/{lib/models/pmJobStatus.d.ts → src/lib/models/pmJobStatus.ts} +8 -3
- package/src/lib/models/reason.model.ts +7 -0
- package/src/lib/models/reasonCode.ts +9 -0
- package/src/lib/models/reasonContact.ts +7 -0
- package/{lib/models/reportDateMailRequest.model.d.ts → src/lib/models/reportDateMailRequest.model.ts} +3 -1
- package/src/lib/models/role.ts +5 -0
- package/src/lib/models/service.model.ts +8 -0
- package/src/lib/models/serviceName.ts +14 -0
- package/{lib/models/socialLoginRequest.model.d.ts → src/lib/models/socialLoginRequest.model.ts} +1 -1
- package/src/lib/models/socialMadia.ts +4 -0
- package/src/lib/models/stingBoolean.ts +7 -0
- package/src/lib/models/system.ts +15 -0
- package/{lib/models/theme.model.d.ts → src/lib/models/theme.model.ts} +18 -11
- package/src/lib/models/tokenStatus.ts +6 -0
- package/src/lib/models/warranty.ts +18 -0
- package/src/lib/pipes/pipes/pipes.module.ts +14 -0
- package/src/lib/pipes/subrtring-w.pipe.spec.ts +8 -0
- package/src/lib/pipes/subrtring-w.pipe.ts +16 -0
- package/src/lib/pipes/substring.pipe.spec.ts +8 -0
- package/src/lib/pipes/substring.pipe.ts +15 -0
- package/src/lib/shared/choose-another-date/choose-another-date.component.html +12 -0
- package/src/lib/shared/choose-another-date/choose-another-date.component.scss +12 -0
- package/src/lib/shared/choose-another-date/choose-another-date.component.spec.ts +25 -0
- package/src/lib/shared/choose-another-date/choose-another-date.component.ts +127 -0
- package/src/lib/shared/confirm-dialog/confirm-dialog.component.html +26 -0
- package/src/lib/shared/confirm-dialog/confirm-dialog.component.scss +0 -0
- package/src/lib/shared/confirm-dialog/confirm-dialog.component.spec.ts +25 -0
- package/src/lib/shared/confirm-dialog/confirm-dialog.component.ts +39 -0
- package/src/lib/shared/confirm-dialog-contact/confirm-dialog-contact.component.css +0 -0
- package/src/lib/shared/confirm-dialog-contact/confirm-dialog-contact.component.html +19 -0
- package/src/lib/shared/confirm-dialog-contact/confirm-dialog-contact.component.spec.ts +23 -0
- package/src/lib/shared/confirm-dialog-contact/confirm-dialog-contact.component.ts +36 -0
- package/src/lib/shared/confirmed-date-information/confirmed-date-information.component.html +25 -0
- package/src/lib/shared/confirmed-date-information/confirmed-date-information.component.scss +23 -0
- package/src/lib/shared/confirmed-date-information/confirmed-date-information.component.spec.ts +25 -0
- package/src/lib/shared/confirmed-date-information/confirmed-date-information.component.ts +30 -0
- package/src/lib/shared/contact/contact.component.css +144 -0
- package/src/lib/shared/contact/contact.component.html +136 -0
- package/src/lib/shared/contact/contact.component.spec.ts +23 -0
- package/src/lib/shared/contact/contact.component.ts +169 -0
- package/src/lib/shared/contact-support/contact-support.component.html +130 -0
- package/src/lib/shared/contact-support/contact-support.component.scss +10 -0
- package/src/lib/shared/contact-support/contact-support.component.spec.ts +25 -0
- package/src/lib/shared/contact-support/contact-support.component.ts +188 -0
- package/src/lib/shared/dashboard/dashboard.component.html +81 -0
- package/src/lib/shared/dashboard/dashboard.component.scss +5 -0
- package/src/lib/shared/dashboard/dashboard.component.spec.ts +23 -0
- package/src/lib/shared/dashboard/dashboard.component.ts +23 -0
- package/src/lib/shared/maintenance-list/maintenance-list.component.html +105 -0
- package/src/lib/shared/maintenance-list/maintenance-list.component.scss +26 -0
- package/src/lib/shared/maintenance-list/maintenance-list.component.spec.ts +25 -0
- package/src/lib/shared/maintenance-list/maintenance-list.component.ts +403 -0
- package/src/lib/shared/shared-routing.module.ts +10 -0
- package/src/lib/shared/shared.module.ts +80 -0
- package/src/lib/shared/show-links/show-links.component.html +49 -0
- package/src/lib/shared/show-links/show-links.component.scss +0 -0
- package/src/lib/shared/show-links/show-links.component.spec.ts +25 -0
- package/src/lib/shared/show-links/show-links.component.ts +78 -0
- package/src/lib/shared/system-list/system-list.component.css +0 -0
- package/src/lib/shared/system-list/system-list.component.html +40 -0
- package/src/lib/shared/system-list/system-list.component.spec.ts +23 -0
- package/src/lib/shared/system-list/system-list.component.ts +26 -0
- package/{public-api.d.ts → src/public-api.ts} +16 -1
- package/src/test.ts +27 -0
- package/tsconfig.lib.dev.json +10 -0
- package/tsconfig.lib.json +15 -0
- package/tsconfig.lib.pp.json +10 -0
- package/tsconfig.lib.prod.json +10 -0
- package/tsconfig.spec.json +17 -0
- package/esm2020/awf-test-lib.mjs +0 -5
- package/esm2020/lib/core/core-routing.module.mjs +0 -18
- package/esm2020/lib/core/core.module.mjs +0 -51
- package/esm2020/lib/core/menu/menu.component.mjs +0 -40
- package/esm2020/lib/core/menu-consomer/menu-consomer.component.mjs +0 -27
- package/esm2020/lib/core/menu-ge-portal/menu-ge-portal.component.mjs +0 -105
- package/esm2020/lib/core/menu-warranty/menu-warranty.component.mjs +0 -35
- package/esm2020/lib/core/not-found/not-found.component.mjs +0 -19
- package/esm2020/lib/core/top-bar/top-bar.component.mjs +0 -41
- package/esm2020/lib/models/account.model.mjs +0 -3
- package/esm2020/lib/models/alternativeDate.model.mjs +0 -3
- package/esm2020/lib/models/applicationName.mjs +0 -7
- package/esm2020/lib/models/cancelPMMailRequest.model.mjs +0 -4
- package/esm2020/lib/models/customObject.model.mjs +0 -3
- package/esm2020/lib/models/detailedPmJob.model.mjs +0 -3
- package/esm2020/lib/models/emailStatus.mjs +0 -6
- package/esm2020/lib/models/emailType.mjs +0 -17
- package/esm2020/lib/models/eventStatus.mjs +0 -9
- package/esm2020/lib/models/field.mjs +0 -9
- package/esm2020/lib/models/language.mjs +0 -6
- package/esm2020/lib/models/mailRequest.model.mjs +0 -3
- package/esm2020/lib/models/pMGroupedJob.model.mjs +0 -3
- package/esm2020/lib/models/pmJob.model.mjs +0 -3
- package/esm2020/lib/models/pmJobRequest.model.mjs +0 -3
- package/esm2020/lib/models/pmJobStatus.mjs +0 -17
- package/esm2020/lib/models/reason.model.mjs +0 -3
- package/esm2020/lib/models/reasonCode.mjs +0 -9
- package/esm2020/lib/models/reasonContact.mjs +0 -8
- package/esm2020/lib/models/reportDateMailRequest.model.mjs +0 -4
- package/esm2020/lib/models/role.mjs +0 -7
- package/esm2020/lib/models/service.model.mjs +0 -3
- package/esm2020/lib/models/serviceName.mjs +0 -12
- package/esm2020/lib/models/socialLoginRequest.model.mjs +0 -3
- package/esm2020/lib/models/socialMadia.mjs +0 -5
- package/esm2020/lib/models/stingBoolean.mjs +0 -6
- package/esm2020/lib/models/system.mjs +0 -3
- package/esm2020/lib/models/theme.model.mjs +0 -2
- package/esm2020/lib/models/tokenStatus.mjs +0 -7
- package/esm2020/lib/models/warranty.mjs +0 -3
- package/esm2020/lib/pipes/pipes/pipes.module.mjs +0 -21
- package/esm2020/lib/pipes/subrtring-w.pipe.mjs +0 -20
- package/esm2020/lib/pipes/substring.pipe.mjs +0 -16
- package/esm2020/lib/shared/choose-another-date/choose-another-date.component.mjs +0 -110
- package/esm2020/lib/shared/confirm-dialog/confirm-dialog.component.mjs +0 -45
- package/esm2020/lib/shared/confirm-dialog-contact/confirm-dialog-contact.component.mjs +0 -42
- package/esm2020/lib/shared/confirmed-date-information/confirmed-date-information.component.mjs +0 -39
- package/esm2020/lib/shared/contact/contact.component.mjs +0 -160
- package/esm2020/lib/shared/contact-support/contact-support.component.mjs +0 -172
- package/esm2020/lib/shared/dashboard/dashboard.component.mjs +0 -35
- package/esm2020/lib/shared/maintenance-list/maintenance-list.component.mjs +0 -352
- package/esm2020/lib/shared/shared-routing.module.mjs +0 -18
- package/esm2020/lib/shared/shared.module.mjs +0 -144
- package/esm2020/lib/shared/show-links/show-links.component.mjs +0 -80
- package/esm2020/lib/shared/system-list/system-list.component.mjs +0 -33
- package/esm2020/public-api.mjs +0 -48
- package/fesm2015/awf-test-lib.mjs +0 -1654
- package/fesm2015/awf-test-lib.mjs.map +0 -1
- package/fesm2020/awf-test-lib.mjs +0 -1650
- package/fesm2020/awf-test-lib.mjs.map +0 -1
- package/index.d.ts +0 -5
- package/lib/core/core-routing.module.d.ts +0 -7
- package/lib/core/core.module.d.ts +0 -15
- package/lib/core/menu/menu.component.d.ts +0 -17
- package/lib/core/menu-consomer/menu-consomer.component.d.ts +0 -12
- package/lib/core/menu-ge-portal/menu-ge-portal.component.d.ts +0 -20
- package/lib/core/menu-warranty/menu-warranty.component.d.ts +0 -15
- package/lib/core/not-found/not-found.component.d.ts +0 -10
- package/lib/core/top-bar/top-bar.component.d.ts +0 -13
- package/lib/models/alternativeDate.model.d.ts +0 -6
- package/lib/models/applicationName.d.ts +0 -5
- package/lib/models/customObject.model.d.ts +0 -3
- package/lib/models/detailedPmJob.model.d.ts +0 -23
- package/lib/models/emailStatus.d.ts +0 -4
- package/lib/models/emailType.d.ts +0 -15
- package/lib/models/eventStatus.d.ts +0 -7
- package/lib/models/field.d.ts +0 -7
- package/lib/models/language.d.ts +0 -4
- package/lib/models/pMGroupedJob.model.d.ts +0 -3
- package/lib/models/pmJobRequest.model.d.ts +0 -5
- package/lib/models/reason.model.d.ts +0 -4
- package/lib/models/reasonCode.d.ts +0 -7
- package/lib/models/reasonContact.d.ts +0 -6
- package/lib/models/role.d.ts +0 -5
- package/lib/models/service.model.d.ts +0 -8
- package/lib/models/serviceName.d.ts +0 -10
- package/lib/models/socialMadia.d.ts +0 -3
- package/lib/models/stingBoolean.d.ts +0 -4
- package/lib/models/system.d.ts +0 -14
- package/lib/models/tokenStatus.d.ts +0 -5
- package/lib/models/warranty.d.ts +0 -17
- package/lib/pipes/pipes/pipes.module.d.ts +0 -9
- package/lib/pipes/subrtring-w.pipe.d.ts +0 -7
- package/lib/pipes/substring.pipe.d.ts +0 -7
- package/lib/shared/choose-another-date/choose-another-date.component.d.ts +0 -33
- package/lib/shared/confirm-dialog/confirm-dialog.component.d.ts +0 -21
- package/lib/shared/confirm-dialog-contact/confirm-dialog-contact.component.d.ts +0 -19
- package/lib/shared/confirmed-date-information/confirmed-date-information.component.d.ts +0 -17
- package/lib/shared/contact/contact.component.d.ts +0 -39
- package/lib/shared/contact-support/contact-support.component.d.ts +0 -50
- package/lib/shared/dashboard/dashboard.component.d.ts +0 -18
- package/lib/shared/maintenance-list/maintenance-list.component.d.ts +0 -81
- package/lib/shared/shared-routing.module.d.ts +0 -7
- package/lib/shared/shared.module.d.ts +0 -40
- package/lib/shared/show-links/show-links.component.d.ts +0 -24
- package/lib/shared/system-list/system-list.component.d.ts +0 -16
@@ -0,0 +1,25 @@
|
|
1
|
+
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
2
|
+
|
3
|
+
import { ChooseAnotherDateComponent } from './choose-another-date.component';
|
4
|
+
|
5
|
+
describe('ChooseAnotherDateComponent', () => {
|
6
|
+
let component: ChooseAnotherDateComponent;
|
7
|
+
let fixture: ComponentFixture<ChooseAnotherDateComponent>;
|
8
|
+
|
9
|
+
beforeEach(async () => {
|
10
|
+
await TestBed.configureTestingModule({
|
11
|
+
declarations: [ ChooseAnotherDateComponent ]
|
12
|
+
})
|
13
|
+
.compileComponents();
|
14
|
+
});
|
15
|
+
|
16
|
+
beforeEach(() => {
|
17
|
+
fixture = TestBed.createComponent(ChooseAnotherDateComponent);
|
18
|
+
component = fixture.componentInstance;
|
19
|
+
fixture.detectChanges();
|
20
|
+
});
|
21
|
+
|
22
|
+
it('should create', () => {
|
23
|
+
expect(component).toBeTruthy();
|
24
|
+
});
|
25
|
+
});
|
@@ -0,0 +1,127 @@
|
|
1
|
+
import { Component, EventEmitter, Input,OnChanges,OnInit,Output, ViewChild, ViewEncapsulation } from '@angular/core';
|
2
|
+
import { MessageService } from 'primeng/api';
|
3
|
+
import { Calendar } from 'primeng/calendar';
|
4
|
+
import { AlternativeDate } from '../../models/alternativeDate.model';
|
5
|
+
import { PrimeNGConfig } from 'primeng/api';
|
6
|
+
@Component({
|
7
|
+
selector: 'app-choose-another-date',
|
8
|
+
templateUrl: './choose-another-date.component.html',
|
9
|
+
styleUrls: ['./choose-another-date.component.scss'],
|
10
|
+
encapsulation: ViewEncapsulation.None,
|
11
|
+
})
|
12
|
+
export class ChooseAnotherDateComponent implements OnChanges, OnInit {
|
13
|
+
@Input() displayAnotherDate!: boolean;
|
14
|
+
@Input() globaltranslate!: any;
|
15
|
+
@Input() translate!: any;
|
16
|
+
@Input() alternativeDatesList!: AlternativeDate[];
|
17
|
+
@Output() closeAnotherDate = new EventEmitter<boolean>();
|
18
|
+
@Output() acceptDate = new EventEmitter<AlternativeDate[]>();
|
19
|
+
@ViewChild('calendar') calendar!: Calendar;
|
20
|
+
|
21
|
+
dates: Date[]= [];
|
22
|
+
datesRef: Date[]= [];
|
23
|
+
selectedDate !: any;
|
24
|
+
show=false;
|
25
|
+
dateslength = 0 ;
|
26
|
+
indexSelectedDate = 0;
|
27
|
+
constructor(private messageService :MessageService) {}
|
28
|
+
|
29
|
+
ngOnInit(): void {
|
30
|
+
this.loadDates() ;
|
31
|
+
}
|
32
|
+
|
33
|
+
ngOnChanges(): void {}
|
34
|
+
|
35
|
+
close()
|
36
|
+
{
|
37
|
+
this.closeAnotherDate.emit(true);
|
38
|
+
this.messageService.add({ severity: 'error', summary: this.globaltranslate.summaryReject, detail: this.globaltranslate.detailReject });
|
39
|
+
}
|
40
|
+
|
41
|
+
|
42
|
+
accept()
|
43
|
+
{
|
44
|
+
this.controlAlternativeDates();
|
45
|
+
|
46
|
+
this.acceptDate.emit(this.alternativeDatesList);
|
47
|
+
}
|
48
|
+
|
49
|
+
askDate()
|
50
|
+
{
|
51
|
+
this.closeAnotherDate.emit(false);
|
52
|
+
|
53
|
+
}
|
54
|
+
|
55
|
+
|
56
|
+
controlAlternativeDates()
|
57
|
+
{
|
58
|
+
let i = 0;
|
59
|
+
this.alternativeDatesList.forEach((item :AlternativeDate )=>
|
60
|
+
{
|
61
|
+
item.selected = (i===this.indexSelectedDate) ? "Yes" : "No";
|
62
|
+
i++
|
63
|
+
});
|
64
|
+
}
|
65
|
+
|
66
|
+
|
67
|
+
loadDates()
|
68
|
+
{
|
69
|
+
this.dates =[] ;
|
70
|
+
this.datesRef =[] ;
|
71
|
+
if(this.alternativeDatesList)
|
72
|
+
{
|
73
|
+
this.alternativeDatesList.forEach((element : AlternativeDate) => {
|
74
|
+
this.dates.push( new Date(element.startDateTime));
|
75
|
+
this.datesRef.push( new Date(element.startDateTime));
|
76
|
+
});
|
77
|
+
|
78
|
+
}
|
79
|
+
this.dateslength = this.dates.length ;
|
80
|
+
}
|
81
|
+
|
82
|
+
onSelect()
|
83
|
+
{
|
84
|
+
if( this.dateslength < this.dates.length )
|
85
|
+
{
|
86
|
+
this.loadDates();
|
87
|
+
}
|
88
|
+
else if(this.dateslength > this.dates.length)
|
89
|
+
{
|
90
|
+
this.selectedDate = this.arrdiff(this.datesRef,this.dates)[0];
|
91
|
+
|
92
|
+
for (var i = 0; i < this.datesRef.length; i++) {
|
93
|
+
if(this.datesRef[i] == this.selectedDate )
|
94
|
+
{
|
95
|
+
this.indexSelectedDate = i;
|
96
|
+
}
|
97
|
+
}
|
98
|
+
this.controlAlternativeDates();
|
99
|
+
this.accept();
|
100
|
+
this.loadDates() ;
|
101
|
+
}
|
102
|
+
this.dates ;
|
103
|
+
}
|
104
|
+
|
105
|
+
|
106
|
+
arrdiff (a1 :any, a2 :any) {
|
107
|
+
var a = [], diff = [];
|
108
|
+
for (var i = 0; i < a1.length; i++) {
|
109
|
+
a[a1[i]] = true;
|
110
|
+
}
|
111
|
+
for (var i = 0; i < a2.length; i++) {
|
112
|
+
if (a[a2[i]]) {
|
113
|
+
delete a[a2[i]];
|
114
|
+
} else {
|
115
|
+
a[a2[i]] = true;
|
116
|
+
}
|
117
|
+
}
|
118
|
+
for (var k in a) {
|
119
|
+
diff.push(k);
|
120
|
+
}
|
121
|
+
return diff;
|
122
|
+
}
|
123
|
+
|
124
|
+
}
|
125
|
+
|
126
|
+
|
127
|
+
|
@@ -0,0 +1,26 @@
|
|
1
|
+
<p-dialog [header]="globaltranslate.confirmation" [(visible)]="displayConfirmDialog" [modal]="true" [style]="{width: '50vw'}" (onHide)="rejectDate()" [maximizable]="true" [baseZIndex]="10000" [draggable]="false" [resizable]="false">
|
2
|
+
<div>
|
3
|
+
{{ isProposedDate ? translate.textProposed : translate.textAlternative }}
|
4
|
+
<div>
|
5
|
+
<br> <br>{{translate.start}} : <i class="pi pi-calendar"></i> <strong>
|
6
|
+
{{startDateTime | date: "EEE dd MMM yyyy":"":language}} </strong> {{translate.from}}: <strong>08:00 </strong>
|
7
|
+
<div *ngIf="detailedPmJobLinkedList.length>0">
|
8
|
+
<br> <p style="color:rgb(245, 57, 57) ;"><strong>{{ translate.textWarn }}</strong></p>
|
9
|
+
<ul>
|
10
|
+
<strong><li *ngFor="let detailedPmJob of detailedPmJobLinkedList">{{ detailedPmJob.pmJob.workorderNumber }}</li></strong>
|
11
|
+
|
12
|
+
</ul>
|
13
|
+
</div>
|
14
|
+
<br><br>
|
15
|
+
<p>{{translate.infoEmail}}</p>
|
16
|
+
|
17
|
+
</div>
|
18
|
+
|
19
|
+
</div>
|
20
|
+
|
21
|
+
<ng-template pTemplate="footer">
|
22
|
+
<p-button icon="pi pi-times" (click)="rejectDate()" class="annuler" [label]="globaltranslate.no"></p-button>
|
23
|
+
<p-button icon="pi pi-check" (click)="confirmDate()" [label]="globaltranslate.yes" class="p-button-text"></p-button>
|
24
|
+
</ng-template>
|
25
|
+
</p-dialog>
|
26
|
+
<p-toast position="top-center"></p-toast>
|
File without changes
|
@@ -0,0 +1,25 @@
|
|
1
|
+
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
2
|
+
|
3
|
+
import { ConfirmDialogComponent } from './confirm-dialog.component';
|
4
|
+
|
5
|
+
describe('ConfirmDialogComponent', () => {
|
6
|
+
let component: ConfirmDialogComponent;
|
7
|
+
let fixture: ComponentFixture<ConfirmDialogComponent>;
|
8
|
+
|
9
|
+
beforeEach(async () => {
|
10
|
+
await TestBed.configureTestingModule({
|
11
|
+
declarations: [ ConfirmDialogComponent ]
|
12
|
+
})
|
13
|
+
.compileComponents();
|
14
|
+
});
|
15
|
+
|
16
|
+
beforeEach(() => {
|
17
|
+
fixture = TestBed.createComponent(ConfirmDialogComponent);
|
18
|
+
component = fixture.componentInstance;
|
19
|
+
fixture.detectChanges();
|
20
|
+
});
|
21
|
+
|
22
|
+
it('should create', () => {
|
23
|
+
expect(component).toBeTruthy();
|
24
|
+
});
|
25
|
+
});
|
@@ -0,0 +1,39 @@
|
|
1
|
+
import { Component, EventEmitter, Input, Output } from '@angular/core';
|
2
|
+
import { MessageService } from 'primeng/api';
|
3
|
+
import { DetailedPmJob } from '../../models/detailedPmJob.model';
|
4
|
+
@Component({
|
5
|
+
selector: 'app-confirm-dialog',
|
6
|
+
templateUrl: './confirm-dialog.component.html',
|
7
|
+
styleUrls: ['./confirm-dialog.component.scss']
|
8
|
+
})
|
9
|
+
export class ConfirmDialogComponent {
|
10
|
+
@Input() displayConfirmDialog!: boolean;
|
11
|
+
@Input() startDateTime!: any;
|
12
|
+
@Input() endDateTime!: any;
|
13
|
+
@Input() globaltranslate!: any;
|
14
|
+
@Input() translate!: any;
|
15
|
+
@Input() isProposedDate!: boolean;
|
16
|
+
@Input() detailedPmJobLinkedList: DetailedPmJob[] = [];
|
17
|
+
|
18
|
+
@Output() closeConfirmDialog = new EventEmitter<boolean>();
|
19
|
+
|
20
|
+
languageStored : string | null = localStorage.getItem("lang");
|
21
|
+
language: string = this.languageStored ? this.languageStored : navigator.language.substr(0, 2).toLowerCase();
|
22
|
+
|
23
|
+
constructor(private messageService :MessageService) {
|
24
|
+
}
|
25
|
+
|
26
|
+
|
27
|
+
|
28
|
+
rejectDate()
|
29
|
+
{
|
30
|
+
this.closeConfirmDialog.emit(false);
|
31
|
+
this.messageService.add({ severity: 'error', summary: this.globaltranslate.summaryReject, detail: this.globaltranslate.detailReject });
|
32
|
+
}
|
33
|
+
|
34
|
+
confirmDate()
|
35
|
+
{
|
36
|
+
this.closeConfirmDialog.emit(true);
|
37
|
+
}
|
38
|
+
|
39
|
+
}
|
File without changes
|
@@ -0,0 +1,19 @@
|
|
1
|
+
<p-dialog [header]="globaltranslate.confirmation" [(visible)]="displayConfirmDialogContact" [modal]="true" [style]="{width: '50vw'}" (onHide)="rejectDate()" [maximizable]="true" [baseZIndex]="10000" [draggable]="false" [resizable]="false">
|
2
|
+
{{ translate.text }}<br>
|
3
|
+
<!-- <br>{{translate.start}} : <i class="pi pi-calendar"></i> <strong>
|
4
|
+
{{startDateTime | date: 'dd MMM yyyy'}} </strong> {{translate.from}}: <strong>08:00 </strong> -->
|
5
|
+
<div *ngIf="detailedPmJobLinkedList.length>0">
|
6
|
+
<br> <p style="color:rgb(245, 57, 57) ;"><strong>{{ translate.textWarn }}</strong></p>
|
7
|
+
<ul>
|
8
|
+
<strong><li *ngFor="let detailedPmJob of detailedPmJobLinkedList">{{ detailedPmJob.pmJob.workorderNumber }}</li></strong>
|
9
|
+
|
10
|
+
</ul>
|
11
|
+
</div>
|
12
|
+
<br><br>
|
13
|
+
<!-- <p>{{translate.infoEmail}}</p> -->
|
14
|
+
<ng-template pTemplate="footer">
|
15
|
+
<p-button icon="pi pi-times" (click)="rejectDate()" class="annuler" [label]="globaltranslate.no"></p-button>
|
16
|
+
<p-button icon="pi pi-check" (click)="confirmDate()" [label]="globaltranslate.yes" class="p-button-text"></p-button>
|
17
|
+
</ng-template>
|
18
|
+
</p-dialog>
|
19
|
+
<p-toast position="top-center"></p-toast>
|
@@ -0,0 +1,23 @@
|
|
1
|
+
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
2
|
+
|
3
|
+
import { ConfirmDialogContactComponent } from './confirm-dialog-contact.component';
|
4
|
+
|
5
|
+
describe('ConfirmDialogContactComponent', () => {
|
6
|
+
let component: ConfirmDialogContactComponent;
|
7
|
+
let fixture: ComponentFixture<ConfirmDialogContactComponent>;
|
8
|
+
|
9
|
+
beforeEach(async () => {
|
10
|
+
await TestBed.configureTestingModule({
|
11
|
+
declarations: [ ConfirmDialogContactComponent ]
|
12
|
+
})
|
13
|
+
.compileComponents();
|
14
|
+
|
15
|
+
fixture = TestBed.createComponent(ConfirmDialogContactComponent);
|
16
|
+
component = fixture.componentInstance;
|
17
|
+
fixture.detectChanges();
|
18
|
+
});
|
19
|
+
|
20
|
+
it('should create', () => {
|
21
|
+
expect(component).toBeTruthy();
|
22
|
+
});
|
23
|
+
});
|
@@ -0,0 +1,36 @@
|
|
1
|
+
import { Component, EventEmitter, Input, Output } from '@angular/core';
|
2
|
+
import { MessageService } from 'primeng/api';
|
3
|
+
import { DetailedPmJob } from '../../models/detailedPmJob.model';
|
4
|
+
|
5
|
+
@Component({
|
6
|
+
selector: 'app-confirm-dialog-contact',
|
7
|
+
templateUrl: './confirm-dialog-contact.component.html',
|
8
|
+
styleUrls: ['./confirm-dialog-contact.component.css']
|
9
|
+
})
|
10
|
+
export class ConfirmDialogContactComponent {
|
11
|
+
|
12
|
+
@Input() displayConfirmDialogContact!: boolean;
|
13
|
+
@Input() startDateTime!: any;
|
14
|
+
@Input() endDateTime!: any;
|
15
|
+
@Input() globaltranslate!: any;
|
16
|
+
@Input() translate!: any;
|
17
|
+
@Input() detailedPmJobLinkedList: DetailedPmJob[] = [];
|
18
|
+
|
19
|
+
@Output() closeConfirmDialogContact = new EventEmitter<boolean>();
|
20
|
+
|
21
|
+
constructor(private messageService :MessageService) { }
|
22
|
+
|
23
|
+
|
24
|
+
|
25
|
+
rejectDate()
|
26
|
+
{
|
27
|
+
this.closeConfirmDialogContact.emit(false);
|
28
|
+
this.messageService.add({ severity: 'error', summary: this.globaltranslate.summaryReject, detail: this.globaltranslate.detailReject });
|
29
|
+
}
|
30
|
+
|
31
|
+
confirmDate()
|
32
|
+
{
|
33
|
+
this.closeConfirmDialogContact.emit(true);
|
34
|
+
}
|
35
|
+
|
36
|
+
}
|
@@ -0,0 +1,25 @@
|
|
1
|
+
<p-dialog [header]="globaltranslate.information" [(visible)]="displayConfirmedDateInfos" [modal]="true" [style]="{width: '50vw'}" (onHide)="confirmDate()" [maximizable]="true" [baseZIndex]="10000" [draggable]="false" [resizable]="false">
|
2
|
+
<i class="pi pi-check icon-check"></i>
|
3
|
+
|
4
|
+
|
5
|
+
<div *ngIf="moreDates" style="text-align:center ;">
|
6
|
+
<br><br>
|
7
|
+
{{translate.textMoreDates}}
|
8
|
+
<br><br>
|
9
|
+
|
10
|
+
</div>
|
11
|
+
<div *ngIf="!moreDates">
|
12
|
+
<div class="text-center">
|
13
|
+
<p> {{translate.text }} <br> {{translate.start}} : <i class="pi pi-calendar"></i> <strong>
|
14
|
+
{{startDateTime | date: "EEE dd MMM yyyy":"":language}}</strong> <br> {{translate.from}}: <strong>08:00 </strong> </p>
|
15
|
+
</div>
|
16
|
+
<br><br>
|
17
|
+
<p>{{translate.infoEmail}}</p>
|
18
|
+
|
19
|
+
</div>
|
20
|
+
|
21
|
+
|
22
|
+
<ng-template pTemplate="footer">
|
23
|
+
<p-button icon="pi pi-times " (click)="confirmDate()" label="Close" class=" text-center d-block"></p-button>
|
24
|
+
</ng-template>
|
25
|
+
</p-dialog>
|
@@ -0,0 +1,23 @@
|
|
1
|
+
p-dialog{
|
2
|
+
p{
|
3
|
+
font-size: 14px;
|
4
|
+
line-height: 34px;
|
5
|
+
margin-top: 30px;
|
6
|
+
}
|
7
|
+
.icon-check{
|
8
|
+
text-align: center;
|
9
|
+
color: white;
|
10
|
+
background: var(--primarycolor);
|
11
|
+
width: 80px;
|
12
|
+
height: 80px;
|
13
|
+
display: flex ;
|
14
|
+
justify-content: center;
|
15
|
+
align-items: center;
|
16
|
+
border-radius: 50%;
|
17
|
+
font-size: 30px;
|
18
|
+
font-weight: bold;
|
19
|
+
margin:auto;
|
20
|
+
}
|
21
|
+
|
22
|
+
}
|
23
|
+
|
package/src/lib/shared/confirmed-date-information/confirmed-date-information.component.spec.ts
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
2
|
+
|
3
|
+
import { ConfirmedDateInformationComponent } from './confirmed-date-information.component';
|
4
|
+
|
5
|
+
describe('ConfirmedDateInformationComponent', () => {
|
6
|
+
let component: ConfirmedDateInformationComponent;
|
7
|
+
let fixture: ComponentFixture<ConfirmedDateInformationComponent>;
|
8
|
+
|
9
|
+
beforeEach(async () => {
|
10
|
+
await TestBed.configureTestingModule({
|
11
|
+
declarations: [ ConfirmedDateInformationComponent ]
|
12
|
+
})
|
13
|
+
.compileComponents();
|
14
|
+
});
|
15
|
+
|
16
|
+
beforeEach(() => {
|
17
|
+
fixture = TestBed.createComponent(ConfirmedDateInformationComponent);
|
18
|
+
component = fixture.componentInstance;
|
19
|
+
fixture.detectChanges();
|
20
|
+
});
|
21
|
+
|
22
|
+
it('should create', () => {
|
23
|
+
expect(component).toBeTruthy();
|
24
|
+
});
|
25
|
+
});
|
@@ -0,0 +1,30 @@
|
|
1
|
+
import { Component, EventEmitter, Input, Output, OnDestroy } from '@angular/core';
|
2
|
+
|
3
|
+
@Component({
|
4
|
+
selector: 'app-confirmed-date-information',
|
5
|
+
templateUrl: './confirmed-date-information.component.html',
|
6
|
+
styleUrls: ['./confirmed-date-information.component.scss']
|
7
|
+
})
|
8
|
+
export class ConfirmedDateInformationComponent implements OnDestroy {
|
9
|
+
@Input() displayConfirmedDateInfos!: boolean;
|
10
|
+
@Input() startDateTime!: any;
|
11
|
+
@Input() endDateTime!: any;
|
12
|
+
@Input() globaltranslate!: any;
|
13
|
+
@Input() translate!: any;
|
14
|
+
@Input() moreDates!: boolean;
|
15
|
+
@Output() closeConfirmedDateInfo = new EventEmitter<boolean>();
|
16
|
+
languageStored : string | null = localStorage.getItem("lang");
|
17
|
+
language: string = this.languageStored ? this.languageStored : navigator.language.substr(0, 2).toLowerCase();
|
18
|
+
constructor() { }
|
19
|
+
|
20
|
+
ngOnDestroy(): void {
|
21
|
+
// this.displayConfirmedDateInfos = false;
|
22
|
+
}
|
23
|
+
|
24
|
+
|
25
|
+
confirmDate()
|
26
|
+
{
|
27
|
+
this.closeConfirmedDateInfo.emit(true);
|
28
|
+
}
|
29
|
+
|
30
|
+
}
|
@@ -0,0 +1,144 @@
|
|
1
|
+
h1, h2, h3, h4, h5, h6, p, span, label, ::placeholder {
|
2
|
+
font-family: var(--font);
|
3
|
+
}
|
4
|
+
.app-section-header-img {
|
5
|
+
background-image: url('/assets/img/GEPortal/contact.png');
|
6
|
+
background-repeat: no-repeat;
|
7
|
+
background-size: cover;
|
8
|
+
background-position: center center;
|
9
|
+
display: flex;
|
10
|
+
align-items: center;
|
11
|
+
height: 237px;
|
12
|
+
}
|
13
|
+
@media (max-width: var(--smallscreen)) {
|
14
|
+
.app-section-header-img {
|
15
|
+
height: auto;
|
16
|
+
}
|
17
|
+
}
|
18
|
+
.app-section-header-img h2 {
|
19
|
+
font-size: 48px;
|
20
|
+
font-family: var(--font);
|
21
|
+
font-weight: 600;
|
22
|
+
color: white;
|
23
|
+
text-align: center;
|
24
|
+
}
|
25
|
+
@media (max-width: var(--smallscreen)) {
|
26
|
+
.app-section-header-img h2 {
|
27
|
+
font-size: 30px;
|
28
|
+
}
|
29
|
+
}
|
30
|
+
@media (max-width: var(--smallscreen)) {
|
31
|
+
.app-section-header-img {
|
32
|
+
padding-left: 15px;
|
33
|
+
padding-right: 15px;
|
34
|
+
}
|
35
|
+
}
|
36
|
+
@media (max-width: var(--tinyscreen)) {
|
37
|
+
.app-section-header-img {
|
38
|
+
height: 200px;
|
39
|
+
}
|
40
|
+
}
|
41
|
+
h2 {
|
42
|
+
font-weight: 600;
|
43
|
+
}
|
44
|
+
a:focus {
|
45
|
+
outline: none !important;
|
46
|
+
}
|
47
|
+
a:hover {
|
48
|
+
text-decoration: none;
|
49
|
+
}
|
50
|
+
input {
|
51
|
+
outline: none;
|
52
|
+
border: none;
|
53
|
+
}
|
54
|
+
input.input100 {
|
55
|
+
height: 62px;
|
56
|
+
padding: 0 20px 0 58px;
|
57
|
+
}
|
58
|
+
input[type="number"] {
|
59
|
+
-moz-appearance: textfield;
|
60
|
+
appearance: none;
|
61
|
+
-webkit-appearance: none;
|
62
|
+
}
|
63
|
+
input[type="number"]::-webkit-outer-spin-button, input[type="number"]::-webkit-inner-spin-button {
|
64
|
+
-webkit-appearance: none;
|
65
|
+
}
|
66
|
+
textarea {
|
67
|
+
outline: none;
|
68
|
+
border: none;
|
69
|
+
}
|
70
|
+
textarea.input100 {
|
71
|
+
min-height: 199px;
|
72
|
+
padding: 19px 20px 0 23px;
|
73
|
+
}
|
74
|
+
textarea:focus, input:focus {
|
75
|
+
border-color: transparent !important;
|
76
|
+
}
|
77
|
+
.container-contact100 {
|
78
|
+
display: flex;
|
79
|
+
flex-wrap: wrap;
|
80
|
+
justify-content: center;
|
81
|
+
align-items: center;
|
82
|
+
padding: 15px;
|
83
|
+
}
|
84
|
+
.wrap-contact100 {
|
85
|
+
width: 550px;
|
86
|
+
background: transparent;
|
87
|
+
padding: 30px 0 80px 0;
|
88
|
+
}
|
89
|
+
.contact100-form-title {
|
90
|
+
display: block;
|
91
|
+
font-family: var(--font);
|
92
|
+
font-size: 30px;
|
93
|
+
color: #43383e;
|
94
|
+
line-height: 1.2;
|
95
|
+
text-align: left;
|
96
|
+
padding-bottom: 35px;
|
97
|
+
}
|
98
|
+
.wrap-input100 {
|
99
|
+
width: 100%;
|
100
|
+
position: relative;
|
101
|
+
background-color: #fff;
|
102
|
+
margin-bottom: 17px;
|
103
|
+
}
|
104
|
+
.label-input100 {
|
105
|
+
display: flex;
|
106
|
+
justify-content: center;
|
107
|
+
align-items: center;
|
108
|
+
width: 58px;
|
109
|
+
height: 62px;
|
110
|
+
position: absolute;
|
111
|
+
top: 0;
|
112
|
+
left: 0;
|
113
|
+
cursor: pointer;
|
114
|
+
font-size: 18px;
|
115
|
+
color: #999999;
|
116
|
+
}
|
117
|
+
.input100 {
|
118
|
+
display: block;
|
119
|
+
width: 100%;
|
120
|
+
background: transparent;
|
121
|
+
font-size: 15px;
|
122
|
+
color: #43383e;
|
123
|
+
line-height: 1.2;
|
124
|
+
padding: 0 5px;
|
125
|
+
}
|
126
|
+
@media (max-width: var(--smallscreen)) {
|
127
|
+
.contact iframe {
|
128
|
+
width: auto;
|
129
|
+
}
|
130
|
+
}
|
131
|
+
.contact label {
|
132
|
+
margin-left: 10px;
|
133
|
+
color: #a2a2a2;
|
134
|
+
font-weight: bold;
|
135
|
+
}
|
136
|
+
.contact i {
|
137
|
+
color: #a2a2a2;
|
138
|
+
font-weight: bold;
|
139
|
+
}
|
140
|
+
.contact .social li {
|
141
|
+
display: inline;
|
142
|
+
padding: 10px;
|
143
|
+
}
|
144
|
+
|