Compare commits

...

4 Commits

Author SHA1 Message Date
Nino
94af2f6b76 #4712 Removed isShippingEnabled check from availabilities modal
(cherry picked from commit d5b79dcf6f)
2024-03-20 14:08:25 +01:00
Nino Righi
8f47163627 Merged PR 1762: #4692 Hotfix Undefined Values in Route Url
#4692 Hotfix Undefined Values in Route Url
2024-03-07 14:33:36 +00:00
Nino Righi
a209d59ea9 Merged PR 1760: #4532 Fallback Route if Url contains Undefined or Null values
#4532 Fallback Route if Url contains Undefined or Null values
2024-03-06 12:13:13 +00:00
Lorenz Hilpert
b838f4c475 Merge branch 'develop' into release/3.0 2024-02-01 18:33:25 +01:00
4 changed files with 41 additions and 2 deletions

View File

@@ -35,7 +35,11 @@
</div>
<div class="branch-actions">
<button *ngIf="(branch.id | stockInfo: (inStock$ | async))?.availableQuantity > 0" class="cta-reserve" (click)="reserve(branch)">
<button
*ngIf="(branch.id | stockInfo: (inStock$ | async))?.availableQuantity > 0 && branch?.isShippingEnabled"
class="cta-reserve"
(click)="reserve(branch)"
>
Reservieren
</button>

View File

@@ -37,7 +37,7 @@ export class ModalAvailabilitiesComponent {
(branch) =>
branch &&
branch?.isOnline &&
branch?.isShippingEnabled &&
// branch?.isShippingEnabled && ------ Rausgenommen aufgrund des Tickets #4712
branch?.isOrderingEnabled &&
branch?.id !== userbranch?.id &&
branch?.branchType === 1

View File

@@ -96,6 +96,10 @@ export class PickupShelfInComponent extends PickupShelfBaseComponent {
const order = await this.detailsStore.order$.pipe(take(1)).toPromise();
if (!order) {
return;
}
if (order?.orderNumber) {
return order?.orderNumber;
}
@@ -110,6 +114,12 @@ export class PickupShelfInComponent extends PickupShelfBaseComponent {
const orderItemSubsetId = this.detailsStore.orderItemSubsetId;
const compartmentInfo = this.detailsStore.compartmentInfo;
// Ticket #4692 - Wenn keine Order vorhanden ist, dann soll Breadcrumb nicht erstellt werden
// Dies kann z.B. passieren bei Datenbankproblemen wenn das Fetchen der Order sehr lange braucht
if (!order) {
return;
}
return this._pickupShelfInNavigationService.detailRoute({
item: {
orderId: order?.id,

View File

@@ -230,11 +230,36 @@ export class ShellSideMenuComponent {
return fallback;
}
// #4692 Return Fallback if Values contain undefined or null values, regardless if path is from type string or array
if (typeof lastCrumb?.path === 'string') {
if (lastCrumb?.path?.includes('undefined') || lastCrumb?.path?.includes('null')) {
return fallback;
}
} else {
let valuesToCheck = [];
for (const value of lastCrumb?.path) {
if (value?.outlets && value?.outlets?.primary && value?.outlets?.side) {
valuesToCheck.push(...Object.values(value?.outlets?.primary), ...Object.values(value?.outlets?.side));
} else {
valuesToCheck.push(value);
}
}
if (this.checkIfArrayContainsUndefinedOrNull(valuesToCheck)) {
return fallback;
}
}
return { path: lastCrumb.path, queryParams: lastCrumb.params };
})
);
}
checkIfArrayContainsUndefinedOrNull(array: any[]) {
return array?.includes(undefined) || array?.includes('undefined') || array?.includes(null) || array?.includes('null');
}
getLastActivatedCustomerProcessId$() {
return this._app.getProcesses$('customer').pipe(
map((processes) => {