mirror of https://github.com/openspug/spug
fix issue
parent
4d8dcf5d66
commit
712aeca4fc
|
@ -15,6 +15,12 @@ import os
|
||||||
|
|
||||||
class AppView(View):
|
class AppView(View):
|
||||||
def get(self, request):
|
def get(self, request):
|
||||||
|
# v2.3.14 临时数据初始化
|
||||||
|
app = App.objects.first()
|
||||||
|
if app and hasattr(app, 'sort_id') and app.sort_id == 0:
|
||||||
|
for app in App.objects.all():
|
||||||
|
app.sort_id = app.id
|
||||||
|
app.save()
|
||||||
query = {}
|
query = {}
|
||||||
if not request.user.is_supper:
|
if not request.user.is_supper:
|
||||||
query['id__in'] = request.user.deploy_perms['apps']
|
query['id__in'] = request.user.deploy_perms['apps']
|
||||||
|
|
Loading…
Reference in New Issue