Explorar o código

Fixed the problem when insert a new ONU in Flowdat3

Jean Sumara %!s(int64=5) %!d(string=hai) anos
pai
achega
12c1326303
Modificáronse 1 ficheiros con 1 adicións e 3 borrados
  1. 1 3
      src/FTTHBundle/EventListener/ONUSubscriber.php

+ 1 - 3
src/FTTHBundle/EventListener/ONUSubscriber.php

@@ -87,9 +87,7 @@ class ONUSubscriber implements EventSubscriber
         try{
             $entity = $args->getEntity();
             if($entity instanceof ONU){
-                if(isset($args->getEntityChangeSet()['clientId']) && $args->getOldValue('clientId') != $entity->getClientId()){
-                    $this->setStateOnu($entity);
-                }
+                $this->setStateOnu($entity);
             }
         }catch(Exception $ex){
             ExceptionFactory::make($ex->getMessage());