Current File : /home/karenpetzb/application/modules/backoffice/views/scripts/annoncefooter/list.phtml
 <div class="table-box">
	<?php if ($this->populateFormAnnonceFooter['TITRE']) { ?>
	<form action="<?php echo $this->baseUrl; ?>/backoffice/annoncefooter/edit" method="post" name="editAnnonceForm" >
	<?php } else { ?>
	<form action="<?php echo $this->baseUrl; ?>/backoffice/annoncefooter/add" method="post" name="addAnnonceForm" >
	<?php } ?>
	<table class="table">
		<thead>
			<tr>
				<th colspan="2" class="col-md-4" ><?php echo $this->titlePage; ?></th>
			</tr>
		</thead>
		<tbody>
			<?php echo $this->render("alert_tr.phtml"); ?>
			<tr >
				<td class="col-md-4"><i class="glyphicon glyphicon-asterisk"></i>&nbsp;Titre</td>
				<td class="col-md-8"><input class="form-control" type="text" class="form-control"  placeholder="Titre de l'information"  name="titre" size="40" id="titre" value="<?php echo $this->populateFormAnnonceFooter['TITRE']; ?>"/></td>
			</tr>
			<tr >
				<td class="col-md-4"><i class="glyphicon glyphicon-asterisk"></i>&nbsp;Statut</td>
				<td class="col-md-8">
					<input type="radio" value="0" name="isshow" id="isshow1" class="bluecheckradios" <?php if ($this->populateFormAnnonceFooter['isSHOW'] == 0) { echo 'checked="checked"';} ?>><label for="isshow1">&nbsp;Actif</label>
					<input type="radio" value="1" name="isshow" id="isshow2" class="bluecheckradios" <?php if ($this->populateFormAnnonceFooter['isSHOW'] == 1) { echo 'checked="checked"';} ?>><label for="isshow2">&nbsp;Inactif</label>
			
				</td>
			</tr>
			<tr >
				<td class="col-md-4">Localisation</td>
				<td class="col-md-8">
					<div class="col-md-6 no-space-top">
						<?php $tabController = explode(';',$this->populateFormAnnonceFooter['CONT_NAME']); 
						$selectedController = array();
						for ($i=0;$i<sizeof($tabController);$i++) {
							$selectedController[$tabController[$i]] = true;
						}
						?>
							<select class="form-control" size="10" name="controllername[]"  multiple="multiple">
								<option value="index" <?php if (isset($selectedController['index'])) {echo 'selected="selected"';} ?> >Accueil</option>
								<option value="user" <?php if (isset($selectedController['user'])) {echo 'selected="selected"';} ?>>Compte</option>
								<option value="produits" <?php if (isset($selectedController['produits'])) {echo 'selected="selected"';} ?>>Produits</option>
								<option value="commande" <?php if (isset($selectedController['commande'])) {echo 'selected="selected"';} ?>>Commande</option>
								<option value="services" <?php if (isset($selectedController['services'])) {echo 'selected="selected"';} ?>>Services</option>
								<option value="produitspromotion" <?php if (isset($selectedController['produitspromotion'])) {echo 'selected="selected"';} ?>>Promotions</option>
								
							</select>
					</div>
					<div class="col-md-6 no-space-top">	
						<?php if (isset($selectedController['produits'])) { 
							$tabCategorie = explode(';',$this->populateFormAnnonceFooter['CAT_ID']); 
							$selectedCategorie = array();
							for ($i=0;$i<sizeof($tabCategorie);$i++) {
								$selectedCategorie[$tabCategorie[$i]] = true;
							}
							
							?>
							<div class="col-md-2 no-space-top">Produits</div>
							<div class="col-md-10 no-space-top">
								<select class="form-control" size="10" name="categorie[]"  multiple="multiple">
									<option value="1" <?php if (isset($selectedCategorie[1])) {echo 'selected="selected"';} ?> >Manutention, levage</option>
									<option value="2" <?php if (isset($selectedCategorie[2])) {echo 'selected="selected"';} ?> >Pr�vention de l'environnement</option>
									<option value="3" <?php if (isset($selectedCategorie[3])) {echo 'selected="selected"';} ?> >Stockage, rayonnage</option>
									<option value="4" <?php if (isset($selectedCategorie[4])) {echo 'selected="selected"';} ?> >Entretien, propret�</option>
									<option value="5" <?php if (isset($selectedCategorie[5])) {echo 'selected="selected"';} ?> >Protection, s�curit�</option>
									<option value="6" <?php if (isset($selectedCategorie[6])) {echo 'selected="selected"';} ?> >Emballage</option>
									<option value="7" <?php if (isset($selectedCategorie[7])) {echo 'selected="selected"';} ?> >Outillage</option>
									<option value="8" <?php if (isset($selectedCategorie[8])) {echo 'selected="selected"';} ?> >Mobilier d'atelier</option>
									<option value="9" <?php if (isset($selectedCategorie[9])) {echo 'selected="selected"';} ?> >Mobilier de bureau et de collectivit�</option>
								</select>
							</div>
						<?php } ?>
					</div>
				</td>
			</tr>
			<tr >
				<td class="col-md-4"><i class="glyphicon glyphicon-asterisk"></i>&nbsp;Contenu</td>
				<td class="col-md-8">
						<textarea  name="content" cols="130" rows="20" id="annonceContent" name="annonceContent">
						<?php if (isset($this->populateFormAnnonceFooter['CONTENT']) && !empty($this->populateFormAnnonceFooter['CONTENT'])) { 
							 echo $this->populateFormAnnonceFooter['CONTENT']; 
						} ?>
						</textarea>
				</td>
			</tr>
			<tr>
				<td colspan="2" class="text-center">
					<?php if ($this->populateFormAnnonceFooter['TITRE']) { ?>
						<input type="hidden" name="id" value="<?php echo $this->populateFormAnnonceFooter['ID'];?>">
						<button class="btn btn-success" type="submit" name="edit"><i class="glyphicon glyphicon-edit"></i>&nbsp;Modifier</button>
					<?php } else { ?>
						<button class="btn btn-success" type="submit" name="add"><i class="glyphicon glyphicon-plus"></i>&nbsp;Ajouter</button>
					<?php } ?>
				</td>
			</tr>
		</tbody>
	</table>
	</form>
