transaction事务模块

通过使用@transaction.atomic 添加装饰

在函数内使用 with transaction.atomic():

具体使用百度

原文地址:https://www.cnblogs.com/wangdongpython/p/10856095.html