mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-08-01 22:58:59 +00:00
[Bugfix] 资产导入中下载模板异常
This commit is contained in:
parent
9a6bc9fec5
commit
c16471d54f
@ -191,7 +191,7 @@ class AssetDetailView(DetailView):
|
||||
class AssetExportView(View):
|
||||
def get(self, request):
|
||||
spm = request.GET.get('spm', '')
|
||||
assets_id_default = [Asset.objects.first().id] if Asset.objects.first() else [1]
|
||||
assets_id_default = [Asset.objects.first().id] if Asset.objects.first() else []
|
||||
assets_id = cache.get(spm, assets_id_default)
|
||||
fields = [
|
||||
field for field in Asset._meta.fields
|
||||
|
Loading…
Reference in New Issue
Block a user