Skip to content

Commit

Permalink
fix: EIP entity field, preselect value + allow null (#470)
Browse files Browse the repository at this point in the history
* fix: EIP entity field, preselect value + allow null

* phpcs
  • Loading branch information
SpaghettiBolognaise authored Aug 30, 2024
1 parent d571e73 commit 3fab2ce
Show file tree
Hide file tree
Showing 6 changed files with 9,845 additions and 31,042 deletions.
7 changes: 5 additions & 2 deletions assets/sb-admin/js/editinplace.js
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,11 @@ function submitEIP(eip_elem, eip_input, eip_val) {
let entityId = eip_input.tomselect.getValue();
let entity = eip_input.tomselect.options[entityId];

eip_val.textContent = entity.text;
eip_input.tomselect.clear();
if (entity) {
eip_val.textContent = entity.text;
} else {
eip_val.textContent = '';
}
} else {
eip_val.textContent = eip_input.value;
}
Expand Down
Loading

0 comments on commit 3fab2ce

Please sign in to comment.