diff options
author | Frédéric Guillot <fred@kanboard.net> | 2014-12-28 11:28:50 -0500 |
---|---|---|
committer | Frédéric Guillot <fred@kanboard.net> | 2014-12-28 11:28:50 -0500 |
commit | 34d7450d3c13342715e90ec21bceaa13e1baa876 (patch) | |
tree | a2d8f2f22ad3fe9b56f01fe2db0357f9b963e660 /app/Template/action/index.php | |
parent | 88d84073aecbe8bdc5f10825b6d7ca6b81c5f7b1 (diff) |
Template helpers refactoring
Diffstat (limited to 'app/Template/action/index.php')
-rw-r--r-- | app/Template/action/index.php | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/app/Template/action/index.php b/app/Template/action/index.php index 54f13691..e388fbc9 100644 --- a/app/Template/action/index.php +++ b/app/Template/action/index.php @@ -15,26 +15,26 @@ <?php foreach ($actions as $action): ?> <tr> - <td><?= Helper\in_list($action['event_name'], $available_events) ?></td> - <td><?= Helper\in_list($action['action_name'], $available_actions) ?></td> + <td><?= $this->inList($action['event_name'], $available_events) ?></td> + <td><?= $this->inList($action['action_name'], $available_actions) ?></td> <td> <ul> <?php foreach ($action['params'] as $param): ?> <li> - <?= Helper\in_list($param['name'], $available_params) ?> = + <?= $this->inList($param['name'], $available_params) ?> = <strong> - <?php if (Helper\contains($param['name'], 'column_id')): ?> - <?= Helper\in_list($param['value'], $columns_list) ?> - <?php elseif (Helper\contains($param['name'], 'user_id')): ?> - <?= Helper\in_list($param['value'], $users_list) ?> - <?php elseif (Helper\contains($param['name'], 'project_id')): ?> - <?= Helper\in_list($param['value'], $projects_list) ?> - <?php elseif (Helper\contains($param['name'], 'color_id')): ?> - <?= Helper\in_list($param['value'], $colors_list) ?> - <?php elseif (Helper\contains($param['name'], 'category_id')): ?> - <?= Helper\in_list($param['value'], $categories_list) ?> - <?php elseif (Helper\contains($param['name'], 'label')): ?> - <?= Helper\escape($param['value']) ?> + <?php if ($this->contains($param['name'], 'column_id')): ?> + <?= $this->inList($param['value'], $columns_list) ?> + <?php elseif ($this->contains($param['name'], 'user_id')): ?> + <?= $this->inList($param['value'], $users_list) ?> + <?php elseif ($this->contains($param['name'], 'project_id')): ?> + <?= $this->inList($param['value'], $projects_list) ?> + <?php elseif ($this->contains($param['name'], 'color_id')): ?> + <?= $this->inList($param['value'], $colors_list) ?> + <?php elseif ($this->contains($param['name'], 'category_id')): ?> + <?= $this->inList($param['value'], $categories_list) ?> + <?php elseif ($this->contains($param['name'], 'label')): ?> + <?= $this->e($param['value']) ?> <?php endif ?> </strong> </li> @@ -42,7 +42,7 @@ </ul> </td> <td> - <?= Helper\a(t('Remove'), 'action', 'confirm', array('project_id' => $project['id'], 'action_id' => $action['id'])) ?> + <?= $this->a(t('Remove'), 'action', 'confirm', array('project_id' => $project['id'], 'action_id' => $action['id'])) ?> </td> </tr> <?php endforeach ?> @@ -51,12 +51,12 @@ <?php endif ?> <h3><?= t('Add an action') ?></h3> -<form method="post" action="<?= Helper\u('action', 'event', array('project_id' => $project['id'])) ?>" class="listing"> - <?= Helper\form_csrf() ?> - <?= Helper\form_hidden('project_id', $values) ?> +<form method="post" action="<?= $this->u('action', 'event', array('project_id' => $project['id'])) ?>" class="listing"> + <?= $this->formCsrf() ?> + <?= $this->formHidden('project_id', $values) ?> - <?= Helper\form_label(t('Action'), 'action_name') ?> - <?= Helper\form_select('action_name', $available_actions, $values) ?><br/> + <?= $this->formLabel(t('Action'), 'action_name') ?> + <?= $this->formSelect('action_name', $available_actions, $values) ?><br/> <div class="form-actions"> <input type="submit" value="<?= t('Next step') ?>" class="btn btn-blue"/> |