fixed bug on views from sfmodel loading time

This commit is contained in:
anon 2022-08-02 21:58:48 -03:00
parent 8bb1002751
commit 47520e958e
2 changed files with 14 additions and 19 deletions

View file

@ -97,17 +97,17 @@
<div class="col">
<p>
<i class="bx bx-user"></i> Morpheus
<i class="bx bx-calendar"></i> May 11, 25 contributions >
<i class="bx bx-calendar"></i> May 11, 35 contributions >
</p>
</div>
<div class="col">
<p style="text-align: right;">
(manual update) <i class="bx bx-money"></i> Raised 10.31 of 46 XMR
(manual update) <i class="bx bx-money"></i> Raised 11.01 of 46 XMR
</p>
</div>
</div>
<div class="progress">
<div class="progress-bar bg-danger" role="progressbar" style="width: 23%; color: #ff4d21" aria-valuenow="10.31" aria-valuemin="0" aria-valuemax="46"></div>
<div class="progress-bar bg-danger" role="progressbar" style="width: 24%; color: #ff4d21" aria-valuenow="11.01" aria-valuemin="0" aria-valuemax="46"></div>
</div>
</div>
</div>
@ -135,17 +135,17 @@
<div class="col">
<p>
<i class="bx bx-user"></i> Morpheus
<i class="bx bx-calendar"></i> May 11, 25 contributions >
<i class="bx bx-calendar"></i> May 11, 35 contributions >
</p>
</div>
<div class="col">
<p style="text-align: right;">
(manual update) <i class="bx bx-money"></i> Raised 10.31 of 46 XMR
(manual update) <i class="bx bx-money"></i> Raised 11.01 of 46 XMR
</p>
</div>
</div>
<div class="progress">
<div class="progress-bar bg-danger" role="progressbar" style="width: 23%; color: #ff4d21" aria-valuenow="10.31" aria-valuemin="0" aria-valuemax="46"></div>
<div class="progress-bar bg-danger" role="progressbar" style="width: 24%; color: #ff4d21" aria-valuenow="11.01" aria-valuemin="0" aria-valuemax="46"></div>
</div>
</div>
</div>

View file

@ -3727,7 +3727,6 @@ def sfmodel(request):
update_visitors(False)
dt = datetime.datetime.now(timezone.utc).timestamp()
update = False
today = datetime.datetime.strftime(date.today(), '%Y-%m-%d')
@ -3742,23 +3741,19 @@ def sfmodel(request):
print('no need to update')
update = False
else:
print('need to update, coin has missing parameters')
now = datetime.datetime.now()
current_time = int(now.strftime("%H"))
if current_time >= 5:
coin.delete()
#coin_aux.delete()
update = True
else:
update = False
else:
print('no coin found yesterday')
print('no coin found yesterday - 1')
update = True
except:
print('no coin found yesterday')
print('no coin found yesterday - 2')
update = True
if update:
now = datetime.datetime.now()
current_time = int(now.strftime("%H"))
if update and (current_time >= 5):
print('social')
check_new_social('Bitcoin')
check_new_social('Monero')