Commit b51ad05a authored by BaiJiangJie's avatar BaiJiangJie

[Update] 修复初始化 Default 节点的 Bug(原因:在其他组织下 Default 节点默认的 key 1 已经存在)5

parent ca178c53
......@@ -355,9 +355,7 @@ class SomeNodesMixin:
with transaction.atomic():
if not ori_org.is_real():
return cls.default_node()
set_current_org(Organization.root())
key = cls.get_next_org_root_node_key()
set_current_org(ori_org)
root = cls.objects.create(key=key, value=ori_org.name)
return root
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment