Changeset 6f7b2e


Ignore:
Timestamp:
04/27/15 08:15:25 (2 years ago)
Author:
pierre-alain <pierre-alain@…>
Branches:
master
Children:
712cca
Parents:
ed39d4
git-author:
pierre-alain <pierre-alain@…> (04/27/15 08:15:25)
git-committer:
pierre-alain <pierre-alain@…> (04/27/15 08:15:25)
Message:

adding stat on dead/unavailable streams

Location:
OWR
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • OWR/Includes/Themes/Original/tpl/blocks/stats.html

    r7c60cc r6f7b2e  
    1515            <tr> 
    1616                <td class="full_rounded"><?php echo $this->_utilities->_('Streams');?></td> 
    17                 <td class="full_rounded"><?php echo $nbStreams;?></td> 
     17                <td class="full_rounded"><?php echo $nbStreams . ' (-' . $nbDeadStreams . ')';?></td> 
    1818            </tr> 
    1919            <tr> 
     
    3838            <tr> 
    3939                <td class="full_rounded"><?php echo $this->_utilities->_('Total streams');?></td> 
    40                 <td class="full_rounded"><?php echo $nbTotalStreams;?></td> 
     40                <td class="full_rounded"><?php echo $nbTotalStreams . ' (-' . $nbTotalDeadStreams . ')';?></td> 
    4141            </tr> 
    4242<?php } 
  • OWR/Model/Users.php

    rde92cf r6f7b2e  
    489489        $datas['nbCategories'] = DAO::getCachedDAO('streams_groups')->count()->nb; 
    490490        $datas['nbStreams'] = DAO::getCachedDAO('streams_relations')->count()->nb; 
     491        $datas['nbDeadStreams'] = $datas['nbStreams'] - DAO::getCachedDAO('streams_relations')->count(array('streams.status' => 0))->nb; 
    491492        $datas['nbNews'] = DAO::getCachedDAO('news_relations')->count()->nb; 
    492493        $datas['nbUnreads'] = DAO::getCachedDAO('news_relations')->count(array('status' => 1))->nb; 
     
    498499            $datas['nbTotalStreams'] = DAO::getCachedDAO('streams')->count()->nb; 
    499500            $datas['nbTotalNews'] = DAO::getCachedDAO('news')->count()->nb; 
     501            $datas['nbTotalDeadStreams'] = $datas['nbTotalStreams'] - DAO::getCachedDAO('streams')->count(array('status' => 0))->nb; 
    500502        } 
    501503 
Note: See TracChangeset for help on using the changeset viewer.