mirror of
https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
synced 2025-06-23 06:20:34 +00:00
Use ISO 8601 as the default datetime format
This commit is contained in:
@ -96,9 +96,9 @@ def ressource_after_update_handler(mapper, connection, ressource):
|
||||
if not history.has_changes():
|
||||
continue
|
||||
new_value = history.added[0]
|
||||
# DateTime attributes must be converted to a timestamp
|
||||
# DateTime attributes must be converted to a string
|
||||
if isinstance(new_value, datetime):
|
||||
new_value = new_value.timestamp()
|
||||
new_value = new_value.isoformat()
|
||||
jsonpatch.append(
|
||||
{
|
||||
'op': 'replace',
|
||||
|
Reference in New Issue
Block a user