Bug 13351 - Untranslatable javascript in members.tt
This patch streamlines the page title text for search results in Home > Patrons to make it translateable (and more readable). To test: - Apply patch - Select Englsh language - Apply filter wit several values or click on a letter for "Browse by last name" - Verify that the title makes sense - Translate to your language and select this language - Verify that the text appears properly in your language Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Works as described, no problems found. http://bugs.koha-community.org/show_bug.cgi?id=13352 Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This commit is contained in:
parent
1858f90bc2
commit
6004b2492b
1 changed files with 6 additions and 7 deletions
|
@ -221,26 +221,25 @@ $(document).ready(function() {
|
|||
|
||||
// Update the string "Results found ..."
|
||||
function update_searched(){
|
||||
var searched = "";
|
||||
searched += "on " + $("#searchfieldstype_filter").find("option:selected").text().toLowerCase() + " fields";
|
||||
var searched = $("#searchfieldstype_filter").find("option:selected").text();
|
||||
if ( $("#searchmember_filter").val() ) {
|
||||
if ( $("#searchtype_filter").val() == 'start_with' ) {
|
||||
searched += _(" starting with ");
|
||||
} else {
|
||||
searched += _(" containing ");
|
||||
}
|
||||
searched += $("#searchmember_filter").val();
|
||||
searched += "'" + $("#searchmember_filter").val() + "'";
|
||||
}
|
||||
if ( $("#firstletter_filter").val() ) {
|
||||
searched += _(" begin with ") + $("#firstletter_filter").val();
|
||||
searched += _(" begins with ") + "'" + $("#firstletter_filter").val() +"'";
|
||||
}
|
||||
if ( $("#categorycode_filter").val() ) {
|
||||
searched += _(" with category ") + $("#categorycode_filter").find("option:selected").text();
|
||||
searched += _(" with category ") + "'" + $("#categorycode_filter").find("option:selected").text() + "'";
|
||||
}
|
||||
if ( $("#branchcode_filter").val() ) {
|
||||
searched += _(" in library ") + $("#branchcode_filter").find("option:selected").text();
|
||||
}
|
||||
$("#searchpattern").text("for patron " + searched);
|
||||
$("#searchpattern").text(searched);
|
||||
}
|
||||
|
||||
// Redraw the table
|
||||
|
@ -327,7 +326,7 @@ function filterByFirstLetterSurname(letter) {
|
|||
|
||||
<div id="searchresults">
|
||||
<div id="searchheader">
|
||||
<h3>Results found <span id="searchpattern">[% IF searchmember %] for '[% searchmember %]'[% END %]</span></h3>
|
||||
<h3>Patrons found for: <span id="searchpattern">[% IF searchmember %] for '[% searchmember %]'[% END %]</span></h3>
|
||||
</div>
|
||||
[% IF CAN_user_tools_manage_patron_lists %]
|
||||
<div id="searchheader">
|
||||
|
|
Loading…
Reference in a new issue