add wallet page
This commit is contained in:
parent
77671bb560
commit
80a11afca3
3 changed files with 37 additions and 0 deletions
0
wotstats/models/wallet.py
Normal file
0
wotstats/models/wallet.py
Normal file
13
wotstats/templates/pages/wallet/index.html
Normal file
13
wotstats/templates/pages/wallet/index.html
Normal file
|
@ -0,0 +1,13 @@
|
|||
{% extends 'layouts/main.html' %}
|
||||
|
||||
{% block content %}
|
||||
<h2>My Wallet</h2>
|
||||
<p>Cash: $100500</p>
|
||||
<h2>Add Money</h2>
|
||||
<form action="" method="post" class="mui-form">
|
||||
<div class="mui-textfield">
|
||||
<input type='text' name="" value="" placeholder="100" />
|
||||
</div>
|
||||
<input type='submit' value="pay" class="mui-btn mui-btn--raised" />
|
||||
</form>
|
||||
{% endblock %}
|
24
wotstats/views/wallet.py
Normal file
24
wotstats/views/wallet.py
Normal file
|
@ -0,0 +1,24 @@
|
|||
import requests
|
||||
from flask import (
|
||||
g, Blueprint, render_template, abort, current_app, redirect,
|
||||
redirect, request, url_for, session, flash
|
||||
)
|
||||
from jinja2 import TemplateNotFound
|
||||
from wotstats.openid import oid
|
||||
|
||||
from wotstats.database import db
|
||||
from wotstats.models import User
|
||||
from wotstats.lib import parse_wargaming_openid_url
|
||||
|
||||
pages_wallet = Blueprint(
|
||||
'pages_wallet', __name__, url_prefix='/wallet', template_folder='templates')
|
||||
|
||||
|
||||
@pages_wallet.route('/')
|
||||
def index():
|
||||
if not g.user:
|
||||
return redirect(url_for('pages_home.index'))
|
||||
|
||||
return render_template(
|
||||
'pages/wallet/index.html'
|
||||
)
|
Reference in a new issue