Simon Willison
a8a5f81372
Made show_messages available to plugins, closes #864
2020-06-28 17:50:47 -07:00
Simon Willison
7ac4936cec
.add_message() now works inside plugins, closes #864
...
Refs #870
2020-06-28 17:25:35 -07:00
Simon Willison
563f5a2d3a
Magic parameters for canned queries
...
Closes #842
Includes a new plugin hook, register_magic_parameters()
2020-06-27 19:58:16 -07:00
Simon Willison
4b142862f2
Support non-async view functions, closes #867
2020-06-27 11:30:34 -07:00
Simon Willison
28bb1c5189
csrftoken() now works with .render_template(), closes #863
2020-06-23 20:23:50 -07:00
Simon Willison
6c26345836
New plugin hook: canned_queries(), refs #852
2020-06-18 16:35:15 -07:00
Simon Willison
6151c25a5a
Respect existing scope["actor"] if set, closes #854
2020-06-18 11:37:28 -07:00
Simon Willison
d2aef9f7ef
Test illustrating POST against register_routes(), closes #853
2020-06-18 09:21:15 -07:00
Simon Willison
d60bd6ad13
Update plugin tests, refs #834
2020-06-13 11:15:33 -07:00
Simon Willison
72ae975156
Added test for async startup hook, refs #834
2020-06-13 10:58:32 -07:00
Simon Willison
09a3479a54
New "startup" plugin hook, closes #834
2020-06-13 10:55:41 -07:00
Simon Willison
fac8e93815
request.url_vars property, closes #822
2020-06-08 20:40:00 -07:00
Simon Willison
f5e79adf26
register_routes() plugin hook ( #819 )
...
Fixes #215
2020-06-08 20:12:06 -07:00
Simon Willison
4fa7cf6853
Flash messages mechanism, closes #790
2020-06-02 14:12:18 -07:00
Simon Willison
9315bacf6f
Implemented datasette.permission_allowed(), refs #699
2020-05-31 18:16:42 -07:00
Simon Willison
461c82838d
Implemented actor_from_request with tests, refs #699
...
Also added datasette argument to permission_allowed hook
2020-05-31 18:16:42 -07:00
Simon Willison
84616a2364
request.args.getlist() returns [] if missing, refs #774
...
Also added some unit tests for request.args
2020-05-29 15:51:30 -07:00
Simon Willison
7bb30c1f11
request.url now respects force_https_urls, closes #781
2020-05-28 10:10:06 -07:00
Simon Willison
5ab411c733
can_render mechanism for register_output_renderer, closes #770
2020-05-27 22:57:05 -07:00
Simon Willison
6d95cb4f91
Unit test for register_facet_classes plugin, closes #773
...
I was a bit lazy with this one. I didn't hook up a test for the facet_results mechanism.
The custom facet hook isn't a great design so I will probably rethink it at some point
in the future anyway.
2020-05-27 21:09:16 -07:00
Simon Willison
cbeea23d00
Test for prepare_jinja2_environment, refs #773
2020-05-27 20:13:32 -07:00
Simon Willison
57f48b8416
Made register_output_renderer callback optionally awaitable, closes #776
2020-05-27 19:43:30 -07:00
Simon Willison
52c4387c7d
Redesigned register_output_renderer plugin hook, closes #581
2020-05-27 19:21:41 -07:00
Simon Willison
446e5de65d
Refactored test plugins into tests/plugins, closes #775
2020-05-27 17:57:25 -07:00