summaryrefslogtreecommitdiffstats
path: root/ogcp
diff options
context:
space:
mode:
Diffstat (limited to 'ogcp')
-rw-r--r--ogcp/views.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/ogcp/views.py b/ogcp/views.py
index a5b04a1..c0d19ad 100644
--- a/ogcp/views.py
+++ b/ogcp/views.py
@@ -473,8 +473,10 @@ def action_hardware():
ips = form.ips.data.split(' ')
r = g.server.post('/hardware', payload={'clients': ips})
if r.status_code == requests.codes.ok:
- return make_response("200 OK", 200)
- return make_response("400 Bad Request", 400)
+ flash(_(f'Hardware inventory command has been sent'), category='info')
+ else:
+ flash(_(f'There was a problem sending the hardware inventory command'), category='error')
+ return redirect(url_for('commands'))
else:
ips = parse_elements(request.args.to_dict())
scopes, _clients = get_scopes(ips)