mirror of
https://github.com/Karaka-Management/oms-Script.git
synced 2026-02-11 18:58:40 +00:00
Implement php 7.4 type hints
This commit is contained in:
parent
e3ae3adc6a
commit
77b0aa961e
|
|
@ -74,7 +74,7 @@ class Controller extends ModuleAbstract implements WebInterface
|
||||||
* @var string[]
|
* @var string[]
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $providing = [];
|
protected static array $providing = [];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Dependencies.
|
* Dependencies.
|
||||||
|
|
@ -82,5 +82,5 @@ class Controller extends ModuleAbstract implements WebInterface
|
||||||
* @var string[]
|
* @var string[]
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $dependencies = [];
|
protected static array $dependencies = [];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -68,7 +68,7 @@ class Report implements \JsonSerializable
|
||||||
/**
|
/**
|
||||||
* Report created at.
|
* Report created at.
|
||||||
*
|
*
|
||||||
* @var \DateTime
|
* @var null|\DateTime
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected $createdAt = null;
|
protected $createdAt = null;
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ final class ReportMapper extends DataMapperAbstract
|
||||||
* @var array<string, array<string, bool|string>>
|
* @var array<string, array<string, bool|string>>
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $columns = [
|
protected static array $columns = [
|
||||||
'helper_report_id' => ['name' => 'helper_report_id', 'type' => 'int', 'internal' => 'id'],
|
'helper_report_id' => ['name' => 'helper_report_id', 'type' => 'int', 'internal' => 'id'],
|
||||||
'helper_report_status' => ['name' => 'helper_report_status', 'type' => 'int', 'internal' => 'status'],
|
'helper_report_status' => ['name' => 'helper_report_status', 'type' => 'int', 'internal' => 'status'],
|
||||||
'helper_report_title' => ['name' => 'helper_report_title', 'type' => 'string', 'internal' => 'title'],
|
'helper_report_title' => ['name' => 'helper_report_title', 'type' => 'string', 'internal' => 'title'],
|
||||||
|
|
@ -44,7 +44,7 @@ final class ReportMapper extends DataMapperAbstract
|
||||||
* @var array<string, array<string, string>>
|
* @var array<string, array<string, string>>
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $ownsOne = [
|
protected static array $ownsOne = [
|
||||||
'source' => [
|
'source' => [
|
||||||
'mapper' => \Modules\Media\Models\CollectionMapper::class,
|
'mapper' => \Modules\Media\Models\CollectionMapper::class,
|
||||||
'src' => 'helper_report_media',
|
'src' => 'helper_report_media',
|
||||||
|
|
@ -61,7 +61,7 @@ final class ReportMapper extends DataMapperAbstract
|
||||||
* @var array<string, array<string, string>>
|
* @var array<string, array<string, string>>
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $belongsTo = [
|
protected static array $belongsTo = [
|
||||||
'createdBy' => [
|
'createdBy' => [
|
||||||
'mapper' => AccountMapper::class,
|
'mapper' => AccountMapper::class,
|
||||||
'src' => 'helper_report_creator',
|
'src' => 'helper_report_creator',
|
||||||
|
|
@ -74,7 +74,7 @@ final class ReportMapper extends DataMapperAbstract
|
||||||
* @var string
|
* @var string
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $table = 'helper_report';
|
protected static string $table = 'helper_report';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Primary field name.
|
* Primary field name.
|
||||||
|
|
@ -82,7 +82,7 @@ final class ReportMapper extends DataMapperAbstract
|
||||||
* @var string
|
* @var string
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $primaryField = 'helper_report_id';
|
protected static string $primaryField = 'helper_report_id';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created at.
|
* Created at.
|
||||||
|
|
@ -90,5 +90,5 @@ final class ReportMapper extends DataMapperAbstract
|
||||||
* @var string
|
* @var string
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $createdAt = 'helper_report_created';
|
protected static string $createdAt = 'helper_report_created';
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -84,7 +84,7 @@ class Template implements \JsonSerializable
|
||||||
/**
|
/**
|
||||||
* Template created at.
|
* Template created at.
|
||||||
*
|
*
|
||||||
* @var \DateTime
|
* @var null|\DateTime
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected $createdAt = null;
|
protected $createdAt = null;
|
||||||
|
|
|
||||||
|
|
@ -27,7 +27,7 @@ final class TemplateMapper extends DataMapperAbstract
|
||||||
* @var array<string, array<string, bool|string>>
|
* @var array<string, array<string, bool|string>>
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $columns = [
|
protected static array $columns = [
|
||||||
'helper_template_id' => ['name' => 'helper_template_id', 'type' => 'int', 'internal' => 'id'],
|
'helper_template_id' => ['name' => 'helper_template_id', 'type' => 'int', 'internal' => 'id'],
|
||||||
'helper_template_status' => ['name' => 'helper_template_status', 'type' => 'int', 'internal' => 'status'],
|
'helper_template_status' => ['name' => 'helper_template_status', 'type' => 'int', 'internal' => 'status'],
|
||||||
'helper_template_title' => ['name' => 'helper_template_title', 'type' => 'string', 'internal' => 'name'],
|
'helper_template_title' => ['name' => 'helper_template_title', 'type' => 'string', 'internal' => 'name'],
|
||||||
|
|
@ -49,7 +49,7 @@ final class TemplateMapper extends DataMapperAbstract
|
||||||
* @var array<string, array<string, string>>
|
* @var array<string, array<string, string>>
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $ownsOne = [
|
protected static array $ownsOne = [
|
||||||
'source' => [
|
'source' => [
|
||||||
'mapper' => CollectionMapper::class,
|
'mapper' => CollectionMapper::class,
|
||||||
'src' => 'helper_template_media',
|
'src' => 'helper_template_media',
|
||||||
|
|
@ -62,7 +62,7 @@ final class TemplateMapper extends DataMapperAbstract
|
||||||
* @var array<string, array<string, string>>
|
* @var array<string, array<string, string>>
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $belongsTo = [
|
protected static array $belongsTo = [
|
||||||
'createdBy' => [
|
'createdBy' => [
|
||||||
'mapper' => AccountMapper::class,
|
'mapper' => AccountMapper::class,
|
||||||
'src' => 'helper_template_creator',
|
'src' => 'helper_template_creator',
|
||||||
|
|
@ -75,7 +75,7 @@ final class TemplateMapper extends DataMapperAbstract
|
||||||
* @var array<string, array<string, null|string>>
|
* @var array<string, array<string, null|string>>
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $hasMany = [
|
protected static array $hasMany = [
|
||||||
'reports' => [
|
'reports' => [
|
||||||
'mapper' => ReportMapper::class,
|
'mapper' => ReportMapper::class,
|
||||||
'table' => 'helper_report',
|
'table' => 'helper_report',
|
||||||
|
|
@ -90,7 +90,7 @@ final class TemplateMapper extends DataMapperAbstract
|
||||||
* @var string
|
* @var string
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $table = 'helper_template';
|
protected static string $table = 'helper_template';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created at.
|
* Created at.
|
||||||
|
|
@ -98,7 +98,7 @@ final class TemplateMapper extends DataMapperAbstract
|
||||||
* @var string
|
* @var string
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $createdAt = 'helper_template_created';
|
protected static string $createdAt = 'helper_template_created';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Primary field name.
|
* Primary field name.
|
||||||
|
|
@ -106,5 +106,5 @@ final class TemplateMapper extends DataMapperAbstract
|
||||||
* @var string
|
* @var string
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
*/
|
*/
|
||||||
protected static $primaryField = 'helper_template_id';
|
protected static string $primaryField = 'helper_template_id';
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user