aboutsummaryrefslogtreecommitdiffstats
path: root/admin/themes/default/template
diff options
context:
space:
mode:
authormistic100 <mistic@piwigo.org>2014-05-28 19:04:40 +0000
committermistic100 <mistic@piwigo.org>2014-05-28 19:04:40 +0000
commit9a842dd86af254aa5d2212d0e3e4a10961aef492 (patch)
tree5271edfc6826b58b160d59c8d210af4d38247444 /admin/themes/default/template
parent7b3783c9814173d05d5efb216d5b383a4aa2a8fe (diff)
feature 3077 : fix addAlbum process when creating the first ever album, improve data API
git-svn-id: http://piwigo.org/svn/trunk@28555 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'admin/themes/default/template')
-rw-r--r--admin/themes/default/template/batch_manager_global.tpl17
-rw-r--r--admin/themes/default/template/batch_manager_unit.tpl3
-rw-r--r--admin/themes/default/template/cat_perm.tpl6
-rw-r--r--admin/themes/default/template/photos_add_direct.tpl3
-rw-r--r--admin/themes/default/template/picture_modify.tpl14
-rw-r--r--admin/themes/default/template/user_list.tpl3
6 files changed, 25 insertions, 21 deletions
diff --git a/admin/themes/default/template/batch_manager_global.tpl b/admin/themes/default/template/batch_manager_global.tpl
index 00cdc50f3..971fb90fb 100644
--- a/admin/themes/default/template/batch_manager_global.tpl
+++ b/admin/themes/default/template/batch_manager_global.tpl
@@ -98,7 +98,6 @@ jQuery(document).ready(function() {ldelim}
return filtered;
}
else {
- options.default = categories[0].id;
return categories;
}
}
@@ -603,7 +602,7 @@ $(document).ready(function() {
<input type="checkbox" name="filter_category_use" class="useFilterCheckbox" {if isset($filter.category)}checked="checked"{/if}>
{'Album'|@translate}
<select data-selectize="categories" data-value="{$filter_category_selected|@json_encode|escape:html}"
- name="filter_category" style="width:400px"></select>
+ data-default="first" name="filter_category" style="width:400px"></select>
<label><input type="checkbox" name="filter_category_recursive" {if isset($filter.category_recursive)}checked="checked"{/if}> {'include child albums'|@translate}</label>
</li>
@@ -612,6 +611,7 @@ $(document).ready(function() {
<input type="checkbox" name="filter_tags_use" class="useFilterCheckbox" {if isset($filter.tags)}checked="checked"{/if}>
{'Tags'|@translate}
<select data-selectize="tags" data-value="{$filter_tags|@json_encode|escape:html}"
+ placeholder="{'Type in a search term'|translate}"
name="filter_tags[]" multiple style="width:400px;"></select>
<label><span><input type="radio" name="tag_mode" value="AND" {if !isset($filter.tag_mode) or $filter.tag_mode eq 'AND'}checked="checked"{/if}> {'All tags'|@translate}</span></label>
<label><span><input type="radio" name="tag_mode" value="OR" {if isset($filter.tag_mode) and $filter.tag_mode eq 'OR'}checked="checked"{/if}> {'Any tag'|@translate}</span></label>
@@ -811,14 +811,14 @@ UL.thumbnails SPAN.wrap2 {ldelim}
<!-- associate -->
<div id="action_associate" class="bulkAction">
- <select data-selectize="categories" name="associate" style="width:400px"></select>
+ <select data-selectize="categories" data-default="first" name="associate" style="width:400px"></select>
<br>{'... or '|@translate}
<a href="#" data-add-album="associate" title="{'create a new album'|@translate}">{'create a new album'|@translate}</a>
</div>
<!-- move -->
<div id="action_move" class="bulkAction">
- <select data-selectize="categories" name="move" style="width:400px"></select>
+ <select data-selectize="categories" data-default="first" name="move" style="width:400px"></select>
<br>{'... or '|@translate}
<a href="#" data-add-album="move" title="{'create a new album'|@translate}">{'create a new album'|@translate}</a>
</div>
@@ -826,19 +826,22 @@ UL.thumbnails SPAN.wrap2 {ldelim}
<!-- dissociate -->
<div id="action_dissociate" class="bulkAction albumDissociate" style="display:none">
- <select data-selectize="categories" name="dissociate" style="width:400px"></select>
+ <select data-selectize="categories" placeholder="{'Type in a search term'|translate}"
+ name="dissociate" style="width:400px"></select>
</div>
<!-- add_tags -->
<div id="action_add_tags" class="bulkAction">
- <select data-selectize="tags" data-selectize-create name="add_tags[]" multiple style="width:400px;"></select>
+ <select data-selectize="tags" data-create="true" placeholder="{'Type in a search term'|translate}"
+ name="add_tags[]" multiple style="width:400px;"></select>
</div>
<!-- del_tags -->
<div id="action_del_tags" class="bulkAction">
{if !empty($associated_tags)}
- <select data-selectize="tags" name="del_tags[]" multiple style="width:400px;">
+ <select data-selectize="tags" name="del_tags[]" multiple style="width:400px;"
+ placeholder="{'Type in a search term'|translate}">
{foreach from=$associated_tags item=tag}
<option value="{$tag.id}">{$tag.name}</option>
{/foreach}
diff --git a/admin/themes/default/template/batch_manager_unit.tpl b/admin/themes/default/template/batch_manager_unit.tpl
index 27f8cd721..dd7b5aa64 100644
--- a/admin/themes/default/template/batch_manager_unit.tpl
+++ b/admin/themes/default/template/batch_manager_unit.tpl
@@ -98,7 +98,8 @@ $(".elementEdit img")
<td><strong>{'Tags'|@translate}</strong></td>
<td>
<select data-selectize="tags" data-value="{$element.TAGS|@json_encode|escape:html}"
- name="tags-{$element.id}[]" multiple style="width:500px;" data-selectize-create></select>
+ placeholder="{'Type in a search term'|translate}"
+ data-create="true" name="tags-{$element.id}[]" multiple style="width:500px;"></select>
</td>
</tr>
diff --git a/admin/themes/default/template/cat_perm.tpl b/admin/themes/default/template/cat_perm.tpl
index edaab262a..52272e06b 100644
--- a/admin/themes/default/template/cat_perm.tpl
+++ b/admin/themes/default/template/cat_perm.tpl
@@ -72,7 +72,8 @@ jQuery("#selectStatus").change(function() {
<strong>{'Permission granted for groups'|@translate}</strong>
<br>
<select data-selectize="groups" data-value="{$groups_selected|@json_encode|escape:html}"
- name="groups[]" multiple style="width:600px;"></select>
+ placeholder="{'Type in a search term'|translate}"
+ name="groups[]" multiple style="width:600px;"></select>
{else}
{'There is no group in this gallery.'|@translate} <a href="admin.php?page=group_list" class="externalLink">{'Group management'|@translate}</a>
{/if}
@@ -82,7 +83,8 @@ jQuery("#selectStatus").change(function() {
<strong>{'Permission granted for users'|@translate}</strong>
<br>
<select data-selectize="users" data-value="{$users_selected|@json_encode|escape:html}"
- name="users[]" multiple style="width:600px;"></select>
+ placeholder="{'Type in a search term'|translate}"
+ name="users[]" multiple style="width:600px;"></select>
</p>
{if isset($nb_users_granted_indirect) && $nb_users_granted_indirect>0}
diff --git a/admin/themes/default/template/photos_add_direct.tpl b/admin/themes/default/template/photos_add_direct.tpl
index 0a23ca8f0..39eb856cc 100644
--- a/admin/themes/default/template/photos_add_direct.tpl
+++ b/admin/themes/default/template/photos_add_direct.tpl
@@ -27,7 +27,6 @@ categoriesCache.selectize(jQuery('[data-selectize=categories]'), {
filter: function(categories, options) {
if (categories.length > 0) {
jQuery("#albumSelection, .selectFiles, .showFieldset").show();
- options.default = categories[0].id;
}
return categories;
@@ -201,7 +200,7 @@ jQuery(document).ready(function(){
<span id="albumSelection" style="display:none">
<select data-selectize="categories" data-value="{$selected_category|@json_encode|escape:html}"
- name="category" style="width:400px"></select>
+ data-default="first" name="category" style="width:400px"></select>
<br>{'... or '|@translate}</span>
<a href="#" data-add-album="category" title="{'create a new album'|@translate}">{'create a new album'|@translate}</a>
</fieldset>
diff --git a/admin/themes/default/template/picture_modify.tpl b/admin/themes/default/template/picture_modify.tpl
index 60c98140d..21033be92 100644
--- a/admin/themes/default/template/picture_modify.tpl
+++ b/admin/themes/default/template/picture_modify.tpl
@@ -16,12 +16,7 @@ var categoriesCache = new CategoriesCache({
rootUrl: '{$ROOT_URL}'
});
-categoriesCache.selectize(jQuery('[data-selectize=categories]'), { {if $STORAGE_ALBUM}
- filter: function(categories, options) {
- options.default = (this.name == 'associate[]') ? {$STORAGE_ALBUM} : undefined;
- return categories;
- }
-{/if} });
+categoriesCache.selectize(jQuery('[data-selectize=categories]'));
{* <!-- TAGS --> *}
var tagsCache = new TagsCache({
@@ -109,13 +104,15 @@ jQuery(function(){ {* <!-- onLoad needed to wait localization loads --> *}
<strong>{'Linked albums'|@translate}</strong>
<br>
<select data-selectize="categories" data-value="{$associated_albums|@json_encode|escape:html}"
- name="associate[]" multiple style="width:600px;"></select>
+ placeholder="{'Type in a search term'|translate}"
+ data-default="{$STORAGE_ALBUM}" name="associate[]" multiple style="width:600px;"></select>
</p>
<p>
<strong>{'Representation of albums'|@translate}</strong>
<br>
<select data-selectize="categories" data-value="{$represented_albums|@json_encode|escape:html}"
+ placeholder="{'Type in a search term'|translate}"
name="represent[]" multiple style="width:600px;"></select>
</p>
@@ -123,7 +120,8 @@ jQuery(function(){ {* <!-- onLoad needed to wait localization loads --> *}
<strong>{'Tags'|@translate}</strong>
<br>
<select data-selectize="tags" data-value="{$tag_selection|@json_encode|escape:html}"
- name="tags[]" multiple style="width:600px;" data-selectize-create></select>
+ placeholder="{'Type in a search term'|translate}"
+ data-create="true" name="tags[]" multiple style="width:600px;"</select>
</p>
<p>
diff --git a/admin/themes/default/template/user_list.tpl b/admin/themes/default/template/user_list.tpl
index fbbaf873d..e55f2f9e0 100644
--- a/admin/themes/default/template/user_list.tpl
+++ b/admin/themes/default/template/user_list.tpl
@@ -1104,7 +1104,8 @@ span.infos, span.errors {background-image:none; padding:2px 5px; margin:0;border
<div class="userProperty"><label><input type="checkbox" name="enabled_high"<% if (user.enabled_high == 'true') { %> checked="checked"<% } %>> <strong>{'High definition enabled'|translate}</strong></label></div>
<div class="userProperty"><strong>{'Groups'|translate}</strong><br>
- <select data-selectize="groups" name="group_id[]" multiple style="width:340px;"></select>
+ <select data-selectize="groups" placeholder="{'Type in a search term'|translate}"
+ name="group_id[]" multiple style="width:340px;"></select>
</div>
</div>