fix some bugs and format

This commit is contained in:
Tiago Vasconcelos
2022-12-22 12:23:22 +00:00
parent cdb5e8176d
commit ef73f3ca75
3 changed files with 5 additions and 5 deletions

View File

@@ -52,7 +52,7 @@ async def create_shop_product(data: createProduct) -> Products:
return product
async def update_shop_product(product_id: str, **kwargs) -> Optional[Stalls]:
async def update_shop_product(product_id: str, **kwargs) -> Optional[Products]:
q = ", ".join([f"{field[0]} = ?" for field in kwargs.items()])
await db.execute(

View File

@@ -39,7 +39,7 @@ async def index(request: Request, user: User = Depends(check_user_exists)):
@shop_ext.get("/stalls/{stall_id}", response_class=HTMLResponse)
async def display(request: Request, stall_id):
async def stall(request: Request, stall_id):
stall = await get_shop_stall(stall_id)
products = await get_shop_products(stall_id)
zones = []
@@ -68,7 +68,7 @@ async def display(request: Request, stall_id):
@shop_ext.get("/market/{market_id}", response_class=HTMLResponse)
async def display(request: Request, market_id):
async def market(request: Request, market_id):
market = await get_shop_market(market_id)
if not market:
@@ -92,7 +92,7 @@ async def display(request: Request, market_id):
@shop_ext.get("/order", response_class=HTMLResponse)
async def chat_page(
async def order_chat(
request: Request,
merch: str = Query(...),
invoice_id: str = Query(...),

View File

@@ -19,8 +19,8 @@ from lnbits.decorators import (
require_admin_key,
require_invoice_key,
)
from lnbits.helpers import urlsafe_short_hash
from ...helpers import urlsafe_short_hash
from . import db, shop_ext
from .crud import (
create_shop_market,