浏览代码

HUE-8950 [core] Fix error of saving copied document (#886)

batou9150 6 年之前
父节点
当前提交
6a10e983d6
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      desktop/core/src/desktop/models.py

+ 2 - 0
desktop/core/src/desktop/models.py

@@ -708,6 +708,8 @@ class Document(models.Model):
         content_object.doc.get().delete()
         content_object.doc.get().delete()
       content_object.doc.add(copy_doc)
       content_object.doc.add(copy_doc)
 
 
+      copy_doc.save()
+
       return copy_doc
       return copy_doc
     else:
     else:
       raise PopupException(_("Document copy method requires a content_object argument."))
       raise PopupException(_("Document copy method requires a content_object argument."))