summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Kremmel <xing@synapse.plus.com>2007-08-23 07:28:43 +0000
committerMax Kremmel <xing@synapse.plus.com>2007-08-23 07:28:43 +0000
commitb45c4c328e70c800061cbbdcd08ff625cee99b59 (patch)
tree9e5ad8e6ce71e620e615eb02b4d98a04fd5b64a3
parent56bd80ff83bfa32cdff3752aa926f7fbb2cd1f52 (diff)
downloadpigeonholes-b45c4c328e70c800061cbbdcd08ff625cee99b59.tar.gz
pigeonholes-b45c4c328e70c800061cbbdcd08ff625cee99b59.tar.bz2
pigeonholes-b45c4c328e70c800061cbbdcd08ff625cee99b59.zip
remove duplicate code
-rw-r--r--templates/service_edit_tab_inc.tpl46
1 files changed, 7 insertions, 39 deletions
diff --git a/templates/service_edit_tab_inc.tpl b/templates/service_edit_tab_inc.tpl
index 465d939..5e63383 100644
--- a/templates/service_edit_tab_inc.tpl
+++ b/templates/service_edit_tab_inc.tpl
@@ -1,41 +1,9 @@
{strip}
-{jstab title="Categorize"}
- {legend legend="Categorize"}
- <div class="row">
- {formlabel label="Pick Categories" for="pigeonholes"}
- {if $pigeonPathList|@count ne 0}
- {forminput}
- {if $pigeonPathList|@count < $gBitSystem->getConfig( 'pigeonholes_scrolling_list_number' )}
- {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|escape}
- {/foreach}
- <br />
- </label>
- {/foreach}
- {else}
- <select name="pigeonholes[pigeonhole][]" id="pigeonholes" multiple="multiple" size="5">
- {foreach from=$pigeonPathList key=pigeonId item=path}
- <option value="{$pigeonId}" {if $path.0.selected}selected="selected"{/if}>
- {foreach from=$path item=node}
- {if $node.parent_id} &raquo;{/if} {$node.title|escape}
- {/foreach}
- </option>
- {/foreach}
- </select>
- {/if}
- {/forminput}
- {else}
- {forminput}
- <p>{tr}There are no categories available at the moment.{/tr}</p>
- {if $gBitUser->isAdmin()}
- {smartlink ititle="Create Category" ipackage="pigeonholes" ifile="edit_pigeonholes.php"}
- {/if}
- {/forminput}
- {/if}
- </div>
- {/legend}
-{/jstab}
+{if $gBitUser->hasPermission( 'p_pigeonholes_insert_member' )}
+ {jstab title="Categorize"}
+ {legend legend="Categorize"}
+ {include file="bitpackage:pigeonholes/service_edit_mini_inc.tpl"}
+ {/legend}
+ {/jstab}
+{/if}
{/strip}