Added message for empty resultsets
This commit is contained in:
parent
c7fcbc6d39
commit
6ed59e39fe
|
@ -74,6 +74,14 @@ def getHTML(library):
|
||||||
html.append(body)
|
html.append(body)
|
||||||
body.append(main)
|
body.append(main)
|
||||||
main.append(h1)
|
main.append(h1)
|
||||||
|
|
||||||
|
# Check for empty resultset
|
||||||
|
if len(library) == 0:
|
||||||
|
p = ET.Element('p')
|
||||||
|
p.text = "No items"
|
||||||
|
main.append(p)
|
||||||
|
return tree
|
||||||
|
|
||||||
main.append(table)
|
main.append(table)
|
||||||
|
|
||||||
# Build a beautiful table header
|
# Build a beautiful table header
|
||||||
|
|
Loading…
Reference in New Issue