mirror of
https://github.com/akveo/ngx-admin.git
synced 2025-09-22 05:50:48 +02:00
fix(demo-docs): fix banners in backend bundles section (#5594)
This commit is contained in:
parent
f3e9bef4d2
commit
e4c53bf70d
4 changed files with 7 additions and 7 deletions
|
@ -21,8 +21,8 @@ export interface ProductVariant {
|
||||||
}
|
}
|
||||||
|
|
||||||
export const BUNDLE_LICENSE = {
|
export const BUNDLE_LICENSE = {
|
||||||
single: 'single',
|
personal: 'personal',
|
||||||
multi: 'multi',
|
developer: 'developer',
|
||||||
};
|
};
|
||||||
|
|
||||||
export class Feature {
|
export class Feature {
|
||||||
|
|
|
@ -62,8 +62,8 @@
|
||||||
<table class="features-table">
|
<table class="features-table">
|
||||||
<tr class="header">
|
<tr class="header">
|
||||||
<th class="left">FEATURES</th>
|
<th class="left">FEATURES</th>
|
||||||
<th>SINGLE APP</th>
|
<th>PERSONAL APP</th>
|
||||||
<th>MULTI APP</th>
|
<th>DEVELOPER APP</th>
|
||||||
</tr>
|
</tr>
|
||||||
<tr *ngFor="let feature of features | async">
|
<tr *ngFor="let feature of features | async">
|
||||||
<td class="left">{{ feature.text }}</td>
|
<td class="left">{{ feature.text }}</td>
|
||||||
|
|
|
@ -29,7 +29,7 @@ export class BackendBundlesSectionComponent implements AfterViewInit {
|
||||||
|
|
||||||
@Output() loaded = new EventEmitter();
|
@Output() loaded = new EventEmitter();
|
||||||
|
|
||||||
selectedLicenseType = BUNDLE_LICENSE.single;
|
selectedLicenseType = BUNDLE_LICENSE.personal;
|
||||||
|
|
||||||
licenses = Object.values(BUNDLE_LICENSE);
|
licenses = Object.values(BUNDLE_LICENSE);
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ import { ProductVariant } from '../../../@core/data/service/bundles.service';
|
||||||
export class LicensePipe implements PipeTransform {
|
export class LicensePipe implements PipeTransform {
|
||||||
transform(variants: ProductVariant[], license: string): ProductVariant {
|
transform(variants: ProductVariant[], license: string): ProductVariant {
|
||||||
const result = variants
|
const result = variants
|
||||||
.filter(variant => variant.title.toLowerCase().includes(license.toLowerCase()));
|
.find(variant => variant.title.toLowerCase().includes(license.toLowerCase()));
|
||||||
return result.length ? result[0] : undefined;
|
return result ? result : variants[0];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue