Skip to content

Commit

Permalink
feat(products) remove base products variant display
Browse files Browse the repository at this point in the history
  • Loading branch information
belsman committed Nov 12, 2024
1 parent c3b05b8 commit 55bcc9a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div class="data-list m-0 p-0">
<div class="row justify-content-between align-items-center">
<div class="my-2 rc-lv-l-heading">
Product Variants [{{ variants.length }}]
Product Variants [{{ actualVariantLength }}]
</div>

<button
Expand All @@ -20,7 +20,7 @@
<ul class="data-list-body no-border">
<li
class="row data-list-item product-item"
*ngFor="let variant of variants"
*ngFor="let variant of variantsWithoutBaseVariant"
>
<rc-product-variant
[variant]="variant"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,12 @@ export class RcProductVariantsComponent {
new EventEmitter<IIoRestorecommerceProductPhysicalVariant>();

@Output() deleteVariant = new EventEmitter<string>();

get variantsWithoutBaseVariant() {
return this.variants.slice(1);
}

get actualVariantLength() {
return this.variants.length - 1;
}
}

0 comments on commit 55bcc9a

Please sign in to comment.