Browse Source

fix: 将节点的资产添加到系统用户时固定组织

pull/5324/head
xinwen 4 years ago committed by Jiangjie.Bai
parent
commit
332f65cf2f
  1. 3
      apps/assets/tasks/common.py

3
apps/assets/tasks/common.py

@ -3,10 +3,13 @@
from celery import shared_task
from orgs.utils import tmp_to_root_org
__all__ = ['add_nodes_assets_to_system_users']
@shared_task
@tmp_to_root_org()
def add_nodes_assets_to_system_users(nodes_keys, system_users):
from ..models import Node
assets = Node.get_nodes_all_assets(nodes_keys).values_list('id', flat=True)

Loading…
Cancel
Save