Member FK
This commit is contained in:
parent
85ff347090
commit
ad6e4b2943
@ -34,13 +34,13 @@
|
|||||||
## ExamMemberRank
|
## ExamMemberRank
|
||||||
|
|
||||||
- BelongsTo MemberRank
|
- BelongsTo MemberRank
|
||||||
- **TODO** BelongsTo Member (External DB)
|
- BelongsTo Member (External DB, creation in Social Plugin)
|
||||||
- BelongsToMany ExamMemberRankQuestion
|
- BelongsToMany ExamMemberRankQuestion
|
||||||
- BelongsToMany ExamMemberRankAnswers
|
- BelongsToMany ExamMemberRankAnswers
|
||||||
|
|
||||||
## ExamTyperating
|
## ExamTyperating
|
||||||
|
|
||||||
- BelongsTo Typerating
|
- BelongsTo Typerating
|
||||||
- **TODO** BelongsTo Member (External DB)
|
- BelongsTo Member (External DB, creation in Social Plugin)
|
||||||
- BelongsToMany ExamTyperatingQuestion
|
- BelongsToMany ExamTyperatingQuestion
|
||||||
- BelongsToMany ExamTyperatingAnswers
|
- BelongsToMany ExamTyperatingAnswers
|
||||||
|
|||||||
@ -33,6 +33,7 @@ class ExamMemberRank extends Model
|
|||||||
|
|
||||||
public $belongsTo = [
|
public $belongsTo = [
|
||||||
'member_rank' => 'GermanAirlinesVa\Schooling\Models\MemberRank',
|
'member_rank' => 'GermanAirlinesVa\Schooling\Models\MemberRank',
|
||||||
|
'member' => 'GermanAirlinesVa\Social\Models\Member',
|
||||||
];
|
];
|
||||||
|
|
||||||
public $belongsToMany = [
|
public $belongsToMany = [
|
||||||
|
|||||||
@ -33,6 +33,7 @@ class ExamTyperating extends Model
|
|||||||
|
|
||||||
public $belongsTo = [
|
public $belongsTo = [
|
||||||
'typerating' => 'GermanAirlinesVa\Schooling\Models\Typerating',
|
'typerating' => 'GermanAirlinesVa\Schooling\Models\Typerating',
|
||||||
|
'member' => 'GermanAirlinesVa\Social\Models\Member',
|
||||||
];
|
];
|
||||||
|
|
||||||
public $belongsToMany = [
|
public $belongsToMany = [
|
||||||
|
|||||||
@ -2,9 +2,11 @@ columns:
|
|||||||
id:
|
id:
|
||||||
label: id
|
label: id
|
||||||
type: number
|
type: number
|
||||||
member_id:
|
member:
|
||||||
label: member_id
|
label: member
|
||||||
type: number
|
type: text
|
||||||
|
relation: member
|
||||||
|
valueFrom: name
|
||||||
member_rank:
|
member_rank:
|
||||||
label: member_rank
|
label: member_rank
|
||||||
type: text
|
type: text
|
||||||
|
|||||||
@ -2,9 +2,11 @@ columns:
|
|||||||
id:
|
id:
|
||||||
label: id
|
label: id
|
||||||
type: number
|
type: number
|
||||||
member_id:
|
member:
|
||||||
label: member_id
|
label: member
|
||||||
type: number
|
type: text
|
||||||
|
relation: member
|
||||||
|
valueFrom: name
|
||||||
typerating:
|
typerating:
|
||||||
label: typerating
|
label: typerating
|
||||||
type: text
|
type: text
|
||||||
|
|||||||
@ -22,6 +22,8 @@ class BuilderTableCreateExamAnswers extends Migration
|
|||||||
|
|
||||||
public function down()
|
public function down()
|
||||||
{
|
{
|
||||||
|
Schema::connection('germanairlinesva_schooling')->disableForeignKeyConstraints();
|
||||||
Schema::connection('germanairlinesva_schooling')->dropIfExists('exam_answers');
|
Schema::connection('germanairlinesva_schooling')->dropIfExists('exam_answers');
|
||||||
|
Schema::connection('germanairlinesva_schooling')->enableForeignKeyConstraints();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -31,7 +31,7 @@ class BuilderTableCreateExamExamAnswerExamQuestion extends Migration
|
|||||||
public function down()
|
public function down()
|
||||||
{
|
{
|
||||||
Schema::connection('germanairlinesva_schooling')->disableForeignKeyConstraints();
|
Schema::connection('germanairlinesva_schooling')->disableForeignKeyConstraints();
|
||||||
Schema::dropIfExists('germanairlinesva_schooling_exam_exam_answer_exam_question');
|
Schema::connection('germanairlinesva_schooling')->dropIfExists('exam_exam_answer_exam_question');
|
||||||
Schema::connection('germanairlinesva_schooling')->disableForeignKeyConstraints();
|
Schema::connection('germanairlinesva_schooling')->enableForeignKeyConstraints();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -35,6 +35,8 @@ class BuilderTableCreateExams extends Migration
|
|||||||
|
|
||||||
public function down()
|
public function down()
|
||||||
{
|
{
|
||||||
|
Schema::connection('germanairlinesva_schooling')->disableForeignKeyConstraints();
|
||||||
Schema::connection('germanairlinesva_schooling')->dropIfExists('exams');
|
Schema::connection('germanairlinesva_schooling')->dropIfExists('exams');
|
||||||
|
Schema::connection('germanairlinesva_schooling')->enableForeignKeyConstraints();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user