📜  保存后的 django 更新字段 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:45.526000             🧑  作者: Mango

代码示例1
# django update field after save
record = Record.objects.get(id=1)
record.name = "new record name"
record.save(update_fields=['name'])