summaryrefslogtreecommitdiffstats
path: root/nfsw/io.py
diff options
context:
space:
mode:
authorrsiddharth <s@ricketyspace.net>2019-09-21 11:49:37 -0400
committerrsiddharth <s@ricketyspace.net>2019-09-21 11:49:37 -0400
commitd57948a0a2a2fb0390e95183d45924c33e496d94 (patch)
tree521a67758bae1b4af8ac5c685659c18780a42e6e /nfsw/io.py
parent2b1c163835c34d7ac9379993da586d735d8f8264 (diff)
nfsw/io.py: Add query.
Diffstat (limited to 'nfsw/io.py')
-rw-r--r--nfsw/io.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/nfsw/io.py b/nfsw/io.py
index 3e8bb4c..0600b3f 100644
--- a/nfsw/io.py
+++ b/nfsw/io.py
@@ -10,3 +10,13 @@ bp = Blueprint('io', __name__)
@login_required
def io():
return render_template('io.html')
+
+
+@bp.route('/io/query', methods=['POST'])
+@login_required_ajax
+def query():
+ cmd = request.get_data(as_text=True)
+
+ return {
+ 'ans': cmd
+ }