summaryrefslogtreecommitdiff
path: root/public/app/config/setup-application.php
diff options
context:
space:
mode:
Diffstat (limited to 'public/app/config/setup-application.php')
-rw-r--r--public/app/config/setup-application.php478
1 files changed, 0 insertions, 478 deletions
diff --git a/public/app/config/setup-application.php b/public/app/config/setup-application.php
deleted file mode 100644
index ec9a7bb..0000000
--- a/public/app/config/setup-application.php
+++ /dev/null
@@ -1,478 +0,0 @@
-<?php
-/** SETUP APPLICATION
- * -----------------------------------------------------------------------------
- *
- * Define application specific constants
- *
- * -----------------------------------------------------------------------------
- */
-
-
-// email setup /////////////////////////////////////////////////////////////////
-// -----------------------------------------------------------------------------
-
- // SMTP
-define('MAIL_MAILER', $env['MAIL_MAILER']);
-define('MAIL_HOST', $env['MAIL_HOST']);
-define('MAIL_PORT', $env['MAIL_PORT']);
-define('MAIL_USERNAME', $env['MAIL_USERNAME']);
-define('MAIL_PASSWORD', $env['MAIL_PASSWORD']);
-define('MAIL_ENCRYPTION', $env['MAIL_ENCRYPTION']);
- // Mailjet
-define('MAILJET_APIKEY', $env['MAILJET_APIKEY']); // apikey
-define('MAILJET_SECRET', $env['MAILJET_SECRET']); // secret
-define('MAILJET_TICKET', $env['MAILJET_TICKET']); // apikey:secret
- // sender info
-define('MAIL_FROM_NAME', $env['MAIL_FROM_NAME']);
-define('NO_REPLY_EMAIL', $env['NO_REPLY_EMAIL']);
-define('REPLY_TO_EMAIL', $env['REPLY_TO_EMAIL']);
-
-// default mail service; options so far: [ mailjet | phpmailer ]
-define('DEFAULT_MAIL_SERVICE', 'mailjet');
-
-
-// DEFAULT VALUES //////////////////////////////////////////////////////////////
-// -----------------------------------------------------------------------------
-
-// default privileges (for the subscribed user)
-// (array of privilege aliases)
-// --- -- -- - - -
-define('DEFAULT_PRIVILEGES', [
- 1, // economics, level 1
- 5 // programming. level 1
-]);
-
-
-// User Roles
-// --- -- -- - - -
-define('Admin', 1);
-define('Secretary', 2);
-define('Teacher', 3);
-
-
-// ACCESS HISTORY //////////////////////////////////////////////////////////////
-// -----------------------------------------------------------------------------
-// (user-)access types
-
-define('TRACK_LOGIN', 1); // login / logout
-define('TRACK_ACCOUNT', 2); // create user / activate account / modidy profile
-define('TRACK_REQUESTS', 4); // order / payment / refund etc...
-
-// access type strings
-// ---
-define('USER_ACCESS_TYPE', [
- 1 => 'Login',
- 2 => 'Account',
- 3 => 'Request'
-]);
-
-
-
-// ERRORS AND ERROR MESSAGES ///////////////////////////////////////////////////
-// -----------------------------------------------------------------------------
-
-define('EMPTY_REQUIRED_FIELDS', 'Δεν έχουν συμπληρωθεί όλα τα υποχρεωτικά πεδία');
-
-
-
-// ASSETS: PATHS USED HEAVILY //////////////////////////////////////////////////
-// -----------------------------------------------------------------------------
-// these paths are used in order to easily find and autoload useful elemets
-
-
-// JAVASCRIPT LIBRARY PATHS
-// -----------------------------------------------------------------------------
-define('JS_DIR', '/content/'); // <base> path to contruct link
-
-
-
-// CSS ASSET PATHS
-// -----------------------------------------------------------------------------
-define('CSS_DIR', '/content/css/'); // <base> path to contruct link
-define('CSS_FILES', array( // path after <base> to the actual file
- 'main' => 'main.min.css',
- 'filter' => 'filter.css',
- 'overides' => 'overides.css',
- )
-);
-
-
-
-// Mesagges ////////////////////////////////////////////////////////////////////
-// -----------------------------------------------------------------------------
-
-// 404
-// ---
-define('PAGE_404_TITLE', '404: Not Found');
-
-// registration
-// ---
-define('REGISTRATION_SUCCESS', "<h3>Επιτυχής Εγγραφή</h3>
- <p>
- Παρακαλώ ελέγξτε το email σας και ακολουθήστε το σύνδεσμο ενεργοποίησης
- που σας 'εχει αποσταλεί, ώστε να έχετε πρόσβαση σε επιπλέον περιεχόμενο του site
- </p>"
-);
-define ('REGISTRATION_USER_EXISTS', "<h3>Αποτυχία Εγγραφής</h3>
- <p>
- Υπάρχει ήδη χρήστης με αυτό το email. Αν δεν θυμάστε το password
- μπορείτε να κάνετε επαναφορά του ακολουθώντας
- <a href='/reset-password'>αυτό το σύνδεσμο</a>.
- </p>"
-);
-
-
-// activation
-// ---
-define('ACCOUNT_ACTIVATED_TITLE', 'Ο λογαριασμός σας έχει ενεργοποιηθεί');
-define('ACCOUNT_ACTIVATED_MESSAGE', 'Τώρα μπορείτε να
- <a href="/login">συνδεθείτε στο σύστημα</a>.');
-define('NOT_VALID_ACTIVATION_TITLE', 'Σφάλμα!');
-define('NOT_VALID_ACTIVATION_MESSAGE', 'Ο λογαριασμός δεν έχει ενεργοποιηθεί.
- Ξαναδοκιμάστε αργότερα κι αν το σφάλμα επιμείνει, επικοινωνήστε με την υπεύθυνη του προγράμμαρος.');
-
-define ('PETITION_TYPE', [
- 1 => 'common',
- 2 => 'penalty'
-]);
-
-
-
-// the forms ///////////////////////////////////////////////////////////////////
-// -----------------------------------------------------------------------------
-
-// registration/activation form (from invitation)
-// ---
-define('REGISTRATION_FORM', [
- 'defaults' => [
- 'outer_class' => 'col-12',
- 'inner_class' => 'form-control',
- 'type' => 'text',
- 'source' => '\app\controllers\User::current'
- ],
- 'form' => [
- [
- 'name' => 'first_name',
- 'label' => 'Όνομα',
- 'value' => 'auto',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'last_name',
- 'label' => 'Επίθετο',
- 'value' => 'auto',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'email',
- 'label' => 'Email',
- 'type' => 'email',
- 'value' => 'auto',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'father_name',
- 'label' => 'Πατρώνυμο',
- 'value' => 'auto',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'registration_number',
- 'label' => 'Αριθμός μητρώου',
- 'class' => 'col-8',
- 'value' => 'auto',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'sector',
- 'label' => 'Κλάδος / Ειδικότητα',
- 'value' => 'auto',
- 'type' => 'select',
- 'attributes' => ['required'],
- 'options' => [
- 'ΠΕ01 ΘΕΟΛΟΓΟΙ',
- 'ΠΕ02 ΦΙΛΟΛΟΓΟΙ',
- 'ΠΕ02.50 ΦΙΛΟΛΟΓΟΙ ΕΙΔΙΚΗΣ ΑΓΩΓΗΣ',
- 'ΠΕ03 ΜΑΘΗΜΑΤΙΚΟΙ',
- 'ΠΕ03.50 ΜΑΘΗΜΑΤΙΚΟΙ ΕΙΔΙΚΗΣ ΑΓΩΓΗΣ',
- 'ΠΕ04.01 ΦΥΣΙΚΟΙ',
- 'ΠΕ04.01.50 ΦΥΣΙΚΟΙ ΕΙΔΙΚΗΣ ΑΓΩΓΗΣ',
- 'ΠΕ04.02 ΧΗΜΙΚΟΙ',
- 'ΠΕ04.04 ΒΙΟΛΟΓΟΙ',
- 'ΠΕ05 ΓΑΛΛΙΚΗΣ ΦΙΛΟΛΟΓΙΑΣ',
- 'ΠΕ06 ΑΓΓΛΙΚΗΣ ΦΙΛΟΛΟΓΙΑΣ',
- 'ΠΕ07 ΓΕΡΜΑΝΙΚΗΣ ΦΙΛΟΛΟΓΙΑΣ',
- 'ΠΕ08 ΚΑΛΛΙΤΕΧΝΙΚΩΝ',
- 'ΠΕ11 ΦΥΣΙΚΗΣ ΑΓΩΓΗΣ',
- 'ΠΕ23-ΣΔΕΥ ΨΥΧΟΛΟΓΟΙ',
- 'ΠΕ30-ΣΔΕΥ ΚΟΙΝΩΝΙΚΟΙ ΛΕΙΤΟΥΡΓΟΙ',
- 'ΠΕ78 ΚΟΙΝΩΝΙΚΩΝ ΕΠΙΣΤΗΜΩΝ',
- 'ΠΕ79.01 ΜΟΥΣΙΚΗΣ ΕΠΙΣΤΗΜΗΣ',
- 'ΠΕ80 ΟΙΚΟΝΟΜΙΑΣ',
- 'ΠΕ81 ΠΟΛ.ΜΗΧΑΝΙΚΩΝ-ΑΡΧΙΤΕΚΤΟΝΩΝ',
- 'ΠΕ82 ΜΗΧΑΝΟΛΟΓΩΝ',
- 'ΠΕ86 ΠΛΗΡΟΦΟΡΙΚΗΣ',
- 'ΠΕ88.01 ΓΕΩΠΟΝΟΙ'
- ]
- ],
- [
- 'name' => 'belonging_school',
- 'label' => 'Σχολείο τοποθέτησης',
- 'value' => 'auto',
- 'attributes' => ['required']
- ],
- // [ // working school = (obviously) is the current school
- // 'name' => 'working_school',
- // 'label' => 'Σχολείο εργασίας',
- // 'attributes' => ['required']
- // ],
- [
- 'name' => 'position',
- 'label' => 'Θέση',
- 'type' => 'select',
- 'value' => 'auto',
- 'attributes' => ['required'],
- 'options' => []
- ],
- [
- 'name' => 'phone',
- 'label' => 'Τηλέφωνο',
- 'class' => 'col-8',
- 'value' => 'auto',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'password',
- 'label' => 'Κωδικός πρόσβασης',
- 'type' => 'password',
- 'class' => 'col-8',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'confirm_password',
- 'label' => 'Επαλήθευση κωδικού πρόσβασης',
- 'type' => 'password',
- 'class' => 'col-8',
- 'attributes' => ['required']
- ]
- ]
-]);
-
-// common requesy form (for any application)
-// ---
-define('COMMON_REQUEST_FORM', [
- 'defaults' => [
- 'outer_class' => 'col-12',
- 'inner_class' => 'form-control',
- 'type' => 'text',
- 'source' => '\app\controllers\User::current'
- ],
- 'form' => [
- [
- 'name' => 'subject',
- 'label' => 'Θέμα (χαρακτηριστικός τίτλος για αναφορά)',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'first_name',
- 'label' => 'Όνομα',
- 'attributes' => ['auto']
- ],
- [
- 'name' => 'last_name',
- 'label' => 'Επίθετο',
- 'attributes' => ['auto']
- ],
- [
- 'name' => 'email',
- 'label' => 'e-mail',
- 'type' => 'email',
- 'attributes' => ['auto']
- ],
- [
- 'name' => 'father_name',
- 'label' => 'Πατρώνυμο',
- 'attributes' => ['auto']
- ],
- [
- 'name' => 'registration_number',
- 'label' => 'Αριθμός μητρώου',
- 'class' => 'col-5',
- 'attributes' => ['auto']
- ],
- [
- 'name' => 'sector',
- 'label' => 'Κλάδος / Ειδικότητα',
- 'attributes' => ['auto']
- ],
- [
- 'name' => 'belonging_school',
- 'label' => 'Σχολείο τοποθέτησης',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'working_school',
- 'label' => 'Σχολείο εργασίας',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'position',
- 'label' => 'Θέση',
- 'type' => 'select',
- 'source' => 'positions',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'phone',
- 'label' => 'Τηλέφωνο',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'request',
- 'label' => 'Αίτημα (πχ, Παρακαλώ να μου χορηγήσετε ...)',
- 'type' => 'textarea',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'date',
- 'label' => 'Ημερομηνία αίτησης',
- 'type' => 'date',
- 'attributes' => ['required']
- ]
- ]
-]);
-
-// penalty form
-// ---
-
-define('PENALTY_FORM', [
- 'defaults' => [
- 'outer_class' => 'col-12',
- 'inner_class' => 'form-control',
- 'type' => 'text',
- 'source' => 'user'
- ],
- 'form' => [
- [
- 'name' => 'subject',
- 'label' => 'Θέμα (χαρακτηριστικός τίτλος για αναφορά)',
- 'attributes' => ['required']
- ],
- [
- 'label' => '',
- 'type' => 'label'
- ],
- [
- 'label' => 'Πειθαρχική υπόθεση',
- 'type' => 'label'
- ],
- [
- 'name' => 'of_article',
- 'label' => 'του/της/των...',
- 'type' => 'select',
- 'options' => [
- 'του μαθητή',
- 'της μαθήτριας',
- 'των μαθητών',
- 'των μαθητριών'
- ],
- 'class' => 'col-md-4',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'student_names',
- 'label' => '(ονοματεπώνυ-μο/μα, πτώση γενική)',
- 'type' => 'textarea',
- 'class' => 'col-md-8',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'of_department',
- 'label' => 'του τμήματος...',
- 'class' => 'col-md-4',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'date',
- 'label' => 'Ημερομηνία',
- 'type' => 'date',
- 'class' => 'col-md-4',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'time',
- 'label' => 'Ώρα',
- 'class' => 'col-md-4',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'place',
- 'label' => 'Τόπος',
- 'type' => 'select',
- 'options' => [
- 'Γραφείο Διευθηντή',
- 'Γραφείο Καθηγητών'
- ],
- 'attributes' => ['required']
- ],
- [
- 'name' => 'rapporteur',
- 'label' => 'εισηγητής',
- 'type' => 'select',
- 'source' => '\app\extends\Cache_service::all_users',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'charge',
- 'label' => 'Περιγραφή συμβάντος:',
- 'type' => 'textarea',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'apology',
- 'label' => 'Απολογία: (μαθητή/-των)', // + of_student
- 'type' => 'textarea',
- 'attributes' => []
- ],
- [
- 'name' => 'decision_reasoning',
- 'label' => 'Αιτιολογία απόφασης (πχ. Επειδή...)',
- 'type' => 'textarea',
- 'attributes' => []
- ],
- [
- 'label' => 'Το Πειθαρχικό Συμβούλιο',
- 'type' => 'label'
- ],
- [
- 'name' => 'decision',
- 'label' => 'Αποφασίζει',
- 'type' => 'select',
- 'options' => [
- 'προφορική επίπληξη',
- 'ωριαία αποβολή',
- 'ημερήσια αποβολή'
- ],
- 'attributes' => []
- ],
- [
- 'name' => 'decision_more',
- 'label' => '(μη τυποποιημένο κείμενο απόφασης)',
- 'attributes' => []
- ],
- [
- 'name' => 'president',
- 'label' => 'Πρόεδρος συνεδρίασης',
- 'type' => 'select',
- 'source' => '\app\extends\Cache_service::all_users',
- 'attributes' => ['required']
- ],
- [
- 'name' => 'members',
- 'label' => 'Μέλη',
- 'type' => 'select',
- 'attributes' => ['required', 'multiple'],
- 'source' => '\app\extends\Cache_service::all_users'
- ]
- ]
-]);