Sedang Disiapkan

Custom datatables sort function where cell has two values

I am using datatables and in one column the cells "td" elements have the following html within.

<td>

<h4 data-pos="5">5</h4>

<span data-second="-4">-4</span>

</td>

I have a custom drop down in the table header with two buttons. Each button's click event is linked to this column and the associate data attributes. On click I would like the column to be sorted by either data-pos or data-second depending on the button clicked.

So you will need to write a function to get the data attributes and either re order the table or sort the table by these values.

Sorting on click will toggle between ASC and DESC for the data attribute.

Kemahiran: Javascript, jQuery / Prototaip

Lihat lebih lanjut: datatables custom search, datatables custom filter dropdown, datatables filter date range, datatables custom filter, datatables sort null last, jquery datatables date range filter example, datatable filter column, datatables custom search box, postgresql custom sort function, javascript custom sort function, custom query sort using category, virtuemart custom product sort order, wordpress custom field sort posts, wordpress advanced custom search sort, cre loaded custom product sort

Tentang Majikan:
( 13 ulasan ) Mount Sinai, United States

ID Projek: #15406209

Dianugerahkan kepada:

baldoius

Table Sorting By Attrbitures for data-table Relevante Fähigkeiten und Erfahrungen Javascript / jQuery Vorgeschlagene Milestones $15 USD - Sorting Mechanism

$15 USD dalam sehari
(12 Ulasan)
3.6

18 freelancers are bidding on average $27 for this job

TakeReal

My name is Sergey. I am Freelancer from [url removed, login to view], Russia. I can help you as Javascript/jQuery programmer to sort and reorder this table by either data-pos or data-second. In ASC od DESC direction Relevant Skills Lagi

$50 USD dalam sehari
(293 Ulasan)
6.5
$50 USD dalam 0 hari
(63 Ulasan)
6.4
aryan151

Hello sir, i have 9 years of exp, i am ready to start work right now.............................................................

$10 USD dalam sehari
(91 Ulasan)
5.4
SohaibRehman17

Five star technologies passion Relevant Skills and Experience I have 7 years experience with your project skill please review my profile Proposed Milestones $25 USD - work Hi sir can you please come to the chat box Lagi

$25 USD dalam sehari
(15 Ulasan)
4.7
artashapinyan

Hello Mister I read details and understand what [url removed, login to view] start now and done good work .I hope will work together Thanks Artash Relevant Skills and Experience Javascript, jQuery / Prototype Proposed Milestones $25 Lagi

$25 USD dalam 0 hari
(37 Ulasan)
4.8
rocksiri2017

Hello I read your job posting. It's possible. When I will click sort button, I will sort it using JQuery. I think I can do in a few of hours. Relevant Skills and Experience I hope you will send me your existing html Lagi

$30 USD dalam sehari
(11 Ulasan)
4.8
$30 USD dalam 0 hari
(42 Ulasan)
4.8
kooljay999

REAL OFFER : i can have worked on several datatables , including the custom ones. i have over 8 yrs of experience in this domain. We can chat for more details to get this work done. thanks. Relevant Skills and Experie Lagi

$30 USD dalam 2 hari
(23 Ulasan)
4.3
joshiprakash

Hi i just looked into your requirement and i think i can finish this without any problem and can start now. message me if you would like to proceed with me. Relevant Skills and Experience Jjquery datatable, javascirpt Lagi

$15 USD dalam sehari
(24 Ulasan)
4.0
$25 USD dalam sehari
(9 Ulasan)
4.0
sahildeveloper01

Hi there, i have vast experience with databases. Relevant Skills and Experience I have Experience of more than 6 years in Web Designing,Wordpress,codeigniter, WooCommerce, Opencart, PHP, MYSQL, js, JQUERY, PHP Framew Lagi

$25 USD dalam sehari
(5 Ulasan)
3.3
AMDigitalS

A proposal has not yet been provided

$35 USD dalam sehari
(7 Ulasan)
2.4
yh2013

I have the required experience, check my portfolio. Relevant Skills and Experience My skills are programming in Javascript, php, html, Jquery, etc. Proposed Milestones $30 USD - Complete the project. Additional Serv Lagi

$30 USD dalam 2 hari
(2 Ulasan)
2.2
shahidabro8

A proposal has not yet been provided

$35 USD dalam sehari
(1 Ulasan)
0.8
$10 USD dalam sehari
(0 Ulasan)
0.0
$25 USD dalam sehari
(0 Ulasan)
0.0
a7mad3akef

It's a very basic task which I can deliver in few hours

$15 USD dalam sehari
(1 Ulasan)
0.0