Browse Source
Both fields should be written in one go. An inline write like this causes validations to be called two times and fail at times where lastname becomes False and firstname is written only in following write. Use Case: When the intention is to change the order of firstname and lastname, the user is guided to override the _get_inverse_name. One of the simpler approaches is to switch the fields of the result returned by this function. However, this will fail for companies. At the moment lastname and firstname attributes are written, lastname will be written first (if the order is changed it will be False) leaving the record temporarily with both lastname and firstname False which raises an exception in _check_name function.pull/276/head
1 changed files with 6 additions and 1 deletions
Loading…
Reference in new issue