mirror of
https://github.com/house-of-vanity/OutFleet.git
synced 2025-07-07 01:24:06 +00:00
Added traffic info
This commit is contained in:
7
main.py
7
main.py
@ -75,13 +75,16 @@ def index():
|
||||
add_server=request.args.get('add_server', None),
|
||||
format_timestamp=format_timestamp,
|
||||
)
|
||||
else:
|
||||
elif request.method == 'POST':
|
||||
server = request.form['server_id']
|
||||
server = next((item for item in SERVERS if item.info()["server_id"] == server), None)
|
||||
server.apply_config(request.form)
|
||||
update_state()
|
||||
return redirect(
|
||||
url_for('index', nt="Updated Outline VPN Server", selected_server=request.args.get('selected_server')))
|
||||
else:
|
||||
return redirect(
|
||||
url_for('index'))
|
||||
|
||||
|
||||
@app.route('/clients', methods=['GET', 'POST'])
|
||||
@ -176,7 +179,7 @@ def add_client():
|
||||
update_state()
|
||||
return redirect(url_for('clients', nt="Clients updated", selected_client=request.form.get('user_id')))
|
||||
else:
|
||||
return redirect(url_for('index'))
|
||||
return redirect(url_for('clients'))
|
||||
|
||||
|
||||
@app.route('/del_client', methods=['POST'])
|
||||
|
Reference in New Issue
Block a user