Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

Rev 5658 | Rev 5661 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 5658 Rev 5659
Línea 867... Línea 867...
867
            $conversation_id =  $this->params()->fromRoute('id');
867
            $conversation_id =  $this->params()->fromRoute('id');
Línea 868... Línea 868...
868
 
868
 
869
            $conversationMapper = ConversationMapper::getInstance($this->adapter);
869
            $conversationMapper = ConversationMapper::getInstance($this->adapter);
Línea 870... Línea -...
870
            $conversation = $conversationMapper->fetchAllByUserId($currentUser->id);
-
 
871
 
-
 
872
            echo "<pre>";
-
 
873
            print_r($conversation[0]->sender_id);
-
 
874
            echo "</pre>";
870
            $conversation = $conversationMapper->fetchAllByUserId($currentUser->id);
Línea 875... Línea 871...
875
 
871
 
Línea 876... Línea 872...
876
            if ($conversation) {
872
            if ($conversation) {
Línea 905... Línea 901...
905
 
901
 
906
    private function deleteConversation($conversation)
902
    private function deleteConversation($conversation)
907
    {
903
    {
908
        $conversationMapper = ConversationMapper::getInstance($this->adapter);
904
        $conversationMapper = ConversationMapper::getInstance($this->adapter);
909
        $conversation->sender_status = Conversation::STATUS_DELETED;
-
 
910
        // echo '<pre>';
-
 
911
        // print_r($conversation);
-
 
Línea 912... Línea 905...
912
        // echo '</pre>';
905
        $conversation->sender_status = Conversation::STATUS_DELETED;
913
 
906
 
914
        if ($conversationMapper->update($conversation)) {
907
        if ($conversationMapper->update($conversation)) {
915
            $response = [
908
            $response = [
Línea 923... Línea 916...
923
                'success' => false,
916
                'success' => false,
924
                'data' => $conversationMapper->getError()
917
                'data' => $conversationMapper->getError()
925
            ];
918
            ];
926
        }
919
        }
Línea 927... Línea -...
927
 
-
 
928
 
-
 
929
        /*$commentMapper = CommentMapper::getInstance($this->adapter);
-
 
930
        if($commentMapper->deleteAllByFeedId($feed->id)) {
-
 
931
            if($feedMapper->delete($feed->id)) {
-
 
932
                $target_path = $this->config['leaderslinked.fullpath.feed'] . DIRECTORY_SEPARATOR . $feed->id;
-
 
933
                if(file_exists($target_path)) {
-
 
934
                    $this->deletePath($target_path);
-
 
935
                }
-
 
936
                
-
 
937
                $response = [
-
 
938
                    'success' => true,
-
 
939
                    'data' => 'LABEL_FEED_WAS_DELETED'
-
 
940
                ];
-
 
941
                
-
 
942
            } else {
-
 
943
                $response = [
-
 
944
                    'success' => false,
-
 
945
                    'data' => $feedMapper->getError()
-
 
946
                ];
-
 
947
            }
-
 
948
        } else {
-
 
949
            $response = [
-
 
950
                'success' => false,
-
 
951
                'data' => $commentMapper->getError()
-
 
952
            ];
-
 
953
            
-
 
954
        }*/
-
 
955
 
920
 
956
        return $response;
921
        return $response;
957
    }
922
    }