paginas 0.2.3 → 0.2.3.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 03043e84f64a14fc81373c8768c76925af02fb7d
4
- data.tar.gz: 3990936367d143a4ba03e1918fa77d5c7d87b6ca
3
+ metadata.gz: c51ea3cc77c15364872fc6ff8b2edc6dc5864435
4
+ data.tar.gz: 7518552f75fc14b2f1ed5e83b9b3e8eea21aa4c9
5
5
  SHA512:
6
- metadata.gz: 26d79b13c04c55135b5b2127919dc454708d217b9f3900f276b2cdddb970bd558390ff2ec268ecb81319553ff54c4dbc5cc95c6b148e62960b21fb58b6459e28
7
- data.tar.gz: b5ae843b768bdb8269cfef0fdc6bf45bfe3d38541a66a71bc1436ad0ddd1ddfd6ab4da1d14372c4fd69c7017e16f549a66ec0ce4afd309f37bde274d12031e3c
6
+ metadata.gz: 3893361f2661e2ec6035cb5abb513e74c9389aeabd2304b88d24dc54740fe9760f0b84ba2ff58d9a06e7f13ced93dc95179b001b574a01d3ae6257afbc79c4cb
7
+ data.tar.gz: 6ff7bad9753bd60b05a12700ab7873312e62455dc76a55ad796f774a901332f81ce24bec9c18722a20faccf5760292dec3761acf7180f58fc3040f5d623d2980
@@ -3,9 +3,10 @@
3
3
  if( typeof jQuery != 'undefined')
4
4
  {
5
5
  $(document).on('page:receive',function(){
6
- tinymce.remove();
6
+
7
7
  });
8
8
  $(document).ready(function(){
9
+ tinymce.remove();
9
10
  tinyMCE.init({
10
11
  selector: "textarea.tinymce"
11
12
  });
@@ -14,6 +15,7 @@ if( typeof jQuery != 'undefined')
14
15
  else
15
16
  {
16
17
  document.addEventListener("DOMContentLoaded", function(event) {
18
+ tinymce.remove();
17
19
  tinyMCE.init({
18
20
  selector: "textarea.tinymce"
19
21
  });
@@ -40,19 +40,22 @@ module Paginas
40
40
 
41
41
  output = ''
42
42
  separator = ''
43
- Category.find(catid).pages.each do |page|
44
- item = ''
45
- item += separator
46
- item += options[:item_style].gsub(/\[link\]/, link_to(page.title ,display_path(page.id)))
43
+ cats = Category.where(:id => catid).first
44
+ if !cats.blank?
45
+ cats.pages.each do |page|
46
+ item = ''
47
+ item += separator
48
+ item += options[:item_style].gsub(/\[link\]/, link_to(page.title ,display_path(page.id)))
47
49
 
48
- active = ''
49
- if params[:controller] == options[:controller] && params[:action] == options[:action] && params[:id] == page.id.to_s
50
- active = options[:active_class]
51
- end
52
- item = item.gsub(/\[active\]/, active)
53
- output += item
54
- if separator == ''
55
- separator= options[:item_separator]
50
+ active = ''
51
+ if params[:controller] == options[:controller] && params[:action] == options[:action] && params[:id] == page.id.to_s
52
+ active = options[:active_class]
53
+ end
54
+ item = item.gsub(/\[active\]/, active)
55
+ output += item
56
+ if separator == ''
57
+ separator= options[:item_separator]
58
+ end
56
59
  end
57
60
  end
58
61
  output = options[:group_style].gsub(/\[items\]/, output)
@@ -1,3 +1,3 @@
1
1
  module Paginas
2
- VERSION = "0.2.3"
2
+ VERSION = "0.2.3.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: paginas
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Carlos Roque
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-19 00:00:00.000000000 Z
11
+ date: 2015-02-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails