TypeError: ids is undefined /TypeError: multiIds is undefined

TypeError: ids is undefined /TypeError: multiIds is undefined

KimvdLindeKimvdLinde Posts: 30Questions: 8Answers: 0
edited September 2015 in Bug reports

I use the following code:

$('#schedule').on('click', 'tbody td', function () {
        
    var field = editor.field('totalCosts');
    console.log(field);
    console.log(field.isMultiValue()); //false
    field.multiSet('totalCosts','test'); //error
    console.log(field.isMultiValue());
       editor.inline(this, {
            submitOnBlur: true
        });
    });

And it throws this error: multiIds is undefined (dataTables.editor.js:382:4)
If I replace multiSet with set, it throws this error: ids is undefined(dataTables.editor.js:531:18)

When I only have editor.inline, it works fine.

Not sure what goes wrong

Replies

  • allanallan Posts: 63,494Questions: 1Answers: 10,470 Site admin

    Hi,

    The values can only be modified when Editor is in an editing mode. Prior to inline() being called in the above code it is not editing anything, so yes, an error would be thrown if trying to set a value.

    Try setting the value after calling the inline method.

    Regards,
    Allan

  • KimvdLindeKimvdLinde Posts: 30Questions: 8Answers: 0
    edited September 2015

    Okay, that explains.

This discussion has been closed.