Skip to content

Commit

Permalink
fix: sub details cond key autocomplete
Browse files Browse the repository at this point in the history
  • Loading branch information
akurilov committed Mar 16, 2024
1 parent eee6c2a commit 0dffc1f
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions web/sub-details.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,21 @@ editor.on('change', function () {
let keyOptsInt = [];
let keyOptsTxt = [];

window.JSONEditor.defaults.callbacks = {
"autocomplete": {
"autoCompleteKeyInt": function search(editor, input) {
return new Promise(function (resolve) {
return resolve(keyOptsInt);
});
},
"autoCompleteKeyTxt": function search(editor, input) {
return new Promise(function (resolve) {
return resolve(keyOptsTxt);
});
},
},
};

function loadAttributeTypes() {
let optsReq = {
method: "GET",
Expand Down

0 comments on commit 0dffc1f

Please sign in to comment.