summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorMax Kremmel <xing@synapse.plus.com>2005-08-21 16:22:48 +0000
committerMax Kremmel <xing@synapse.plus.com>2005-08-21 16:22:48 +0000
commit7d183a779b42072de4a913029a7daad9f5b30034 (patch)
tree2a21a8105228e1268ab33b0abe061b52b9475f7a /templates
downloadpigeonholes-7d183a779b42072de4a913029a7daad9f5b30034.tar.gz
pigeonholes-7d183a779b42072de4a913029a7daad9f5b30034.tar.bz2
pigeonholes-7d183a779b42072de4a913029a7daad9f5b30034.zip
import pigeonholes - take 2
Diffstat (limited to 'templates')
-rw-r--r--templates/admin_pigeonholes.tpl29
-rw-r--r--templates/assign_non_members.tpl112
-rw-r--r--templates/display_members.tpl54
-rw-r--r--templates/display_paths.tpl9
-rw-r--r--templates/edit_pigeonholes.tpl19
-rw-r--r--templates/edit_pigeonholes_inc.tpl55
-rw-r--r--templates/edit_structure.tpl11
-rw-r--r--templates/list.tpl55
-rw-r--r--templates/menu_pigeonholes.tpl26
-rw-r--r--templates/menu_pigeonholes_admin.tpl1
-rw-r--r--templates/pigeonholes_input_inc.tpl18
-rw-r--r--templates/structure_section_inc.tpl97
-rw-r--r--templates/view_structure.tpl15
-rw-r--r--templates/view_structure_inc.tpl26
14 files changed, 527 insertions, 0 deletions
diff --git a/templates/admin_pigeonholes.tpl b/templates/admin_pigeonholes.tpl
new file mode 100644
index 0000000..b80dfcb
--- /dev/null
+++ b/templates/admin_pigeonholes.tpl
@@ -0,0 +1,29 @@
+{* $Header: /cvsroot/bitweaver/_bit_pigeonholes/templates/admin_pigeonholes.tpl,v 1.1 2005/08/21 16:22:47 squareing Exp $ *}
+{strip}
+{form}
+ {legend legend="Category Settings"}
+ <input type="hidden" name="page" value="{$page}" />
+ {foreach from=$pigeonholeSettings key=feature item=output}
+ <div class="row">
+ {formlabel label=`$output.label` for=$feature}
+ {forminput}
+ {html_checkboxes name="$feature" values="y" checked=`$gBitSystemPrefs.$feature` labels=false id=$feature}
+ {formhelp note=`$output.note` page=`$output.page`}
+ {/forminput}
+ </div>
+ {/foreach}
+
+ <div class="row">
+ {formlabel label="Number of Members" for="member_number"}
+ {forminput}
+ {html_options name="limit_member_number" options=$memberLimit values=$memberLimit selected=`$gBitSystemPrefs.limit_member_number` id=member_number}
+ {formhelp note="Here you can specify what number of members are displayed at the bottom of a page."}
+ {/forminput}
+ </div>
+
+ <div class="row submit">
+ <input type="submit" name="pigeonhole_settings" value="{tr}Change preferences{/tr}" />
+ </div>
+ {/legend}
+{/form}
+{/strip}
diff --git a/templates/assign_non_members.tpl b/templates/assign_non_members.tpl
new file mode 100644
index 0000000..31437dc
--- /dev/null
+++ b/templates/assign_non_members.tpl
@@ -0,0 +1,112 @@
+{strip}
+<div class="edit pigeonholes">
+ <div class="header">
+ <h1>{tr}Assign Content to Categories{/tr}</h1>
+ </div>
+
+ <div class="body">
+ {if !$pigeonList}
+ {formfeedback warning="No categories have been set up yet. You need to create some before you can assign content to them."}
+ {else}
+ {form legend="Assign Content"}
+ <input type="hidden" name="sort_mode" value="{$smarty.request.sort_mode}" />
+ <div class="row">
+ {formlabel label="Restrict listing" for="content_type"}
+
+ {forminput}
+ <select name="max_rows">
+ <option>{tr}All{/tr}</option>
+ <option value="50" {if $smarty.request.max_rows eq 50}selected="selected"{/if}>{tr}50{/tr}</option>
+ <option value="100" {if $smarty.request.max_rows eq 100 or !$smarty.request.max_rows}selected="selected"{/if}>{tr}100{/tr}</option>
+ <option value="200" {if $smarty.request.max_rows eq 200}selected="selected"{/if}>{tr}200{/tr}</option>
+ <option value="500" {if $smarty.request.max_rows eq 500}selected="selected"{/if}>{tr}500{/tr}</option>
+ </select> {tr}Records{/tr}
+ {/forminput}
+
+ {forminput}
+ <select name="include">
+ <option value="">{tr}Hide assigned content{/tr}</option>
+ <option value="members" {if $smarty.request.include eq 'members'}selected="selected"{/if}>{tr}Display assigned content{/tr}</option>
+ </select>
+ {/forminput}
+
+ {forminput}
+ {html_options values=$contentTypes options=$contentTypes name=content_type id=content_type selected=$contentSelect}
+ {/forminput}
+
+ {forminput}
+ <input type="text" value="{$smarty.request.find_objects}" name="find_objects" />&nbsp;
+ {formhelp note="You can restrict the content listing to a given content type or apply a filter."}
+ {/forminput}
+ </div>
+
+ <div class="row submit">
+ <input type="submit" value="{tr}Restrict Listing{/tr}" name="search_objects" />
+ </div>
+ {/form}
+
+ {formfeedback hash=$feedback}
+
+ {form}
+ <input type="hidden" name="sort_mode" value="{$smarty.request.sort_mode}" />
+ <input type="hidden" name="include" value="{$smarty.request.include}" />
+ <input type="hidden" name="find_objects" value="{$smarty.request.find_objects}" />
+ <input type="hidden" name="content_type" value="{$contentSelect}" />
+
+ {if $gBitSystem->isFeatureActive( 'custom_member_sorting' ) && $smarty.request.include eq 'members'}
+ {formfeedback warning="Using this insertion method will reset any custom sorting you have done so far."}
+ {/if}
+
+ <table class="data">
+ <caption>{tr}Available Content{/tr} <span class="total">[ {$contentCount} ]</span></caption>
+ <tr>
+ <th>{smartlink ititle="Title" isort=title idefault=1 max_rows=$smarty.request.max_rows content_type=$contentSelect find_objects=$find_objects include=$smarty.request.include page=$page}</th>
+ <th>{smartlink ititle="Content Type" isort=content_type_guid max_rows=$smarty.request.max_rows content_type=$contentSelect find_objects=$find_objects include=$smarty.request.include page=$page}</th>
+ {if $nonMembers}
+ {foreach from=$pigeonList item=pigeon}
+ <th><abbr title="{$pigeon.title}">{counter}</abbr></th>
+ {/foreach}
+ {/if}
+ </tr>
+
+ {foreach from=$nonMembers item=item}
+ <tr class="{cycle values='odd,even'}">
+ <td><a href="{$smarty.const.BIT_ROOT_URL}index.php?content_id={$item.content_id}">{$item.title}</a></td>
+ <td>{assign var=content_type_guid value=`$item.content_type_guid`}{$contentTypes.$content_type_guid}</td>
+ {foreach from=$pigeonList item=pigeon}
+ <td style="text-align:center">
+ <input type="checkbox" name="pigeonhole[{$item.content_id}][]" value="{$pigeon.content_id}"
+ {foreach from=$item.assigned item=parent_id}
+ {if $pigeon.content_id eq $parent_id}checked="checked"{/if}
+ {/foreach}
+ title="{$pigeon.title}" />
+ </td>
+ {/foreach}
+ </tr>
+ {foreachelse}
+ <tr>
+ <td colspan="2" class="norecords">{tr}No Content can be found with your selection criteria{/tr}</td>
+ </tr>
+ {/foreach}
+ </table>
+
+ {if $nonMembers}
+ <div class="row submit">
+ <input type="submit" name="insert_content" value="Insert Content into Categories" />
+ </div>
+ {/if}
+ {/form}
+
+ {if $nonMembers}
+ {foreach from=$pigeonList item=pigeon}
+ <dl>
+ <dt>{counter name=dogEatsPigeon}</dt>
+ <dd>{$pigeon.display_path}<br /><small>{$pigeon.data|escape}</small></dd>
+ </dl>
+ {/foreach}
+ {/if}
+ {/if}
+ </div><!-- end .body -->
+</div><!-- end .liberty -->
+{/strip}
+
diff --git a/templates/display_members.tpl b/templates/display_members.tpl
new file mode 100644
index 0000000..b34d290
--- /dev/null
+++ b/templates/display_members.tpl
@@ -0,0 +1,54 @@
+{strip}
+<div class="display pigeonholes">
+ {if $gBitSystem->isFeatureActive( 'display_pigeonhole_members' ) and $pigeonData}
+ <h2>{tr}Related Items{/tr}</h2>
+ {foreach from=$pigeonData item=pigeonItem}
+ <div class="box">
+ <h3>{$pigeonItem.display_path}</h3>
+
+ <div class="boxcontent">
+ {if $pigeonItem.data and $gBitSystem->isFeatureActive( 'display_pigeonhole_description' )}
+ {$pigeonItem.data}<br />
+ {/if}
+
+ {* reset vars *}
+ {counter start=0 assign=member_count}
+ {assign var=more value=0}
+
+ {if $gBitSystem->isFeatureActive( 'custom_member_sorting' )}
+ {foreach from=$pigeonItem.members item=member}
+ {if !$gBitSystemPrefs.limit_member_number or $member_count lt $gBitSystemPrefs.limit_member_number}
+ <a href="{$smarty.const.BIT_ROOT_URL}index.php?content_id={$member.content_id}">{$member.title}</a> &bull;&nbsp;
+ {else}
+ {assign var=more value=1}
+ {/if}
+ {counter assign=member_count}
+ {/foreach}
+ {else}
+ {foreach from=$pigeonItem.members item=member}
+ {assign var=ctg1 value=$member.content_type_guid}
+
+ {if $ctg1 ne $ctg2}{if $ctg2}<br />{/if}{$gLibertySystem->mContentTypes.$ctg1.content_description}: {/if}
+
+ {if !$gBitSystemPrefs.limit_member_number or $member_count lt $gBitSystemPrefs.limit_member_number}
+ <a href="{$smarty.const.BIT_ROOT_URL}index.php?content_id={$member.content_id}">{$member.title}</a> &bull;&nbsp;
+ {else}
+ {assign var=more value=1}
+ {/if}
+
+ {counter assign=member_count}
+ {assign var=ctg2 value=$member.content_type_guid}
+ {/foreach}
+ {/if}
+
+ {if $more eq 1}
+ <a href="{$smarty.const.PIGEONHOLES_PKG_URL}view.php?structure_id={$pigeonItem.structure_id}">[ &hellip; ]</a>
+ {/if}
+ </div>
+ </div>
+ {* reset the ctg2 value *}
+ {assign var=ctg2 value=''}
+ {/foreach}
+ {/if}
+</div>
+{/strip}
diff --git a/templates/display_paths.tpl b/templates/display_paths.tpl
new file mode 100644
index 0000000..eed90a5
--- /dev/null
+++ b/templates/display_paths.tpl
@@ -0,0 +1,9 @@
+{strip}
+{if $gBitSystem->isFeatureActive( 'display_pigeonhole_path' )}
+ <div class="structurebar pigeonholesbar">
+ {foreach from=$pigeonData item=pigeonItem}
+ <span class="path">{$pigeonItem.display_path}</span>
+ {/foreach}
+ </div><!-- end .structurebar -->
+{/if}
+{/strip}
diff --git a/templates/edit_pigeonholes.tpl b/templates/edit_pigeonholes.tpl
new file mode 100644
index 0000000..ed2f2a2
--- /dev/null
+++ b/templates/edit_pigeonholes.tpl
@@ -0,0 +1,19 @@
+<div class="floaticon">{bithelp}</div>
+
+<div class="edit pigeonholes">
+ <div class="header">
+ <h1>{tr}Edit Categories{/tr}</h1>
+ </div>
+
+ <div class="body">
+ {formfeedback hash=$feedback}
+ {if $gBitUser->hasPermission( 'bit_p_edit_pigeonholes' ) and ( $smarty.request.action eq 'create' or $smarty.request.action eq 'edit' or !$gPigeonholes->mContentId )}
+ {include file="bitpackage:pigeonholes/edit_pigeonholes_inc.tpl"}
+ {elseif $gBitUser->hasPermission( 'bit_p_edit_pigeonholes' )}
+ {smartlink ititle="Insert new Category" ifile="edit_pigeonholes.php" structure_id=`$gPigeonholes->mStructureId` action=create}
+ <br />
+ {/if}
+
+ {include file="bitpackage:pigeonholes/view_structure_inc.tpl" edit=true}
+ </div><!-- end .body -->
+</div><!-- end .edit -->
diff --git a/templates/edit_pigeonholes_inc.tpl b/templates/edit_pigeonholes_inc.tpl
new file mode 100644
index 0000000..db2ce32
--- /dev/null
+++ b/templates/edit_pigeonholes_inc.tpl
@@ -0,0 +1,55 @@
+{form legend="Create / Edit Category"}
+ {if $gPigeonholes->mStructureId}
+ <input type="hidden" name="structure_id" value="{$gPigeonholes->mStructureId}" />
+ <input type="hidden" name="content_id" value="{$pigeonInfo.content_id}" />
+ <input type="hidden" name="action" value="{$smarty.request.action}" />
+
+ <div class="row">
+ {formlabel label="Parent" for="pigeonhole-parent"}
+ {forminput}
+ {* we need to disable dropdown when editing since it might confus users when nothing happens *}
+ {if $pigeonInfo.content_id}
+ {html_options id="pigeonhole-parent" name="pigeonhole[parent_id]" values=$pigeonStructure options=$pigeonStructure selected=$pigeonInfo.parent_id disabled=disabled}
+ {else}
+ {html_options id="pigeonhole-parent" name="pigeonhole[parent_id]" values=$pigeonStructure options=$pigeonStructure selected=$pigeonInfo.parent_id}
+ {/if}
+ {formhelp note="Pick where you would like to create a new sub-category. To change the hierarchy of the categories, please visit the change structure page."}
+ {/forminput}
+ </div>
+ {/if}
+
+ <div class="row">
+ {formlabel label="Title" for="pigeonhole-title"}
+ {forminput}
+ <input type="text" size="50" id="pigeonhole-title" name="pigeonhole[title]" value="{$pigeonInfo.title}" />
+ {/forminput}
+ </div>
+
+ <div class="row">
+ {formlabel label="Description" for="pigeonhole-desc"}
+ {forminput}
+ <textarea id="pigeonhole-desc" name="pigeonhole[edit]" rows="3" cols="80">{$pigeonInfo.data|escape}</textarea>
+ {formhelp note="A description of the category. This will be visible when users view this particular category."}
+ {/forminput}
+ </div>
+
+ <div class="row">
+ {formlabel label="Content" for="pigeonhole-content"}
+ {forminput}
+ {html_options values=$contentTypes options=$contentTypes name=content_type_guid selected=$contentSelect}
+ {/forminput}
+
+ {forminput}
+ {html_options multiple="multiple" size="12" name="pigeonhole[members][]" id="pigeonhole-content" values=$contentList options=$contentList selected=$pigeonInfo.selected_members}
+ {/forminput}
+
+ {forminput}
+ <input type="text" name="find_objects" value="{$smarty.request.find_objects}" />
+ <input type="submit" value="{tr}Apply filter{/tr}" name="search_objects" />
+ {/forminput}
+ </div>
+
+ <div class="row submit">
+ <input type="submit" name="pigeonhole_store" value="{tr}Save Category{/tr}" />
+ </div>
+{/form}
diff --git a/templates/edit_structure.tpl b/templates/edit_structure.tpl
new file mode 100644
index 0000000..196637f
--- /dev/null
+++ b/templates/edit_structure.tpl
@@ -0,0 +1,11 @@
+<div class="floaticon">{bithelp}</div>
+
+<div class="edit pigeonholes">
+ <div class="header">
+ <h1>{tr}Edit Category Hierarchy{/tr}</h1>
+ </div>
+
+ <div class="body">
+ {include file="bitpackage:liberty/edit_structure_inc.tpl" hide_extended=TRUE}
+ </div><!-- end .body -->
+</div><!-- end .edit -->
diff --git a/templates/list.tpl b/templates/list.tpl
new file mode 100644
index 0000000..4ac7f87
--- /dev/null
+++ b/templates/list.tpl
@@ -0,0 +1,55 @@
+{strip}
+<div class="listing pigeonholes">
+ <div class="header">
+ <h1>{tr}Categories Listing{/tr}</h1>
+ </div>
+
+ {* user sort related assigning *}
+ {if $gBitSystem->isFeatureActive( 'display_name' ) eq login}
+ {assign var=isort_author value=creator_user}
+ {assign var=isort_editor value=modifier_user}
+ {else}
+ {assign var=isort_author value=creator_real_name}
+ {assign var=isort_editor value=modifier_real_name}
+ {/if}
+
+ <div class="body">
+ {minifind}
+
+ <table class="data">
+ <caption>{tr}Available Categories{/tr} <span class="total">[ {$pigeonCount} ]</span></caption>
+ <tr>
+ <th>{smartlink ititle="Title" isort=title page=$page idefault=1} / {smartlink ititle="Description" isort=data page=$page}</th>
+ <th>{tr}Categories{/tr}</th>
+ {if $gBitUser->hasPermission( 'bit_p_edit_pigeonholes' )}
+ <th>{tr}Actions{/tr}</th>
+ {/if}
+ </tr>
+
+ {foreach from=$pigeonList item=item}
+ <tr class="{cycle values='odd,even'}">
+ <td>
+ <h2>{$item.display_link}</h2>
+ {$item.data}
+ </td>
+ <td>{include file="bitpackage:pigeonholes/view_structure_inc.tpl" plain=true subtree=$item.subtree}</td>
+ {if $gBitUser->hasPermission( 'bit_p_edit_pigeonholes' )}
+ <td class="actionicon">
+ {smartlink ititle="Insert new Category" ifile="edit_pigeonholes.php" ibiticon="liberty/new" structure_id=`$item.structure_id` action=create}
+ {smartlink ititle="Edit Category" ifile="edit_pigeonholes.php" ibiticon="liberty/edit" structure_id=`$item.structure_id`}
+ {smartlink ititle="Change Structure" ifile="edit_structure.php" ibiticon="pigeonholes/organise" structure_id=`$item.structure_id`}
+ {smartlink ititle="Remove Category" ifile="edit_pigeonholes.php" ibiticon="liberty/delete" action="remove" structure_id=`$item.structure_id`}
+ </td>
+ {/if}
+ </tr>
+ {foreachelse}
+ <tr class="norecords">
+ <td colspan="5">{tr}No Records Found{/tr}</td>
+ </tr>
+ {/foreach}
+ </table>
+
+ {libertypagination numPages=$numPages page=$curPage sort_mode=$sort_mode content_type=$contentSelect user_id=$user_id}
+ </div><!-- end .body -->
+</div><!-- end .liberty -->
+{/strip}
diff --git a/templates/menu_pigeonholes.tpl b/templates/menu_pigeonholes.tpl
new file mode 100644
index 0000000..cf96345
--- /dev/null
+++ b/templates/menu_pigeonholes.tpl
@@ -0,0 +1,26 @@
+{strip}
+<ul>
+ {if $gBitUser->hasPermission( 'bit_p_edit_pigeonholes' )}
+ <li><a class="item" href="{$smarty.const.PIGEONHOLES_PKG_URL}edit_pigeonholes.php?action=create">{biticon ipackage=liberty iname=new iexplain="Create Category"} {tr}Create Category{/tr}</a></li>
+ {/if}
+
+ {if $gBitUser->hasPermission( 'bit_p_view_pigeonholes' )}
+ <li><a class="item" href="{$smarty.const.PIGEONHOLES_PKG_URL}list.php">{biticon ipackage=liberty iname=list iexplain="List Categories"} {tr}List Categories{/tr}</a></li>
+ {if $gPigeonholes->mStructureId}
+ <li><a class="item" href="{$smarty.const.PIGEONHOLES_PKG_URL}view.php?structure_id={$gPigeonholes->mStructureId}">{biticon ipackage=liberty iname=spacer iexplain=""} {tr}View Category{/tr}</a></li>
+ {if $gBitUser->hasPermission( 'bit_p_edit_pigeonholes' ) and $gPigeonholes->mStructureId}
+ <li><a class="head" href="{$smarty.const.PIGEONHOLES_PKG_URL}edit_pigeonholes.php?structure_id={$gPigeonholes->mInfo.structure_id}">{biticon ipackage=liberty iname=edit iexplain="Edit Category"} {tr}Edit Category{/tr}</a>
+ <ul>
+ <li><a class="item" href="{$smarty.const.PIGEONHOLES_PKG_URL}edit_pigeonholes.php?structure_id={$gPigeonholes->mInfo.root_structure_id}&amp;action=create">{biticon ipackage=liberty iname=new iexplain="Insert Category"} {tr}Insert Category{/tr}</a></li>
+ <li><a class="item" href="{$smarty.const.PIGEONHOLES_PKG_URL}edit_structure.php?structure_id={$gPigeonholes->mInfo.structure_id}">{biticon ipackage=pigeonholes iname=organise iexplain="Change Structure"} {tr}Change Structure{/tr}</a></li>
+ </ul>
+ </li>
+ {/if}
+ {/if}
+ {/if}
+
+ {if $gBitUser->hasPermission( 'bit_p_insert_pigeonholes' )}
+ <li><a class="item" href="{$smarty.const.PIGEONHOLES_PKG_URL}assign_non_members.php">{biticon ipackage=liberty iname=assign iexplain="Assign Content"} {tr}Assign Content{/tr}</a></li>
+ {/if}
+</ul>
+{/strip}
diff --git a/templates/menu_pigeonholes_admin.tpl b/templates/menu_pigeonholes_admin.tpl
new file mode 100644
index 0000000..3e62101
--- /dev/null
+++ b/templates/menu_pigeonholes_admin.tpl
@@ -0,0 +1 @@
+<ul><li>{smartlink ititle="Pigeonhole Settings" ipackage="kernel" ifile="admin/index.php" page="pigeonholes"}</li></ul>
diff --git a/templates/pigeonholes_input_inc.tpl b/templates/pigeonholes_input_inc.tpl
new file mode 100644
index 0000000..2172113
--- /dev/null
+++ b/templates/pigeonholes_input_inc.tpl
@@ -0,0 +1,18 @@
+{strip}
+{if $pigeonPathList}
+ <div class="row">
+ {formlabel label="Pick Categories"}
+ {forminput}
+ {foreach from=$pigeonPathList key=pigeonId item=path}
+ <label>
+ <input type="checkbox" value="{$pigeonId}" {if $path.0.selected}checked="checked" {/if}name="pigeonholes[pigeonhole][]" />
+ {foreach from=$path item=node}
+ {if $node.parent_id} &raquo;{/if} {$node.title}
+ {/foreach}
+ <br />
+ </label>
+ {/foreach}
+ {/forminput}
+ </div>
+{/if}
+{/strip}
diff --git a/templates/structure_section_inc.tpl b/templates/structure_section_inc.tpl
new file mode 100644
index 0000000..d60f6a9
--- /dev/null
+++ b/templates/structure_section_inc.tpl
@@ -0,0 +1,97 @@
+{strip}
+{if $gPigeonholes->mStructureId eq $subtree[ix].structure_id or $smarty.request.expand_all}
+ {assign var=iname value=Expanded}
+{else}
+ {assign var=iname value=Collapsed}
+{/if}
+
+<div class="highlight">
+ {if $edit}
+ <div class="floaticon">
+ {smartlink ititle="Edit Category" ibiticon="liberty/edit" ifile="edit_pigeonholes.php" structure_id=$subtree[ix].structure_id action=edit}
+ {smartlink ititle="Remove Category" ibiticon="liberty/delete" ifile="edit_pigeonholes.php" structure_id=$subtree[ix].structure_id action=remove}
+ </div>
+ {/if}
+
+ <a href="javascript:icntoggle('sid{$subtree[ix].structure_id}');">
+ {biticon ipackage=liberty iname=$iname id=sid`$subtree[ix].structure_id`img"} {$subtree[ix].title}
+ </a> &nbsp;
+
+ <script type="text/javascript">
+ setfoldericonstate('sid{$subtree[ix].structure_id}');
+ </script>
+
+ {foreach from=$pigeonList item=pigeonItem}
+ {if $pigeonItem.structure_id eq $subtree[ix].structure_id}
+ <small> {tr}{$pigeonItem.members_count} Item(s){/tr} </small>
+ {/if}
+ {/foreach}
+
+ <noscript>
+ <div style="padding-left:18px;" class="small"><a href="{$smarty.const.PIGEONHOLES_PKG_URL}{if $edit}edit_pigeonholes{else}index{/if}.php?structure_id={$subtree[ix].structure_id}">{tr}Expand{/tr}</a></div>
+ </noscript>
+</div>
+
+{foreach from=$pigeonList item=pigeonItem}
+ {if $pigeonItem.structure_id eq $subtree[ix].structure_id}
+ <small>{$pigeonItem.data|escape}</small>
+
+ {if $pigeonItem.members}
+ <ul id="sid{$subtree[ix].structure_id}" style="display:{if $gPigeonholes->mStructureId eq $subtree[ix].structure_id or $smarty.request.expand_all}block{else}none{/if};" class="data">
+ {foreach from=$pigeonItem.members item=pigeonMember}
+ {if $gBitSystem->isFeatureActive( 'custom_member_sorting' )}
+ <li>
+ {if $edit && $gBitSystem->isFeatureActive( 'custom_member_sorting' )}
+ {if $pigeonMember.pos ne 1}
+ {smartlink ititle="Move item up" ibiticon="liberty/nav_up" expand_all=$smarty.request.expand_all ifile="edit_pigeonholes.php" action=move orientation=north structure_id=$pigeonItem.structure_id parent_id=$pigeonItem.content_id member_id=$pigeonMember.content_id}
+ {else}
+ {biticon ipackage="liberty" iname="spacer"}
+ {/if}
+
+ {if $pigeonMember.pos ne $pigeonItem.members_count}
+ {smartlink ititle="Move item down" ibiticon="liberty/nav_down" expand_all=$smarty.request.expand_all ifile="edit_pigeonholes.php" action=move orientation=south structure_id=$pigeonItem.structure_id parent_id=$pigeonItem.content_id member_id=$pigeonMember.content_id}
+ {else}
+ {biticon ipackage="liberty" iname="spacer"}
+ {/if}
+ {/if}
+ &nbsp; <a href="{$smarty.const.BIT_ROOT_URL}index.php?content_id={$pigeonMember.content_id}">{$pigeonMember.title}</a> &nbsp;
+ {if $edit}
+ {smartlink ititle="Remove Item" ibiticon="liberty/delete_small" expand_all=$smarty.request.expand_all ifile="edit_pigeonholes.php" action=demember structure_id=$pigeonItem.structure_id parent_id=$pigeonMember.content_id content_id=$pigeonItem.content_id}
+ {/if}
+ </li>
+ {else}
+ {assign var=ctg1 value=$pigeonMember.content_type_guid}
+
+ {* close off the content type <ul> *}
+ {if $ctg1 ne $ctg2 and $ctg2}
+ </ul>
+ </li>
+ {/if}
+
+ {* open the content type <ul> *}
+ {if $ctg1 ne $ctg2}
+ <li>{$gLibertySystem->mContentTypes.$ctg1.content_description}
+ <ul>
+ {/if}
+
+ <li>
+ <a href="{$smarty.const.BIT_ROOT_URL}index.php?content_id={$pigeonMember.content_id}">{$pigeonMember.title}</a>
+ {if $edit}
+ &nbsp; {smartlink ititle="Remove Item" ibiticon="liberty/delete_small" expand_all=$smarty.request.expand_all ifile="edit_pigeonholes.php" action=demember structure_id=$pigeonItem.structure_id parent_id=$pigeonMember.content_id content_id=$pigeonItem.content_id}
+ {/if}
+ </li>
+
+ {assign var=ctg2 value=$pigeonMember.content_type_guid}
+ {/if}
+ {/foreach}
+
+ {* close any open uls and lis *}
+ {if !$gBitSystem->isFeatureActive( 'custom_member_sorting' )}
+ </ul>
+ </li>
+ {/if}
+ </ul>
+ {/if}
+ {/if}
+{/foreach}
+{/strip}
diff --git a/templates/view_structure.tpl b/templates/view_structure.tpl
new file mode 100644
index 0000000..a53a3fb
--- /dev/null
+++ b/templates/view_structure.tpl
@@ -0,0 +1,15 @@
+{strip}
+<div class="display pigeonholes">
+ <div class="header">
+ <h1>{tr}Categories Listing{/tr}</h1>
+ </div>
+
+ <div class="body">
+ {if !$smarty.request.expand_all and !( $smarty.request.action eq 'edit' or $smarty.request.action eq 'create' )}
+ {smartlink ititle="Expand All" expand_all=1 structure_id=$gPigeonholes->mStructureId}
+ {/if}
+
+ {include file="bitpackage:pigeonholes/view_structure_inc.tpl"}
+ </div><!-- end .body -->
+</div><!-- end .liberty -->
+{/strip}
diff --git a/templates/view_structure_inc.tpl b/templates/view_structure_inc.tpl
new file mode 100644
index 0000000..164685a
--- /dev/null
+++ b/templates/view_structure_inc.tpl
@@ -0,0 +1,26 @@
+{strip}
+<ul class="toc">
+ <li>
+ {section name=ix loop=$subtree}
+ {assign var=structId value=$subtree[ix].structure_id}
+ {if $subtree[ix].pos eq ''}
+ {if $plain}
+ {$subtree[ix].title}
+ {else}
+ {include file="bitpackage:pigeonholes/structure_section_inc.tpl"}
+ {/if}
+ {else}
+ {if $subtree[ix].first}<ul>{else}</li>{/if}
+ {if $subtree[ix].last}</ul>{else}
+ <li>
+ {if $plain}
+ {$subtree[ix].title}
+ {else}
+ {include file="bitpackage:pigeonholes/structure_section_inc.tpl"}
+ {/if}
+ {/if}
+ {/if}
+ {/section}
+ </li>
+</ul><!-- end outermost .toc -->
+{/strip}