2014-01-23 14:00:36 +00:00
{assign var=requiredFields value=$cbcollection->load_required_fields($data)}
{assign var=otherFields value=$cbcollection->load_other_fields($data)}
< form action = "" method = "post" enctype = "multipart/form-data" name = "edit_collection" id = "edit_collection" >
< div class = "row" >
< div class = "lead dropdown" > Editing {$data.collection_name}
< a class = "btn btn-primary btn-sm dropdown-toggle pull-right" data-toggle = "dropdown" href = "" > Actions < i class = "caret" > < / i > < / a >
< ul class = "dropdown-menu pull-right" role = "menu" aria-labelledby = "dropdownMenu1" >
{if $data.active!='yes'}
< li role = "presentation" > < a role = "menuitem" tabindex = "-1" href = "edit_collection.php?collection={$data.collection_id}&mode=ac" > Activate< / a > < / li >
{else}
< li role = "presentation" > < a role = "menuitem" tabindex = "-1" href = "edit_collection.php?collection={$data.collection_id}&mode=dac" > Deactivate< / a > < / li >
{/if}
{if $data.featured!='yes'}
< li role = "presentation" > < a role = "menuitem" tabindex = "-1" href = "edit_collection.php?collection={$data.collection_id}&mode=mcf" > Make Featured< / a > < / li >
{else}
< li role = "presentation" > < a role = "menuitem" tabindex = "-1" href = "edit_collection.php?collection={$data.collection_id}&mode=mcuf" > Make Unfeatured< / a > < / li >
{/if}
2014-02-12 13:10:18 +00:00
< li role = "presentation" > < a role = "menuitem" tabindex = "-1" href = "javascript:void(0)" onClick = "javascript:_cb.Confirm_Delete('collection_manager.php?delete_collection={$data.collection_id}')" > Delete This Collection< / a >
2014-01-23 14:00:36 +00:00
< / ul >
< / div >
< div class = "col-sm-6 col-md-6 col-lg-6 col x1-12" >
< input class = "form-control" name = "admin" type = "hidden" id = "admin" value = "true" / >
< input name = "collection_id" type = "hidden" value = "{$data.collection_id}" / >
2014-03-04 10:20:04 +00:00
< div class = "tabbable" >
< ul class = "nav nav-tabs" id = "myTab" >
< li class = "active" >
< a data-toggle = "tab" href = "#cldetails" >
Collection Details
< / a >
< / li >
< li class = "" >
< a data-toggle = "tab" href = "#uinformation" >
< i class = "glyphicon glyphicon-user" > < / i >
Uploader Information
< / a >
< / li >
< / ul >
< div class = "tab-content" >
< div id = "cldetails" class = "tab-pane active" >
< div class = "table-responsive" >
< legend > Collection Details< / legend >
< table class = "table-bordered" >
< tr >
< td class = "alert-info ecollection" > < label for = "collecionID" > Collection ID< / label > < / td >
< td class = "ecollection1" > < input disabled = "disabled" class = "form-control" name = "collecionID" type = "text" id = "collecionID" value = "{$data.collection_id}" / >
< / td >
< / tr >
< / table >
< / div >
{foreach from=$requiredFields item=field}
{$field.class='form-control'}
{if $field.title=='Collection name'}
< table >
< tr >
< td class = "alert-info ecollection" > {$field.title}< / td >
< td class = "ecollection1" > {$formObj->createField($field)}< / td >
< / tr >
{/if}
{/foreach}
{foreach from=$requiredFields item=field}
{if $field.title=='Collection description'}
{$field.class='form-control'}
< tr >
< td class = "alert-info ecollection" > {$field.title}< / td >
< td class = "ecollection1" > {$formObj->createField($field)}< / td >
< / tr >
{/if}
{/foreach}
{foreach from=$requiredFields item=field}
{if $field.title=='Collection tags'}
{$field.class='form-control'}
< tr >
< td class = "alert-info ecollection" > {$field.title}< / td >
< td class = "ecollection1" > {$formObj->createField($field)}< / td >
< / tr >
{/if}
{/foreach}
{foreach from=$requiredFields item=field}
{if $field.title=='Collection type'}
{$field.class='form-control'}
< tr >
< td class = "alert-info ecollection" > {$field.title}< / td >
< td class = "ecollection1" > {$formObj->createField($field)}< / td >
< / tr >
{/if}
{/foreach}
< / table >
< hr >
{foreach from=$requiredFields item=field}
{if $field.title=='Collection category'}
< label > {$field.title}< / label >
< div class = "tab-content scroll" >
{$formObj->createField($field)}
< / div >
{/if}
{/foreach}
< / div >
< div id = "uinformation" class = "tab-pane" >
< legend > Uploader Information< / legend >
< div class = "form-group" >
< img src = "{$userquery->getUserThumb($u,'small')}" class = "btn btn-app btn-primary btn-xs" / >
< / div >
< div class = "table-responsive" >
< table class = "table table-bordered" >
< tr >
< td class = "alert-info" > < label class = "alert-info" > User Id< / label > < / td >
< td > < input type = "text" value = "{$data.userid}" disabled = "disabled" class = "form-control" > < / label > < / td >
< / tr >
< tr >
< td class = "alert-info" > < label class = "alert-info" > User Name< / label > < / td >
< td > < input class = "form-control" disabled = "disabled" type = "text" value = "{$data.userid|get_username}" > < / td >
< / tr >
< tr >
< td class = "alert-info" > < label class = "alert-info" > DOB< / label > < / td >
< td > < input class = "form-control" disabled = "disabled" type = "text" value = "{$data.dob}" > < / td >
< / tr >
< tr >
< td class = "alert-info" > < label class = "alert-info" > Email< / label > < / td >
< td > < input class = "form-control" disabled = "disabled" type = "text" value = "{$data.email}" > < / td >
< / tr >
< tr >
< td class = "alert-info" > < label class = "alert-info" > Gender< / label > < / td >
< td > < input class = "form-control" disabled = "disabled" type = "text" value = "{$data.sex}" > < / td >
< / tr >
< tr >
< td class = "alert-info" > < label class = "alert-info" > Rating< / label > < / td >
< td > < input class = "form-control" disabled = "disabled" type = "text" value = "{$data.rating}" > < / td >
< / tr >
< / table >
< / div >
< / div >
< / div >
< br >
< div class = "row" >
< legend > Collection Stats< / legend >
< div class = "col-md-6" >
2014-01-23 14:00:36 +00:00
< label for = "total_objects" > Total Objects< / label >
< input class = "form-control" name = "total_objects" type = "text" id = "total_objects" value = "{$data.total_objects}" / >
< / div >
2014-03-04 10:20:04 +00:00
< div class = "col-md-6" >
2014-01-23 14:00:36 +00:00
< label for = "total_comments" > Total Comments< / label >
< input name = "total_comments" class = "form-control" type = "text" id = "total_comments" value = "{$data.total_comments}" / >
< / div >
2014-03-04 10:20:04 +00:00
< / div >
2014-01-23 14:00:36 +00:00
< input type = "submit" class = "btn btn-primary" value = "Update Collection Details" style = "margin:15px 0px 0px 15px" name = "update_collection" >
< / div >
2014-03-04 10:20:04 +00:00
< / div >
2014-01-23 14:00:36 +00:00
< div class = "col-sm-6 col-md-6 col-lg-6 col x1-12 pull-right" >
2014-03-04 10:20:04 +00:00
< span class = "btn btn-app btn-sm btn-light no-hover" >
< span class = "line-height-1 bigger-170 blue" > {$data.views|number_format}< / span >
< br >
< span class = "line-height-1 smaller-90" > Views < / span >
< / span >
2014-04-14 13:09:35 +00:00
< span class = "btn btn-app btn-sm btn-yellow no-hover" >
2014-03-04 10:20:04 +00:00
< span class = "line-height-1 bigger-170" > {$data.comments_count} < / span >
< br >
< span class = "line-height-1 smaller-90" > Comments < / span >
< / span >
2014-04-14 13:09:35 +00:00
< span class = "btn btn-app btn-sm btn-pink no-hover" >
< span class = "line-height-1" > {if $data.active=='yes'}< span class = "glyphicon glyphicon-ok" > < / span >
2014-03-04 10:20:04 +00:00
{else}< span class = "glyphicon glyphicon-remove" > {/if}< / span >
< br >
2014-04-14 13:09:35 +00:00
< span class = "line-height-1 smaller-90" > Active< / span >
2014-03-04 10:20:04 +00:00
< / span >
< / span >
< span class = "btn btn-app btn-sm btn-grey no-hover" >
2014-04-14 13:09:35 +00:00
< span class = "line-height-1" > {if $data.featured=='No'}< span class = "glyphicon glyphicon-ok" > < / span >
2014-03-04 10:20:04 +00:00
{else}< span class = "glyphicon glyphicon-remove" > {/if}< / span >
< br >
2014-04-14 13:09:35 +00:00
< span class = "line-height-1 smaller-90" > Featured< / span >
2014-03-04 10:20:04 +00:00
< / span >
< / span >
2014-04-14 13:09:35 +00:00
<!-- <span class="btn btn - app btn - sm btn - pink no - hover"> -->
<!-- <span class="line - height - 1 bigger - 170"> {if $data.active=='yes'}<span class="glyphicon glyphicon - ok"></span> -->
<!-- {else}<span class="glyphicon glyphicon - remove">{/if}</span> -->
<!-- <br> -->
<!-- <span class="line - height - 1 smaller - 90"> Active </span> -->
<!-- </span> -->
<!-- </span> -->
<!-- <span class="btn btn - app btn - sm btn - grey no - hover"> -->
<!-- <span class="line - height - 1 bigger - 170">{if $data.featured=='yes'}<span class="glyphicon glyphicon - ok"></span> -->
<!-- {else}<span class="glyphicon glyphicon - remove">{/if}</span> -->
<!-- <br> -->
<!-- <span class="line - height - 1 smaller - 90"> Featured </span> -->
<!-- </span> -->
<!-- </span> -->
2014-03-04 10:20:04 +00:00
< span class = "btn btn-app btn-sm btn-primary no-hover" >
2014-04-14 13:09:35 +00:00
{section name=list loop=$FlaggedPhotos}
< span class = "line-height-1 bigger-170" > {$FlaggedPhotos[list].total_flags} < / span >
2014-03-04 10:20:04 +00:00
{/section}
< br >
< span class = "line-height-1 smaller-90" > Flagged < / span >
< / span >
2014-04-15 11:45:14 +00:00
2014-04-15 12:34:50 +00:00
<!-- <div class="tabbable"> -->
<!-- <ul class="nav nav - tabs" id="myTab"> -->
<!-- <li class="active"> -->
<!-- <a data - toggle="tab" href="#citems"> Manage Items</a> -->
<!-- </li> -->
<!-- <div class="tab - content"> -->
<!-- <div id="citems" class="tab - pane active"> -->
<!-- {if $objects} -->
<!-- {section name=list loop=$objects} -->
<!-- {if $data.type == 'photos'} -->
<!-- {get_photo details=$objects[list] output='html' title=$photos[list].photo_title} -->
<!-- {/if} -->
<!-- {if $data.type == 'videos'} -->
<!-- <img src="{get_thumb vdetails=$objects[list]}" width="120" height="70" /> -->
<!-- {/if} -->
<!-- {/section} -->
<!-- {assign var=rest value=$data.total_objects - 4} -->
<!-- <a style="display:block; font:bold 11px Tahoma; text - align:center; padding:4px; background:#fafafa;border:1px solid #aaa;" href="manage_items.php?collection={$data.collection_id}&type={$data.type}">Manage Items{if $rest && $rest>0} - {$rest} more item{if $rest>1}s{/if}{/if}</a> -->
<!-- {else} -->
<!-- Collection has 0 items -->
<!-- {/if} -->
2014-04-15 11:45:14 +00:00
2014-04-15 12:34:50 +00:00
<!-- </div> -->
<!-- </div> -->
<!-- </ul> -->
<!-- </div> -->
2014-04-15 11:45:14 +00:00
2014-04-15 12:34:50 +00:00
< div class = "tabbable" style = "margin-top: 20px" >
2014-03-04 10:20:04 +00:00
< ul class = "nav nav-tabs" id = "myTab3" >
< li class = "active" >
< a data-toggle = "tab" href = "#fields" >
Other Fields
< / a >
< / li >
< li >
< a data-toggle = "tab" href = "#clpreview" >
Collection Preview
< / a >
< / li >
2014-04-15 12:34:50 +00:00
< li >
< a data-toggle = "tab" href = "#citems" >
Manage Items
< / a >
< / li >
2014-03-04 10:20:04 +00:00
< / ul >
< div class = "tab-content" >
< div id = "fields" class = "tab-pane in active" >
2014-01-23 14:00:36 +00:00
< legend > Other Fields< / legend >
< div class = "form-group" >
{foreach from=$otherFields item=field}
2014-03-04 10:20:04 +00:00
< label class = "label label-danger" for = "{$field.id}" > {$field.title} :< / label >
2014-01-23 14:00:36 +00:00
{$field.hint_1}< br / >
{$formObj->createField($field)}< br / >
{$field.hint_2}
{/foreach}
< / div >
2014-03-04 10:20:04 +00:00
< / div >
< div id = "clpreview" class = "tab-pane" >
2014-01-23 14:00:36 +00:00
< legend > Collection Preview< / legend >
< div class = "form-group" >
2014-03-04 10:20:04 +00:00
< label class = "label label-danger" > Collection Preview :< / label >
2014-01-23 14:00:36 +00:00
< img style = "padding:2px; border:1px solid #ccc;" src = "{$cbcollection->get_thumb($data,NULL,TRUE)}" / >
< input class = "forum-control" type = "checkbox" value = "{$data.collection_id}" name = "delete_preview" id = "del_{$data.collection_id}_preview" / > < label for = "del_{$data.collection_id}_preview" > Delete Preview< / label >
< / div >
< div class = "form-group" >
< label for = "collection_thumb" > Upload New :< / label >
< input type = "file" name = "collection_thumb" id = "collection_thumb" >
< / div >
< / div >
2014-04-15 12:34:50 +00:00
< div id = "citems" class = "tab-pane" >
{if $objects}
{section name=list loop=$objects}
{if $data.type == 'photos'}
{get_photo details=$objects[list] output='html' title=$photos[list].photo_title}
{/if}
{if $data.type == 'videos'}
< img src = "{get_thumb vdetails=$objects[list]}" width = "120" height = "70" / >
{/if}
{/section}
{assign var=rest value=$data.total_objects-4}
< a style = "display:block; font:bold 11px Tahoma; text-align:center; padding:4px; background:#fafafa;border:1px solid #aaa;" href = "manage_items.php?collection={$data.collection_id}&type={$data.type}" > Manage Items{if $rest & & $rest>0} - {$rest} more item{if $rest>1}s{/if}{/if}< / a >
{else}
Collection has 0 items
{/if}
< / div >
2014-01-23 14:00:36 +00:00
< / div >
2014-03-04 10:20:04 +00:00
< / div >
< / div >
< / div >
2014-01-23 14:00:36 +00:00
< / form >