formatting
This commit is contained in:
parent
2fcf2153c3
commit
ce41e4b689
5 changed files with 13 additions and 7 deletions
|
|
@ -13,6 +13,7 @@ from .helpers import fetch_onchain_balance
|
||||||
from .models import Charges, CreateCharge, SatsPayThemes
|
from .models import Charges, CreateCharge, SatsPayThemes
|
||||||
|
|
||||||
from loguru import logger
|
from loguru import logger
|
||||||
|
|
||||||
###############CHARGES##########################
|
###############CHARGES##########################
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -179,7 +180,6 @@ async def get_themes(user_id: str) -> List[SatsPayThemes]:
|
||||||
return await get_config(row.user)
|
return await get_config(row.user)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
################## SETTINGS ###################
|
################## SETTINGS ###################
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -75,6 +75,7 @@ class Charges(BaseModel):
|
||||||
def must_call_webhook(self):
|
def must_call_webhook(self):
|
||||||
return self.webhook and self.paid and self.config.webhook_success == False
|
return self.webhook and self.paid and self.config.webhook_success == False
|
||||||
|
|
||||||
|
|
||||||
class SatsPayThemes(BaseModel):
|
class SatsPayThemes(BaseModel):
|
||||||
css_id: str = Query(None)
|
css_id: str = Query(None)
|
||||||
title: str = Query(None)
|
title: str = Query(None)
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,11 @@
|
||||||
color="primary"
|
color="primary"
|
||||||
@click="getThemes();formDialogThemes.show = true"
|
@click="getThemes();formDialogThemes.show = true"
|
||||||
>New CSS Theme
|
>New CSS Theme
|
||||||
<q-tooltip>For security reason, custom css is only available to server admins.</q-tooltip></q-btn>
|
<q-tooltip
|
||||||
|
>For security reason, custom css is only available to server
|
||||||
|
admins.</q-tooltip
|
||||||
|
></q-btn
|
||||||
|
>
|
||||||
</q-card-section>
|
</q-card-section>
|
||||||
</q-card>
|
</q-card>
|
||||||
|
|
||||||
|
|
@ -949,7 +953,7 @@
|
||||||
},
|
},
|
||||||
created: async function () {
|
created: async function () {
|
||||||
console.log(this.admin)
|
console.log(this.admin)
|
||||||
if(this.admin == "True"){
|
if (this.admin == 'True') {
|
||||||
await this.getThemes()
|
await this.getThemes()
|
||||||
}
|
}
|
||||||
await this.getCharges()
|
await this.getCharges()
|
||||||
|
|
|
||||||
|
|
@ -19,6 +19,7 @@ from loguru import logger
|
||||||
|
|
||||||
templates = Jinja2Templates(directory="templates")
|
templates = Jinja2Templates(directory="templates")
|
||||||
|
|
||||||
|
|
||||||
@satspay_ext.get("/", response_class=HTMLResponse)
|
@satspay_ext.get("/", response_class=HTMLResponse)
|
||||||
async def index(request: Request, user: User = Depends(check_user_exists)):
|
async def index(request: Request, user: User = Depends(check_user_exists)):
|
||||||
admin = False
|
admin = False
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue