mirror of
https://git.wownero.com/wownero/wownero-funding-system.git
synced 2024-08-15 00:53:45 +00:00
Include QR codes on the proposal page; added API route
This commit is contained in:
parent
75c7f49842
commit
531072d2aa
15 changed files with 191 additions and 21 deletions
|
@ -154,7 +154,7 @@ def proposal_api_add(title, content, pid, funds_target, addr_receiving, category
|
|||
return make_response(jsonify('letters detected'),500)
|
||||
if funds_target < 1:
|
||||
return make_response(jsonify('Proposal asking less than 1 error :)'), 500)
|
||||
if len(addr_receiving) != 97:
|
||||
if len(addr_receiving) != settings.COIN_ADDRESS_LENGTH:
|
||||
return make_response(jsonify('Faulty address, should be of length 72'), 500)
|
||||
|
||||
p = Proposal(headline=title, content=content, category='misc', user=current_user)
|
||||
|
@ -208,6 +208,7 @@ def user(name):
|
|||
user = q.first()
|
||||
return render_template('user.html', user=user)
|
||||
|
||||
|
||||
@app.route('/proposals')
|
||||
@endpoint.api(
|
||||
parameter('status', type=int, location='args', required=False),
|
||||
|
@ -234,6 +235,7 @@ def proposals(status, page, cat):
|
|||
return make_response(render_template('proposal/proposals.html',
|
||||
proposals=proposals, status=status, cat=cat))
|
||||
|
||||
|
||||
@app.route('/register', methods=['GET', 'POST'])
|
||||
def register():
|
||||
if settings.USER_REG_DISABLED:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue