Skip to content

Commit

Permalink
SEBSERV-608
Browse files Browse the repository at this point in the history
  • Loading branch information
anhefti committed Dec 19, 2024
1 parent 2aebfb8 commit ca82121
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@ public class AddSecurityKeyGrantPopup {
new LocTextKey("sebserver.exam.signaturekey.list.info");
private static final LocTextKey TABLE_COLUMN_STATUS =
new LocTextKey("sebserver.exam.signaturekey.list.status");
private static final LocTextKey GRANT_LIST_NO_ASK_SENT =
new LocTextKey("sebserver.exam.signaturekey.grantlist.noask");

private final PageService pageService;

Expand Down Expand Up @@ -139,8 +141,8 @@ public Supplier<FormHandle<?>> compose(final Composite parent) {
Domain.SEB_SECURITY_KEY_REGISTRY.ATTR_KEY_VALUE,
TITLE_TEXT_FORM_SIGNATURE,
(hasASK)
? String.valueOf(this.appSignatureKeyInfo.key)
: Constants.EMPTY_NOTE)
? this.appSignatureKeyInfo.key
: pageService.getI18nSupport().getText(GRANT_LIST_NO_ASK_SENT))
.readonly(true))

.addFieldIf(() -> hasASK && !readonly,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,8 @@ public class ExamSignatureKeyForm implements TemplateComposer {
new LocTextKey("sebserver.exam.signaturekey.grantlist.pleaseSelect");
private static final LocTextKey GRANT_LIST_DELETE_CONFORM =
new LocTextKey("sebserver.exam.signaturekey.grantlist.delete.confirm");
private static final LocTextKey GRANT_LIST_NO_ASK_SENT =
new LocTextKey("sebserver.exam.signaturekey.grantlist.noask");

private final PageService pageService;
private final ResourceService resourceService;
Expand Down Expand Up @@ -169,10 +171,12 @@ public void compose(final PageContext pageContext) {
.withPaging(-1)
.hideNavigation()

.withColumn(new ColumnDefinition<>(
.withColumn(new ColumnDefinition<AppSignatureKeyInfo>(
Domain.SEB_SECURITY_KEY_REGISTRY.ATTR_KEY_VALUE,
APP_SIG_KEY_LIST_KEY,
AppSignatureKeyInfo::getKey)
i -> StringUtils.isNotBlank(i.key)
? i.key
: pageService.getI18nSupport().getText(GRANT_LIST_NO_ASK_SENT))
.widthProportion(2))

.withColumn(new ColumnDefinition<>(
Expand Down
1 change: 1 addition & 0 deletions src/main/resources/messages.properties
Original file line number Diff line number Diff line change
Expand Up @@ -1001,6 +1001,7 @@ sebserver.exam.signaturekey.grantlist.tag=Tag Name
sebserver.exam.signaturekey.grantlist.tag.tooltip=The tag name if the security key grant
sebserver.exam.signaturekey.grantlist.pleaseSelect=Please select a security key grant from the list.
sebserver.exam.signaturekey.grantlist.delete.confirm=Are you sure to delete this security key grant
sebserver.exam.signaturekey.grantlist.noask=No ASK sent by these Clients

sebserver.exam.signaturekey.grant.title=Granted
sebserver.exam.signaturekey.grant.key=Granted Key Hash
Expand Down

0 comments on commit ca82121

Please sign in to comment.