ItemContent::user_name(EzcEnv & env) changed to ItemContent::user(morm::ModelWrapper ** model_wrapper) and we return a User class

ItemContent::group_name(EzcEnv & env) changed to ItemContent::group(morm::ModelWrapper ** model_wrapper) and we return a Group class
added ItemContent::display_user_name(EzcEnv & env)
some functions in templates/item.cpp moved to Item
This commit is contained in:
2021-06-19 23:48:12 +02:00
parent d8c1a81bcb
commit e7c7324058
20 changed files with 318 additions and 88 deletions

View File

@@ -1,20 +1,20 @@
[if item_content_type_is "other"][item.content.print_content][else]
[if item.content.type_is "other"][item.content.print_content][else]
[if false]
[if mount_page_arg_is "subject"][if mount_page_arg_is "info"]<h1 class="withinfo">[else]<h1>[end][item_subject]</h1>[end]
[if mount_page_arg_is "info"][include "item_info.html"][end]
[if mount_page_arg_is "subject"][if mount_page_arg_is "info"]<h1 class="withinfo">[else]<h1>[end][item.subject]</h1>[end]
[if mount_page_arg_is "info"][include "item.info.html"][end]
[end]
[if one item_filetype_is_image]
[if item.content.file_type_is_image]
<a href="[item_link]"><img class="catimage" [if not item_has_thumb]height="100"[end] src="[item_link]/download[if item_has_thumb]/thumb[end]" alt="[item_subject]"></a>
<a href="[item.link]"><img class="catimage" [if not item.has_thumb]height="100"[end] src="[item.link]/download[if item.has_thumb]/thumb[end]" alt="[item.subject]"></a>
[# we use pre.nowinixbreak to tell the html_filter not to put a blank space into those urles]
<div>
<pre class="nowinixbreak">
{cat_image_url}: [item_link]<br>
{cat_image_thumb_url}: [item_link]/-/thumb
{cat_image_url}: [item.link]<br>
{cat_image_thumb_url}: [item.link]/-/thumb
</pre>
</div>
@@ -22,11 +22,11 @@
[else]
[if not item_filetype_is_none]
{download}: <a href="[item_link]/download" title="[item_subject]">[item_subject]</a>
[if not item.content.file_type_is_none]
{download}: <a href="[item.link]/download" title="[item.subject]">[item.subject]</a>
<div>
<pre class="nowinixbreak">
{cat_file_url}: [item_link]<br>
{cat_file_url}: [item.link]<br>
</pre>
</div>