演练查询bug
This commit is contained in:
parent
c653c98528
commit
297c8cf966
|
@ -3315,13 +3315,12 @@ def ylhandle(req):
|
|||
elif req.GET.get('a') == 'listsearch':
|
||||
userid = req.session['userid']
|
||||
companyid = getcompany(userid)
|
||||
a = Drill.objects.filter(usecomp=Partment.objects.get(
|
||||
partid=companyid), deletemark=1)
|
||||
qssj = req.GET.get('qssj')
|
||||
jssj = req.GET.get('jssj')
|
||||
ylbm = req.GET.get('drillpart')
|
||||
yljb = req.GET.get('drilllevel')
|
||||
ylnr = req.GET.get('drillcontent')
|
||||
a = Drill.objects.filter(usecomp__partid=companyid, deletemark=1)
|
||||
qssj = req.GET.get('qssj', None)
|
||||
jssj = req.GET.get('jssj', None)
|
||||
ylbm = req.GET.get('drillpart', None)
|
||||
yljb = req.GET.get('drilllevel', None)
|
||||
ylnr = req.GET.get('drillcontent', None)
|
||||
if yljb:
|
||||
a = a.filter(drilllevel__dicid=yljb)
|
||||
if ylnr:
|
||||
|
@ -3334,7 +3333,7 @@ def ylhandle(req):
|
|||
a = a.filter(starttime__lte=jssj)
|
||||
total = a.count()
|
||||
startnum, endnum = fenye(req)
|
||||
obj = a.order_by('-starttime')[startnum:endnum].values('drillnum', 'drillid', 'state', 'drillplace',
|
||||
a = a.order_by('-starttime')[startnum:endnum].values('drillnum', 'drillid', 'state', 'drillplace',
|
||||
'starttime', 'drillname', 'drilltype__dickeyname', 'chief__name', 'submituser__name', 'submituser__userid')
|
||||
return HttpResponse(transjson(total, a), content_type="application/json")
|
||||
|
||||
|
|
Loading…
Reference in New Issue