mirror of
https://github.com/Karaka-Management/jsOMS.git
synced 2026-02-14 16:38:39 +00:00
Fix bug where always same value path was used
This commit is contained in:
parent
f88bd58915
commit
c7c0a7f5dc
|
|
@ -121,6 +121,7 @@ export class AdvancedInput {
|
||||||
*/
|
*/
|
||||||
remoteCallback(self, data)
|
remoteCallback(self, data)
|
||||||
{
|
{
|
||||||
|
console.log(data);
|
||||||
data = JSON.parse(data.response)[0];
|
data = JSON.parse(data.response)[0];
|
||||||
const dataLength = data.length;
|
const dataLength = data.length;
|
||||||
|
|
||||||
|
|
@ -251,8 +252,7 @@ export class AdvancedInput {
|
||||||
let value = '';
|
let value = '';
|
||||||
|
|
||||||
for (let j = 0; j < fieldLength; ++j) {
|
for (let j = 0; j < fieldLength; ++j) {
|
||||||
// todo: this is always the same value (the data-tpl-value of the parent container, change for the future to do only once or create uuid from multiple values?)
|
value = document.activeElement.querySelectorAll('[data-tpl-value="' + fields[j].getAttribute('data-tpl-value') + '"]')[0].getAttribute('data-value');
|
||||||
value = document.activeElement.querySelectorAll('[data-tpl-value="' + newTag.firstElementChild.getAttribute('data-tpl-value') + '"]')[0].getAttribute('data-value');
|
|
||||||
fields[j].setAttribute('data-value', value);
|
fields[j].setAttribute('data-value', value);
|
||||||
|
|
||||||
uuid += value;
|
uuid += value;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user