Fixing content type ordering when content_type is not defined.
[akelos.git] / lib / utils / generators / scaffold / templates / view_listing.tpl
blob98d44e2538e3710e86e8f6d9db342a6ec02cd9ec
1 <div id="sidebar">
2   <h1>_{Tasks}:</h1>
3   <ul>
4     <li><?php  echo '<?php  echo  '?>$url_helper->link_to($text_helper->translate('Create new <?php  echo AkInflector::humanize($singular_name)?>'), array('action' => 'add'))?></li>
5   </ul> 
6 </div>
8 <div id="content">
9   <h1>_{<?php  echo AkInflector::humanize($plural_name)?>}</h1>
11   {?<?php  echo $plural_name?>}
12   <div class="listing">
13   <table cellspacing="0" summary="_{Listing available <?php  echo AkInflector::humanize($plural_name)?>}">
15   <tr>
16     <?php  echo '<?php  '?>$content_columns = array_keys($<?php  echo $model_name?>->getContentColumns()); ?>
17     {loop content_columns}
18         <th scope="col"><?php  echo '<?php  echo  '?>$pagination_helper->sortable_link($content_column) ?></th>
19     {end}
20     <th colspan="3" scope="col"><span class="auraltext">_{Item actions}</span></th>
21   </tr>
23   {loop <?php  echo $plural_name?>}
24     <tr {?<?php  echo $singular_name?>_odd_position}class="odd"{end}>
25     {loop content_columns}
26       <td class="field"><?php  echo '<?php  echo  '?>$<?php  echo $singular_name?>->get($content_column) ?></td>
27     {end}
28       <td class="operation"><?php  echo '<?php  echo  '.$helper_var_name?>->link_to_show($<?php  echo $singular_name?>)?></td>
29       <td class="operation"><?php  echo '<?php  echo  '.$helper_var_name?>->link_to_edit($<?php  echo $singular_name?>)?></td>
30       <td class="operation"><?php  echo '<?php  echo  '.$helper_var_name?>->link_to_destroy($<?php  echo $singular_name?>)?></td>    
31     </tr>
32   {end}
33    </table>
34   </div>
35   {end}
36   
37     {?<?php  echo $singular_name?>_pages.links}
38         <div id="<?php  echo $model_name?>Pagination">
39         <div id="paginationHeader"><?php  echo '<?php  echo '?>translate('Showing page %page of %number_of_pages',array('%page'=>$<?php  echo $singular_name?>_pages->getCurrentPage(),'%number_of_pages'=>$<?php  echo $singular_name?>_pages->pages))?></div>
40         {<?php  echo $singular_name?>_pages.links?}
41         </div>
42     {end}
43   
44 </div>