myexperiment-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[myexperiment-hackers] [2210] trunk: clickable workflow types in workflo


From: noreply
Subject: [myexperiment-hackers] [2210] trunk: clickable workflow types in workflow tab
Date: Mon, 8 Jun 2009 10:11:26 -0400 (EDT)

Revision
2210
Author
dgc
Date
2009-06-08 10:11:25 -0400 (Mon, 08 Jun 2009)

Log Message

clickable workflow types in workflow tab

Modified Paths

Diff

Modified: trunk/app/models/workflow.rb (2209 => 2210)


--- trunk/app/models/workflow.rb	2009-06-08 11:54:09 UTC (rev 2209)
+++ trunk/app/models/workflow.rb	2009-06-08 14:11:25 UTC (rev 2210)
@@ -84,9 +84,7 @@
   #non_versioned_fields.push("image", "svg", "license", "tag_list") # acts_as_versioned and file_column don't get on
   non_versioned_columns.push("license", "tag_list", "body_html")
   
-# acts_as_solr(:fields => [ :title, :body, :tag_list, :contributor_name, { :rating => :integer } ],
-
-  acts_as_solr(:fields => [ :title, :body, :tag_list, :contributor_name, :type, :get_all_search_terms ],
+  acts_as_solr(:fields => [ :title, :body, :tag_list, :contributor_name, :kind, :get_all_search_terms ],
                :include => [ :comments ]) if Conf.solr_enable
 
   acts_as_runnable
@@ -258,4 +256,6 @@
   def type
     content_type.title
   end
+
+  alias_method :kind, :type
 end

Modified: trunk/app/views/workflows/index.rhtml (2209 => 2210)


--- trunk/app/views/workflows/index.rhtml	2009-06-08 11:54:09 UTC (rev 2209)
+++ trunk/app/views/workflows/index.rhtml	2009-06-08 14:11:25 UTC (rev 2210)
@@ -1,8 +1,8 @@
 <div class="box_standout" style="text-align: center; margin-bottom: 1em; font-weight: bold; line-height: 1.5em;">
 	<% Workflow.count(:all, :group => 'content_type_id').sort{|x,y| y[1] <=> x[1]}.each do |arr| %>
-		| <%= pluralize(arr[1], (h(ContentType.find_by_id(arr[0]).title + " workflow"))) %>
+		  <span class="nowrap"><%= link_to((h(ContentType.find_by_id(arr[0]).title)),
+        search_workflows_path + "?query=kind:(#{ContentType.find_by_id(arr[0]).title})") %> (<%= arr[1] %>)</span>
 	<% end %>
-	|
 </div>
 
 <ul class="sectionIcons">

Modified: trunk/public/stylesheets/styles.css (2209 => 2210)


--- trunk/public/stylesheets/styles.css	2009-06-08 11:54:09 UTC (rev 2209)
+++ trunk/public/stylesheets/styles.css	2009-06-08 14:11:25 UTC (rev 2210)
@@ -1960,3 +1960,7 @@
   text-decoration: none;
 }
 
+.nowrap {
+  white-space: nowrap;
+}
+

reply via email to

[Prev in Thread] Current Thread [Next in Thread]