forked from rDrama/rDrama
hggh
parent
f8d31b02ca
commit
4d63aa70a5
|
@ -147,7 +147,7 @@ def frontlist(v=None, sort="hot", page=1, t="all", ids_only=True, filter_words='
|
||||||
secondrange = firstrange+200
|
secondrange = firstrange+200
|
||||||
posts = posts[firstrange:secondrange]
|
posts = posts[firstrange:secondrange]
|
||||||
|
|
||||||
if v and v.hidevotedon: posts = [x for x in posts if not (hasattr(x, 'voted') and x.voted != 0)]
|
if v and v.hidevotedon: posts = [x for x in posts if not hasattr(x, 'voted') or x.voted == 0]
|
||||||
|
|
||||||
words = ['captainmeta4', ' cm4 ', 'dissident001', 'ladine']
|
words = ['captainmeta4', ' cm4 ', 'dissident001', 'ladine']
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,7 @@ beams_client = PushNotifications(
|
||||||
@app.post("/pay_rent")
|
@app.post("/pay_rent")
|
||||||
@auth_required
|
@auth_required
|
||||||
def pay_rent(v):
|
def pay_rent(v):
|
||||||
|
if v.coins < 500: return "You must have more than 500 coins."
|
||||||
v.coins -= 500
|
v.coins -= 500
|
||||||
v.rent_utc = int(time.time())
|
v.rent_utc = int(time.time())
|
||||||
g.db.add(v)
|
g.db.add(v)
|
||||||
|
|
|
@ -12,7 +12,9 @@
|
||||||
<h2 class="h5">This account is private</h2>
|
<h2 class="h5">This account is private</h2>
|
||||||
<p class="text-muted">This user has enabled private mode to cloak their posting history.</p>
|
<p class="text-muted">This user has enabled private mode to cloak their posting history.</p>
|
||||||
{% if u.id == 253 and 'rdrama' in request.host %}
|
{% if u.id == 253 and 'rdrama' in request.host %}
|
||||||
|
{% if v and v.coins > 500 and not v.is_suspended %}
|
||||||
<a class="btn btn-primary" href="javascript:void(0)", onclick="post('/pay_rent', callback=function(){window.location.reload(true)})">Pay rent to view profile (500 coins)</a>
|
<a class="btn btn-primary" href="javascript:void(0)", onclick="post('/pay_rent', callback=function(){window.location.reload(true)})">Pay rent to view profile (500 coins)</a>
|
||||||
|
{% endif %}
|
||||||
<pre></pre>
|
<pre></pre>
|
||||||
{% if v and v.coins > 5000 and time - v.created_utc > 604800 and not v.is_suspended %}
|
{% if v and v.coins > 5000 and time - v.created_utc > 604800 and not v.is_suspended %}
|
||||||
<a class="btn btn-primary" href="javascript:void(0)", onclick="post('/steal', callback=function(){window.location.reload(true)})">Attempt to steal coins</a>
|
<a class="btn btn-primary" href="javascript:void(0)", onclick="post('/steal', callback=function(){window.location.reload(true)})">Attempt to steal coins</a>
|
||||||
|
|
Loading…
Reference in New Issue