Hi. This is very weird thing:
I have a simple repeater with an input element and a button for update. I get the input value from a collection via dataset, and I want the user to be able to update that value by changing it and click the button.
However, as soon as I connect the input element to the dataset for showing the current value, the element gets disabled and when I unconnect it, it is available and the button updates the collection with the value inserted (but it doesnât show the value from the collection since it doesnât connected)âŚ
How can I make it enable?
I added my code though Iâm not sure it is neccasery
$w.onReady(function () {
$w("#repeater1").onItemReady( ($item, itemData, index) => {
$item('#button1').onClick(() => {
button1_click(itemData._id, $item('#input1').value);
});
});
});
export function button1_click(id, name) {
let toUpdate = {
"_id": id,
"name": name
};
wixData.update("myCollection", toUpdate);
}
My site when the input element connected to dataset: