Typeratings

This commit is contained in:
Gogs
2021-06-16 22:40:17 +02:00
parent 80b4516de4
commit 0c182914d9
15 changed files with 319 additions and 2 deletions
+37
View File
@@ -0,0 +1,37 @@
<?php namespace GermanAirlinesVa\Schooling\Models;
use Model;
/**
* Model
*/
class ExamTyperatingQuestion extends Model
{
use \October\Rain\Database\Traits\Validation;
/*
* Disable timestamps by default.
* Remove this line if timestamps are defined in the database table.
*/
public $timestamps = false;
/**
* @var string The database table used by the model.
*/
public $table = 'exam_questions';
protected $connection = 'germanairlinesva_schooling';
/**
* @var array Validation rules
*/
public $rules = [
'typerating' => 'required',
'in_use' => 'required',
'mandatory' => 'required',
'text' => 'required',
];
public $belongsTo = [
'typerating' => 'GermanAirlinesVa\Schooling\Models\Typerating',
];
}
+4 -2
View File
@@ -2,9 +2,11 @@ columns:
id:
label: id
type: text
member_rank_id:
label: member_rank_id
member_rank:
label: member_rank
relation: member_rank
type: text
valueFrom: name
in_use:
label: in_use
type: text
@@ -0,0 +1,21 @@
columns:
id:
label: id
type: text
typerating:
label: typerating
type: text
relation: typerating
valueFrom: name
in_use:
label: in_use
type: text
mandatory:
label: mandatory
type: text
text:
label: text
type: text
picture:
label: picture
type: text
+29
View File
@@ -0,0 +1,29 @@
fields:
typerating:
label: 'germanairlinesva.schooling::lang.exam_question.typerating'
nameFrom: name
descriptionFrom: description
span: auto
required: 1
type: relation
in_use:
label: 'germanairlinesva.schooling::lang.exam_question.in_use'
span: auto
required: 1
type: switch
mandatory:
label: 'germanairlinesva.schooling::lang.exam_question.mandatory'
span: auto
required: 1
type: switch
text:
label: 'germanairlinesva.schooling::lang.exam_question.text'
size: large
span: auto
required: 1
type: richeditor
picture:
label: 'germanairlinesva.schooling::lang.exam_question.picture'
mode: file
span: auto
type: mediafinder