feat(console): email label policy, cleanup policy grid module (#890)

* add primitive label policy component, routing

* label policy, i18n

* refactor policy grid

* i18n

* lint

* cleanup i19n policy

* rm failed events styling

* fix detail layout padding, de i18n

* remove unused translations
This commit is contained in:
Max Peintner
2020-10-24 20:28:48 +02:00
committed by GitHub
parent a7ed5fed50
commit e7514998bf
40 changed files with 549 additions and 544 deletions
+14
View File
@@ -7,6 +7,9 @@ import {
CreateHumanRequest,
CreateOrgRequest,
CreateUserRequest,
DefaultLabelPolicy,
DefaultLabelPolicyUpdate,
DefaultLabelPolicyView,
DefaultLoginPolicy,
DefaultLoginPolicyView,
DefaultPasswordAgePolicyRequest,
@@ -162,6 +165,17 @@ export class AdminService {
return this.grpcService.admin.updateDefaultPasswordLockoutPolicy(req);
}
/* label */
public GetDefaultLabelPolicy(): Promise<DefaultLabelPolicyView> {
const req = new Empty();
return this.grpcService.admin.getDefaultLabelPolicy(req);
}
public UpdateDefaultLabelPolicy(req: DefaultLabelPolicyUpdate): Promise<DefaultLabelPolicy> {
return this.grpcService.admin.updateDefaultLabelPolicy(req);
}
/* login */
public GetDefaultLoginPolicy(
+4 -4
View File
@@ -612,13 +612,13 @@ export class ManagementService {
public getLocalizedComplexityPolicyPatternErrorString(policy: PasswordComplexityPolicy.AsObject): string {
if (policy.hasNumber && policy.hasSymbol) {
return 'ORG.POLICY.PWD_COMPLEXITY.SYMBOLANDNUMBERERROR';
return 'POLICY.PWD_COMPLEXITY.SYMBOLANDNUMBERERROR';
} else if (policy.hasNumber) {
return 'ORG.POLICY.PWD_COMPLEXITY.NUMBERERROR';
return 'POLICY.PWD_COMPLEXITY.NUMBERERROR';
} else if (policy.hasSymbol) {
return 'ORG.POLICY.PWD_COMPLEXITY.SYMBOLERROR';
return 'POLICY.PWD_COMPLEXITY.SYMBOLERROR';
} else {
return 'ORG.POLICY.PWD_COMPLEXITY.PATTERNERROR';
return 'POLICY.PWD_COMPLEXITY.PATTERNERROR';
}
}