Commit 08dedc63 authored by Χάρης Παπαδόπουλος's avatar Χάρης Παπαδόπουλος
Browse files

Merge branch 'director_view' into 'develop'

Application updates

See merge request !31
parents 41ff0596 3adde4b6
......@@ -38,4 +38,3 @@ epal.application_submit:
_controller: '\Drupal\epal\Controller\ApplicationSubmit::appSubmit'
requirements:
_user_is_logged_in: 'TRUE'
......@@ -229,6 +229,26 @@ class EpalCriteria extends ContentEntityBase implements EpalCriteriaInterface {
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['mutual_disabled_id'] = BaseFieldDefinition::create('integer')
->setLabel(t('Id αμοιβαία αποκλειόμενου κριτηρίου'))
->setDescription(t('Id αμοιβαία αποκλειόμενου κριτηρίου.'))
->setSettings(array(
'max_length' => 2,
'text_processing' => 0,
))
->setRequired(true)
->setDisplayOptions('view', array(
'label' => 'above',
'type' => 'integer',
'weight' => -4,
))
->setDisplayOptions('form', array(
'type' => 'integer',
'weight' => -4,
))
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['status'] = BaseFieldDefinition::create('boolean')
->setLabel(t('Publishing status'))
->setDescription(t('A boolean indicating whether the Epal criteria is published.'))
......
......@@ -438,6 +438,26 @@ class EpalStudent extends ContentEntityBase implements EpalStudentInterface {
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['student_record_id'] = BaseFieldDefinition::create('string')
->setLabel(t('Id μαθητή από myschool'))
->setDescription(t('Δώσε το Id μαθητή από myschool.'))
->setSettings(array(
'max_length' => 50,
'text_processing' => 0,
))
->setDefaultValue('')
->setDisplayOptions('view', array(
'label' => 'above',
'type' => 'string',
'weight' => -4,
))
->setDisplayOptions('form', array(
'type' => 'string_textfield',
'weight' => -4,
))
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['name'] = BaseFieldDefinition::create('string')
->setLabel(t('Όνομα μαθητή'))
->setDescription(t('Δώσε το μικρό μαθητή.'))
......@@ -497,6 +517,25 @@ class EpalStudent extends ContentEntityBase implements EpalStudentInterface {
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['sex'] = BaseFieldDefinition::create('boolean')
->setLabel(t('Φύλο'))
->setDescription(t('Φύλο.'))
->setSettings(array(
'text_processing' => 0,
))
->setRequired(false)
->setDisplayOptions('view', array(
'label' => 'above',
'type' => 'boolean',
'weight' => -4,
))
->setDisplayOptions('form', array(
'type' => 'boolean',
'weight' => -4,
))
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['fatherfirstname'] = BaseFieldDefinition::create('string')
->setLabel(t('Όνομα του πατέρα'))
->setDescription(t('Δώσε το όνομα του πατέρα.'))
......@@ -581,7 +620,6 @@ class EpalStudent extends ContentEntityBase implements EpalStudentInterface {
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['studentamka'] = BaseFieldDefinition::create('string')
->setLabel(t('ΑΜΚΑ μαθητή'))
->setDescription(t('Δώσε το ΑΜΚΑ μαθητή.'))
......@@ -722,6 +760,67 @@ class EpalStudent extends ContentEntityBase implements EpalStudentInterface {
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
//entity_reference has to be changed to a reference to new entity containing the whole schools
$fields['graduate_school'] = BaseFieldDefinition::create('entity_reference')
->setLabel(t('Σχολείο αποφοίτησης'))
->setDescription(t('Δώσε το σχολείο αποφοίτησης.'))
->setSetting('target_type', 'eepal_school')
->setSetting('handler', 'default')
// ->setTranslatable(TRUE)
->setDisplayOptions('view', array(
'label' => 'above',
'type' => 'author',
'weight' => -4,
))
->setDisplayOptions('form', array(
'type' => 'entity_reference_autocomplete',
'weight' => -4,
'settings' => array(
'match_operator' => 'CONTAINS',
'size' => '60',
'autocomplete_type' => 'tags',
'placeholder' => '',
),
))
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['apolytirio_id'] = BaseFieldDefinition::create('string')
->setLabel(t('Αριθμός απολυτηρίου'))
->setDescription(t('Δώσε τον αριθμό απολυτηρίου'))
->setSettings(array(
'max_length' => 50,
'text_processing' => 0,
))
->setDefaultValue('')
->setDisplayOptions('view', array(
'label' => 'above',
'type' => 'string',
'weight' => -4,
))
->setDisplayOptions('form', array(
'type' => 'string_textfield',
'weight' => -4,
))
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['apolytirio_date'] = BaseFieldDefinition::create('datetime')
->setLabel(t('Ημερομηνία κτήσης απολυτηρίου'))
->setDescription(t('Δώσε την ημερομηνία κτήσης απολυτηρίου.'))
->setSetting('datetime_type', 'date')
->setRequired(false)
->setDisplayOptions('view', array(
'label' => 'above',
'type' => 'string',
'weight' => -4,
))->setDisplayOptions('form', array(
'type' => 'string_textfield',
'weight' => -4,
))
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['currentclass'] = BaseFieldDefinition::create('string')
->setLabel(t('Τάξη παρακολούθησης'))
->setDescription(t('Δώσε την τρέχουσα τάξη παρακολούθησης'))
......@@ -786,6 +885,26 @@ class EpalStudent extends ContentEntityBase implements EpalStudentInterface {
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['currentcourse'] = BaseFieldDefinition::create('string')
->setLabel(t('Ειδικότητα παρακολούθησης'))
->setDescription(t('Δώσε την ειδικότητα παρακολούθησης.'))
->setSettings(array(
'max_length' => 50,
'text_processing' => 0,
))
->setDefaultValue('')
->setDisplayOptions('view', array(
'label' => 'above',
'type' => 'string',
'weight' => -4,
))
->setDisplayOptions('form', array(
'type' => 'string_textfield',
'weight' => -4,
))
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['relationtostudent'] = BaseFieldDefinition::create('string')
->setLabel(t('Σχέση αιτούντα με μαθητή'))
->setDescription(t('Δώσε τη σχέση αιτούντα με μαθητή, πχ Γονέας - Κηδεμόνας - Μαθητής'))
......@@ -826,6 +945,27 @@ class EpalStudent extends ContentEntityBase implements EpalStudentInterface {
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
//for test purposes
$fields['moria'] = BaseFieldDefinition::create('integer')
->setLabel(t('Συνολικά μόρια αίτησης'))
->setDescription(t('Δώσε τη σειρά προτίμησης.'))
->setSettings(array(
'max_length' => 2,
'text_processing' => 0,
))
->setRequired(false)
->setDisplayOptions('view', array(
'label' => 'above',
'type' => 'integer',
'weight' => -4,
))
->setDisplayOptions('form', array(
'type' => 'integer',
'weight' => -4,
))
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['status'] = BaseFieldDefinition::create('boolean')
->setLabel(t('Publishing status'))
->setDescription(t('A boolean indicating whether the EPAL Student is published.'))
......
langcode: el
status: true
dependencies:
config:
- user.role.administrator
- user.role.applicant
- user.role.authenticated
module:
- basic_auth
- epal
- hal
- rest
- serialization
- user
id: criterialist
label: criteriaList
module: views
description: ''
tag: ''
base_table: epal_criteria
base_field: id
core: 8.x
display:
default:
display_plugin: default
id: default
display_title: Master
position: 0
display_options:
access:
type: role
options:
role:
authenticated: authenticated
administrator: administrator
applicant: applicant
cache:
type: tag
options: { }
query:
type: views_query
options:
disable_sql_rewrite: false
distinct: false
replica: false
query_comment: ''
query_tags: { }
exposed_form:
type: basic
options:
submit_button: Apply
reset_button: false
reset_button_label: Reset
exposed_sorts_label: 'Sort by'
expose_sort_order: true
sort_asc_label: Asc
sort_desc_label: Desc
pager:
type: mini
options:
items_per_page: 10
offset: 0
id: 0
total_pages: null
expose:
items_per_page: false
items_per_page_label: 'Items per page'
items_per_page_options: '5, 10, 25, 50'
items_per_page_options_all: false
items_per_page_options_all_label: '- All -'
offset: false
offset_label: Offset
tags:
previous: ‹‹
next: ››
style:
type: serializer
row:
type: fields
options:
inline: { }
separator: ''
hide_empty: false
default_field_elements: true
fields:
id:
id: id
table: epal_criteria
field: id
relationship: none
group_type: group
admin_label: ''
label: ''
exclude: false
alter:
alter_text: false
text: ''
make_link: false
path: ''
absolute: false
external: false
replace_spaces: false
path_case: none
trim_whitespace: false
alt: ''
rel: ''
link_class: ''
prefix: ''
suffix: ''
target: ''
nl2br: false
max_length: 0
word_boundary: true
ellipsis: true
more_link: false
more_link_text: ''
more_link_path: ''
strip_tags: false
trim: false
preserve_tags: ''
html: false
element_type: ''
element_class: ''
element_label_type: ''
element_label_class: ''
element_label_colon: false
element_wrapper_type: ''
element_wrapper_class: ''
element_default_classes: true
empty: ''
hide_empty: false
empty_zero: false
hide_alter_empty: true
click_sort_column: value
type: number_integer
settings:
thousand_separator: ''
prefix_suffix: true
group_column: value
group_columns: { }
group_rows: true
delta_limit: 0
delta_offset: 0
delta_reversed: false
delta_first_last: false
multi_type: separator
separator: ', '
field_api_classes: false
entity_type: epal_criteria
entity_field: id
plugin_id: field
name:
table: epal_criteria
field: name
id: name
entity_type: null
entity_field: name
plugin_id: field
relationship: none
group_type: group
admin_label: ''
label: ''
exclude: false
alter:
alter_text: false
text: ''
make_link: false
path: ''
absolute: false
external: false
replace_spaces: false
path_case: none
trim_whitespace: false
alt: ''
rel: ''
link_class: ''
prefix: ''
suffix: ''
target: ''
nl2br: false
max_length: 0
word_boundary: true
ellipsis: true
more_link: false
more_link_text: ''
more_link_path: ''
strip_tags: false
trim: false
preserve_tags: ''
html: false
element_type: ''
element_class: ''
element_label_type: ''
element_label_class: ''
element_label_colon: true
element_wrapper_type: ''
element_wrapper_class: ''
element_default_classes: true
empty: ''
hide_empty: false
empty_zero: false
hide_alter_empty: true
click_sort_column: value
type: string
settings: { }
group_column: value
group_columns: { }
group_rows: true
delta_limit: 0
delta_offset: 0
delta_reversed: false
delta_first_last: false
multi_type: separator
separator: ', '
field_api_classes: false
mutual_disabled_id:
id: mutual_disabled_id
table: epal_criteria
field: mutual_disabled_id
relationship: none
group_type: group
admin_label: ''
label: ''
exclude: false
alter:
alter_text: false
text: ''
make_link: false
path: ''
absolute: false
external: false
replace_spaces: false
path_case: none
trim_whitespace: false
alt: ''
rel: ''
link_class: ''
prefix: ''
suffix: ''
target: ''
nl2br: false
max_length: 0
word_boundary: true
ellipsis: true
more_link: false
more_link_text: ''
more_link_path: ''
strip_tags: false
trim: false
preserve_tags: ''
html: false
element_type: ''
element_class: ''
element_label_type: ''
element_label_class: ''
element_label_colon: false
element_wrapper_type: ''
element_wrapper_class: ''
element_default_classes: true
empty: ''
hide_empty: false
empty_zero: false
hide_alter_empty: true
click_sort_column: value
type: number_integer
settings:
thousand_separator: ''
prefix_suffix: true
group_column: value
group_columns: { }
group_rows: true
delta_limit: 0
delta_offset: 0
delta_reversed: false
delta_first_last: false
multi_type: separator
separator: ', '
field_api_classes: false
entity_type: epal_criteria
entity_field: mutual_disabled_id
plugin_id: field
filters: { }
sorts: { }
header: { }
footer: { }
empty: { }
relationships: { }
arguments: { }
display_extenders: { }
cache_metadata:
max-age: -1
contexts:
- 'languages:language_content'
- 'languages:language_interface'
- request_format
- url.query_args
- user.roles
tags: { }
rest_export_1:
display_plugin: rest_export
id: rest_export_1
display_title: 'REST export'
position: 1
display_options:
display_extenders: { }
path: criteria/list
pager:
type: some
options:
items_per_page: 0
offset: 0
style:
type: serializer
options:
uses_fields: false
formats:
hal_json: hal_json
json: json
row:
type: data_field
options:
field_options:
id:
alias: ''
raw_output: true
name:
alias: ''
raw_output: true
mutual_disabled_id:
alias: ''
raw_output: true
auth:
- basic_auth
cache_metadata:
max-age: -1
contexts:
- 'languages:language_content'
- 'languages:language_interface'
- request_format
- user.roles
tags: { }
......@@ -256,6 +256,26 @@ class EepalSchool extends ContentEntityBase implements EepalSchoolInterface {
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['unit_type_id'] = BaseFieldDefinition::create('integer')
->setLabel(t('Id τύπου σχολείου'))
->setDescription(t('Δώσε το Id τύπου σχολείου.'))
->setSettings(array(
'max_length' => 2,
'text_processing' => 0,
))
->setRequired(true)
->setDisplayOptions('view', array(
'label' => 'above',
'type' => 'integer',
'weight' => -4,
))
->setDisplayOptions('form', array(
'type' => 'integer',
'weight' => -4,
))
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
$fields['street_address'] = BaseFieldDefinition::create('string')
->setLabel(t('Διεύθυνση'))
->setDescription(t('Δώσε την Διεύθυνση Σχολείου'))
......@@ -488,6 +508,44 @@ class EepalSchool extends ContentEntityBase implements EepalSchoolInterface {
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);