mirror of
https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend
synced 2025-12-31 09:37:15 +01:00
Merged PR 1156: #2972 Fix Remission Start Remission Popup Updated if supplier is ZL
#2972 Fix Remission Start Remission Popup Updated if supplier is ZL
This commit is contained in:
committed by
Andreas Schickinger
parent
25f22b46c5
commit
8145436d1d
@@ -3,11 +3,15 @@
|
||||
<div class="text-center">
|
||||
<p class="text-xl mt-4">
|
||||
Um einen Warenbegleitschein zu <br />
|
||||
eröffnen, scannen Sie die Packstück-ID <br />
|
||||
oder lassen Sie diese automatisch generieren.
|
||||
eröffnen,
|
||||
<ng-container *ngIf="supplierId === 2">
|
||||
scannen Sie die Packstück-ID <br />
|
||||
oder
|
||||
</ng-container>
|
||||
lassen Sie diese automatisch generieren.
|
||||
</p>
|
||||
</div>
|
||||
<div class="text-center flex my-4">
|
||||
<div class="text-center flex justify-center my-4">
|
||||
<button
|
||||
(click)="startRemission()"
|
||||
class="border-solid border-2 border-brand text-brand font-bold text-lg px-6 py-3 rounded-full mr-4 whitespace-nowrap"
|
||||
@@ -15,6 +19,7 @@
|
||||
Packstück-ID generieren
|
||||
</button>
|
||||
<ui-searchbox
|
||||
*ngIf="supplierId === 2"
|
||||
placeholder="Packstück-ID scannen"
|
||||
class="mx-auto w-5/6"
|
||||
query=""
|
||||
|
||||
@@ -27,6 +27,10 @@ export class CreateRemissionComponent implements OnInit {
|
||||
return this._scanProvider;
|
||||
}
|
||||
|
||||
get supplierId(): number {
|
||||
return +this._activatedRoute?.snapshot?.queryParams?.supplierId;
|
||||
}
|
||||
|
||||
constructor(
|
||||
@Inject(UiFilterScanProvider) @Optional() private scanProviders: UiFilterScanProvider[],
|
||||
private _activatedRoute: ActivatedRoute,
|
||||
@@ -58,9 +62,8 @@ export class CreateRemissionComponent implements OnInit {
|
||||
}
|
||||
|
||||
async getSupplier() {
|
||||
const supplierId = +this._activatedRoute?.snapshot?.queryParams?.supplierId;
|
||||
const suppliers = await this._domainRemissionService.getSuppliers().pipe(first()).toPromise();
|
||||
return suppliers.find((s) => s.id === supplierId);
|
||||
return suppliers.find((s) => s.id === this.supplierId);
|
||||
}
|
||||
|
||||
async createReturn(supplierId: number, returnGroup: string) {
|
||||
|
||||
Reference in New Issue
Block a user