Sorting based on cell color

Sorting based on cell color

parsonsparsonsparsonsparsons Posts: 29Questions: 8Answers: 0

Is there any way for me to prioritize sorting of a column based on it's color? Right now I only have two background-colors, white or green. I want the green to have priority. Thanks!

Answers

  • allanallan Posts: 61,743Questions: 1Answers: 10,111 Site admin

    Where is the colour information? Is it in the cell's class name? Or do you have that information in the data for the table? If you have it in the data, then yes, its fairly easy using orthogonal data. If its just classes though, we'd need to extract the colour information which is a fair bit harder.

    Allan

  • parsonsparsonsparsonsparsons Posts: 29Questions: 8Answers: 0

    It is in the data kind of, the datatable is a list of results from a keyword search, and any green cell contains an indexOf the search text.

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

    We're happy to take a look, but as per the forum rules, please link to a test case - a test case that replicates the issue will ensure you'll get a quick and accurate response. Information on how to create a test case (if you aren't able to link to the page you are working on) is available here.

    Cheers,

    Colin

This discussion has been closed.