feedback updates
This commit is contained in:
parent
cfcc565099
commit
d31084fad3
@ -0,0 +1 @@
|
|||||||
|
<p>additional-set works!</p>
|
||||||
11
src/app/carnet/additional-set/additional-set.component.ts
Normal file
11
src/app/carnet/additional-set/additional-set.component.ts
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
import { Component } from '@angular/core';
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
selector: 'app-additional-set',
|
||||||
|
imports: [],
|
||||||
|
templateUrl: './additional-set.component.html',
|
||||||
|
styleUrl: './additional-set.component.scss'
|
||||||
|
})
|
||||||
|
export class AdditionalSetComponent {
|
||||||
|
|
||||||
|
}
|
||||||
@ -77,7 +77,7 @@ export class ApplicationComponent {
|
|||||||
name: this.applicationName,
|
name: this.applicationName,
|
||||||
});
|
});
|
||||||
|
|
||||||
if (this.isEditMode) {
|
if (this.isEditMode || this.isViewMode) {
|
||||||
this.applicationDetailsForm.get('name')?.disable();
|
this.applicationDetailsForm.get('name')?.disable();
|
||||||
this.disableSaveButton = true;
|
this.disableSaveButton = true;
|
||||||
}
|
}
|
||||||
|
|||||||
1
src/app/carnet/duplicate/duplicate.component.html
Normal file
1
src/app/carnet/duplicate/duplicate.component.html
Normal file
@ -0,0 +1 @@
|
|||||||
|
<p>duplicate works!</p>
|
||||||
0
src/app/carnet/duplicate/duplicate.component.scss
Normal file
0
src/app/carnet/duplicate/duplicate.component.scss
Normal file
11
src/app/carnet/duplicate/duplicate.component.ts
Normal file
11
src/app/carnet/duplicate/duplicate.component.ts
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
import { Component } from '@angular/core';
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
selector: 'app-duplicate',
|
||||||
|
imports: [],
|
||||||
|
templateUrl: './duplicate.component.html',
|
||||||
|
styleUrl: './duplicate.component.scss'
|
||||||
|
})
|
||||||
|
export class DuplicateComponent {
|
||||||
|
|
||||||
|
}
|
||||||
@ -174,6 +174,10 @@ export class GoodsComponent {
|
|||||||
horseUsed: data.horseUsed || false,
|
horseUsed: data.horseUsed || false,
|
||||||
authorizedRepresentatives: data.authorizedRepresentatives || ''
|
authorizedRepresentatives: data.authorizedRepresentatives || ''
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if (this.isViewMode) {
|
||||||
|
this.goodsForm.disable();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Add new item to the table
|
// Add new item to the table
|
||||||
|
|||||||
@ -0,0 +1 @@
|
|||||||
|
<p>replacement-set works!</p>
|
||||||
11
src/app/carnet/replacement-set/replacement-set.component.ts
Normal file
11
src/app/carnet/replacement-set/replacement-set.component.ts
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
import { Component } from '@angular/core';
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
selector: 'app-replacement-set',
|
||||||
|
imports: [],
|
||||||
|
templateUrl: './replacement-set.component.html',
|
||||||
|
styleUrl: './replacement-set.component.scss'
|
||||||
|
})
|
||||||
|
export class ReplacementSetComponent {
|
||||||
|
|
||||||
|
}
|
||||||
78
src/app/carnet/shipping/fees-dialog.component.ts
Normal file
78
src/app/carnet/shipping/fees-dialog.component.ts
Normal file
@ -0,0 +1,78 @@
|
|||||||
|
import { Component, inject, Inject } from '@angular/core';
|
||||||
|
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
||||||
|
import { AngularMaterialModule } from '../../shared/module/angular-material.module';
|
||||||
|
import { CommonModule } from '@angular/common';
|
||||||
|
import { FormsModule } from '@angular/forms';
|
||||||
|
import { CarnetService } from '../../core/services/carnet/carnet.service';
|
||||||
|
import { Fees } from '../../core/models/carnet/fee';
|
||||||
|
import { ApiErrorHandlerService } from '../../core/services/common/api-error-handler.service';
|
||||||
|
import { NotificationService } from '../../core/services/common/notification.service';
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
selector: 'app-fees-dialog',
|
||||||
|
imports: [AngularMaterialModule, CommonModule, FormsModule],
|
||||||
|
template: `
|
||||||
|
<h3 mat-dialog-title>Fees and Charges</h3>
|
||||||
|
<mat-dialog-content>
|
||||||
|
<p> The following fees apply:</p>
|
||||||
|
<ul>
|
||||||
|
<li *ngIf="estimatedFees.basicFee">Basic fee: {{estimatedFees.basicFee | currency}}</li>
|
||||||
|
<li *ngIf="estimatedFees.counterFoilFee">Counterfoil Fee: {{estimatedFees.counterFoilFee | currency}}
|
||||||
|
</li>
|
||||||
|
<li *ngIf="estimatedFees.continuationSheetFee">Continuation sheet fee:
|
||||||
|
{{estimatedFees.continuationSheetFee | currency}}</li>
|
||||||
|
<li *ngIf="estimatedFees.expeditedFee">Expedited fee: {{estimatedFees.expeditedFee | currency}}</li>
|
||||||
|
<li *ngIf="estimatedFees.shippingFee">Shipping fee: {{estimatedFees.shippingFee | currency}}</li>
|
||||||
|
<li *ngIf="estimatedFees.bondPremium">Bond Premium: {{estimatedFees.bondPremium | currency}}</li>
|
||||||
|
<li *ngIf="estimatedFees.cargoPremium">Cargo Premium: {{estimatedFees.cargoPremium | currency}}</li>
|
||||||
|
<li *ngIf="estimatedFees.ldiPremium">LDI Premium: {{estimatedFees.ldiPremium | currency}}</li>
|
||||||
|
</ul>
|
||||||
|
</mat-dialog-content>
|
||||||
|
<mat-dialog-actions>
|
||||||
|
<button mat-raised-button color="primary" (click)="onClose()">
|
||||||
|
Ok
|
||||||
|
</button>
|
||||||
|
</mat-dialog-actions>
|
||||||
|
`,
|
||||||
|
styles: [`
|
||||||
|
li {
|
||||||
|
margin-bottom: 8px;
|
||||||
|
}
|
||||||
|
`]
|
||||||
|
})
|
||||||
|
export class FeesDialogComponent {
|
||||||
|
estimatedFees: Fees = {};
|
||||||
|
headerid: number | null = null;
|
||||||
|
|
||||||
|
private carnetService = inject(CarnetService);
|
||||||
|
private notificationService = inject(NotificationService);
|
||||||
|
private errorHandler = inject(ApiErrorHandlerService);
|
||||||
|
|
||||||
|
constructor(
|
||||||
|
public dialogRef: MatDialogRef<FeesDialogComponent>,
|
||||||
|
@Inject(MAT_DIALOG_DATA) public data: { headerid: any }
|
||||||
|
) {
|
||||||
|
this.headerid = data.headerid;
|
||||||
|
}
|
||||||
|
|
||||||
|
ngOnInit(): void {
|
||||||
|
if (this.headerid && this.headerid > 0) {
|
||||||
|
this.carnetService.getEstimatedFees(this.headerid).subscribe({
|
||||||
|
next: (data: Fees) => {
|
||||||
|
if (data) {
|
||||||
|
this.estimatedFees = data;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: (error: any) => {
|
||||||
|
let errorMessage = this.errorHandler.handleApiError(error, 'Failed to get estimated fees');
|
||||||
|
this.notificationService.showError(errorMessage);
|
||||||
|
console.error('Error getting estimated fees:', error);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
onClose(): void {
|
||||||
|
this.dialogRef.close();
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -343,6 +343,16 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-actions">
|
<div class="form-actions">
|
||||||
|
<button mat-raised-button color="primary" type="button" (click)="showEstimatedFees()"
|
||||||
|
*ngIf="showEstimatedFeesButton && !isViewMode">
|
||||||
|
<span>Estimated Fees</span>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<button mat-raised-button color="primary" type="submit" *ngIf="!isViewMode"
|
||||||
|
[disabled]="shippingForm.invalid || changeInProgress">
|
||||||
|
Save
|
||||||
|
</button>
|
||||||
|
|
||||||
<button mat-raised-button color="primary" type="button" (click)="processApplication()"
|
<button mat-raised-button color="primary" type="button" (click)="processApplication()"
|
||||||
[disabled]="!enableSubmitButton" *ngIf="showProcessButton && !isViewMode">
|
[disabled]="!enableSubmitButton" *ngIf="showProcessButton && !isViewMode">
|
||||||
<span>Process Application</span>
|
<span>Process Application</span>
|
||||||
@ -353,11 +363,6 @@
|
|||||||
<span>Submit Application</span>
|
<span>Submit Application</span>
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<button mat-raised-button color="primary" type="submit" *ngIf="!isViewMode"
|
|
||||||
[disabled]="shippingForm.invalid || changeInProgress">
|
|
||||||
Save
|
|
||||||
</button>
|
|
||||||
|
|
||||||
<button mat-raised-button color="primary" type="button" (click)="returnToHome()" *ngIf="isViewMode">
|
<button mat-raised-button color="primary" type="button" (click)="returnToHome()" *ngIf="isViewMode">
|
||||||
Back
|
Back
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@ -26,6 +26,7 @@ import { StorageService } from '../../core/services/common/storage.service';
|
|||||||
import { FormOfSecurity } from '../../core/models/formofsecurity';
|
import { FormOfSecurity } from '../../core/models/formofsecurity';
|
||||||
import { CarnetService } from '../../core/services/carnet/carnet.service';
|
import { CarnetService } from '../../core/services/carnet/carnet.service';
|
||||||
import { environment } from '../../../environments/environment';
|
import { environment } from '../../../environments/environment';
|
||||||
|
import { FeesDialogComponent } from './fees-dialog.component';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-shipping',
|
selector: 'app-shipping',
|
||||||
@ -62,7 +63,9 @@ export class ShippingComponent {
|
|||||||
deliveryEstimate: string = '';
|
deliveryEstimate: string = '';
|
||||||
holderid: number = 0;
|
holderid: number = 0;
|
||||||
holder: Holder | undefined | null = null;
|
holder: Holder | undefined | null = null;
|
||||||
|
|
||||||
showSubmitButton: boolean = environment.appType === 'client';
|
showSubmitButton: boolean = environment.appType === 'client';
|
||||||
|
showEstimatedFeesButton: boolean = environment.appType === 'client';
|
||||||
showProcessButton: boolean = environment.appType === 'service-provider';
|
showProcessButton: boolean = environment.appType === 'service-provider';
|
||||||
|
|
||||||
countriesHasStates = ['US', 'CA', 'MX'];
|
countriesHasStates = ['US', 'CA', 'MX'];
|
||||||
@ -444,6 +447,10 @@ export class ShippingComponent {
|
|||||||
this.calculateDeliveryEstimate();
|
this.calculateDeliveryEstimate();
|
||||||
this.shippingForm.markAsUntouched();
|
this.shippingForm.markAsUntouched();
|
||||||
this.completed.emit(this.shippingForm.valid);
|
this.completed.emit(this.shippingForm.valid);
|
||||||
|
|
||||||
|
if (this.isViewMode) {
|
||||||
|
this.shippingForm.disable();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
patchAddressContactData(): void {
|
patchAddressContactData(): void {
|
||||||
@ -460,7 +467,7 @@ export class ShippingComponent {
|
|||||||
if (this.holder?.holderType.trim() === 'GOV') {
|
if (this.holder?.holderType.trim() === 'GOV') {
|
||||||
formOfSecurityControl?.setValue(this.govFormOfSecurities?.[0].value);
|
formOfSecurityControl?.setValue(this.govFormOfSecurities?.[0].value);
|
||||||
formOfSecurityControl?.disable();
|
formOfSecurityControl?.disable();
|
||||||
} else {
|
} else if (!this.isViewMode) {
|
||||||
formOfSecurityControl?.enable();
|
formOfSecurityControl?.enable();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -688,6 +695,13 @@ export class ShippingComponent {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
showEstimatedFees(): void {
|
||||||
|
const dialogRef = this.dialog.open(FeesDialogComponent, {
|
||||||
|
width: '500px',
|
||||||
|
data: { headerid: this.headerid }
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
submitApplication(): void {
|
submitApplication(): void {
|
||||||
this.onSubmit(true);
|
this.onSubmit(true);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -284,6 +284,9 @@ export class TravelPlanComponent {
|
|||||||
});
|
});
|
||||||
|
|
||||||
this.completed.emit(this.travelForm.valid);
|
this.completed.emit(this.travelForm.valid);
|
||||||
|
if (this.isViewMode) {
|
||||||
|
this.travelForm.disable();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onSubmit(): void {
|
onSubmit(): void {
|
||||||
|
|||||||
@ -18,7 +18,7 @@
|
|||||||
<span>{{ userEmail }}</span>
|
<span>{{ userEmail }}</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<button mat-menu-item (click)="navigateTo('/usersettings')">
|
<button mat-menu-item (click)="navigateTo('usersettings')">
|
||||||
<mat-icon>settings</mat-icon>
|
<mat-icon>settings</mat-icon>
|
||||||
<span>User Preferences</span>
|
<span>User Preferences</span>
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@ -33,13 +33,13 @@ export class ShippingService {
|
|||||||
paymentMethod: shippingDetails.PAYMENTMETHOD,
|
paymentMethod: shippingDetails.PAYMENTMETHOD,
|
||||||
|
|
||||||
//needsBond: shippingDetails.BONDPROTECTION === 'Y',
|
//needsBond: shippingDetails.BONDPROTECTION === 'Y',
|
||||||
needsInsurance: shippingDetails.INSPROTECTION === 'Y',
|
needsInsurance: shippingDetails.INSPROTECTION === 'ACCEPT',
|
||||||
needsLostDocProtection: shippingDetails.LDIPROTECTION === 'Y',
|
needsLostDocProtection: shippingDetails.LDIPROTECTION === 'ACCEPT',
|
||||||
formOfSecurity: shippingDetails.FORMOFSECURITY
|
formOfSecurity: shippingDetails.FORMOFSECURITY
|
||||||
};
|
};
|
||||||
|
|
||||||
shippingData.address = {
|
shippingData.address = {
|
||||||
companyName: shippingDetails.P_SHIPNAME,
|
companyName: shippingDetails.SHIPNAME,
|
||||||
addressid: shippingDetails.SHIPADDRESSID,
|
addressid: shippingDetails.SHIPADDRESSID,
|
||||||
address1: shippingDetails.ADDRESS1,
|
address1: shippingDetails.ADDRESS1,
|
||||||
address2: shippingDetails.ADDRESS2,
|
address2: shippingDetails.ADDRESS2,
|
||||||
@ -77,8 +77,8 @@ export class ShippingService {
|
|||||||
P_PAYMENTMETHOD: shippingData.paymentMethod,
|
P_PAYMENTMETHOD: shippingData.paymentMethod,
|
||||||
|
|
||||||
// P_BONDPROTECTION: shippingData.needsBond ? 'Y' : 'N',
|
// P_BONDPROTECTION: shippingData.needsBond ? 'Y' : 'N',
|
||||||
P_INSPROTECTION: shippingData.needsInsurance ? 'Y' : 'N',
|
P_INSPROTECTION: shippingData.needsInsurance ? 'ACCEPT' : 'DECLINE',
|
||||||
P_LDIPROTECTION: shippingData.needsLostDocProtection ? 'Y' : 'N',
|
P_LDIPROTECTION: shippingData.needsLostDocProtection ? 'ACCEPT' : 'DECLINE',
|
||||||
P_FORMOFSECURITY: shippingData.formOfSecurity,
|
P_FORMOFSECURITY: shippingData.formOfSecurity,
|
||||||
|
|
||||||
P_SHIPNAME: shippingData.address?.companyName,
|
P_SHIPNAME: shippingData.address?.companyName,
|
||||||
|
|||||||
@ -38,7 +38,7 @@ export class HomeService {
|
|||||||
expiryDate: item.EXPDATE || null,
|
expiryDate: item.EXPDATE || null,
|
||||||
orderType: item.ORDERTYPE,
|
orderType: item.ORDERTYPE,
|
||||||
carnetStatus: item.CARNETSTATUS,
|
carnetStatus: item.CARNETSTATUS,
|
||||||
headerId: item.HEADERID,
|
headerid: item.HEADERID,
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -14,6 +14,7 @@ import { BasicDetailService } from '../../core/services/holder/basic-detail.serv
|
|||||||
import { BasicDetail } from '../../core/models/holder/basic-detail';
|
import { BasicDetail } from '../../core/models/holder/basic-detail';
|
||||||
import { StorageService } from '../../core/services/common/storage.service';
|
import { StorageService } from '../../core/services/common/storage.service';
|
||||||
import { NavigationService } from '../../core/services/common/navigation.service';
|
import { NavigationService } from '../../core/services/common/navigation.service';
|
||||||
|
import { environment } from '../../../environments/environment';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-basic-detail',
|
selector: 'app-basic-detail',
|
||||||
@ -37,6 +38,7 @@ export class BasicDetailComponent implements OnInit, OnDestroy {
|
|||||||
isLoading = false;
|
isLoading = false;
|
||||||
changeInProgress = false;
|
changeInProgress = false;
|
||||||
countriesHasStates = ['US', 'CA', 'MX'];
|
countriesHasStates = ['US', 'CA', 'MX'];
|
||||||
|
returnTo: string = environment.appType === 'client' ? 'edit-carnet' : 'process-carnet';
|
||||||
|
|
||||||
private destroy$ = new Subject<void>();
|
private destroy$ = new Subject<void>();
|
||||||
|
|
||||||
@ -121,7 +123,7 @@ export class BasicDetailComponent implements OnInit, OnDestroy {
|
|||||||
: this.basicDetailService.createBasicDetail(basicDetailData);
|
: this.basicDetailService.createBasicDetail(basicDetailData);
|
||||||
|
|
||||||
this.changeInProgress = true;
|
this.changeInProgress = true;
|
||||||
|
|
||||||
saveObservable.pipe(finalize(() => {
|
saveObservable.pipe(finalize(() => {
|
||||||
this.changeInProgress = false;
|
this.changeInProgress = false;
|
||||||
})).subscribe({
|
})).subscribe({
|
||||||
@ -215,7 +217,7 @@ export class BasicDetailComponent implements OnInit, OnDestroy {
|
|||||||
|
|
||||||
goBackToCarnetApplication(): void {
|
goBackToCarnetApplication(): void {
|
||||||
this.storageService.removeItem('currentapplication')
|
this.storageService.removeItem('currentapplication')
|
||||||
this.navigationService.navigate(["edit-carnet", this.currentApplicationDetails?.headerid],
|
this.navigationService.navigate([this.returnTo, this.currentApplicationDetails?.headerid],
|
||||||
{
|
{
|
||||||
state: { isEditMode: true },
|
state: { isEditMode: true },
|
||||||
queryParams: {
|
queryParams: {
|
||||||
|
|||||||
@ -17,6 +17,7 @@ import { ConfirmDialogComponent } from '../../shared/components/confirm-dialog/c
|
|||||||
import { NavigationService } from '../../core/services/common/navigation.service';
|
import { NavigationService } from '../../core/services/common/navigation.service';
|
||||||
import { StorageService } from '../../core/services/common/storage.service';
|
import { StorageService } from '../../core/services/common/storage.service';
|
||||||
import { finalize } from 'rxjs';
|
import { finalize } from 'rxjs';
|
||||||
|
import { environment } from '../../../environments/environment';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-contacts',
|
selector: 'app-contacts',
|
||||||
@ -47,6 +48,7 @@ export class ContactsComponent {
|
|||||||
showInactiveContacts = false;
|
showInactiveContacts = false;
|
||||||
contacts: Contact[] = [];
|
contacts: Contact[] = [];
|
||||||
currentApplicationDetails: { headerid: number, applicationName: string } | null = null;
|
currentApplicationDetails: { headerid: number, applicationName: string } | null = null;
|
||||||
|
returnTo: string = environment.appType === 'client' ? 'edit-carnet' : 'process-carnet';
|
||||||
|
|
||||||
contactReadOnlyFields: any = {
|
contactReadOnlyFields: any = {
|
||||||
lastChangedDate: null,
|
lastChangedDate: null,
|
||||||
@ -149,7 +151,7 @@ export class ContactsComponent {
|
|||||||
: this.contactService.createContact(this.holderid, contactData);
|
: this.contactService.createContact(this.holderid, contactData);
|
||||||
|
|
||||||
this.changeInProgress = true;
|
this.changeInProgress = true;
|
||||||
|
|
||||||
saveObservable.pipe(finalize(() => {
|
saveObservable.pipe(finalize(() => {
|
||||||
this.changeInProgress = false;
|
this.changeInProgress = false;
|
||||||
})).subscribe({
|
})).subscribe({
|
||||||
@ -245,7 +247,7 @@ export class ContactsComponent {
|
|||||||
|
|
||||||
goBackToCarnetApplication(): void {
|
goBackToCarnetApplication(): void {
|
||||||
this.storageService.removeItem('currentapplication')
|
this.storageService.removeItem('currentapplication')
|
||||||
this.navigationService.navigate(["edit-carnet", this.currentApplicationDetails?.headerid],
|
this.navigationService.navigate([this.returnTo, this.currentApplicationDetails?.headerid],
|
||||||
{
|
{
|
||||||
state: { isEditMode: true },
|
state: { isEditMode: true },
|
||||||
queryParams: {
|
queryParams: {
|
||||||
|
|||||||
@ -124,6 +124,25 @@
|
|||||||
matTooltip="Edit">
|
matTooltip="Edit">
|
||||||
<mat-icon>edit</mat-icon>
|
<mat-icon>edit</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
|
<button matIconButton [matMenuTriggerFor]="carnetActions">
|
||||||
|
<mat-icon>more_horiz</mat-icon>
|
||||||
|
</button>
|
||||||
|
<mat-menu #carnetActions="matMenu">
|
||||||
|
<button mat-menu-item (click)="viewCarnet(item)">
|
||||||
|
<mat-icon>article</mat-icon>
|
||||||
|
<span>View Carnet</span>
|
||||||
|
</button>
|
||||||
|
<button mat-menu-item (click)="deleteCarnet(item.headerid)"
|
||||||
|
*ngIf="getCarnetStatusLabel(item.carnetStatus) === 'Not Submitted'">
|
||||||
|
<mat-icon>delete</mat-icon>
|
||||||
|
<span>Delete Carnet</span>
|
||||||
|
</button>
|
||||||
|
<button mat-menu-item (click)="printGeneralList(item.headerid)">
|
||||||
|
<mat-icon>print</mat-icon>
|
||||||
|
<span>Print Carnet</span>
|
||||||
|
</button>
|
||||||
|
</mat-menu>
|
||||||
|
<!--
|
||||||
<button mat-icon-button color="primary" (click)="viewCarnet(item)" matTooltip="View">
|
<button mat-icon-button color="primary" (click)="viewCarnet(item)" matTooltip="View">
|
||||||
<mat-icon>article</mat-icon>
|
<mat-icon>article</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
@ -134,7 +153,7 @@
|
|||||||
<button mat-icon-button color="primary" (click)="printGeneralList(item.headerid)"
|
<button mat-icon-button color="primary" (click)="printGeneralList(item.headerid)"
|
||||||
matTooltip="Print General List">
|
matTooltip="Print General List">
|
||||||
<mat-icon>print</mat-icon>
|
<mat-icon>print</mat-icon>
|
||||||
</button>
|
</button> -->
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
|||||||
@ -91,15 +91,15 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.mat-column-actions {
|
// .mat-column-actions {
|
||||||
width: 135px;
|
// width: 135px;
|
||||||
|
|
||||||
.action-buttons {
|
// .action-buttons {
|
||||||
width: 100%;
|
// width: 100%;
|
||||||
display: flex;
|
// display: flex;
|
||||||
gap: 4px;
|
// gap: 4px;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
.no-data-message {
|
.no-data-message {
|
||||||
|
|||||||
@ -166,8 +166,8 @@ export class HomeComponent {
|
|||||||
}
|
}
|
||||||
|
|
||||||
editCarnet(item: any): void {
|
editCarnet(item: any): void {
|
||||||
if (item && item.headerId) {
|
if (item && item.headerid) {
|
||||||
this.navigateTo(['edit-carnet', item.headerId], {
|
this.navigateTo(['edit-carnet', item.headerid], {
|
||||||
queryParams: { applicationname: item.applicationName }
|
queryParams: { applicationname: item.applicationName }
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
@ -176,8 +176,8 @@ export class HomeComponent {
|
|||||||
}
|
}
|
||||||
|
|
||||||
viewCarnet(item: any): void {
|
viewCarnet(item: any): void {
|
||||||
if (item && item.headerId) {
|
if (item && item.headerid) {
|
||||||
this.navigateTo(['view-carnet', item.headerId], {
|
this.navigateTo(['view-carnet', item.headerid], {
|
||||||
queryParams: { applicationname: item.applicationName }
|
queryParams: { applicationname: item.applicationName }
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
@ -185,9 +185,9 @@ export class HomeComponent {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
printGeneralList(headerId: number): void {
|
printGeneralList(headerid: number): void {
|
||||||
if (headerId) {
|
if (headerid) {
|
||||||
this.homeService.printGeneralList(headerId).subscribe({
|
this.homeService.printGeneralList(headerid).subscribe({
|
||||||
next: () => {
|
next: () => {
|
||||||
|
|
||||||
},
|
},
|
||||||
@ -202,8 +202,8 @@ export class HomeComponent {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
deleteCarnet(headerId: number): void {
|
deleteCarnet(headerid: number): void {
|
||||||
if (headerId) {
|
if (headerid) {
|
||||||
const dialogRef = this.dialog.open(ConfirmDialogComponent, {
|
const dialogRef = this.dialog.open(ConfirmDialogComponent, {
|
||||||
width: '350px',
|
width: '350px',
|
||||||
data: {
|
data: {
|
||||||
@ -216,7 +216,7 @@ export class HomeComponent {
|
|||||||
|
|
||||||
dialogRef.afterClosed().subscribe(result => {
|
dialogRef.afterClosed().subscribe(result => {
|
||||||
if (result) {
|
if (result) {
|
||||||
this.homeService.deleteCarnet(headerId).subscribe({
|
this.homeService.deleteCarnet(headerid).subscribe({
|
||||||
next: () => {
|
next: () => {
|
||||||
this.notificationService.showSuccess('Carnet deleted successfully');
|
this.notificationService.showSuccess('Carnet deleted successfully');
|
||||||
this.loadCarnetData();
|
this.loadCarnetData();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user