-<?php require $this->out_file("views/tinymce.init.js.php"); ?>
+<?php require $this->out_file("views/tinymce.init.js.php"); $data = $this->data(); ?>
<h2>Modifier un morceau</h2>
<script type="text/javascript">
-var albums = {};
-<?php foreach($this->out["albums"] as $id_groupe => $albums) : ?>
-albums["<?php echo $id_groupe ?>"] = {};
-<?php foreach($albums as $id_album => $album) : ?>
-albums["<?php echo $id_groupe ?>"]["<?php echo $id_album ?>"] = "<?php echo $album["titre"] ?>";
-<?php endforeach; ?>
-<?php endforeach; ?>
var derivations = {};
<?php
<ul class="form">
<li>
- <label for="id_groupe">groupe</label>
+ <label for="id_groupe"> </label>
<div class="form_input">
- <select name="id_groupe" id="id_groupe" onchange="select_groupe(this.options[this.selectedIndex].value)">
- <?php
-
- $current_groupe = null;
- $first_groupe = null;
- foreach($this->out["groupes"]["list"] as $id_groupe => $groupe) :
- $selected = false;
- if(!isset($first_groupe)) $first_groupe = $id_groupe;
- if($this->out["groupe"]["id"] == $id_groupe)
- { $current_groupe = $id_groupe;
- $selected = true;
- }
-
- ?>
- <option value="<?php echo $id_groupe ?>"<?php echo $selected ? "selected=\"selected\"" : "" ?>><?php echo $groupe["nom"] ?></option>
- <?php
-
- endforeach;
- if(!isset($current_groupe)) $current_groupe = $first_groupe;
-
- ?>
- </select>
+ <ul class="source_groupes">
+ <?php foreach($this->out["morceau"]["groupes"] as $id_groupe => $groupe) : ?>
+ <li class="source_groupe" id="source_groupe_<?php echo $id_groupe; ?>">
+ <span class="author"><?php echo $groupe["nom"]; ?></span>
+ <span class="access"><?php echo $this->out["sources_access"][$groupe["id_groupe_status"]]["intitule"]; ?></span>
+ </li>
+ <?php endforeach; ?>
+ </ul>
</div>
</li>
-
+
+ </ul>
+
+<!-- ul class="buttons">
+ <li><a href="<?php echo $this->url("users/morceaux/groupes") ?>">Editer les groupes du morceau</a></li>
+</ul -->
+
+ <ul>
+
<li>
<div id="album_select">
<label for="album">album</label>
<div class="form_input">
<select name="album" id="album">
- <option value="0"<?php echo $_GET[$this->param("album")] == "0" ? " selected=\"selected\"" : "" ?>>hors album</option>
- <?php if($this->out["albums"][$current_groupe]) : ?>
- <?php foreach($this->out["albums"][$current_groupe] as $id_album => $album) : ?>
+ <option value="0"<?php echo $this->out["morceau"]["album"] == "0" ? " selected=\"selected\"" : "" ?>>hors album</option>
+ <?php foreach($this->out["albums"] as $id_album => $album) : ?>
<option value="<?php echo $id_album ?>"<?php echo $this->out["morceau"]["album"] == $id_album ? " selected=\"selected\"" : "" ?>><?php echo $album["titre"] ?></option>
<?php endforeach; ?>
- <?php endif; ?>
</select>
</div>
</div>
</select>
</div>
</li>
-
+
<li>
<label for="date_creation">date de création</label>
<div class="form_input">