question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

insert Row after Click event and addClass doesn't work

See original GitHub issue

this donen’t work for me

'click .move-up': function (e, value, row, index) {
    if (index != 0) {
                     $table.bootstrapTable("insertRow", {
                            index: index - 1,
                            row: row
                        });
                       $('.success').removeClass('success');
                       $(this).parent().parent().prev().addClass('success')
                    }
           }

remove insetRow event ,is work

'click .move-up': function (e, value, row, index) {
    if (index != 0) {
                       $('.success').removeClass('success');
                       $(this).parent().parent().prev().addClass('success')
                    }
           }

i don’t know why?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
dabroscommented, Aug 5, 2016

@panxq5 - we need a fiddle to help more, examples and such are provided in my last post

0reactions
panxq5commented, Aug 9, 2016

@dabros thank you!!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Table row on click jQuery addClass not working with Bootstrap
I have a dynamic table in Bootstrap. The idea is to change row color on click. Firebug tells me that the "selectedRow" class...
Read more >
JavaScript - Bootstrap
If caused by a click, the clicked element is available as the relatedTarget property of the event. shown.bs.modal, This event is fired when...
Read more >
How to add active class on click event in custom list group in ...
click (function() { $('selector.active').removeClass("active"); $(this).addClass("active"); }); });. Following examples illustrates how ...
Read more >
Can't select row to add class after clearing table and adding ...
I just need to be able to get the node of the selected row so I can add the style back on.
Read more >
.toggleClass() | jQuery API Documentation
Add the "highlight" class to the clicked paragraph on every third click of that paragraph, remove it every first and second click. 1....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found