mirror of
https://github.com/Karaka-Management/oms-RiskManagement.git
synced 2026-02-10 01:08:39 +00:00
implement immutable datetime
This commit is contained in:
parent
b9d6720e47
commit
ac66d80629
|
|
@ -89,7 +89,7 @@ class Risk
|
||||||
*/
|
*/
|
||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
$this->createdAt = new \DateTime('now');
|
$this->createdAt = new \DateTimeImmutable('now');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -46,7 +46,7 @@ final class RiskMapper extends DataMapperAbstract
|
||||||
'riskmngmt_risk_process' => ['name' => 'riskmngmt_risk_process', 'type' => 'int', 'internal' => 'process'],
|
'riskmngmt_risk_process' => ['name' => 'riskmngmt_risk_process', 'type' => 'int', 'internal' => 'process'],
|
||||||
'riskmngmt_risk_responsible' => ['name' => 'riskmngmt_risk_responsible', 'type' => 'int', 'internal' => 'responsible'],
|
'riskmngmt_risk_responsible' => ['name' => 'riskmngmt_risk_responsible', 'type' => 'int', 'internal' => 'responsible'],
|
||||||
'riskmngmt_risk_deputy' => ['name' => 'riskmngmt_risk_deputy', 'type' => 'int', 'internal' => 'deputy'],
|
'riskmngmt_risk_deputy' => ['name' => 'riskmngmt_risk_deputy', 'type' => 'int', 'internal' => 'deputy'],
|
||||||
'riskmngmt_risk_created_at' => ['name' => 'riskmngmt_risk_created_at', 'type' => 'DateTime', 'internal' => 'createdAt', 'readonly' => true],
|
'riskmngmt_risk_created_at' => ['name' => 'riskmngmt_risk_created_at', 'type' => 'DateTimeImmutable', 'internal' => 'createdAt', 'readonly' => true],
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user