Tri.form

Latest version: v7.5.0

Safety actively analyzes 630360 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 6 of 13

5.0.4

~~~~~~~~~~~~~~~~~~

* Revert new default parser on `Field.choice`.

5.0.3

~~~~~~~~~~~~~~~~~~

* Improve default parser implementation on `Field.choice`. A reasonable implementation of `__str__` is enough for objects in `choices`.

* Fix evaluation order so that `Field.initial`/`Field.initial_list` is available when fields are evaluated. (`Field.show` is still invoked early)

5.0.2

~~~~~~~~~~~~~~~~~~

* `Field.from_model` produced incorrect parser for foreign keys.

5.0.1

~~~~~~~~~~~~~~~~~~

* Correctly check unique constraints when editing object

* Bug where `form.instance` was set too late in `Form` constructor, resulting in `AttributeError` in certain lambdas

5.0.0

~~~~~~~~~~~~~~~~~~

* Refactored to use new tri.declarative: using `RefinableObject`, `Shortcut`, and the new `call_target` parameter of `Namespace`

* Changed dispatch separator from `__` to `/`

* Changed `label` on `Field` to `display_name`. This is in line with tri.query and tri.table.

* `Field.choice` incorrectly handles post_validation (fixes github issue 9)

* `Form` now doesn't try to read initial data and form data from Fields that are show=False

* `create_or_edit_object` doesn't take a parameter `render_context` anymore, use `render__context`

* You no longer need to specify the `model` parameter to `choice_queryset` or `multi_choice_queryset` if you give it a `QuerySet` as `choices` (as opposed to giving a callable)

* `Field.choice_queryset` and `Field.multi_choice_queryset` now reevaluates the QuerySet on each usage (fixes tri.table github issue 16)

4.10.1

~~~~~~~~~~~~~~~~~~~

* Bugfix: `on_save` callback for `create_or_edit_object` was missing `form` parameter

Page 6 of 13

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.