fix(app): main services [EE-1896] (#6279)

[EE-1896]
pull/6311/head
Chaim Lev-Ari 2021-12-21 12:08:44 +02:00 committed by GitHub
parent 6e53bf5dc7
commit 5a3687a564
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 7 deletions

View File

@ -72,11 +72,9 @@ export default class OAuthSettingsController {
onChangeHideInternalAuth(checked) {
this.$scope.$evalAsync(() => {
if (this.featureService.isLimitedToBE(this.limitedFeature)) {
return;
if (!this.isLimitedToBE) {
this.settings.HideInternalAuth = checked;
}
this.settings.HideInternalAuth = checked;
});
}

View File

@ -1,12 +1,12 @@
import _ from 'lodash-es';
import { FeatureId } from '@/portainer/feature-flags/enums';
import { isLimitedToBE } from '@/portainer/feature-flags/feature-flags.service';
export default class AdSettingsController {
/* @ngInject */
constructor(LDAPService, featureService) {
constructor(LDAPService) {
this.LDAPService = LDAPService;
this.featureService = featureService;
this.domainSuffix = '';
this.limitedFeatureId = FeatureId.HIDE_INTERNAL_AUTH;
@ -58,7 +58,7 @@ export default class AdSettingsController {
}
isSaveSettingButtonDisabled() {
return this.featureService.isLimitedToBE(this.limitedFeatureId) || !this.isLdapFormValid();
return isLimitedToBE(this.limitedFeatureId) || !this.isLdapFormValid();
}
$onInit() {