Hey there, Awesome Customers!

Just a heads up: We'll be taking a breather to celebrate International Workers' Day (May 1st and 2nd - Wednesday and Thursday) and Orthodox Easter from Good Friday (May 3rd) through Easter Monday (May 6th). So, from May 1st to May 6th, our team will be off enjoying some well-deserved downtime.

During this time, our customer support will be running on a smaller crew, but don't worry! We'll still be around to help with any urgent matters, though it might take us a bit longer than usual to get back to you.

We'll be back in action at full throttle on May 7th (Tuesday), ready to tackle your questions and requests with gusto!

In the meantime, you can explore our documentation for Amelia and wpDataTables. You'll find loads of helpful resources, including articles and handy video tutorials on YouTube (Amelia's YouTube Channel and wpDataTables' YouTube Channel). These gems might just have the answers you're looking for while we're kicking back.

Thanks a bunch for your understanding and support!

Catch you on the flip side!

Warm regards,

TMS

Okay
  Public Ticket #2512109
Get record by clicking on row
Closed

Comments

  • Leo started the conversation

    Hello,

    Could someone give me some tips on how to retrieve a row by clicking on it, parsing a column value from it?
    I added a new column to one of my tables as 
    '<button type="button" onclick="trackItem()" class="track-button">+</button>' TrackItem,

    I tried adding the following function to /assets/js/wpdatatables/wpdatatables.js but I was not able to get any values.


    var clickEvent = function (e) {

    function trackItem() {
        var row = $(tableDescription.selector + ' tr.selected').get(0);
        var data = wpDataTables[tableDescription.tableId].fnGetData(row);
        data = data[0];
        console.log('inside function: addItem' + data);
    }

    ...

    Any tips?

  •  2,498
    Aleksandar replied

    Hello Leo

    Thank you for your purchase.

    I am sorry to disappoint you, but unfortunately something like this is not possible with the plugin's built-in features and it has to be done as custom work, which is not included in the provided support for the plugin, so I can't help you with that.

    If I had an example on this, I would gladly share it with you, but unfortunately I don't. You can take a look at our hooks and filters and see if there's something there that can help you out.

    Kind Regards, 

    Aleksandar Vuković
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables