Message5894
I've now traced this a little further, it turns out that
- Form values *are* preserved internally. The whole form is present in
the cgi client used to render an issue
- But: The database wins. Only if a field is empty in the database
(return None but for Number a 0 will probably also be overridden) the
form will override this value.
Code is in cgi/templating.py notably the HTMLProperty class (from which
all the special classes like DateHTMLProperty inherit) does a lookup of
the form value only if it is passed an empty value in the constructor.
This in turn is called from __getitem__ of _HTMLItem which looks up the
value from the database.
Now to fix this we need some way to pass information to HTMLProperty to
indicate that it should prefer the form contents over the database contents.
I don't know if this would be a security risk to *always* prefer the
form values... |
|
Date |
User |
Action |
Args |
2016-08-16 13:40:27 | schlatterbeck | set | messageid: <1471354827.16.0.401892448948.issue1408570@psf.upfronthosting.co.za> |
2016-08-16 13:40:27 | schlatterbeck | set | recipients:
+ schlatterbeck, richard, stefan, rouilj |
2016-08-16 13:40:27 | schlatterbeck | link | issue1408570 messages |
2016-08-16 13:40:26 | schlatterbeck | create | |
|