wip
This commit is contained in:
102
app/plugins/resume/controllers/admin/resume.php
Normal file
102
app/plugins/resume/controllers/admin/resume.php
Normal file
@ -0,0 +1,102 @@
|
||||
<?php
|
||||
/**
|
||||
* app/plugins/resume/controllers/admin/resume.php
|
||||
*
|
||||
* This is the Resume admin controller.
|
||||
*
|
||||
* @package TP Resume
|
||||
* @version 3.0
|
||||
* @author Joey Kimsey <Joey@thetempusproject.com>
|
||||
* @link https://TheTempusProject.com
|
||||
* @license https://opensource.org/licenses/MIT [MIT LICENSE]
|
||||
*/
|
||||
namespace TheTempusProject\Controllers\Admin;
|
||||
|
||||
use TheTempusProject\Bedrock\Functions\Check;
|
||||
use TheTempusProject\Bedrock\Functions\Input;
|
||||
use TheTempusProject\Houdini\Classes\Issues;
|
||||
use TheTempusProject\Houdini\Classes\Views;
|
||||
use TheTempusProject\Houdini\Classes\Navigation;
|
||||
use TheTempusProject\Houdini\Classes\Components;
|
||||
use TheTempusProject\Classes\AdminController;
|
||||
use TheTempusProject\Classes\Forms;
|
||||
use TheTempusProject\Models\Positions;
|
||||
|
||||
class Resume extends AdminController {
|
||||
public static $positions;
|
||||
|
||||
public function __construct() {
|
||||
parent::__construct();
|
||||
self::$positions = new Positions;
|
||||
self::$title = 'Admin - Resume';
|
||||
}
|
||||
|
||||
public function index( $data = null ) {
|
||||
Views::view( 'resume.admin.list', self::$positions->listPaginated() );
|
||||
}
|
||||
|
||||
public function create( $data = null ) {
|
||||
if ( !Input::exists( 'submit' ) ) {
|
||||
return Views::view( 'resume.admin.create' );
|
||||
}
|
||||
if ( !Forms::check( 'newPosition' ) ) {
|
||||
Issues::add( 'error', [ 'There was an error with your request.' => Check::userErrors() ] );
|
||||
return $this->index();
|
||||
}
|
||||
$result = self::$positions->create( Input::post( 'name' ), Input::post( 'position' ), Input::post( 'start' ), Input::post( 'end' ), Input::post( 'details' ), Input::post( 'detailsNobs' ) );
|
||||
if ( $result ) {
|
||||
Issues::add( 'success', 'Your position has been created.' );
|
||||
return $this->index();
|
||||
} else {
|
||||
Issues::add( 'error', [ 'There was an unknown error submitting your data.' => Check::userErrors() ] );
|
||||
return $this->index();
|
||||
}
|
||||
}
|
||||
|
||||
public function edit( $data = null ) {
|
||||
if ( !Input::exists( 'submit' ) ) {
|
||||
return Views::view( 'resume.admin.edit', self::$positions->findById( $data ) );
|
||||
}
|
||||
if ( !Forms::check( 'editPosition' ) ) {
|
||||
Issues::add( 'error', [ 'There was an error with your form.' => Check::userErrors() ] );
|
||||
return $this->index();
|
||||
}
|
||||
$fields = [
|
||||
'name' => Input::post( 'name' ),
|
||||
'position' => Input::post( 'position' ),
|
||||
'start' => Input::post( 'start' ),
|
||||
'end' => Input::post( 'end' ),
|
||||
'details' => Input::post( 'details' ),
|
||||
'details_nobs' => Input::post( 'detailsNobs' ),
|
||||
];
|
||||
if ( self::$positions->update( $data, $fields ) ) {
|
||||
Issues::add( 'success', 'Position Updated.' );
|
||||
return $this->index();
|
||||
}
|
||||
Issues::add( 'error', 'There was an error with your request.' );
|
||||
$this->index();
|
||||
}
|
||||
|
||||
public function view( $data = null ) {
|
||||
$positionData = self::$positions->findById( $data );
|
||||
if ( $positionData !== false ) {
|
||||
return Views::view( 'resume.admin.view', $positionData );
|
||||
}
|
||||
Issues::add( 'error', 'Position not found.' );
|
||||
$this->index();
|
||||
}
|
||||
|
||||
public function delete( $data = null ) {
|
||||
if ( $data == null ) {
|
||||
if ( Input::exists( 'P_' ) ) {
|
||||
$data = Input::post( 'P_' );
|
||||
}
|
||||
}
|
||||
if ( !self::$positions->delete( (array) $data ) ) {
|
||||
Issues::add( 'error', 'There was an error with your request.' );
|
||||
} else {
|
||||
Issues::add( 'success', 'Position has been deleted' );
|
||||
}
|
||||
$this->index();
|
||||
}
|
||||
}
|
67
app/plugins/resume/controllers/resume.php
Normal file
67
app/plugins/resume/controllers/resume.php
Normal file
@ -0,0 +1,67 @@
|
||||
<?php
|
||||
/**
|
||||
* app/plugins/resume/controllers/resume.php
|
||||
*
|
||||
* This is the bug reports controller.
|
||||
*
|
||||
* @package TP Resume
|
||||
* @version 3.0
|
||||
* @author Joey Kimsey <Joey@thetempusproject.com>
|
||||
* @link https://TheTempusProject.com
|
||||
* @license https://opensource.org/licenses/MIT [MIT LICENSE]
|
||||
*/
|
||||
namespace TheTempusProject\Controllers;
|
||||
|
||||
use TheTempusProject\Houdini\Classes\Issues;
|
||||
use TheTempusProject\Houdini\Classes\Views;
|
||||
use TheTempusProject\Classes\Controller;
|
||||
use TheTempusProject\Models\Positions;
|
||||
use TheTempusProject\Bedrock\Functions\Input;
|
||||
use TheTempusProject\Houdini\Classes\Components;
|
||||
use TheTempusProject\Houdini\Classes\Template;
|
||||
|
||||
class Resume extends Controller {
|
||||
protected static $positions;
|
||||
|
||||
|
||||
public function __construct() {
|
||||
parent::__construct();
|
||||
Components::append( 'TEMPLATE_JS_INCLUDES', Template::parse(
|
||||
'<script language="JavaScript" crossorigin="anonymous" type="text/javascript" src="{ROOT_URL}app/plugins/resume/js/resume.js"></script>'
|
||||
) );
|
||||
}
|
||||
|
||||
|
||||
public function index() {
|
||||
self::$positions = new Positions;
|
||||
self::$title = '{SITENAME} - Resume';
|
||||
self::$pageDescription = 'Its not the longest resume in the world, but I\'m certainly proud of it.';
|
||||
|
||||
$positions = self::$positions->listPaginated();
|
||||
if ( false == $positions ) {
|
||||
Issues::add( 'error', 'Well, this is embarrassing, surely he wouldn\'t just have no resume..... right.... Dave? ... erm Joey?' );
|
||||
return;
|
||||
} else {
|
||||
Components::set( 'RESUME_NAV', Views::simpleView( 'resume.nav') );
|
||||
Components::set( 'RESUME_DOWNLOADS', Views::simpleView( 'resume.download') );
|
||||
if ( !Input::exists( 'view' ) ) {
|
||||
return Views::view( 'resume.resume', $positions );
|
||||
} else {
|
||||
Components::append( 'TEMPLATE_CSS_INCLUDES', Template::parse('<link rel="stylesheet" href="{ROOT_URL}app/plugins/resume/css/timeline.css" />') );
|
||||
$side = 'left';
|
||||
foreach ($positions as $key => $position) {
|
||||
$position->side = $side; // Add the new entry for side
|
||||
$side = ($side === 'left') ? 'right' : 'left'; // Alternate between left and right
|
||||
}
|
||||
return Views::view( 'resume.timeline', $positions );
|
||||
}
|
||||
}
|
||||
}
|
||||
public function test() {
|
||||
self::$positions = new Positions;
|
||||
self::$title = '{SITENAME} - Resume';
|
||||
self::$pageDescription = 'Its not the longest resume in the world, but I\'m certainly proud of it.';
|
||||
|
||||
return Views::view( 'resume.test' );
|
||||
}
|
||||
}
|
131
app/plugins/resume/css/timeline.css
Normal file
131
app/plugins/resume/css/timeline.css
Normal file
@ -0,0 +1,131 @@
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
body {
|
||||
/* background-color: #474e5d;
|
||||
font-family: Helvetica, sans-serif; */
|
||||
}
|
||||
|
||||
/* The actual timeline (the vertical ruler) */
|
||||
.resume-timeline {
|
||||
position: relative;
|
||||
max-width: 1200px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
/* The actual timeline (the vertical ruler) */
|
||||
.resume-timeline::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
width: 6px;
|
||||
background-color: #B5B5B5;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
left: 50%;
|
||||
margin-left: -3px;
|
||||
}
|
||||
|
||||
/* Container around content */
|
||||
.timeline-container {
|
||||
padding: 10px 40px;
|
||||
position: relative;
|
||||
background-color: inherit;
|
||||
width: 50%;
|
||||
}
|
||||
|
||||
/* The circles on the timeline */
|
||||
.timeline-container::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
width: 25px;
|
||||
height: 25px;
|
||||
right: -13px;
|
||||
background-color: #337ab7;
|
||||
border: 4px solid #FF9F55;
|
||||
top: 15px;
|
||||
border-radius: 50%;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
/* Place the container to the left */
|
||||
.left {
|
||||
left: 0;
|
||||
}
|
||||
|
||||
/* Place the container to the right */
|
||||
.right {
|
||||
left: 50%;
|
||||
}
|
||||
|
||||
/* Add arrows to the left container (pointing right) */
|
||||
.left::before {
|
||||
content: " ";
|
||||
height: 0;
|
||||
position: absolute;
|
||||
top: 22px;
|
||||
width: 0;
|
||||
z-index: 1;
|
||||
right: 30px;
|
||||
border: medium solid white;
|
||||
border-width: 10px 0 10px 10px;
|
||||
border-color: transparent transparent transparent white;
|
||||
}
|
||||
|
||||
/* Add arrows to the right container (pointing left) */
|
||||
.right::before {
|
||||
content: " ";
|
||||
height: 0;
|
||||
position: absolute;
|
||||
top: 22px;
|
||||
width: 0;
|
||||
z-index: 1;
|
||||
left: 30px;
|
||||
border: medium solid white;
|
||||
border-width: 10px 10px 10px 0;
|
||||
border-color: transparent white transparent transparent;
|
||||
}
|
||||
|
||||
/* Fix the circle for containers on the right side */
|
||||
.right::after {
|
||||
left: -11px;
|
||||
}
|
||||
|
||||
/* The actual content */
|
||||
.timeline-content {
|
||||
padding: 20px 30px;
|
||||
position: relative;
|
||||
border-radius: 6px;
|
||||
}
|
||||
|
||||
/* Media queries - Responsive timeline on screens less than 600px wide */
|
||||
@media screen and (max-width: 600px) {
|
||||
/* Place the timelime to the left */
|
||||
.resume-timeline::after {
|
||||
left: 31px;
|
||||
}
|
||||
|
||||
/* Full-width containers */
|
||||
.timeline-container {
|
||||
width: 100%;
|
||||
padding-left: 70px;
|
||||
padding-right: 25px;
|
||||
}
|
||||
|
||||
/* Make sure that all arrows are pointing leftwards */
|
||||
.timeline-container::before {
|
||||
left: 60px;
|
||||
border: medium solid white;
|
||||
border-width: 10px 10px 10px 0;
|
||||
border-color: transparent white transparent transparent;
|
||||
}
|
||||
|
||||
/* Make sure all circles are at the same spot */
|
||||
.left::after, .right::after {
|
||||
left: 15px;
|
||||
}
|
||||
|
||||
/* Make all right containers behave like the left ones */
|
||||
.right {
|
||||
left: 0%;
|
||||
}
|
||||
}
|
87
app/plugins/resume/forms.php
Normal file
87
app/plugins/resume/forms.php
Normal file
@ -0,0 +1,87 @@
|
||||
<?php
|
||||
/**
|
||||
* app/plugins/resume/forms.php
|
||||
*
|
||||
* This houses all of the form checking functions for this plugin.
|
||||
*
|
||||
* @package TP Resume
|
||||
* @version 3.0
|
||||
* @author Joey Kimsey <Joey@thetempusproject.com>
|
||||
* @link https://TheTempusProject.com
|
||||
* @license https://opensource.org/licenses/MIT [MIT LICENSE]
|
||||
*/
|
||||
namespace TheTempusProject\Plugins\Resume;
|
||||
|
||||
use TheTempusProject\Bedrock\Functions\Input;
|
||||
use TheTempusProject\Bedrock\Functions\Check;
|
||||
use TheTempusProject\Classes\Forms;
|
||||
|
||||
class ResumeForms extends Forms {
|
||||
/**
|
||||
* Adds these functions to the form list.
|
||||
*/
|
||||
public function __construct() {
|
||||
self::addHandler( 'newPosition', __CLASS__, 'newPosition' );
|
||||
self::addHandler( 'editPosition', __CLASS__, 'editPosition' );
|
||||
}
|
||||
|
||||
/**
|
||||
* Validates the new position post form.
|
||||
*
|
||||
* @return {bool}
|
||||
*/
|
||||
public static function newPosition() {
|
||||
if ( !Input::exists( 'name' ) ) {
|
||||
self::addUserError( 'You must specify name' );
|
||||
return false;
|
||||
}
|
||||
if ( !Input::exists( 'position' ) ) {
|
||||
self::addUserError( 'You must specify position' );
|
||||
return false;
|
||||
}
|
||||
if ( !Input::exists( 'start' ) ) {
|
||||
self::addUserError( 'You must specify start' );
|
||||
return false;
|
||||
}
|
||||
if ( !Input::exists( 'end' ) ) {
|
||||
self::addUserError( 'You must specify end' );
|
||||
return false;
|
||||
}
|
||||
if ( !Input::exists( 'details' ) ) {
|
||||
self::addUserError( 'You must specify details' );
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Validates the edit position post form.
|
||||
*
|
||||
* @return {bool}
|
||||
*/
|
||||
public static function editPosition() {
|
||||
if ( !Input::exists( 'name' ) ) {
|
||||
self::addUserError( 'You must specify name' );
|
||||
return false;
|
||||
}
|
||||
if ( !Input::exists( 'position' ) ) {
|
||||
self::addUserError( 'You must specify position' );
|
||||
return false;
|
||||
}
|
||||
if ( !Input::exists( 'start' ) ) {
|
||||
self::addUserError( 'You must specify start' );
|
||||
return false;
|
||||
}
|
||||
if ( !Input::exists( 'end' ) ) {
|
||||
self::addUserError( 'You must specify end' );
|
||||
return false;
|
||||
}
|
||||
if ( !Input::exists( 'details' ) ) {
|
||||
self::addUserError( 'You must specify details' );
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
new ResumeForms;
|
14
app/plugins/resume/js/resume.js
Normal file
14
app/plugins/resume/js/resume.js
Normal file
@ -0,0 +1,14 @@
|
||||
|
||||
document.addEventListener('DOMContentLoaded', function () {
|
||||
const hideBsCheckbox = document.getElementById('hidebs');
|
||||
|
||||
if (hideBsCheckbox) {
|
||||
hideBsCheckbox.addEventListener('change', function () {
|
||||
const detailsElements = document.querySelectorAll('.details, .details_nobs');
|
||||
detailsElements.forEach(function (element) {
|
||||
console.error(element);
|
||||
element.classList.toggle('d-none');
|
||||
});
|
||||
});
|
||||
}
|
||||
});
|
94
app/plugins/resume/models/positions.php
Normal file
94
app/plugins/resume/models/positions.php
Normal file
@ -0,0 +1,94 @@
|
||||
<?php
|
||||
/**
|
||||
* app/plugins/resume/models/positions.php
|
||||
*
|
||||
* This class is used for the manipulation of the positions database table.
|
||||
*
|
||||
* @package TP Resume
|
||||
* @version 3.0
|
||||
* @author Joey Kimsey <Joey@thetempusproject.com>
|
||||
* @link https://TheTempusProject.com
|
||||
* @license https://opensource.org/licenses/MIT [MIT LICENSE]
|
||||
*/
|
||||
namespace TheTempusProject\Models;
|
||||
|
||||
use TheTempusProject\Bedrock\Classes\Config;
|
||||
use TheTempusProject\Bedrock\Functions\Check;
|
||||
use TheTempusProject\Canary\Bin\Canary as Debug;
|
||||
use TheTempusProject\Classes\DatabaseModel;
|
||||
use TheTempusProject\Plugins\Resume as Plugin;
|
||||
|
||||
class Positions extends DatabaseModel {
|
||||
public $tableName = 'positions';
|
||||
public $databaseMatrix = [
|
||||
[ 'name', 'varchar', '128' ],
|
||||
[ 'position', 'varchar', '128' ],
|
||||
[ 'start', 'varchar', '16' ],
|
||||
[ 'end', 'varchar', '16' ],
|
||||
[ 'details', 'text', '' ],
|
||||
[ 'details_nobs', 'text', '' ],
|
||||
[ 'image', 'varchar', '256' ],
|
||||
];
|
||||
public $plugin;
|
||||
|
||||
/**
|
||||
* The model constructor.
|
||||
*/
|
||||
public function __construct() {
|
||||
parent::__construct();
|
||||
$this->plugin = new Plugin;
|
||||
}
|
||||
|
||||
public function create( $name, $position, $start, $end, $details, $detailsNobs = '' ) {
|
||||
if ( !$this->plugin->checkEnabled() ) {
|
||||
Debug::info( 'Resume is disabled in the config.' );
|
||||
return false;
|
||||
}
|
||||
if ( empty( $detailsNobs ) ) {
|
||||
$detailsNobs = $details;
|
||||
}
|
||||
$fields = [
|
||||
'name' => $name,
|
||||
'position' => $position,
|
||||
'start' => $start,
|
||||
'end' => $end,
|
||||
'details' => $details,
|
||||
'details_nobs' => $detailsNobs,
|
||||
];
|
||||
if ( !self::$db->insert( $this->tableName, $fields ) ) {
|
||||
Debug::info( 'Position::create - failed to insert to db' );
|
||||
return false;
|
||||
}
|
||||
return self::$db->lastId();
|
||||
}
|
||||
|
||||
public function filter( $postArray, $params = [] ) {
|
||||
foreach ( $postArray as $instance ) {
|
||||
if ( !is_object( $instance ) ) {
|
||||
$instance = $postArray;
|
||||
$end = true;
|
||||
}
|
||||
$instance->prettyStart = $instance->start;
|
||||
$instance->prettyEnd = $instance->end;
|
||||
$out[] = $instance;
|
||||
if ( !empty( $end ) ) {
|
||||
$out = $out[0];
|
||||
break;
|
||||
}
|
||||
}
|
||||
return $out;
|
||||
}
|
||||
|
||||
public function update( $id, $fields ) {
|
||||
if ( !Check::id( $id ) ) {
|
||||
Debug::info( 'Positions:update: illegal ID.' );
|
||||
return false;
|
||||
}
|
||||
if ( !self::$db->update( $this->tableName, $id, $fields ) ) {
|
||||
// new CustomException( 'positionUpdate' );
|
||||
Debug::error( "Positions:update: $id not updated: $fields" );
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
44
app/plugins/resume/plugin.php
Normal file
44
app/plugins/resume/plugin.php
Normal file
@ -0,0 +1,44 @@
|
||||
<?php
|
||||
/**
|
||||
* app/plugins/resume/plugin.php
|
||||
*
|
||||
* This houses all of the main plugin info and functionality.
|
||||
*
|
||||
* @package TP Resume
|
||||
* @version 3.0
|
||||
* @author Joey Kimsey <Joey@thetempusproject.com>
|
||||
* @link https://TheTempusProject.com
|
||||
* @license https://opensource.org/licenses/MIT [MIT LICENSE]
|
||||
*/
|
||||
namespace TheTempusProject\Plugins;
|
||||
|
||||
use TheTempusProject\Classes\Plugin;
|
||||
|
||||
class Resume extends Plugin {
|
||||
public $pluginName = 'TP Resume';
|
||||
public $pluginAuthor = 'JoeyK';
|
||||
public $pluginWebsite = 'https://TheTempusProject.com';
|
||||
public $modelVersion = '1.0';
|
||||
public $pluginVersion = '3.0';
|
||||
public $pluginDescription = 'A simple plugin which adds management for a resume.';
|
||||
public $configName = 'resume';
|
||||
public $configMatrix = [
|
||||
'enabled' => [
|
||||
'type' => 'radio',
|
||||
'pretty' => 'Enable the resume Feature.',
|
||||
'default' => true,
|
||||
],
|
||||
];
|
||||
public $main_links = [
|
||||
[
|
||||
'text' => 'Resume',
|
||||
'url' => '{ROOT_URL}resume/index',
|
||||
],
|
||||
];
|
||||
public $admin_links = [
|
||||
[
|
||||
'text' => '<i class="fa-solid fa-paperclip"></i> Resume',
|
||||
'url' => '{ROOT_URL}admin/resume',
|
||||
],
|
||||
];
|
||||
}
|
22
app/plugins/resume/views/admin/create.html
Normal file
22
app/plugins/resume/views/admin/create.html
Normal file
@ -0,0 +1,22 @@
|
||||
<h2>Resume Entry Form</h2>
|
||||
<form action="#" method="POST">
|
||||
<label for="name">Company Name:</label><br>
|
||||
<input type="text" id="name" name="name" required><br><br>
|
||||
|
||||
<label for="position">Position:</label><br>
|
||||
<input type="text" id="position" name="position" required><br><br>
|
||||
|
||||
<label for="start">Start Month/Year:</label><br>
|
||||
<input type="month" id="start" name="start" required><br><br>
|
||||
|
||||
<label for="end">End Month/Year:</label><br>
|
||||
<input type="month" id="end" name="end" required><br><br>
|
||||
|
||||
<label for="details">Details:</label><br>
|
||||
<textarea id="details" name="details" rows="20" cols="50" required></textarea><br><br>
|
||||
|
||||
<label for="details">Details ( No BS ):</label><br>
|
||||
<textarea id="detailsNobs" name="detailsNobs" rows="20" cols="50" required></textarea><br><br>
|
||||
|
||||
<input type="submit" name="submit" value="Submit">
|
||||
</form>
|
22
app/plugins/resume/views/admin/edit.html
Normal file
22
app/plugins/resume/views/admin/edit.html
Normal file
@ -0,0 +1,22 @@
|
||||
<h2>Edit Resume Position</h2>
|
||||
<form action="#" method="POST">
|
||||
<label for="name">Company Name:</label><br>
|
||||
<input type="text" id="name" name="name" value="{name}" required><br><br>
|
||||
|
||||
<label for="position">Position:</label><br>
|
||||
<input type="text" id="position" name="position" value="{position}" required><br><br>
|
||||
|
||||
<label for="start">Start Month/Year:</label><br>
|
||||
<input type="month" id="start" name="start" value="{start}" required><br><br>
|
||||
|
||||
<label for="end">End Month/Year:</label><br>
|
||||
<input type="month" id="end" name="end" value="{end}" required><br><br>
|
||||
|
||||
<label for="details">Details:</label><br>
|
||||
<textarea id="details" name="details" rows="20" cols="50" required>{details}</textarea><br><br>
|
||||
|
||||
<label for="details">Details ( No BS ):</label><br>
|
||||
<textarea id="detailsNobs" name="detailsNobs" rows="20" cols="50" required>{details_nobs}</textarea><br><br>
|
||||
|
||||
<input type="submit" name="submit" value="Submit">
|
||||
</form>
|
46
app/plugins/resume/views/admin/list.html
Normal file
46
app/plugins/resume/views/admin/list.html
Normal file
@ -0,0 +1,46 @@
|
||||
<div class="context-main-bg context-main p-3">
|
||||
<legend class="text-center">Resume Positions</legend>
|
||||
<hr>
|
||||
{ADMIN_BREADCRUMBS}
|
||||
<form action="{ROOT_URL}admin/resume/delete" method="post">
|
||||
<table class="table table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="width: 30%">Name</th>
|
||||
<th style="width: 20%">Position</th>
|
||||
<th style="width: 10%">Start</th>
|
||||
<th style="width: 10%">End</th>
|
||||
<th style="width: 10%"></th>
|
||||
<th style="width: 10%"></th>
|
||||
<th style="width: 10%">
|
||||
<INPUT type="checkbox" onchange="checkAll(this)" name="check.b" value="P_[]"/>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{LOOP}
|
||||
<tr>
|
||||
<td><a href="{ROOT_URL}admin/resume/view/{ID}" class="text-decoration-none">{name}</a></td>
|
||||
<td>{position}</td>
|
||||
<td>{prettyStart}</td>
|
||||
<td>{prettyEnd}</td>
|
||||
<td><a href="{ROOT_URL}admin/resume/edit/{ID}" class="btn btn-sm btn-warning" role="button"><i class="fa fa-fw fa-pencil"></i></a></td>
|
||||
<td><a href="{ROOT_URL}admin/resume/delete/{ID}" class="btn btn-sm btn-danger" role="button"><i class="fa fa-fw fa-trash"></i></a></td>
|
||||
<td>
|
||||
<input type="checkbox" value="{ID}" name="P_[]">
|
||||
</td>
|
||||
</tr>
|
||||
{/LOOP}
|
||||
{ALT}
|
||||
<tr>
|
||||
<td colspan="7">
|
||||
No results to show.
|
||||
</td>
|
||||
</tr>
|
||||
{/ALT}
|
||||
</tbody>
|
||||
</table>
|
||||
<a href="{ROOT_URL}admin/resume/create" class="btn btn-sm btn-primary" role="button">Create</a>
|
||||
<button name="submit" value="submit" type="submit" class="btn btn-sm btn-danger"><i class="fa fa-fw fa-trash"></i></button>
|
||||
</form>
|
||||
</div>
|
8
app/plugins/resume/views/admin/view.html
Normal file
8
app/plugins/resume/views/admin/view.html
Normal file
@ -0,0 +1,8 @@
|
||||
<legend>Resume Position</legend>
|
||||
<div class="resume-position">
|
||||
<h3 class="resume-position-title">{name}</h3>
|
||||
<p><b>{position}</b> from <i>{prettyStart}</i> to <i>{prettyEnd}</i></p>
|
||||
<div class="well">
|
||||
{details}
|
||||
</div>
|
||||
</div>
|
13
app/plugins/resume/views/download.html
Normal file
13
app/plugins/resume/views/download.html
Normal file
@ -0,0 +1,13 @@
|
||||
<div class="my-3 row" role="group" aria-label="Resume Downloads">
|
||||
<!-- Adjusted the col-3 div -->
|
||||
<div class="col-4 col-md-3 d-flex align-items-center justify-content-end">
|
||||
<h3>Download</h3>
|
||||
</div>
|
||||
<!-- Button group -->
|
||||
<div class="btn-group btn-group-justified col-8 col-md-6" role="group" aria-label="Resume Downloads">
|
||||
<a href="/downloads/resume/docx" class="btn btn-primary" role="button" target="_blank" download>Word</a>
|
||||
<a href="/downloads/resume/pdf" class="btn btn-primary" role="button" target="_blank" download>PDF</a>
|
||||
<a href="/downloads/resume/md" class="btn btn-primary" role="button" target="_blank" download>Markdown</a>
|
||||
<a href="/downloads/resume/txt" class="btn btn-primary" role="button" target="_blank" download>Text</a>
|
||||
</div>
|
||||
</div>
|
10
app/plugins/resume/views/nav.html
Normal file
10
app/plugins/resume/views/nav.html
Normal file
@ -0,0 +1,10 @@
|
||||
<div class="mb-3 row" role="group" aria-label="Resume View Type">
|
||||
<div class="btn-group btn-group-justified col-6 offset-lg-3" role="group" aria-label="Resume View Type">
|
||||
<a href="?view=tiimeline" class="btn btn-primary" role="button">Timeline</a>
|
||||
<a href="?" class="btn btn-primary" role="button">Standard</a>
|
||||
</div>
|
||||
<div class="form-check form-switch col-6 col-lg-3 d-flex align-items-center justify-content-center justify-content-lg-start">
|
||||
<input class="form-check-input" type="checkbox" role="switch" name="hidebs" id="hidebs" value="true">
|
||||
<label class="form-check-label ps-2" for="hidebs">Hide the Fluff</label>
|
||||
</div>
|
||||
</div>
|
36
app/plugins/resume/views/resume.html
Normal file
36
app/plugins/resume/views/resume.html
Normal file
@ -0,0 +1,36 @@
|
||||
<div class="col-12 col-md-10 col-lg-8 offset-lg-2 offset-md-1 offset-0 mb-3 mb-lg-5 mt-2 mt-lg-4">
|
||||
<div class="p-2 p-lg-4 mb-lg-4 m-2 rounded-3 context-main context-main-bg">
|
||||
<h2 class="text-center">Resume</h2>
|
||||
<hr>
|
||||
{RESUME_NAV}
|
||||
{LOOP}
|
||||
<div class="card context-main context-third-bg py-2 my-2 rounded">
|
||||
<div class="row g-0 px-3">
|
||||
<div class="col-md-4 d-flex justify-content-center align-items-center p-2">
|
||||
<img class="img-fluid" src="{image}" alt="{name}">
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
<div class="card-body">
|
||||
<h4 class="card-title">{name}</h4>
|
||||
<p class="card-text">
|
||||
<b>{position}</b> from <i>{prettyStart}</i> to <i>{prettyEnd}</i>
|
||||
</p>
|
||||
<div class="details card-text">
|
||||
{details}
|
||||
</div>
|
||||
<div class="details_nobs card-text d-none">
|
||||
{details_nobs}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/LOOP}
|
||||
{ALT}
|
||||
<div class="resume-position">
|
||||
<p>None Found</p>
|
||||
</div>
|
||||
{/ALT}
|
||||
{RESUME_DOWNLOADS}
|
||||
</div>
|
||||
</div>
|
35
app/plugins/resume/views/timeline.html
Normal file
35
app/plugins/resume/views/timeline.html
Normal file
@ -0,0 +1,35 @@
|
||||
<div class="col-12 col-md-10 col-lg-8 offset-lg-2 offset-md-1 offset-0 mb-3 mb-lg-5 mt-2 mt-lg-4">
|
||||
<div class="p-2 p-lg-4 mb-lg-4 m-2 rounded-3 context-main context-main-bg">
|
||||
<h2 class="text-center">Resume</h2>
|
||||
<hr>
|
||||
{RESUME_NAV}
|
||||
<div class="details_nobs card-text d-none text-center col-6 offset-3">
|
||||
<p>
|
||||
Honestly, I really wanted to do something fun and interactive here.
|
||||
Unfortunately I didn't have a specific idea in mind and this was abandoned in favor of spending my time somewhere with a bigger impact.
|
||||
</p>
|
||||
</div>
|
||||
{LOOP}
|
||||
<div class="resume-timeline">
|
||||
<div class="timeline-container {side}">
|
||||
<div class="timeline-content context-third-bg">
|
||||
<h3 class="resume-position-title">{name}</h3>
|
||||
<p><b>{position}</b> from <i>{prettyStart}</i> to <i>{prettyEnd}</i></p>
|
||||
<div class="details card-text">
|
||||
{details}
|
||||
</div>
|
||||
<div class="details_nobs card-text d-none">
|
||||
{details_nobs}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/LOOP}
|
||||
{ALT}
|
||||
<div class="resume-timeline">
|
||||
<p>None Found</p>
|
||||
</div>
|
||||
{/ALT}
|
||||
{RESUME_DOWNLOADS}
|
||||
</div>
|
||||
</div>
|
Reference in New Issue
Block a user