Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/richdocuments.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>2018-09-19 22:40:09 +0300
committerRoeland Jago Douma <roeland@famdouma.nl>2018-12-20 09:38:43 +0300
commitdfff288d1eec7b7f9a1c7339b7acb8c201784dde (patch)
tree15bb20fb94d6f782c19e2ce0fa3824e24bf8ae69 /templates/admin.php
parenta5eb500d5ef336e9e9629c8fd709383ad2a0e31d (diff)
Template picker and system tpl script fixes
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Diffstat (limited to 'templates/admin.php')
-rw-r--r--templates/admin.php49
1 files changed, 23 insertions, 26 deletions
diff --git a/templates/admin.php b/templates/admin.php
index ffd4fa2e..566da894 100644
--- a/templates/admin.php
+++ b/templates/admin.php
@@ -58,34 +58,31 @@ script('files', 'jquery.fileupload');
<?php p($l->t('Global templates')) ?>
<label for="add-template" class="icon-add" title="<?php p($l->t('Add a new template')); ?>"></label>
</h2>
- <?php if (!empty($_['templates'])) { ?>
- <ul>
- <li class="hidden template-model">
+ <div id="emptycontent" class="<?php p(empty($_['templates'])?:'hidden') ?>">
+ <div class="icon-file"></div>
+ <h2>
+ <?php p($l->t('No templates defined.')); ?>
+ </h2>
+ <label for="add-template"><?php p($l->t('Add a new one?')); ?></label>
+ </div>
+ <ul class="<?php p(!empty($_['templates'])?:'hidden') ?>">
+ <li class="hidden template-model">
+ <figure>
+ <img src="" alt="<?php p($l->t('template preview')) ?>" />
+ <figcaption></figcaption>
+ </figure>
+ <a href="" class="delete-template icon-delete"></a>
+ <div class="delete-cover"></div>
+ </li>
+ <?php foreach ($_['templates'] as $template) {?>
+ <li>
<figure>
- <img src="" alt="<?php p($l->t('template preview')) ?>" />
- <figcaption></figcaption>
+ <img src="<?php p($template['preview']) ?>?y=297&x=210" alt="<?php p($l->t('template preview')) ?>" />
+ <figcaption><?php p($template['name']) ?></figcaption>
</figure>
- <a href="" class="delete-template icon-delete"></a>
+ <a href="<?php p($template['delete']) ?>" class="delete-template icon-delete"></a>
<div class="delete-cover"></div>
</li>
- <?php foreach ($_['templates'] as $template) {?>
- <li>
- <figure>
- <img src="<?php p($template['preview']) ?>?y=297&x=210" alt="<?php p($l->t('template preview')) ?>" />
- <figcaption><?php p($template['name']) ?></figcaption>
- </figure>
- <a href="<?php p($template['delete']) ?>" class="delete-template icon-delete"></a>
- <div class="delete-cover"></div>
- </li>
- <?php } ?>
- </ul>
- <?php } else { ?>
- <div id="emptycontent">
- <div class="icon-file"></div>
- <h2>
- <?php p($l->t('No templates defined.')); ?>
- </h2>
- <label for="add-template"><?php p($l->t('Add a new one?')); ?></label>
- </div>
- <?php } ?>
+ <?php } ?>
+ </ul>
</form>