mirror of
https://github.com/suitenumerique/docs.git
synced 2026-09-17 23:28:01 +02:00
For the create_for_owner action, all the db operation are made in the serializer. But the lock of the table was acquired in the viewsets, lot of operation are made between the lock is made and the insert in db. We move the lock operation closer to the insert in the database. We wrap it in a transaction to release the lock once the commit made.