From 50a2fbfc0a6334b7926566d521abcc6c39aa3eeb Mon Sep 17 00:00:00 2001 From: Dennis Eichhorn Date: Tue, 26 Feb 2019 21:42:51 +0100 Subject: [PATCH] Test fixes after module+builder test extension --- Admin/Install/db.json | 100 +++++++++++++++---------------- Models/EmployeeHistoryMapper.php | 8 +++ 2 files changed, 58 insertions(+), 50 deletions(-) diff --git a/Admin/Install/db.json b/Admin/Install/db.json index b58dda1..b3c8a55 100644 --- a/Admin/Install/db.json +++ b/Admin/Install/db.json @@ -39,58 +39,58 @@ }, "hr_staff_active": { "name": "hr_staff_active", - "type": "INT", + "type": "TINYINT", "null": false } - }, - "hr_staff_history": { - "name": "hr_staff_history", - "fields": { - "hr_staff_history_id": { - "name": "hr_staff_history_id", - "type": "INT", - "null": false, - "primary": true, - "autoincrement": true - }, - "hr_staff_history_staff": { - "name": "hr_staff_history_staff", - "type": "INT", - "null": false, - "foreignTable": "hr_staff", - "foreignKey": "hr_staff_id" - }, - "hr_staff_history_unit": { - "name": "hr_staff_history_unit", - "type": "INT", - "null": false, - "foreignTable": "organization_unit", - "foreignKey": "organization_unit_id" - }, - "hr_staff_history_department": { - "name": "hr_staff_history_department", - "type": "INT", - "null": false, - "foreignTable": "organization_department", - "foreignKey": "organization_department_id" - }, - "hr_staff_history_position": { - "name": "hr_staff_history_position", - "type": "INT", - "null": false, - "foreignTable": "organization_position", - "foreignKey": "organization_position_id" - }, - "hr_staff_history_start": { - "name": "hr_staff_history_start", - "type": "DATETIME", - "null": false - }, - "hr_staff_history_end": { - "name": "hr_staff_history_end", - "type": "DATETIME", - "null": false - } + } + }, + "hr_staff_history": { + "name": "hr_staff_history", + "fields": { + "hr_staff_history_id": { + "name": "hr_staff_history_id", + "type": "INT", + "null": false, + "primary": true, + "autoincrement": true + }, + "hr_staff_history_staff": { + "name": "hr_staff_history_staff", + "type": "INT", + "null": false, + "foreignTable": "hr_staff", + "foreignKey": "hr_staff_id" + }, + "hr_staff_history_unit": { + "name": "hr_staff_history_unit", + "type": "INT", + "null": false, + "foreignTable": "organization_unit", + "foreignKey": "organization_unit_id" + }, + "hr_staff_history_department": { + "name": "hr_staff_history_department", + "type": "INT", + "null": false, + "foreignTable": "organization_department", + "foreignKey": "organization_department_id" + }, + "hr_staff_history_position": { + "name": "hr_staff_history_position", + "type": "INT", + "null": false, + "foreignTable": "organization_position", + "foreignKey": "organization_position_id" + }, + "hr_staff_history_start": { + "name": "hr_staff_history_start", + "type": "DATETIME", + "null": false + }, + "hr_staff_history_end": { + "name": "hr_staff_history_end", + "type": "DATETIME", + "null": false } } } diff --git a/Models/EmployeeHistoryMapper.php b/Models/EmployeeHistoryMapper.php index c3a4cfb..67b7365 100644 --- a/Models/EmployeeHistoryMapper.php +++ b/Models/EmployeeHistoryMapper.php @@ -25,4 +25,12 @@ final class EmployeeHistoryMapper extends DataMapperAbstract * @since 1.0.0 */ protected static $primaryField = 'hr_staff_history_id'; + + /** + * Primary table. + * + * @var string + * @since 1.0.0 + */ + protected static $table = 'hr_staff_history'; }