X-Git-Url: https://git.llucax.com/mecon/intranet.git/blobdiff_plain/99cee4fba7d5581e7d7f447c6bb54916cc8a7db3..9600fe7934a4f50b31e1d00f456bbf5ce993102e:/sistema/local_lib/HTML_Titulares.php?ds=sidebyside diff --git a/sistema/local_lib/HTML_Titulares.php b/sistema/local_lib/HTML_Titulares.php index e45d0e6..1ab8314 100644 --- a/sistema/local_lib/HTML_Titulares.php +++ b/sistema/local_lib/HTML_Titulares.php @@ -73,16 +73,22 @@ class HTML_Titulares extends HTML_Table { $query = "SELECT Articles.article_id, IF(Articles.publication_date > '$fecha_nuevo', 'NUEVA', null) FROM Articles, ArticlePublicationStates - WHERE Articles.article_publication_state_id = - ArticlePublicationStates.article_publication_state_id - AND ArticlePublicationStates.publication_state_id=5 "; + WHERE Articles.article_publication_state_id = + ArticlePublicationStates.article_publication_state_id + AND ArticlePublicationStates.publication_state_id=5 "; if(!is_null($grupo_secciones)) { $gs = new AI_GrupoSecciones($grupo_secciones); - $gs->cargar($db2); - if(count($gs->secciones) > 0) - $query .= 'AND Articles.section_id IN('.implode(',', $gs->secciones).') '; + $gs->cargar($db2); + if(count($gs->secciones) > 0) + $query .= ' AND Articles.section_id IN('.implode(',', $gs->secciones).') '; } + else{ + $censuradas = $db2->getCol('SELECT seccion FROM secciones_censuradas'); + $query .= ' AND Articles.section_id NOT IN('.implode(',', $censuradas).') '; + + } + if(!is_null($antiguedad)) { $hoy->subtractSeconds(60*60*24*$antiguedad);