syntaxe POO (visibilite)
[mw_pages] / app / out / default / views / pages / admin / list.php
index 89c5bfb..e9b30bf 100644 (file)
@@ -1,30 +1,41 @@
-<h2>Pages</h2>
+<?php
 
-<ul class="admin">
-  <li><a class="add" href="<?php echo $this->url("pages/admin/add"); ?>">Nouvelle page</a></li>
-</ul>
+  $pages_helper = $this->helper("mw_helper_pages");
+
+?>
+<h2>Pages</h2>
 
 <form name="accueil_form" action="<?php echo $this->url("pages/admin/set_accueil"); ?>" method="post">
-<ul class="admin">
-  <li>Page d'accueil du site</li>
-  <li>
-    <select name="id">
-      <option value=""<?php echo $this->config("start_action") ? "" : " selected=\"selected\""; ?>>Page par d&eacute;faut du site</option>
-      <?php echo pages_arbo_start_select_options($this, $this->out["arbo"], $this->config("start_action"), $this->config("start_action_params"), "&nbsp;&nbsp;"); ?>
-    </select>
-  </li>
-  <li class="buttons">
-    <input type="submit" value="Enregistrer" />
-  </li>
-</ul>
+  <fieldset>
+    <ul>
+      <li>
+        <label for="id">Page d'accueil du site</label>
+        <div class="form_input">
+          <select id="id" name="id">
+            <option value=""<?php echo $this->config("start_action") ? "" : " selected=\"selected\""; ?>>Page par d&eacute;faut du site</option>
+            <?php echo $pages_helper->pages_arbo_start_select_options($this, $this->out["arbo"], $this->config("start_action"), $this->config("start_action_params"), "&nbsp;&nbsp;"); ?>
+          </select>
+        </div>
+      </li>
+      <li>
+        <div class="form_single_button">
+          <input type="submit" value="Enregistrer" />
+        </div>
+      </li>
+    </ul>
+  </fieldset>
 </form>
 
-<ul class="admin">
+<ul class="buttons">
+  <li><a class="add" href="<?php echo $this->url("pages/admin/add"); ?>">Nouvelle page</a></li>
+</ul>
+
+<ul class="filters">
   <li>Page parente</li>
   <li>
     <select onchange="document.location=this.options[this.selectedIndex].value;">
       <option value="<?php echo $this->url("pages/admin"); ?>"<?php echo isset($_GET[$this->param("parent")]) ? "" : " selected=\"selected\""; ?>>Afficher toutes les pages</option>
-      <?php echo pages_arbo_list_select_options($this, "pages/admin", $this->out["arbo"], $_GET[$this->param("parent")], "&nbsp;&nbsp;"); ?>
+      <?php echo $pages_helper->pages_arbo_list_select_options($this, "pages/admin", $this->out["arbo"], $_GET[$this->param("parent")], "&nbsp;&nbsp;"); ?>
     </select>
   </li>
 </ul>
@@ -45,7 +56,7 @@
 <?php foreach($this->out["pages"]["list"] as $id_page => $page) : ?>
   <tr class="hl">
     <td><?php echo $page["title"]; ?></td>
-    <td><?php echo date("j M Y : G\hi", datetime2timestamp($page["date_creation"])); ?></td>
+    <td><?php echo date("j M Y : G\hi", $pages_helper->datetime2timestamp($page["date_creation"])); ?></td>
     <td class="action"><input type="text" size="3" name="position_<?php echo $id_page; ?>" value="<?php echo $page["position"]; ?>" /></td>
     <td class="action"><input type="checkbox" name="enabled_<?php echo $id_page; ?>" <?php echo $page["enabled"] ? "checked=\"checked\"" : ""; ?> /></td>
     <td class="action">