立即整改的整改部门与发现部门一致
This commit is contained in:
parent
e4abd4f05f
commit
1da0e12e3b
|
@ -990,6 +990,9 @@ def addyh(req):
|
|||
if zgbm and zgr:
|
||||
a.zgbm = Partment.objects.get(partid=zgbm)
|
||||
a.zgr = User.objects.get(userid=zgr)
|
||||
else:
|
||||
a.zgbm = a.fxbm
|
||||
a.zgr = a.fxr
|
||||
a.save()
|
||||
m = TroubleAccess(troubleid=a, clr=user, yhzt=0,
|
||||
action='新增隐患已整改', result=1)
|
||||
|
@ -1600,7 +1603,6 @@ def accessyh(req):
|
|||
send_wechatmsg.delay(postdict)
|
||||
return JsonResponse({"code": 1})
|
||||
|
||||
|
||||
def parttree2(req):
|
||||
userid = req.session['userid']
|
||||
companyid = getcompany(userid)
|
||||
|
@ -4956,7 +4958,11 @@ def apitool(req):
|
|||
from .tasks import updateAqzs
|
||||
updateAqzs()
|
||||
return JsonResponse({"code":1})
|
||||
|
||||
elif a == 'correct_ljzg':
|
||||
objs = Trouble.objects.filter(yhzt=6, deletemark=1, zgbm__isnull=True, zgr__isnull=True)
|
||||
# print(Trouble.objects.filter(deletemark=1).count(), objs.count())
|
||||
objs.update(zgbm=F('fxbm'), zgr=F('fxr'))
|
||||
return JsonResponse({"code":1})
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue