Wykres commitów

9 Commity (0.52.x)

Autor SHA1 Wiadomość Data
Simon Willison 896cc2c6ac Replace MockRequest with Request.fake()
Close #1004
2020-10-09 09:26:17 -07:00
Simon Willison 7152e76eda Don't suggest array facet if column is only [], closes #610 2019-11-01 14:45:59 -07:00
Simon Willison 50287e7c6b Only suggest array facet for arrays of strings - closes #562 2019-11-01 12:37:46 -07:00
Simon Willison c5542abba5 Removed ManyToManyFacet for the moment, closes #550 2019-07-07 16:21:11 -07:00
Simon Willison 182a3017c2 Sort keys to past tests in Python 3.5 2019-05-25 09:22:02 -07:00
Simon Willison d923d84754 Facet by many-to-many, closes #365 2019-05-25 09:06:32 -07:00
Simon Willison 967230c90e Facet by date, closes #481 2019-05-20 23:09:22 -07:00
Simon Willison 53d2f00b73 Implemented ArrayFacet, closes #359 2019-05-02 20:21:27 -04:00
Simon Willison ea66c45df9
Extract facet code out into a new plugin hook, closes #427 (#445)
Datasette previously only supported one type of faceting: exact column value counting.

With this change, faceting logic is extracted out into one or more separate classes which can implement other patterns of faceting - this is discussed in #427, but potential upcoming facet types include facet-by-date, facet-by-JSON-array, facet-by-many-2-many and more.

A new plugin hook, register_facet_classes, can be used by plugins to add in additional facet classes.

Each class must implement two methods: suggest(), which scans columns in the table to decide if they might be worth suggesting for faceting, and facet_results(), which executes the facet operation and returns results ready to be displayed in the UI.
2019-05-02 17:11:26 -07:00