[Git][noosfero/noosfero][stable-2.5] Merge branch 'issue-6837' into 'master'

Rodrigo Souto gitlab at mg.gitlab.com
Mon Sep 10 17:10:14 BRT 2018


Rodrigo Souto pushed to branch stable-2.5 at Noosfero / noosfero


Commits:
8155ab3b by Rodrigo Souto at 2018-09-10T20:10:11Z
Merge branch 'issue-6837' into 'master'

Fixing search scope for pg_search_plugin

See merge request noosfero/noosfero!1609

(cherry picked from commit 70545edcbbb5441a87ba50f211c4571aa8c261db)

77541138 Fixing search scope for pg_search_plugin
21466909 Improving sample-profiles script
- - - - -


4 changed files:

- plugins/pg_search/lib/pg_search_plugin.rb
- plugins/pg_search/po/pt/pg_search.po
- plugins/pg_search/views/box_organizer/_profile_search_block.html.erb
- script/sample-profiles


Changes:

=====================================
plugins/pg_search/lib/pg_search_plugin.rb
=====================================
@@ -56,7 +56,7 @@ class PgSearchPlugin < Noosfero::Plugin
 
     @asset, @base_scope = asset, scope
 
-    scope = scope.send(params[:filter]) if params[:filter] && params[:filter] != 'more_relevant'
+    scope = scope.send(params[:order]) if params[:order] && params[:order] != 'more_relevant'
 
     scope = filter_by_periods(scope, periods) if params[:periods].present?
     scope = filter_by_facets(scope, facets) if params[:facets].present?


=====================================
plugins/pg_search/po/pt/pg_search.po
=====================================
@@ -75,6 +75,10 @@ msgstr "Limpar filtros"
 msgid "Enable advanced search"
 msgstr "Ativar busca avançada"
 
+#: ../views/box_organizer/_profile_search_block.html.erb:4
+msgid "Customized Search Fields"
+msgstr "Campos de Busca Customizados"
+
 #: ../views/profile_search/_facets.html.erb:3
 msgid "Advanced Search"
 msgstr "Busca Avançada"


=====================================
plugins/pg_search/views/box_organizer/_profile_search_block.html.erb
=====================================
@@ -1,7 +1,7 @@
 <% if environment.plugin_enabled? PgSearchPlugin %>
   <% class_eval { include PgSearchPlugin::SearchHelper } %>
   <%= labelled_check_box(_('Enable advanced search'), 'block[advanced_search]', true, @block.advanced_search) %>
-  <h2>Campos de Busca Customizados</h2>
+  <h2><%=_('Customized Search Fields')%></h2>
   <div class="search-fields-options">
     <% (default_search_fields | custom_field_names(Article, @block.owner.articles)).each do |search_field| %>
       <div>


=====================================
script/sample-profiles
=====================================
@@ -128,8 +128,8 @@ done
 
 
 communities = []
-VERBS = ['Save', 'I like', 'Use']
-STUFF = ['Free Software', 'Organic food', 'the wales', 'the environment']
+VERBS = ['Save', 'I like', 'Use', 'Lovers of', 'Rehabilitate']
+STUFF = ['Free Software', 'Organic food', 'the wales', 'the environment', 'Vegan Food', 'Vegetarians']
 print "Creating communities: "
 for verb in VERBS
   for stuff in STUFF



View it on GitLab: https://gitlab.com/noosfero/noosfero/commit/8155ab3b2f353e9e3f2abfea5e0fd1ddaf8007a8

-- 
View it on GitLab: https://gitlab.com/noosfero/noosfero/commit/8155ab3b2f353e9e3f2abfea5e0fd1ddaf8007a8
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listas.softwarelivre.org/pipermail/noosfero-dev/attachments/20180910/e163a604/attachment-0001.html>


More information about the Noosfero-dev mailing list