Issue 10740

Title
bug: when create attendance periode -> Fault: "attendance.period,6" has no attribute "date"
Priority
bug
Status
resolved
Nosy list
ced, delphine2776, reviewbot, roundup-bot
Assigned to
ced
Keywords
backport, review

Created on 2021-09-10.18:26:08 by delphine2776, last changed 7 days ago by roundup-bot.

Messages

New changeset d44f25ddea52 by Cédric Krier in branch 'default':
Use ends_at for record name of period and use language format
https://hg.tryton.org/tryton-env/rev/d44f25ddea52
New changeset d0501664206f by Cédric Krier in branch 'default':
Use ends_at for record name of period and use language format
https://hg.tryton.org/modules/attendance/rev/d0501664206f
Author: [hidden] (delphine2776)
Date: 2021-09-10.18:26:08

Trytond 6.1

Via Gui, i try create attendance period
When i save, i have this error
During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/trytond/wsgi.py", line 117, in dispatch_request
    return endpoint(request, **request.view_args)
  File "/trytond/protocols/dispatcher.py", line 48, in rpc
    request, database_name, *request.rpc_params)
  File "/trytond/wsgi.py", line 84, in auth_required
    return wrapped(*args, **kwargs)
  File "/trytond/protocols/wrappers.py", line 159, in wrapper
    return func(request, pool, *args, **kwargs)
  File "/trytond/protocols/dispatcher.py", line 181, in _dispatch
    result = rpc.result(meth(*c_args, **c_kwargs))
  File "/trytond/model/modelsql.py", line 866, in read
    sub_ids, cls, field_list, values=sub_results)
  File "/trytond/model/fields/function.py", line 105, in get
    return dict((name, call(name)) for name in names)
  File "/trytond/model/fields/function.py", line 105, in <genexpr>
    return dict((name, call(name)) for name in names)
  File "/trytond/model/fields/function.py", line 100, in call
    return dict((r.id, method(r, name)) for r in records)
  File "/trytond/model/fields/function.py", line 100, in <genexpr>
    return dict((r.id, method(r, name)) for r in records)
  File "/trytond/modules/attendance/attendance.py", line 203, in get_rec_name
    return str(self.date)
  File "/trytond/model/modelstorage.py", line 1514, in __getattr__
    raise AttributeError('"%s" has no attribute "%s"' % (self, name))
AttributeError: "attendance.period,8" has no attribute "date"

Fault: "attendance.period,8" has no attribute "date"
History
Date User Action Args
2021-09-19 00:10:44roundup-botsetmessages: + msg70202
2021-09-19 00:10:39roundup-botsetmessages: + msg70201
nosy: + roundup-bot
status: testing -> resolved
2021-09-19 00:09:53cedsetkeyword: + backport
2021-09-10 18:48:36reviewbotsetmessages: + msg69988
nosy: + reviewbot
2021-09-10 18:39:17cedsetassignedto: ced
keyword: + review
nosy: + ced
reviews: 334971002
status: unread -> testing
2021-09-10 18:30:17cedsetcomponent: + attendance
2021-09-10 18:26:08delphine2776create

Showing 10 items. Show all history (warning: this could be VERY long)