finisch of the borrower funktion
This commit is contained in:
+4
-2
@@ -3605,7 +3605,8 @@ def api_item_detail(item_id):
|
|||||||
borrows_html = ''
|
borrows_html = ''
|
||||||
if borrow_records:
|
if borrow_records:
|
||||||
rows = []
|
rows = []
|
||||||
while len(rows) < 3:
|
count = 1
|
||||||
|
while count < 3:
|
||||||
for rec in borrow_records:
|
for rec in borrow_records:
|
||||||
user_raw = rec.get('User')
|
user_raw = rec.get('User')
|
||||||
try:
|
try:
|
||||||
@@ -3623,7 +3624,8 @@ def api_item_detail(item_id):
|
|||||||
f"{html.escape(str(start))} → {html.escape(str(end))}"
|
f"{html.escape(str(start))} → {html.escape(str(end))}"
|
||||||
f"{(' — ' + notes) if notes else ''}</li>"
|
f"{(' — ' + notes) if notes else ''}</li>"
|
||||||
)
|
)
|
||||||
borrows_html = f"<h3>Ausleihhistorie</h3><ul>{''.join(rows)}</ul>"
|
count += 1
|
||||||
|
borrows_html = f"<h3>Ausleihhistorie</h3><ul>{''.join(rows)}</ul>"
|
||||||
|
|
||||||
detail_html = f"""
|
detail_html = f"""
|
||||||
<h2>{html.escape(str(item.get('Name', 'Untitled')))}</h2>
|
<h2>{html.escape(str(item.get('Name', 'Untitled')))}</h2>
|
||||||
|
|||||||
Reference in New Issue
Block a user