|
@@ -107,7 +107,31 @@ class OLT implements DeviceInterface
|
|
|
*/
|
|
|
protected $workflow;
|
|
|
|
|
|
+ /**
|
|
|
+ * @ORM\Column(type="boolean", nullable=true, columnDefinition="BOOLEAN DEFAULT TRUE")
|
|
|
+ */
|
|
|
+ protected $executeSnmp = true;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @ORM\Column(type="integer", options={"unsigned":true, "default":10})
|
|
|
+ */
|
|
|
+ protected $timeScan = 10;
|
|
|
|
|
|
+ /**
|
|
|
+ * @ORM\Column(type="integer", options={"unsigned":true, "default":5})
|
|
|
+ */
|
|
|
+ protected $timeOltOctets = 5;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @ORM\Column(type="integer", options={"unsigned":true, "default":5})
|
|
|
+ */
|
|
|
+ protected $timePonStats = 5;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @ORM\Column(type="integer", options={"unsigned":true, "default":5})
|
|
|
+ */
|
|
|
+ protected $timeOnuStats = 5;
|
|
|
+
|
|
|
/**
|
|
|
* @return string
|
|
|
*/
|
|
@@ -424,10 +448,22 @@ class OLT implements DeviceInterface
|
|
|
$deviceExtraData = array('snmpCommunity' => $this->snmpCommunity, 'sshUser' => $this->sshUser, 'sshPass' => $this->sshPass,
|
|
|
'libraryVersion' => $this->libraryVersion, 'name' => $this->name);
|
|
|
|
|
|
- ($this->model)? $model = $this->getModel()->getId() : $model = null;
|
|
|
-
|
|
|
- $deviceExtraData['modelId'] = $model;
|
|
|
+ if($this->model) {
|
|
|
+ $model = $this->getModel();
|
|
|
+ $deviceExtraData['modelId'] = $model->getId();
|
|
|
+ $deviceExtraData['mark'] = $model->getMark();
|
|
|
+ $deviceExtraData['library'] = $model->getLibrary();
|
|
|
+ } else {
|
|
|
+ $deviceExtraData['modelId'] = null;
|
|
|
+ $deviceExtraData['mark'] = null;
|
|
|
+ $deviceExtraData['library'] = null;
|
|
|
+ }
|
|
|
|
|
|
+ $deviceExtraData['executeSnmp'] = $this->executeSnmp;
|
|
|
+ $deviceExtraData['timeScan'] = $this->timeScan;
|
|
|
+ $deviceExtraData['timeOnuStats'] = $this->timeOnuStats;
|
|
|
+ $deviceExtraData['timePonStats'] = $this->timePonStats;
|
|
|
+ $deviceExtraData['timeOltOctets'] = $this->timeOltOctets;
|
|
|
|
|
|
$deviceData['extraData'] = json_encode($deviceExtraData);
|
|
|
|
|
@@ -441,4 +477,108 @@ class OLT implements DeviceInterface
|
|
|
);*/
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * Set executeSnmp
|
|
|
+ *
|
|
|
+ * @param boolean $e
|
|
|
+ * @return OLT
|
|
|
+ */
|
|
|
+ public function setExecuteSnmp($e)
|
|
|
+ {
|
|
|
+ $this->executeSnmp = $e;
|
|
|
+ return $this;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Get executeSnmp
|
|
|
+ *
|
|
|
+ * @return boolean
|
|
|
+ */
|
|
|
+ public function getExecuteSnmp()
|
|
|
+ {
|
|
|
+ return $this->executeSnmp;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Set timeScan
|
|
|
+ *
|
|
|
+ * @param integer $timeScan
|
|
|
+ */
|
|
|
+ public function setTimeScan($timeScan)
|
|
|
+ {
|
|
|
+ $this->timeScan = $timeScan;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Get timeScan
|
|
|
+ *
|
|
|
+ * @return integer
|
|
|
+ */
|
|
|
+ public function getTimeScan()
|
|
|
+ {
|
|
|
+ return $this->timeScan;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Set timeOltOctets
|
|
|
+ *
|
|
|
+ * @param integer $timeOltOctets
|
|
|
+ */
|
|
|
+ public function setTimeOltOctets($timeOltOctets)
|
|
|
+ {
|
|
|
+ $this->timeOltOctets = $timeOltOctets;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Get timeOltOctets
|
|
|
+ *
|
|
|
+ * @return integer
|
|
|
+ */
|
|
|
+ public function getTimeOltOctets()
|
|
|
+ {
|
|
|
+ return $this->timeOltOctets;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Set timeOnuStats
|
|
|
+ *
|
|
|
+ * @param integer $timeOnuStats
|
|
|
+ */
|
|
|
+ public function setTimeOnuStats($timeOnuStats)
|
|
|
+ {
|
|
|
+ $this->timeOnuStats = $timeOnuStats;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Get timeOnuStats
|
|
|
+ *
|
|
|
+ * @return integer
|
|
|
+ */
|
|
|
+ public function getTimeOnuStats()
|
|
|
+ {
|
|
|
+ return $this->timeOnuStats;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Set timePonStats
|
|
|
+ *
|
|
|
+ * @param integer $timePonStats
|
|
|
+ */
|
|
|
+ public function setTimePonStats($timePonStats)
|
|
|
+ {
|
|
|
+ $this->timePonStats = $timePonStats;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Get timePonStats
|
|
|
+ *
|
|
|
+ * @return integer
|
|
|
+ */
|
|
|
+ public function getTimePonStats()
|
|
|
+ {
|
|
|
+ return $this->timePonStats;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
}
|