feat(feature-management): make feature management component replaceable

#2404
pull/2522/head
mehmet-erim 6 years ago
parent 17465417a9
commit 6f233f281d

@ -10,6 +10,7 @@ import { pluck, finalize } from 'rxjs/operators';
@Component({
selector: 'abp-feature-management',
templateUrl: './feature-management.component.html',
exportAs: 'abpFeatureManagement',
})
export class FeatureManagementComponent {
@Input()

@ -182,5 +182,18 @@
</form>
</ng-template>
<abp-feature-management [(visible)]="visibleFeatures" providerName="T" [providerKey]="providerKey">
<abp-feature-management
*abpReplaceableTemplate="{
inputs: {
providerName: { value: 'T' },
providerKey: { value: providerKey },
visible: { value: visibleFeatures, twoWay: true }
},
outputs: { visibleChange: onVisibleFeaturesChange },
componentKey: 'FeatureManagement.FeatureManagementComponent'
}"
[(visible)]="visibleFeatures"
providerName="T"
[providerKey]="providerKey"
>
</abp-feature-management>

@ -94,6 +94,10 @@ export class TenantsComponent implements OnInit {
}
}
onVisibleFeaturesChange = (value: boolean) => {
this.visibleFeatures = value;
};
constructor(
private confirmationService: ConfirmationService,
private tenantService: TenantManagementService,

Loading…
Cancel
Save