mirror of
https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend
synced 2025-12-28 22:42:11 +01:00
#4035 Filiale wird bei Reservierung setzen
This commit is contained in:
@@ -270,14 +270,14 @@ export class ArticleDetailsComponent implements OnInit, OnDestroy {
|
||||
type: 'add',
|
||||
processId: this.applicationService.activatedProcessId,
|
||||
items: [item],
|
||||
pickupBranch: selectedBranch,
|
||||
inStoreBranch: selectedBranch,
|
||||
})
|
||||
.afterClosed$.subscribe((result) => {
|
||||
if (result?.data === 'continue') {
|
||||
this.navigateToShoppingCart();
|
||||
console.log('continue');
|
||||
} else if (result?.data === 'continue-shopping') {
|
||||
this.navigateToResultList();
|
||||
console.log('continue-shopping');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -6,4 +6,6 @@ export interface PurchaseOptionsModalData {
|
||||
processId: number;
|
||||
type: ActionType;
|
||||
items: Array<ItemDTO | ShoppingCartItemDTO>;
|
||||
pickupBranch?: BranchDTO;
|
||||
inStoreBranch?: BranchDTO;
|
||||
}
|
||||
|
||||
@@ -160,7 +160,7 @@ export class PurchaseOptionsStore extends ComponentStore<PurchaseOptionsState> {
|
||||
};
|
||||
});
|
||||
|
||||
async initialize({ items, processId, type }: PurchaseOptionsModalData) {
|
||||
async initialize({ items, processId, type, inStoreBranch, pickupBranch }: PurchaseOptionsModalData) {
|
||||
const selectedBranch = await this._service.getSelectedBranchForProcess(processId).toPromise();
|
||||
const defaultBranch = await this._service.fetchDefaultBranch().toPromise();
|
||||
const customerFeatures = await this._service.getCustomerFeatures(processId).toPromise();
|
||||
@@ -170,8 +170,8 @@ export class PurchaseOptionsStore extends ComponentStore<PurchaseOptionsState> {
|
||||
type: type,
|
||||
items: items.map((item) => ({ ...item, quantity: item['quantity'] ?? 1 })),
|
||||
defaultBranch: selectedBranch ?? defaultBranch,
|
||||
pickupBranch: selectedBranch,
|
||||
inStoreBranch: selectedBranch,
|
||||
pickupBranch: pickupBranch ?? selectedBranch,
|
||||
inStoreBranch: inStoreBranch ?? selectedBranch,
|
||||
customerFeatures,
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user