summaryrefslogtreecommitdiffstats
path: root/data/generator/sfPropelAdmin/mailadmin/template/templates/_list_td_tabular.php
diff options
context:
space:
mode:
Diffstat (limited to 'data/generator/sfPropelAdmin/mailadmin/template/templates/_list_td_tabular.php')
-rw-r--r--data/generator/sfPropelAdmin/mailadmin/template/templates/_list_td_tabular.php30
1 files changed, 30 insertions, 0 deletions
diff --git a/data/generator/sfPropelAdmin/mailadmin/template/templates/_list_td_tabular.php b/data/generator/sfPropelAdmin/mailadmin/template/templates/_list_td_tabular.php
new file mode 100644
index 0000000..e4e50bb
--- /dev/null
+++ b/data/generator/sfPropelAdmin/mailadmin/template/templates/_list_td_tabular.php
@@ -0,0 +1,30 @@
+<?php $hs = $this->getParameterValue('list.hide', array()) ?>
+<?php foreach ($this->getColumns('list.display') as $column): ?>
+<?php if (in_array($column->getName(), $hs)) continue ?>
+<?php $credentials = $this->getParameterValue('list.fields.'.$column->getName().'.credentials') ?>
+<?php if ($credentials): $credentials = str_replace("\n", ' ', var_export($credentials, true)) ?>
+ [?php if ($sf_user->hasCredential(<?php echo $credentials ?>)): ?]
+<?php endif; ?>
+ <?php
+ $user_params = $this->getParameterValue('list.fields.'.$column->getName().'.params');
+ $user_params = is_array($user_params) ? sfToolkit::stringToArray($user_params) : $user_params;
+ ?>
+ <?php if ($column->isLink()): ?>
+
+ <?php $editcredentials = $this->getParameterValue('list.object_actions.edit.credentials'); ?>
+ <?php if($editcredentials): $editcredentials = str_replace("\n", ' ', var_export($editcredentials, true)); ?>
+ [?php if ($sf_user->hasCredential(<?php echo $editcredentials ?>)): ?]
+ <?php endif; ?>
+ [?php echo tag('td', <?php echo var_export($user_params, true) ?>, true) ?][?php echo link_to(<?php echo $this->getColumnListTag($column) ?> ? <?php echo $this->getColumnListTag($column) ?> : __('-'), '<?php echo $this->getModuleName() ?>/edit?<?php echo $this->getPrimaryKeyUrlParams() ?>) ?]</td>
+<?php if ($editcredentials): ?>
+ [?php else: ?]
+ [?php echo tag('td', <?php echo var_export($user_params, true) ?>, true) ?][?php echo <?php echo $this->getColumnListTag($column) ?> ?]</td>
+ [?php endif; ?]
+<?php endif; ?>
+<?php else: ?>
+ [?php echo tag('td', <?php echo var_export($user_params, true) ?>, true) ?][?php echo <?php echo $this->getColumnListTag($column) ?> ?]</td>
+ <?php endif; ?>
+<?php if ($credentials): ?>
+ [?php endif; ?]
+<?php endif; ?>
+<?php endforeach; ?>