</div>
<div class="clearfix"></div>
<script type="text/javascript">
$(function(){
	initEditor('#annonceContent');
});
</script>

 <div class="table-box">
<table class="display table" id="annonceFooterTable" width="100%">
	<thead>
		<tr>
			<th>Titre</th>
			<th>Statut</th>
			<th></th>
		</tr>
	</thead>
	<tbody>
	
		<?php foreach($this->listannoncefooter as $row)  { ?>
		<tr>
			<td><?php echo $row['TITRE'];?></td>
			<td><?php if ($this->escape($row['isSHOW'])==0) {echo 'Actif';} else {echo 'Inactif';} ?></td>
			<td>
				<div class="btn-group">
	             	<a class="btn btn-success" href="<?php echo $this->baseUrl; ?>/backoffice/annoncefooter/edit/id/<?php echo $row['ID']; ?>"><span class="glyphicon glyphicon-edit"></span> Modifier</a>
					<button class="btn btn-danger btn-modal" data-toggle="ajaxModalDelete" data-linkok="<?php echo $this->baseUrl; ?>/backoffice/annoncefooter/del/id/<?php echo $row['ID']; ?>" ><span class="glyphicon glyphicon-trash"></span> Supprimer</button>
				</div>
			</td>
		</tr>
		<?php } ?>
	</tbody>
</table>
<script>			
	$(document).ready(function() {
		initDataTable('annonceFooterTable', [[ 0, "asc" ]], [{ "orderable": false, "targets": -1, "width": "270px" }]); 	    
	});
</script>
</div>