Fixed if hyper: cconditional in class MediaPage, lines 2554-2563.
svn: r13598
This commit is contained in:
parent
fb6897848e
commit
06017f562e
@ -2550,19 +2550,15 @@ class MediaPage(BasePage):
|
|||||||
|
|
||||||
with Html("div", id = "GalleryDisplay") as mediadisplay:
|
with Html("div", id = "GalleryDisplay") as mediadisplay:
|
||||||
summaryarea += mediadisplay
|
summaryarea += mediadisplay
|
||||||
|
|
||||||
|
img_url = self.report.build_url_fname(path, None, self.up)
|
||||||
if target_exists:
|
if target_exists:
|
||||||
# TODO. Convert disk path to URL
|
# TODO. Convert disk path to URL
|
||||||
url = self.report.build_url_fname(newpath, None, self.up)
|
url = self.report.build_url_fname(newpath, None, self.up)
|
||||||
hyper = Html("a", href = url)
|
hyper = Html("a", href = url) + (
|
||||||
# TODO. Mixup url and path
|
Html("img", src = img_url, alt = html_escape(self.page_title))
|
||||||
# path = convert_disk_path_to_url(path)
|
)
|
||||||
url = self.report.build_url_fname(path, None, self.up)
|
mediadisplay += hyper
|
||||||
if hyper:
|
|
||||||
hyper += Html("img", src = url, alt = html_escape(self.page_title))
|
|
||||||
else:
|
|
||||||
hyper = Html("img", src = url, alt = html_escape(self.page_title))
|
|
||||||
if target_exists:
|
|
||||||
mediadisplay += hyper
|
|
||||||
else:
|
else:
|
||||||
mediadisplay += missingimage
|
mediadisplay += missingimage
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user