promotions/index.php

Listado de convenios disponibles para un cliente.

Página "Convenios"

Este template le permite a un usuario acceder al listado de convenios que tiene asignado su tipo de cliente.

Objetos disponibles

Descripción

$_userTypePromotion

Convenios.

$_total

Número total de convenios.

Para visualizar este template el usuario debe estar autenticado

Código de ejemplo

promotions/index.php
<h1>Mis convenios</h1>
		
<table class="account">
	<tr>
		<th>Desde</th>
		<th>Hasta</th>
		<th>Descuento</th>
		<th>Límite diario</th>
		<th>Semanal</th>
		<th>Mensual</th>
		<th></th>
	</tr>
	<?php while($_userTypePromotion->getNext()): ?>
	<tr onclick="location.href='<?=$_userTypePromotion->getURL()?>'">
		<td><?=$_front->date($_userTypePromotion->get('start'))?></td>
		<td><?=$_front->date($_userTypePromotion->get('end'))?></td>
		<td><?=($_userTypePromotion->get('priceType') == 0 ? $_front->price($_userTypePromotion->get('priceValue')) : $_userTypePromotion->get('priceValue').'%')?></td>
		<td><?=($_userTypePromotion->get('maxPerDay') ? $_userTypePromotion->get('maxPerDay') : 'Sin límite')?></td>
		<td><?=($_userTypePromotion->get('maxPerWeek') ? $_userTypePromotion->get('maxPerWeek') : 'Sin límite')?></td>
		<td><?=($_userTypePromotion->get('maxPerMonth') ? $_userTypePromotion->get('maxPerMonth') : 'Sin límite')?></td>
	</tr>
	<?php endwhile; ?>
</table>
html

Last updated

Was this helpful?