diff options
| author | Geo Halkiadakis <gchalkiadakis@sklavenitis.co.gr> | 2023-05-26 19:14:56 +0300 |
|---|---|---|
| committer | Geo Halkiadakis <gchalkiadakis@sklavenitis.co.gr> | 2023-05-26 19:14:56 +0300 |
| commit | 38cc5c0c3abed6cfe4fbe0cbabec60a8ed64784d (patch) | |
| tree | 1202a16a980ab18efe60b1efdeed9218eda5320f | |
| parent | 64da2d519297302400930785a968ac3a19bddfb3 (diff) | |
| download | gyraf1gov-38cc5c0c3abed6cfe4fbe0cbabec60a8ed64784d.tar.gz gyraf1gov-38cc5c0c3abed6cfe4fbe0cbabec60a8ed64784d.tar.bz2 gyraf1gov-38cc5c0c3abed6cfe4fbe0cbabec60a8ed64784d.zip | |
user menu and contol panel are ready
| -rw-r--r-- | docker-compose.yml | 4 | ||||
| -rw-r--r-- | public/app/config/setup_application.php | 2 | ||||
| -rw-r--r-- | public/app/routes/user.php | 9 | ||||
| -rw-r--r-- | public/app/views/components/header_includes.php | 6 | ||||
| -rw-r--r-- | public/app/views/components/menu.php | 17 | ||||
| -rw-r--r-- | public/app/views/templates/application.php | 7 | ||||
| -rw-r--r-- | public/app/views/templates/penalty.php | 21 | ||||
| -rw-r--r-- | public/app/views/user/control.php | 40 | ||||
| -rw-r--r-- | public/app/views/user/panel.php | 59 | ||||
| -rw-r--r-- | public/assets/css/class.css | 16 |
10 files changed, 168 insertions, 13 deletions
diff --git a/docker-compose.yml b/docker-compose.yml index a6b435a..5af1295 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -11,8 +11,8 @@ services: build: context: . ports: - - "80:8080" - # - "1415:8080" + # - "80:8080" + - "1415:8080" volumes: - "./public:/var/www/public" - "./core:/var/www/core" diff --git a/public/app/config/setup_application.php b/public/app/config/setup_application.php index a9f48af..88dc176 100644 --- a/public/app/config/setup_application.php +++ b/public/app/config/setup_application.php @@ -467,6 +467,7 @@ define('PENALTY_FORM', [ [ 'name' => 'charge', 'label' => 'Περιγραφή συμβάντος:', + 'class' => 'col-12 x5-lines', 'type' => 'textarea', 'attributes' => ['required'] ], @@ -479,6 +480,7 @@ define('PENALTY_FORM', [ [ 'name' => 'decision_reasoning', 'label' => 'Αιτιολογία απόφασης (πχ. Επειδή...)', + 'class' => 'col-12 x5-lines', 'type' => 'textarea', 'attributes' => [] ], diff --git a/public/app/routes/user.php b/public/app/routes/user.php index aa3b319..26483f4 100644 --- a/public/app/routes/user.php +++ b/public/app/routes/user.php @@ -39,10 +39,11 @@ Route::add('/invite', function() { }); Route::add('/panel', function() { - Render::json([ - 'connected' => Auth::is_connected(), - 'user' => Auth::user_data(), - ]); + Render::view('user/panel'); + // Render::json([ + // 'connected' => Auth::is_connected(), + // 'user' => Auth::user_data(), + // ]); }); diff --git a/public/app/views/components/header_includes.php b/public/app/views/components/header_includes.php index 48f63c6..c20811b 100644 --- a/public/app/views/components/header_includes.php +++ b/public/app/views/components/header_includes.php @@ -33,15 +33,15 @@ <!-- CUSTOM CSS --> +<!-- bootstrap javascript (CDN) --> +<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha2/dist/js/bootstrap.bundle.min.js" integrity="sha384-qKXV1j0HvMUeCBQ+QVp7JcfGl760yU08IQ+GpUo5hlbpg51QRiuqHAJz8+BrxE/N" crossorigin="anonymous"></script> + <!-- main css --> <link href="/assets/css/class.css" rel="stylesheet"> <!-- overides --> <link href="/assets/css/overides.css" rel="stylesheet"> -<!-- bootstrap javascript (CDN) --> -<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha2/dist/js/bootstrap.bundle.min.js" integrity="sha384-qKXV1j0HvMUeCBQ+QVp7JcfGl760yU08IQ+GpUo5hlbpg51QRiuqHAJz8+BrxE/N" crossorigin="anonymous"></script> - <!-- JAVASCRIPT --> <!-- jQuery (CDN) --> diff --git a/public/app/views/components/menu.php b/public/app/views/components/menu.php new file mode 100644 index 0000000..60ad395 --- /dev/null +++ b/public/app/views/components/menu.php @@ -0,0 +1,17 @@ +<ul class="list-group"> + + <li class="list-group-item"><a href="/petition/application">Νέα Αίτηση</a></li> + <li class="list-group-item"><a href="/petition/penalty">Νέo Πρακτικό Πειθαρχικής Υπόθεσης</a></li> + <li class="list-group-item separator">Αρχείο</li> + <li class="list-group-item"><a href="/account/petitions">Πρακτικά και οι αιτήσεις</a></li> + <li class="list-group-item separator">Προφίλ</li> + <li class="list-group-item"><a href="/account/update">Ενημέρωση των στοιχείων σας</a></li> + <li class="list-group-item"><a href="/account/new-password">Αλλαγή password</a></li> + <li class="list-group-item separator">Διαχείριση</li> + <li class="list-group-item"><a href="/account/update">Κατάσταση πρακτικών & αιτήσεων</a></li> + <li class="list-group-item"><a href="/account/update">Αποστολή προσκλήσεων</a></li> + <li class="list-group-item separator"></li> + <li class="list-group-item"><a href="/logout">Αποσύνδεση</a></li> + +</ul> + diff --git a/public/app/views/templates/application.php b/public/app/views/templates/application.php index 4611a2d..4855383 100644 --- a/public/app/views/templates/application.php +++ b/public/app/views/templates/application.php @@ -19,7 +19,12 @@ <form method="post"> <div> - <h4>Αίτηση</h4> + <h4> + Αίτηση + <button class="btn btn-back2panel btn-sm"> + Επιστροφή + </button> + </h4> <hr /> <?=$form['html']?> diff --git a/public/app/views/templates/penalty.php b/public/app/views/templates/penalty.php index 17e5426..e913721 100644 --- a/public/app/views/templates/penalty.php +++ b/public/app/views/templates/penalty.php @@ -19,13 +19,30 @@ <form method="post"> <div> - <h4>Πρακτικό Πειθαρχικής Υπόθεσης</h4> + <h4> + Πρακτικό Πειθαρχικής Υπόθεσης + <button class="btn btn-back2panel btn-sm"> + Επιστροφή + </button> + </h4> <hr /> <?=$form['html']?> + <br /> - <button type="submit" class="btn btn-primary btn-sm col-12">Καταχώριση</button> + <div class="row"> + <div class="col-4"> + <button class="btn btn-preview btn-sm col-12"> + Προεπισκόπηση + </button> + </div> + <div class="col-8"> + <button type="submit" class="btn btn-primary btn-sm col-12"> + Καταχώριση + </button> + </div> + </div> </div> </form> diff --git a/public/app/views/user/control.php b/public/app/views/user/control.php new file mode 100644 index 0000000..b429dc6 --- /dev/null +++ b/public/app/views/user/control.php @@ -0,0 +1,40 @@ +<!DOCTYPE html> +<html lang="en"> +<head> + <meta charset="utf-8"> + <title><?=SITE_TITLE?> - Control Panel</title> + + <?php // header includes + //////////////////////////////////////////////////////////////////////// + Render::view('components/header_includes'); + ?> +<style> +:root { /* login-form overides */ + --form-content-font-size: 1rem; + --form-input-height: 34px; + --select2-arrow-top: 1px; +} +</style> +</head> +<body class="office central-form"> + + <div class='container'> + <div class='content row'> + + <div class="col-2 info"> + <?php // menu + //////////////////////////////////////////////////////////////////// + Render::view('components/menu'); + ?> + </div> + + <div class="col-10"> + <!-- table --> + </div> + + </div> + </div> + +</body> + +</html> diff --git a/public/app/views/user/panel.php b/public/app/views/user/panel.php new file mode 100644 index 0000000..6888a7a --- /dev/null +++ b/public/app/views/user/panel.php @@ -0,0 +1,59 @@ +<!DOCTYPE html> +<html lang="en"> +<head> + <meta charset="utf-8"> + <title><?=SITE_TITLE?> - Control Panel</title> + + <?php // header includes + //////////////////////////////////////////////////////////////////////// + Render::view('components/header_includes'); + ?> +<style> +:root { /* login-form overides */ + --form-content-font-size: 1rem; + --form-input-height: 34px; + --select2-arrow-top: 1px; +} +</style> +</head> +<body class="office central-form left-menu"> + + <div class='container'> + <div class='content row'> + + <div class="col-xs-12 col-sm-3 info"> + <?php // menu + //////////////////////////////////////////////////////////////////// + Render::view('components/menu'); + ?> + </div> + + <div class="col-xs-12 col-sm-9"> + + <!-- content + ** petitions datatable + * change password -> link out (?) + * update properties -> link out (?) + ** admin petitions datatable + * send invitations -> link out (?) + * create member -> link out (?) + + TODO: + switch / case (?) + --> + + </div> + + </div> + </div> + +</body> + +<!-- scripts + * handle show petition request + + if admin: + * modal + give protocol-number +--> + +</html> diff --git a/public/assets/css/class.css b/public/assets/css/class.css index 51bdad9..173010f 100644 --- a/public/assets/css/class.css +++ b/public/assets/css/class.css @@ -62,20 +62,31 @@ html, body { } +.btn-back2panel, .btn-preview { border: 1px solid #aaa7; background: #ddd; } + +.btn-back2panel { float: right; } + +.btn-back2panel:hover, .btn-preview:hover { border: 1px solid #7777; background: #f5f5f5; } +.info .list-group-item a { display: block; text-decoration: none; font-size: 14px; color: #444; padding: 8px 16px; } +.info li.list-group-item { margin:0; padding: 0; } +.info li.list-group-item:hover { background: #f2f2f2; } +.info li.list-group-item.separator { border: 2px solid #f2f2f2; background: #f2f2f2; padding:1px 8px; color: #666; } + /** micro-positioning classes * ----------------------------------------------------------------------------- */ +.max320px { max-width: 320px; width: 100%; } .max420px { max-width: 420px; width: 100%; } .max480px { max-width: 480px; width: 100%; } .max540px { max-width: 540px; width: 100%; } .max720px { max-width: 720px; width: 100%; } .bottom3em { padding-bottom: 3em; } - +.container { max-width: 1400px; } /** central form @@ -88,11 +99,14 @@ html, body { min-height: 100vh; align-items:center; } +.central-form.left-menu .container { align-items: start; } + .central-form .content { width: 100%; margin: auto auto; padding: .5em; font-size: .78em; } +.central-form.left-menu .content { margin: 1em auto; } .central-form .content-form { padding: 1.5em; |
