I have table as seen above and I want to create a custom array to pass values.
Currently I am using the following lines of code:
var arr = $('input[type=text].editfield').map(function () {
return this;
}).get();
var objArr = jQuery.map(arr, function (i) {
return {
myDate: i.parentElement.previousSibling.previousSibling.previousSibling.previousSibling.previousSibling.previousSibling.childNodes[0].textContent,
myValue: i.value
}
}).get();
and I expect to have an array of objects of all items in my grid with Date and Value as properties respectively.
But something is wrong and I can not solve. For example the code above says "jQuery.map(...).get is not a function"
How can I correct my code to perform the correct action?
Regards.