From 25705297f54ea0ba664d766c07830ab4928963c1 Mon Sep 17 00:00:00 2001 From: caoqianming Date: Tue, 4 Aug 2020 21:33:52 +0800 Subject: [PATCH] trouble bug --- safesite/views.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/safesite/views.py b/safesite/views.py index 251be338..32ae4be5 100644 --- a/safesite/views.py +++ b/safesite/views.py @@ -1942,7 +1942,7 @@ def troublehandle(req): userid=userid)).exclude(deletemark=0) total = a.count() startnum, endnum = fenye(req) - obj = a.order_by('-xgsj')[startnum:endnum].values('troubleid', 'fxr__userid', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', + obj = a.order_by('-fxsj')[startnum:endnum].values('troubleid', 'fxr__userid', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', 'yhlb__dickeyname', 'todouser__name', 'todouser__userid', 'yhpg__dickeyname', 'yhnum', 'yhdj__dickeyname', 'shresult', 'zgqx') return HttpResponse(transjson(total, obj), content_type="application/json") elif a == 'listself': @@ -1950,7 +1950,7 @@ def troublehandle(req): a = Trouble.objects.filter(fxr__userid=userid).exclude(deletemark=0) total = a.count() startnum, endnum = fenye(req) - obj = a.order_by('-xgsj')[startnum:endnum].values('troubleid', 'fxr__userid', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', + obj = a.order_by('-fxsj')[startnum:endnum].values('troubleid', 'fxr__userid', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', 'yhlb__dickeyname', 'todouser__name', 'todouser__userid', 'yhpg__dickeyname', 'yhnum', 'yhdj__dickeyname', 'shresult', 'zgqx') return HttpResponse(transjson(total, obj), content_type="application/json") elif a == 'listall': @@ -1960,7 +1960,7 @@ def troublehandle(req): partid=companyid)).exclude(deletemark=0) total = a.count() startnum, endnum = fenye(req) - obj = a.order_by('-xgsj')[startnum:endnum].values('troubleid', 'fxr__userid', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', + obj = a.order_by('-fxsj')[startnum:endnum].values('troubleid', 'fxr__userid', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', 'yhlb__dickeyname', 'todouser__name', 'todouser__userid', 'yhpg__dickeyname', 'yhnum', 'yhdj__dickeyname', 'shresult', 'zgqx') return HttpResponse(transjson(total, obj), content_type="application/json") elif a == 'listsearch': @@ -2025,7 +2025,7 @@ def troublehandle(req): a = a.filter(yhqy__id=yhqy) total = a.count() startnum, endnum = fenye(req) - obj = a.order_by('-xgsj')[startnum:endnum].values('troubleid', 'fxr__userid', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', + obj = a.order_by('-fxsj')[startnum:endnum].values('troubleid', 'fxr__userid', 'fxr__name', 'yhms', 'yhzt', 'fxsj', 'tbsj', 'yhlb__dickeyname', 'todouser__name', 'yhpg__dickeyname', 'yhnum', 'yhdj__dickeyname', 'shresult', 'zgqx', 'yhtp', 'zghtp') return HttpResponse(transjson(total, obj), content_type="application/json")