Different orderData for ASC and DESC (same target)
Different orderData for ASC and DESC (same target)
![gustav22](https://secure.gravatar.com/avatar/1aefb92fe8d9081fe8fc6201592f1a68/?default=https%3A%2F%2Fvanillicon.com%2F1aefb92fe8d9081fe8fc6201592f1a68_200.png&rating=g&size=120)
Hi all
Is it possible to have different orderData for ASC and DESC on the same target?
For example:
{ "orderSequence": [ "asc" ], "targets": [ 1 ], orderData: [ 6, 1 ]}
{ "orderSequence": [ "desc" ], "targets": [ 1 ], orderData: [ 7, 1 ]}
Goal:
ASC on Column 1 => orderData 6,1
DESC on Column 1 => orderData 7,1
Thanks
gustav
This discussion has been closed.
Answers
Hi @gustav ,
It won't work that way, but you can hand craft it - see this example here. That was supposed to be a 5 minute job which turned into an hour - the complication is that if you sort by two columns, when you then sort by one, the direction doesn't necessarily change, hence why the code is a tad convoluted.
That should work for you though, shout if not,
Cheers,
Colin