In Search Panes, is there a way to show the Custom Panes first?

In Search Panes, is there a way to show the Custom Panes first?

DreakerDreaker Posts: 13Questions: 6Answers: 0

I created a custom pane like the one in the documentation:
Custom Pane
And I'm wondering if it is possible to show the custom panes first? Is there a way to do this using Search Panes Options or can I change something in the datatables search panes javascript file to achieve this?

This question has an accepted answers - jump to answer

Answers

  • colincolin Posts: 15,142Questions: 1Answers: 2,586

    I don't think there is. I've raised it internally (DD-1391 for my reference) and we'll have a think and I'll report back here when there's an update.

    Cheers,

    Colin

  • sandysandy Posts: 913Questions: 0Answers: 236
    Answer ✓

    Hi @Dreaker

    I've added the functionality that you've described, here's an example.

    Basically I have added 3 configuration properties.

    The first is a searchPanes.name property which is assigned to each pane, if it is not assigned in the config then it takes the value of the title of the pane. There is a very similar searchPanes.panes.name property for custom panes which does the same job.

    The third is the searchPanes.order property, which is an array you should populate with the pane names in the order you wish to show them. If you declare an order then any names not included here will lead to those panes not being displayed.

    This will be released in SearchPanes 1.1 which isn't too far away now, in the mean time you can access the code from the nightly builds.

    Hope that all makes sense to you, give me a shout if you have any further issues.

    Cheers,
    Sandy

This discussion has been closed.