feat(manager): receive and preview V4 shadow plans without dispatch
This commit is contained in:
@@ -7,11 +7,15 @@ namespace Belevo\EnelixEMS;
|
||||
use RuntimeException;
|
||||
use Throwable;
|
||||
|
||||
require_once __DIR__ . '/ManagerNetzfahrplanV4EmpfangTrait.php';
|
||||
|
||||
/** Shadow telemetry only. Does not read/apply a V4 schedule or write actuators. */
|
||||
trait ManagerNetzfahrplanV4Trait
|
||||
{
|
||||
use ManagerNetzfahrplanV4EmpfangTrait;
|
||||
private function registriereNetzfahrplanV4(): void
|
||||
{
|
||||
$this->registriereNetzfahrplanV4Empfang();
|
||||
$this->RegisterPropertyBoolean('NetzfahrplanV4SchattenAktiv', false);
|
||||
$this->RegisterPropertyBoolean('NetzfahrplanV4NetzladenErlaubt', false);
|
||||
$this->RegisterPropertyString('NetzfahrplanV4BatterieOptionen', '{}');
|
||||
@@ -107,6 +111,8 @@ trait ManagerNetzfahrplanV4Trait
|
||||
$this->WriteAttributeString('NetzfahrplanV4Sendestatus', '{"status":"disabled"}');
|
||||
return;
|
||||
}
|
||||
// Read the preceding completed plan BEFORE sending a new operation/replan trigger.
|
||||
$this->empfangeNetzfahrplanV4();
|
||||
try {
|
||||
if (!$this->berechtigungLizenziert(Lizenzpruefung::NETZFAHRPLAN)) {
|
||||
throw new RuntimeException('Netzfahrplanberechtigung fehlt.');
|
||||
|
||||
Reference in New Issue
Block a user