fix issue @ben ;)

This commit is contained in:
dni ⚡ 2023-01-04 17:09:50 +01:00
parent 32b785d790
commit 40bcee6d22
3 changed files with 256 additions and 250 deletions

View file

@ -70,7 +70,7 @@ def get_text_item_dict(
else: else:
data_text["x"] = x_pos if x_pos > 0 else 0 data_text["x"] = x_pos if x_pos > 0 else 0
data_text["y"] = y_pos if x_pos > 0 else 0 data_text["y"] = y_pos if x_pos > 0 else 0
return text return data_text
def get_date_suffix(dayNumber): def get_date_suffix(dayNumber):
@ -532,7 +532,6 @@ async def get_screen_data(screen_num: int, screens_list: list, gerty):
"title": title, "title": title,
"areas": areas, "areas": areas,
} }
return data return data

View file

@ -1,10 +1,10 @@
{% extends "public.html" %} {% block toolbar_title %} Gerty: {% raw %}{{ {% extends "public.html" %} {% block toolbar_title %} Gerty: {% raw %}{{
gertyname }}{% endraw %}{% endblock %}{% block page %} {% raw %} gertyname }}{% endraw %}{% endblock %}{% block page %} {% raw %}
<div <div
class="q-pa-md row items-start q-gutter-md" class="q-pa-md row items-start q-gutter-md"
v-if="fun_exchange_market_rate || fun_satoshi_quotes" v-if="fun_exchange_market_rate || fun_satoshi_quotes"
> >
<q-card <q-card
v-if="fun_exchange_market_rate" v-if="fun_exchange_market_rate"
unelevated unelevated
@ -30,9 +30,12 @@
<small>~ Satoshi {{fun_satoshi_quotes["date"]}}</small> <small>~ Satoshi {{fun_satoshi_quotes["date"]}}</small>
</blockquote> </blockquote>
</q-card> </q-card>
</div> </div>
<div class="q-pa-md row items-start q-gutter-md" v-if="lnbits_wallets_balance[0]"> <div
class="q-pa-md row items-start q-gutter-md"
v-if="lnbits_wallets_balance[0]"
>
<q-card <q-card
class="q-pa-sm" class="q-pa-sm"
v-for="(wallet, t) in lnbits_wallets_balance" v-for="(wallet, t) in lnbits_wallets_balance"
@ -45,12 +48,12 @@
<small class="text-h4">({{wallet["name"]}})</small> <small class="text-h4">({{wallet["name"]}})</small>
</q-card-section> </q-card-section>
</q-card> </q-card>
</div> </div>
<div <div
class="q-pa-md row items-start q-gutter-md" class="q-pa-md row items-start q-gutter-md"
v-if="dashboard_onchain[0] || dashboard_mining[0] || lightning_dashboard[0]" v-if="dashboard_onchain[0] || dashboard_mining[0] || lightning_dashboard[0]"
> >
<q-card <q-card
class="q-pa-sm" class="q-pa-sm"
v-if="dashboard_onchain[0]" v-if="dashboard_onchain[0]"
@ -78,7 +81,12 @@
</q-card-section> </q-card-section>
</q-card> </q-card>
<q-card class="q-pa-sm" v-if="lightning_dashboard[0]" unelevated class="q-pa-sm"> <q-card
class="q-pa-sm"
v-if="lightning_dashboard[0]"
unelevated
class="q-pa-sm"
>
<q-card-section> <q-card-section>
<div class="text-h6">Lightning (Last 7 days)</div> <div class="text-h6">Lightning (Last 7 days)</div>
</q-card-section> </q-card-section>
@ -139,10 +147,10 @@
</div> </div>
</q-card-section> </q-card-section>
</q-card> </q-card>
</div> </div>
{% endraw %} {% endblock %} {% block scripts %} {% endraw %} {% endblock %} {% block scripts %}
<script> <script>
Vue.component(VueQrcode.name, VueQrcode) Vue.component(VueQrcode.name, VueQrcode)
new Vue({ new Vue({
@ -154,7 +162,7 @@
dashboard_onchain: {}, dashboard_onchain: {},
fun_satoshi_quotes: {}, fun_satoshi_quotes: {},
fun_exchange_market_rate: { fun_exchange_market_rate: {
unit: "" unit: ''
}, },
dashboard_mining: {}, dashboard_mining: {},
lightning_dashboard: {}, lightning_dashboard: {},
@ -246,6 +254,5 @@
await this.getGertyInfo() await this.getGertyInfo()
} }
}) })
</script> </script>
{% endblock %} {% endblock %}

View file

@ -18,10 +18,10 @@ from .crud import (
update_gerty, update_gerty,
) )
from .helpers import ( from .helpers import (
get_screen_data,
get_satoshi,
gerty_should_sleep, gerty_should_sleep,
get_next_update_time, get_next_update_time,
get_satoshi,
get_screen_data,
get_screen_slug_by_index, get_screen_slug_by_index,
) )
from .models import Gerty from .models import Gerty