3 if (!defined('_ECRIRE_INC_VERSION')) return;
6 function compagnon_compagnon_messages($flux) {
8 $exec = $flux['args']['exec'];
9 $pipeline = $flux['args']['pipeline'];
10 $vus = $flux['args']['deja_vus'];
11 $aides = &$flux['data'];
15 case 'affiche_milieu':
22 'inclure' => 'compagnon/accueil',
23 'statuts'=> array('1comite', '0minirezo', 'webmestre')
26 'id' => 'accueil_configurer',
27 'titre' => _T('compagnon:c_accueil_configurer_site'),
28 'texte' => _T('compagnon:c_accueil_configurer_site_texte', array('nom'=>$GLOBALS['meta']['nom_site'])),
29 'statuts'=> array('webmestre'),
30 'target' => '#bando_identite .nom_site_spip .nom',
33 'id' => 'accueil_publication',
34 'titre' => _T('compagnon:c_accueil_publication'),
35 'texte' => _T('compagnon:c_accueil_publication_texte'),
36 'statuts'=> array('webmestre'),
37 'target'=> '#bando1_menu_edition',
43 // eviter si possible une requete sql.
44 if (!isset($vus['rubriques']) and !sql_countsel('spip_rubriques')) {
47 'titre' => _T('compagnon:c_rubriques_creer'),
48 'texte' => _T('compagnon:c_rubriques_creer_texte'),
49 'statuts'=> array('webmestre'),
50 'target'=> '#contenu .icone:first-of-type',
57 // eviter si possible une requete sql.
58 if (!isset($vus['rubrique'])) {
59 $statut = sql_getfetsel('statut', 'spip_rubriques', 'id_rubrique='.$flux['args']['id_rubrique']);
60 if ($statut != 'publie') {
63 'titre' => _T('compagnon:c_rubrique_publier'),
64 'texte' => _T('compagnon:c_rubrique_publier_texte'),
65 'statuts'=> array('webmestre'),
66 'target'=> '#contenu .icone.article-new-24'
73 // eviter si possible une requete sql.
74 if (!isset($vus['articles']) and !sql_countsel('spip_rubriques')) {
77 'titre' => _T('compagnon:c_articles_creer'),
78 'texte' => _T('compagnon:c_articles_creer_texte'),
79 'statuts'=> array('webmestre')
86 'id' => 'article_redaction',
87 'inclure' => 'compagnon/article_redaction',
88 'statuts'=> array('0minirezo', 'webmestre')
91 'id' => 'article_redaction_redacteur',
92 'inclure' => 'compagnon/article_redaction_redacteur',
93 'statuts'=> array('1comite')
99 case 'affiche_gauche':
104 'titre' => _T('compagnon:c_job'),
105 'texte' => _T('compagnon:c_job_texte'),
106 'statuts'=> array('webmestre')