jQWidgets Forums
jQuery UI Widgets › Forums › Angular › Grid with Ever present row with column – Need a Add/Reset Button instead of link
Tagged: angular ui grid
This topic contains 3 replies, has 2 voices, and was last updated by admin 5 years ago.
-
Author
-
May 28, 2020 at 5:48 pm Grid with Ever present row with column – Need a Add/Reset Button instead of link #112095
Hello
I need to build a grid with ever present row with columns. The current implementation of Add and Reset link in separate column creates a link with href=”#” which redirects our app to homepage.
Is there a way to override it and make it “javascript:void();” so that it will not redirect.
below is the code :let settings: jqwidgets.GridOptions = this.jqxGridHelper.defaultGridSettings(); settings.altrows = true; settings.height = "240px"; settings.autoheight = false; settings.pageable = false; settings.autorowheight = false; settings.columns = [ { text: 'BIN', columntype: 'textbox', datafield: 'bin', filtertype: 'input', align: 'center', cellsalign: 'center', validateeverpresentrowwidgetvalue: this.validateFunction}, { text: 'PCN', columntype: 'textbox', datafield: 'pcn', filtertype: 'input', align: 'center', cellsalign: 'center', validateeverpresentrowwidgetvalue: this.validateFunction}, { text: 'Group No.', columntype: 'textbox', datafield: 'groupNo', filtertype: 'input', align: 'center', cellsalign: 'center', validateeverpresentrowwidgetvalue: this.validateFunction}, { text: '', datafield: 'addButtonColumn', width: 50}, { text: '', datafield: 'resetButtonColumn', width: 50} ]; settings.filterable = true; settings.showeverpresentrow = true; settings.everpresentrowposition = "top"; settings.everpresentrowactions = "add reset"; settings.everpresentrowactionsmode = 'columns';
This generates Add and Reset columns with links, is there way to render it something like cellsrenderer we use on regular columns?
Thanks,
Swapnil.May 29, 2020 at 7:10 am Grid with Ever present row with column – Need a Add/Reset Button instead of link #112096Hi Swapnil,
Have you tried with document.querySelector and point out these elements in the selector args?
Regards,
PeterjQWidgets Team
https://www.jqwidgets.com/May 29, 2020 at 3:20 pm Grid with Ever present row with column – Need a Add/Reset Button instead of link #112101hi Peter,
I don’t think we can select these elements. It only adds an anchor tag with href.
When I see in the developer tool I see the div tag as shown below.
<div style="padding-bottom: 2px; text-align: center; margin-top: 7px;"><a href="#">Add</a></div>
You can see this on the DEMO page as well
https://www.jqwidgets.com/angular/angular-grid/#https://www.jqwidgets.com/angular/angular-grid/angular-grid-everpresentrowwithcolumns.htm
Select Ever present row with columns.Instead of
href="#"
, if you could change it tohref="javascript:void()"
, it won’t navigate.Thanks,
Swapnil.June 5, 2020 at 7:57 am Grid with Ever present row with column – Need a Add/Reset Button instead of link #112143Hi Swapnil,
We will create a work item about that.
Regards,
PeterjQWidgets Team
https://www.jqwidgets.com/ -
AuthorPosts
You must be logged in to reply to this topic.