Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New user props #106

Merged
merged 4 commits into from
Sep 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Model/src/main/java/org/gusdb/wdk/core/api/JsonKeys.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,12 @@ public class JsonKeys {
public static final String DISPLAY_TEXT = "displayText";
public static final String HELP = "help";
public static final String HTML_HELP = "htmlHelp";
public static final String SUGGEST_TEXT = "suggestText";
public static final String DESCRIPTION = "description";
public static final String SHORT_DESCRIPTION = "shortDescription";
public static final String SUMMARY = "summary";
public static final String ALIGN = "align";
public static final String INPUT_TYPE = "inputType";
public static final String TRUNCATE_TO = "truncateTo";
public static final String IS_READ_ONLY = "isReadOnly";
public static final String IS_SORTABLE = "isSortable";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,12 @@ public static JSONObject getWdkProjectInfo(WdkModel wdkModel, String serviceEndp
for (UserProperty prop : User.USER_PROPERTIES.values()) {
userProfileProps.put(new JSONObject()
.put(JsonKeys.NAME, prop.getName())
.put(JsonKeys.IS_PUBLIC, prop.isPublic())
.put(JsonKeys.DISPLAY_NAME, prop.getDisplayName())
.put(JsonKeys.IS_REQUIRED, prop.isRequired())
.put(JsonKeys.IS_MULTILINE, prop.isMultiLine())
.put(JsonKeys.IS_PUBLIC, prop.isPublic()));
.put(JsonKeys.HELP, prop.getHelpText())
.put(JsonKeys.SUGGEST_TEXT, prop.getSuggest())
.put(JsonKeys.INPUT_TYPE, prop.getInputType().name().toLowerCase())
.put(JsonKeys.IS_REQUIRED, prop.isRequired()));
}

return new JSONObject()
Expand Down
Loading