Skip to content

Commit

Permalink
fix simple mode setup + filter settings
Browse files Browse the repository at this point in the history
* now render proper settings on new action
* fix disabled state when previous new action and change to edit
* now merge and filter in case we have two settings dict (in this case, service settings and security settings)
* add editor class as extend of default settings class and start editor handling
  • Loading branch information
syrk4web committed Apr 29, 2024
1 parent fe9a73e commit d4f6703
Show file tree
Hide file tree
Showing 4 changed files with 173 additions and 208 deletions.
12 changes: 7 additions & 5 deletions src/ui/static/js/services.js
Original file line number Diff line number Diff line change
Expand Up @@ -145,12 +145,12 @@ class SettingsService {
.querySelector(
`button[data-setting-select-dropdown-btn="security-level"][value="custom"]`,
)
.click();
.removeAttribute("disabled");
document
.querySelector(
`button[data-setting-select-dropdown-btn="security-level"][value="custom"]`,
)
.removeAttribute("disabled");
.click();
}
}
} catch (err) {
Expand Down Expand Up @@ -223,9 +223,11 @@ class SettingsService {
}
} catch (err) {}
}

console.log("mainSettings", mainSettings);
console.log("compareSettings", compareSettings);
// No main settings if new
if (action === "new") {
mainSettings = JSON.parse(JSON.stringify(compareSettings));
compareSettings = null;
}

this.simpleSettings.setSimple(
action,
Expand Down
Loading

0 comments on commit d4f6703

Please sign in to comment.