Browse Source

[Update] 修改资产使用patch方法更新时页面不提示messages信息

pull/2827/head
BaiJiangJie 6 years ago
parent
commit
3da43bf01d
  1. 2
      apps/common/mixins.py

2
apps/common/mixins.py

@ -224,7 +224,7 @@ class ApiMessageMixin:
def dispatch(self, request, *args, **kwargs):
resp = super().dispatch(request, *args, **kwargs)
if request.method.lower() in ("get", "delete"):
if request.method.lower() in ("get", "delete", "patch"):
return resp
if resp.status_code >= 400:
return resp

Loading…
Cancel
Save