Wykres commitów

432 Commity (main)

Autor SHA1 Wiadomość Data
Simon Willison b8711988b9 row_actions() plugin hook, closes #2299 2024-03-12 16:16:05 -07:00
Simon Willison 909c85cd2b view_actions plugin hook, closes #2297 2024-03-12 14:25:28 -07:00
Simon Willison daf5ca02ca homepage_actions() plugin hook, closes #2298 2024-03-12 13:46:06 -07:00
Simon Willison 6ec0081f5d
`query_actions` plugin hook
* New query_actions plugin hook, closes #2283
2024-02-27 21:55:16 -08:00
Simon Willison 26300738e3 Fixes for permissions debug page, closes #2278 2024-02-19 14:17:37 -08:00
Simon Willison b36a2d8f4b Require update-row to use insert replace, closes #2279 2024-02-19 12:55:51 -08:00
Simon Willison 3856a8cb24 Consistent Permission denied:, refs #2279 2024-02-19 12:51:14 -08:00
Simon Willison 3a999a85fb Fire insert-rows on /db/-/create if rows were inserted, refs #2260 2024-02-16 13:59:56 -08:00
Simon Willison bd9ed62e5d Make ds.pemrission_allawed(..., default=) a keyword-only argument, refs #2262 2024-02-08 20:12:31 -08:00
Simon Willison c954795f9a alter: true for row/-/update, refs #2101 2024-02-08 13:36:17 -08:00
Simon Willison 528d89d1a3 alter: true support for /-/insert and /-/upsert, refs #2101 2024-02-08 13:36:17 -08:00
Simon Willison 900d15bcb8 alter table support for /db/-/create API, refs #2101 2024-02-08 13:36:17 -08:00
Simon Willison 60c6692f68
table_config instead of table_metadata (#2257)
Table configuration that was incorrectly placed in metadata is now treated as if it was in config.

New await datasette.table_config() method.

Closes #2247
2024-02-06 21:57:09 -08:00
Simon Willison f049103852 datasette.table_metadata() is now await datasette.table_config(), refs #2247 2024-02-06 17:33:18 -08:00
Simon Willison 69c6e95323 Fixed a bunch of unused imports spotted with ruff 2024-02-06 17:27:20 -08:00
Simon Willison 5a63ecc557 Rename metadata= to table_config= in facet code, refs #2247 2024-02-06 15:03:19 -08:00
Simon Willison 1e901aa690 /-/config page, closes #2254 2024-02-06 12:33:46 -08:00
Simon Willison bcc4f6bf1f
track_event() mechanism for analytics and plugins
* Closes #2240
* Documentation for event plugin hooks, refs #2240
* Include example track_event plugin in docs, refs #2240
* Tests for track_event() and register_events() hooks, refs #2240
* Initial documentation for core events, refs #2240
* Internals documentation for datasette.track_event()
2024-01-31 15:21:40 -08:00
Simon Willison 5c64af6936 Upgrade to latest Black, closes #2239 2024-01-30 19:55:26 -08:00
Simon Willison c3caf36af7
Template slot family of plugin hooks - top_homepage() and others
New plugin hooks:

top_homepage
top_database
top_table
top_row
top_query
top_canned_query

New datasette.utils.make_slot_function()

Closes #1191
2024-01-30 19:54:03 -08:00
Simon Willison c7a4706bcc
jinja2_environment_from_request() plugin hook
Closes #2225
2024-01-05 14:33:23 -08:00
Simon Willison 872dae1e1a Fix for CSV labels=on missing foreign key bug, closes #2214 2023-12-22 15:08:11 -08:00
Simon Willison 978249beda Removed rogue print("max_csv_mb")
Found this while working on #2214
2023-12-22 15:07:42 -08:00
Simon Willison b0e5d8afa3
Stop using parallel SQL queries for tables
Refs:
- #2189
2023-09-20 15:10:55 -07:00
Simon Willison dbfad6d220 Foreign key label expanding respects table permissions, closes #2178 2023-09-07 15:51:09 -07:00
Simon Willison bb12229794 Rename core_ to catalog_, closes #2163 2023-08-29 10:01:28 -07:00
Simon Willison 50da908213
Cascade for restricted token view-table/view-database/view-instance operations (#2154)
Closes #2102

* Permission is now a dataclass, not a namedtuple - refs https://github.com/simonw/datasette/pull/2154/#discussion_r1308087800
* datasette.get_permission() method
2023-08-29 09:32:34 -07:00
Alex Garcia 92b8bf38c0
Add new `--internal internal.db` option, deprecate legacy `_internal` database
Refs:
- #2157 
---------

Co-authored-by: Simon Willison <swillison@gmail.com>
2023-08-28 20:24:23 -07:00
Simon Willison 01e0558825
Merge pull request from GHSA-7ch3-7pp7-7cpq
* API explorer requires view-instance permission

* Check database/table permissions on /-/api page

* Release notes for 1.0a4

Refs #2119, #2133, #2138, #2140

Refs https://github.com/simonw/datasette/security/advisories/GHSA-7ch3-7pp7-7cpq
2023-08-22 10:10:01 -07:00
Simon Willison 4535568f2c Fixed display of database color
Closes #2139, closes #2119
2023-08-10 22:16:19 -07:00
Simon Willison a3593c9015 on_success_message_sql, closes #2138 2023-08-09 17:32:07 -07:00
Simon Willison e34d09c6ec Don't include columns in query JSON, refs #2136 2023-08-09 12:01:59 -07:00
Simon Willison 26be9f0445 Refactored canned query code, replaced old QueryView, closes #2114 2023-08-09 08:26:52 -07:00
Simon Willison cd57b0f712 Brought back parameter fields, closes #2132 2023-08-08 06:45:04 -07:00
Simon Willison 1377a290cd
New JSON design for query views (#2118)
* Refs #2111, closes #2110
* New Context dataclass/subclass mechanism, refs #2127
* Define QueryContext and extract get_tables() method, refs #2127
* Fix OPTIONS bug by porting DaatbaseView to be a View subclass
* Expose async_view_for_class.view_class for test_routes test
* Error/truncated aruments for renderers, closes #2130
2023-08-07 18:47:39 -07:00
Simon Willison 18dd88ee4d Refactored DatabaseDownload to database_download, closes #2116 2023-07-26 11:43:55 -07:00
Simon Willison dda99fc09f
New View base class (#2080)
* New View base class, closes #2078
* Use new View subclass for PatternPortfolioView
2023-05-25 17:18:43 -07:00
Simon Willison 651b78d8e6 Redesign ?_extra=extras a bit, refs #262 2023-03-28 23:07:30 -07:00
Simon Willison 3feed1f66e Re-applied Black 2023-03-22 15:54:35 -07:00
Simon Willison d97e82df3c
?_extra= support and TableView refactor to table_view
* Implemented ?_extra= option for JSON views, refs #262
* New dependency: asyncinject
* Remove now-obsolete TableView class
2023-03-22 15:49:39 -07:00
Simon Willison 0b4a286914 render_cell(..., request) argument, closes #2007 2023-01-27 19:34:14 -08:00
Simon Willison 572bdb5b80 Applied Black, refs #782 2022-12-31 19:32:07 -08:00
Simon Willison d94a3c4326
No need to link to _shape=objects any more
It's the default now. Refs #782
2022-12-31 17:42:48 -08:00
Simon Willison 3c352b7132 Applied Black, refs #782 2022-12-31 13:17:54 -08:00
Simon Willison 5bbe2bcc50 Rename filtered_table_rows_count to count, refs #782 2022-12-31 12:52:57 -08:00
Simon Willison c094dde3ff Extra permission rules for /-/create, closes #1937 2022-12-14 12:21:18 -08:00
Simon Willison 1a3dcf4943 Don't include _memory on /-/create-token, refs #1947 2022-12-13 21:19:31 -08:00
Simon Willison d98a8effb1 UI for restricting permissions on /-/create-token, refs #1947
Also fixes test failures I introduced in #1951
2022-12-13 21:03:17 -08:00
Simon Willison f84acae98e Return 400 errors for ?_sort errors, closes #1950 2022-12-13 14:23:17 -08:00
Simon Willison c6a811237c /-/actor.json no longer requires view-instance, closes #1945 2022-12-12 20:11:51 -08:00