mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-09-21 11:28:38 +00:00
Dev beta (#3167)
* [Update] 添加loading * [Update] 修改避免游离资产 * [Update] 修改nodes * [Update] 修改支持未分组
This commit is contained in:
@@ -64,8 +64,11 @@ class OrgModelMixin(models.Model):
|
||||
sep = '@'
|
||||
|
||||
def save(self, *args, **kwargs):
|
||||
if current_org is not None and current_org.is_real():
|
||||
self.org_id = current_org.id
|
||||
org = get_current_org()
|
||||
if org is not None and (org.is_real() or org.is_system()):
|
||||
self.org_id = org.id
|
||||
elif org is not None and org.is_default():
|
||||
self.org_id = ''
|
||||
return super().save(*args, **kwargs)
|
||||
|
||||
@property
|
||||
|
Reference in New Issue
Block a user