|
@@ -1072,11 +1072,13 @@ class ONU implements DeviceInterface, TenancyIdTraitInterface, LocationInterface
|
|
|
|
|
|
/**
|
|
|
* @param mixed $logOLT
|
|
|
+ *
|
|
|
* @return $this
|
|
|
*/
|
|
|
public function setLogOLT($logOLT)
|
|
|
{
|
|
|
$this->logOLT = $logOLT;
|
|
|
+
|
|
|
return $this;
|
|
|
}
|
|
|
|
|
@@ -1086,7 +1088,7 @@ class ONU implements DeviceInterface, TenancyIdTraitInterface, LocationInterface
|
|
|
public function prePersist()
|
|
|
{
|
|
|
$this->correctSerialNumber();
|
|
|
- $this->setLogOLT(new ONULogOLT());
|
|
|
+ $this->setLogOLT(new ONULogOLT());
|
|
|
}
|
|
|
|
|
|
/**
|
|
@@ -1095,6 +1097,10 @@ class ONU implements DeviceInterface, TenancyIdTraitInterface, LocationInterface
|
|
|
public function preUpdate()
|
|
|
{
|
|
|
$this->correctSerialNumber();
|
|
|
+
|
|
|
+ if (is_null($this->logOLT)) {
|
|
|
+ $this->setLogOLT(new ONULogOLT());
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
public function correctSerialNumber() {
|