changeset cea2a39c6e31 in trytond:default
details: https://hg.tryton.org/trytond?cmd=changeset&node=cea2a39c6e31
description:
Do not set _timestamp on fake singleton instance
It is not really useful because the id of the future record can not be
guessed
for sure by the client.
Also when write is called with such fake _timestamp as singleton create
the
record before actually write, the timestamp check always fails (if the
id was
correctly guessed).
issue10282
diffstat:
trytond/model/modelsingleton.py | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diffs (11 lines):
diff -r 9124f759395d -r cea2a39c6e31 trytond/model/modelsingleton.py
--- a/trytond/model/modelsingleton.py Tue Apr 13 18:17:22 2021 +0200
+++ b/trytond/model/modelsingleton.py Wed Apr 14 00:39:56 2021 +0200
@@ -48,7 +48,6 @@
res['id'] = ids[0]
res['_write'] = True
res['_delete'] = True
- res['_timestamp'] = '0'
return [res]
res = super(ModelSingleton, cls).read([singleton.id], fields_names)
res[0]['id'] = ids[0]