Proyectos de Subversion LeadersLinked - Backend

Rev

Rev 6222 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 6222 Rev 6224
Línea 305... Línea 305...
305
            $form->setData($dataPost);
305
            $form->setData($dataPost);
Línea 306... Línea 306...
306
            
306
            
307
            if($form->isValid()) {
307
            if($form->isValid()) {
308
                $dataPost = (array) $form->getData();
308
                $dataPost = (array) $form->getData();
309
                $dataPost['status'] =  isset($dataPost['status']) ? $dataPost['status'] : PlanningObjectivesAndGoalsObjectives::STATUS_INACTIVE;
309
                $dataPost['status'] =  isset($dataPost['status']) ? $dataPost['status'] : PlanningObjectivesAndGoalsObjectives::STATUS_INACTIVE;
Línea 310... Línea 310...
310
                $dataPost['id_company']=$currentCompany->id;
310
                $dataPost['company_id']=$currentCompany->id;
311
 
311
 
312
                $hydrator = new ObjectPropertyHydrator();
312
                $hydrator = new ObjectPropertyHydrator();
Línea 392... Línea 392...
392
            ];
392
            ];
Línea 393... Línea 393...
393
 
393
 
394
            return new JsonModel($data);
394
            return new JsonModel($data);
Línea 395... Línea 395...
395
        }
395
        }
396
       
396
       
397
        if ($objectives->id_company != $currentCompany->id) {
397
        if ($objectives->company_id != $currentCompany->id) {
398
            return new JsonModel([
398
            return new JsonModel([
399
                'success' => false,
399
                'success' => false,
400
                'data' => 'ERROR_UNAUTHORIZED'
400
                'data' => 'ERROR_UNAUTHORIZED'
Línea 498... Línea 498...
498
            ];
498
            ];
Línea 499... Línea 499...
499
 
499
 
500
            return new JsonModel($data);
500
            return new JsonModel($data);
Línea 501... Línea 501...
501
        }
501
        }
502
       
502
       
503
        if ($objectives->id_company != $currentCompany->id) {
503
        if ($objectives->company_id != $currentCompany->id) {
504
            return new JsonModel([
504
            return new JsonModel([
505
                'success' => false,
505
                'success' => false,
506
                'data' => 'ERROR_UNAUTHORIZED'
506
                'data' => 'ERROR_UNAUTHORIZED'
Línea 569... Línea 569...
569
            ];
569
            ];
Línea 570... Línea 570...
570
 
570
 
571
            return new JsonModel($data);
571
            return new JsonModel($data);
Línea 572... Línea 572...
572
        }
572
        }
573
       
573
       
574
        if ($recordsObjectives->id_company != $currentCompany->id) {
574
        if ($recordsObjectives->company_id != $currentCompany->id) {
575
            return new JsonModel([
575
            return new JsonModel([
576
                'success' => false,
576
                'success' => false,
577
                'data' => 'ERROR_UNAUTHORIZED'
577
                'data' => 'ERROR_UNAUTHORIZED'
Línea 645... Línea 645...
645
        $planningObjectivesAndGoalsTaskMapper = PlanningObjectivesAndGoalsTaskMapper::getInstance($this->adapter);
645
        $planningObjectivesAndGoalsTaskMapper = PlanningObjectivesAndGoalsTaskMapper::getInstance($this->adapter);
646
        $items;
646
        $items;
647
        $contador=0;
647
        $contador=0;
648
        foreach($recordsObjectives as $record){
648
        foreach($recordsObjectives as $record){
Línea 649... Línea 649...
649
 
649
 
650
            if ($record->id_company != $currentCompany->id) {
650
            if ($record->company_id != $currentCompany->id) {
651
                return new JsonModel([
651
                return new JsonModel([
652
                    'success' => false,
652
                    'success' => false,
653
                    'data' => 'ERROR_UNAUTHORIZED'
653
                    'data' => 'ERROR_UNAUTHORIZED'
654
                ]);
654
                ]);
Línea 719... Línea 719...
719
        $planningObjectivesAndGoalsTaskMapper = PlanningObjectivesAndGoalsTaskMapper::getInstance($this->adapter);
719
        $planningObjectivesAndGoalsTaskMapper = PlanningObjectivesAndGoalsTaskMapper::getInstance($this->adapter);
720
        $items;
720
        $items;
721
        $contador=0;
721
        $contador=0;
722
        foreach($recordsObjectives as $record){
722
        foreach($recordsObjectives as $record){
Línea 723... Línea 723...
723
 
723
 
724
            if ($record->id_company != $currentCompany->id) {
724
            if ($record->company_id != $currentCompany->id) {
725
                return new JsonModel([
725
                return new JsonModel([
726
                    'success' => false,
726
                    'success' => false,
727
                    'data' => 'ERROR_UNAUTHORIZED'
727
                    'data' => 'ERROR_UNAUTHORIZED'
728
                ]);
728
                ]);