{"id": "changelog:id161", "page": "changelog", "ref": "id161", "title": "0.15 (2018-04-09)", "content": "The biggest new feature in this release is the ability to sort by column. On the\n table page the column headers can now be clicked to apply sort (or descending\n sort), or you can specify ?_sort=column or ?_sort_desc=column directly\n in the URL. \n \n \n table_rows => table_rows_count , filtered_table_rows =>\n filtered_table_rows_count \n Renamed properties. Closes #194 \n \n \n New sortable_columns option in metadata.json to control sort options. \n You can now explicitly set which columns in a table can be used for sorting\n using the _sort and _sort_desc arguments using metadata.json : \n {\n \"databases\": {\n \"database1\": {\n \"tables\": {\n \"example_table\": {\n \"sortable_columns\": [\n \"height\",\n \"weight\"\n ]\n }\n }\n }\n }\n} \n Refs #189 \n \n \n Column headers now link to sort/desc sort - refs #189 \n \n \n _sort and _sort_desc parameters for table views \n Allows for paginated sorted results based on a specified column. \n Refs #189 \n \n \n Total row count now correct even if _next applied \n \n \n Use .custom_sql() for _group_count implementation (refs #150 ) \n \n \n Make HTML title more readable in query template ( #180 ) [Ryan Pitts] \n \n \n New ?_shape=objects/object/lists param for JSON API ( #192 ) \n New _shape= parameter replacing old .jsono extension \n Now instead of this: \n /database/table.jsono \n We use the _shape parameter like this: \n /database/table.json?_shape=objects \n Also introduced a new _shape called object which looks like this: \n /database/table.json?_shape=object \n Returning an object for the rows key: \n ...\n\"rows\": {\n \"pk1\": {\n ...\n },\n \"pk2\": {\n ...\n }\n} \n Refs #122 \n \n \n Utility for writing test database fixtures to a .db file \n python tests/fixtures.py /tmp/hello.db \n This is useful for making a SQLite database of the test fixtures for\n interactive exploration. \n \n \n Compound primary key _next= now plays well with extra filters \n Closes #190 \n \n \n Fixed bug with keyset pagination over compound primary keys \n Refs #190 \n \n \n Database/Table views inherit source/license/source_url/license_url \n metadata \n If you set the source_url/license_url/source/license fields in your root\n metadata those values will now be inherited all the way down to the database\n and table templates. \n The title/description are NOT inherited. \n Also added unit tests for the HTML generated by the metadata. \n Refs #185 \n \n \n Add metadata, if it exists, to heroku temp dir ( #178 ) [Tony Hirst] \n \n \n Initial documentation for pagination \n \n \n Broke up test_app into test_api and test_html \n \n \n Fixed bug with .json path regular expression \n I had a table called geojson and it caused an exception because the regex\n was matching .json and not \\.json \n \n \n Deploy to Heroku with Python 3.6.3", "breadcrumbs": "[\"Changelog\"]", "references": "[{\"href\": \"https://github.com/simonw/datasette/issues/194\", \"label\": \"#194\"}, {\"href\": \"https://github.com/simonw/datasette/issues/189\", \"label\": \"#189\"}, {\"href\": \"https://github.com/simonw/datasette/issues/189\", \"label\": \"#189\"}, {\"href\": \"https://github.com/simonw/datasette/issues/189\", \"label\": \"#189\"}, {\"href\": \"https://github.com/simonw/datasette/issues/150\", \"label\": \"#150\"}, {\"href\": \"https://github.com/simonw/datasette/issues/180\", \"label\": \"#180\"}, {\"href\": \"https://github.com/simonw/datasette/issues/192\", \"label\": \"#192\"}, {\"href\": \"https://github.com/simonw/datasette/issues/122\", \"label\": \"#122\"}, {\"href\": \"https://github.com/simonw/datasette/issues/190\", \"label\": \"#190\"}, {\"href\": \"https://github.com/simonw/datasette/issues/190\", \"label\": \"#190\"}, {\"href\": \"https://github.com/simonw/datasette/issues/185\", \"label\": \"#185\"}, {\"href\": \"https://github.com/simonw/datasette/issues/178\", \"label\": \"#178\"}]"}