diff options
author | Thomas Lange <code@nerdmind.de> | 2021-06-17 22:00:39 +0200 |
---|---|---|
committer | Thomas Lange <code@nerdmind.de> | 2021-06-17 22:00:39 +0200 |
commit | 5555624546ea48d6327700f32b80848e0662dc90 (patch) | |
tree | 47d61fb756a6cb008aaf33586d292fcfe43da2a1 /theme/admin/html/user | |
parent | 91d8a28c664afa5378735bcd0efe068dd74d589f (diff) | |
parent | 0a2614cb69fc732c2115ef2f0c356f39f602d311 (diff) | |
download | blog-5555624546ea48d6327700f32b80848e0662dc90.tar.gz blog-5555624546ea48d6327700f32b80848e0662dc90.tar.xz blog-5555624546ea48d6327700f32b80848e0662dc90.zip |
Merge branch 'master' into 'optimization'optimization
Diffstat (limited to 'theme/admin/html/user')
-rw-r--r-- | theme/admin/html/user/delete.php | 8 | ||||
-rw-r--r-- | theme/admin/html/user/form.php | 114 | ||||
-rw-r--r-- | theme/admin/html/user/index.php | 15 | ||||
-rw-r--r-- | theme/admin/html/user/insert.php | 6 | ||||
-rw-r--r-- | theme/admin/html/user/item.php | 31 | ||||
-rw-r--r-- | theme/admin/html/user/update.php | 6 |
6 files changed, 180 insertions, 0 deletions
diff --git a/theme/admin/html/user/delete.php b/theme/admin/html/user/delete.php new file mode 100644 index 0000000..b500a12 --- /dev/null +++ b/theme/admin/html/user/delete.php @@ -0,0 +1,8 @@ +<main id="main-content"> +<h1><i class="fa fa-trash-o"></i><?=$Language->text('delete_user')?></h1> +<p><?=$Language->text('delete_user_desc')?></p> + +<p class="red"><?=$Language->text('delete_user_warning')?></p> + +<?=$HTML?> +</main> diff --git a/theme/admin/html/user/form.php b/theme/admin/html/user/form.php new file mode 100644 index 0000000..7e370e5 --- /dev/null +++ b/theme/admin/html/user/form.php @@ -0,0 +1,114 @@ +<?php if($FORM['INFO']): ?> + <div id="message-list-wrapper"> + <ul id="message-list"> + <?php foreach($FORM['INFO'] as $message): ?> + <li><?=$message?></li> + <?php endforeach ?> + </ul> + </div> +<?php endif ?> + +<form action="" method="POST"> + <input type="hidden" name="token" value="<?=$FORM['TOKEN']?>" /> + +<?php if($FORM['TYPE'] !== 'DELETE'): ?> + <div class="form-grid"> + <label for="form_id"> + <i class="fa fa-database"></i>ID</label> + + <div class="form-grid-item"> + <input<?=($FORM['TYPE'] === 'UPDATE') ? ' disabled="disabled"' : '';?> id="form_id" name="id" type="number" placeholder="AUTO_INCREMENT" value="<?=escapeHTML($FORM['DATA']['ID'])?>" /> + </div> + + <label for="form_password"> + <i class="fa fa-key"></i><?=$Language->text('label_password')?></label> + + <div class="form-grid-item"> + <input id="form_password" name="password" placeholder="NO CHANGE" type="password" /> + </div> + + <label for="form_fullname"> + <i class="fa fa-user"></i><?=$Language->text('label_fullname')?></label> + + <div class="form-grid-item"> + <input id="form_fullname" name="fullname" value="<?=escapeHTML($FORM['DATA']['FULLNAME'])?>" /> + </div> + + <label for="form_mailaddr"> + <i class="fa fa-envelope-o"></i><?=$Language->text('label_mailaddr')?></label> + + <div class="form-grid-item"> + <input id="form_mailaddr" name="mailaddr" value="<?=escapeHTML($FORM['DATA']['MAILADDR'])?>" /> + </div> + + <label for="form_username"> + <i class="fa fa-user-secret"></i><?=$Language->text('label_username')?></label> + + <div class="form-grid-item"> + <input id="form_username" name="username" value="<?=escapeHTML($FORM['DATA']['USERNAME'])?>" /> + </div> + + <label for="form_slug"> + <i class="fa fa-link"></i><?=$Language->text('label_slug')?></label> + + <div class="form-grid-item"> + <input id="form_slug" name="slug" value="<?=escapeHTML($FORM['DATA']['SLUG'])?>" /> + </div> + + <label for="form_time_insert"> + <i class="fa fa-clock-o"></i><?=$Language->text('label_insert')?></label> + + <div class="form-grid-item"> + <input id="form_time_insert" name="time_insert" placeholder="YYYY-MM-DD HH:II:SS" value="<?=escapeHTML($FORM['DATA']['TIME_INSERT'])?>" /> + </div> + + <label for="form_time_update"> + <i class="fa fa-clock-o"></i><?=$Language->text('label_update')?></label> + + <div class="form-grid-item"> + <input id="form_time_update" name="time_update" placeholder="<?=escapeHTML($FORM['DATA']['TIME_UPDATE'] ? $FORM['DATA']['TIME_UPDATE'] : 'CURRENT_TIMESTAMP')?>" value="" /> + </div> + </div> + + <div id="content-editor-wrapper" class="form-border-box"> + <div id="button-list-wrapper"> + <ul id="markdown-list" class="button-list markdown"> + <li data-markdown="bold" class="fa fa-bold" title="<?=$Language->text('markdown_bold')?>"></li> + <li data-markdown="italic" class="fa fa-italic" title="<?=$Language->text('markdown_italic')?>"></li> + <li data-markdown="heading" class="fa fa-header" title="<?=$Language->text('markdown_heading')?>"></li> + <li data-markdown="link" class="fa fa-link" title="<?=$Language->text('markdown_link')?>"></li> + <li data-markdown="image" class="fa fa-picture-o" title="<?=$Language->text('markdown_image')?>"></li> + <li data-markdown="code" class="fa fa-code" title="<?=$Language->text('markdown_code')?>"></li> + <li data-markdown="quote" class="fa fa-quote-right" title="<?=$Language->text('markdown_quote')?>"></li> + <li data-markdown="list_ul" class="fa fa-list-ul" title="<?=$Language->text('markdown_list_ul')?>"></li> + <li data-markdown="list_ol" class="fa fa-list-ol" title="<?=$Language->text('markdown_list_ol')?>"></li> + </ul> + </div> + <textarea id="content-editor" name="body" placeholder="[…]"><?=escapeHTML($FORM['DATA']['BODY'])?></textarea> + </div> + <div id="emoticon-list-wrapper" class="form-border-box background padding"> + <ul id="emoticon-list" class="button-list emoticons"> + <?php foreach(getUnicodeEmoticons() as $emoticon => $explanation):?> + <li data-emoticon="<?=$emoticon?>" title="<?=$explanation?>"><?=$emoticon?></li> + <?php endforeach; ?> + </ul> + </div> + <div class="form-border-box background padding"> + <input id="form_argv" name="argv" maxlength="250" placeholder="[ARGUMENT_ONE=foo|ARGUMENT_TWO=bar …]" value="<?=escapeHTML($FORM['DATA']['ARGV'])?>" /> + </div> +<?php else: ?> + <div class="form-border-box background padding"> + <?=$HTML?> + </div> +<?php endif; ?> + + <div class="form-border-box background padding"> + <?php if($FORM['TYPE'] === 'INSERT'): ?> + <input id="insert-button" type="submit" name="insert" value="<?=$Language->text('insert')?>" /> + <?php elseif($FORM['TYPE'] === 'UPDATE'): ?> + <input id="update-button" type="submit" name="update" value="<?=$Language->text('update')?>" /> + <?php elseif($FORM['TYPE'] === 'DELETE'): ?> + <input id="delete-button" type="submit" name="delete" value="<?=$Language->text('delete')?>" data-text="<?=$Language->text('sure')?>" /> + <?php endif; ?> + </div> +</form> diff --git a/theme/admin/html/user/index.php b/theme/admin/html/user/index.php new file mode 100644 index 0000000..7e1d794 --- /dev/null +++ b/theme/admin/html/user/index.php @@ -0,0 +1,15 @@ +<main id="main-content"> +<h1><i class="fa fa-user"></i><?=$Language->text('user_overview')?></h1> +<p class="actions-before"><?=$Language->text('overview_user_desc')?></p> +<ul class="actions"> + <li><a href="<?=Application::getAdminURL('user/insert.php')?>" title="<?=$Language->text('insert_user')?>"><i class="fa fa-pencil-square-o"></i><?=$Language->text('insert')?></a></li> +</ul> + +<div class="item-container user"> + <?php foreach($LIST['USERS'] as $user): ?> + <?php echo $user; ?> + <?php endforeach; ?> +</div> + +<?=$PAGINATION['HTML']?> +</main> diff --git a/theme/admin/html/user/insert.php b/theme/admin/html/user/insert.php new file mode 100644 index 0000000..7c7aba2 --- /dev/null +++ b/theme/admin/html/user/insert.php @@ -0,0 +1,6 @@ +<main id="main-content"> +<h1><i class="fa fa-pencil-square-o"></i><?=$Language->text('insert_user')?></h1> +<p><?=$Language->text('insert_user_desc')?></p> + +<?=$HTML?> +</main> diff --git a/theme/admin/html/user/item.php b/theme/admin/html/user/item.php new file mode 100644 index 0000000..ae16637 --- /dev/null +++ b/theme/admin/html/user/item.php @@ -0,0 +1,31 @@ +<article class="item"> + <header> + <h2><i class="fa fa-user"></i><?=escapeHTML($USER['ATTR']['FULLNAME'])?></h2> + <div> + <span class="brackets item-id">#<?=$USER['ATTR']['ID']?></span> + <time class="brackets" datetime="<?=$USER['ATTR']['TIME_INSERT']?>"><?=parseDatetime($USER['ATTR']['TIME_INSERT'], $Language->text('date_format'))?></time> + </div> + </header> + <blockquote cite="<?=$USER['URL']?>"> + <?php if(isset($USER['FILE']['LIST'][0])): ?> + <img class="item-image" src="<?=$USER['FILE']['LIST'][0]?>" alt="" /> + <?php endif; ?> + <p><?=excerpt($USER['BODY']['HTML']())?></p> + </blockquote> + + <?php if($USER['ARGV']): ?> + <ul class="arguments"> + <?php foreach($USER['ARGV'] as $argument => $value): ?> + <li><strong><?=$argument?>:</strong> <span><?=escapeHTML($value)?></span></li> + <?php endforeach; ?> + </ul> + <?php endif; ?> + + <footer> + <ul> + <li><a href="<?=$USER['URL']?>" target="_blank" title="<?=$Language->text('select_user')?>"><i class="fa fa-external-link"></i><span class="hidden"><?=$Language->text('select_user')?></span></a></li> + <li><a href="<?=Application::getAdminURL("user/update.php?id={$USER['ATTR']['ID']}")?>" title="<?=$Language->text('update_user')?>"><i class="fa fa-pencil-square-o"></i><span class="hidden"><?=$Language->text('update_user')?></span></a></li> + <li><a href="<?=Application::getAdminURL("user/delete.php?id={$USER['ATTR']['ID']}")?>" title="<?=$Language->text('delete_user')?>"><i class="fa fa-trash-o"></i><span class="hidden"><?=$Language->text('delete_user')?></span></a></li> + </ul> + </footer> +</article> diff --git a/theme/admin/html/user/update.php b/theme/admin/html/user/update.php new file mode 100644 index 0000000..ad12677 --- /dev/null +++ b/theme/admin/html/user/update.php @@ -0,0 +1,6 @@ +<main id="main-content"> +<h1><i class="fa fa-pencil-square-o"></i><?=$Language->text('update_user')?></h1> +<p><?=$Language->text('update_user_desc')?></p> + +<?=$HTML?> +</main> |