a_la_chart 0.0.9 → 0.0.10

Sign up to get free protection for your applications and to get access to all the features.
data/History.txt CHANGED
@@ -1,3 +1,9 @@
1
+ === 0.0.10 2009-12-29
2
+
3
+ * 2 major enhancement:
4
+ * added support for inlining fusion chart data
5
+ * added support for 3D fusion charts
6
+
1
7
  === 0.0.8 2009-12-24
2
8
 
3
9
  * 1 major enhancement:
@@ -3,11 +3,11 @@ module ALaChart
3
3
  module HelperMethods
4
4
  def meta(the_case=nil)
5
5
  if the_case.blank?
6
- # (@metadata ||= {})['_'] ||= defined?(get_meta) ? get_meta : {}
7
- @metadata ||= defined?(get_meta) ? get_meta : {}
6
+ (@metadata ||= {})['_'] ||= defined?(get_meta) ? get_meta : {}
7
+ # @metadata ||= defined?(get_meta) ? get_meta : {}
8
8
  else
9
- # (@metadata ||= {})[the_case] ||= respond_to?("get_meta_#{the_case.to_s}") ? send("get_meta_#{the_case.to_s}") : []
10
- @metadata ||= respond_to?("get_meta_#{the_case.to_s}") ? send("get_meta_#{the_case.to_s}") : []
9
+ (@metadata ||= {})[the_case] ||= respond_to?("get_meta_#{the_case.to_s}") ? send("get_meta_#{the_case.to_s}") : []
10
+ # @metadata ||= respond_to?("get_meta_#{the_case.to_s}") ? send("get_meta_#{the_case.to_s}") : []
11
11
  end
12
12
  end
13
13
 
@@ -31,7 +31,7 @@ module ALaChart
31
31
  val = key_field.call(object)
32
32
  elsif key_field.class == Fixnum
33
33
  val = object[key_field] if object.respond_to?('[]')
34
- else
34
+ elsif object.class != Array
35
35
  val = object[key_field] if object.respond_to?('[]')
36
36
  val = (object.respond_to?(key_field) ? object.send(key_field) : nil) if val.nil?
37
37
  val
@@ -142,8 +142,12 @@ module ALaChart
142
142
  cases = [attrs]
143
143
  end
144
144
  elsif attrs.size > 1
145
- cases = attrs[0...-1]
146
- options = attrs[-1]
145
+ if attrs[-1].class == Hash
146
+ cases = attrs[0...-1]
147
+ options = attrs[-1]
148
+ else
149
+ cases = attrs[0..-1]
150
+ end
147
151
  end
148
152
 
149
153
  cases ||= []
data/lib/a_la_chart.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  module ALaChart
2
- VERSION = '0.0.9'
2
+ VERSION = '0.0.10'
3
3
  end
4
4
 
5
5
  require File.join(File.dirname(__FILE__), 'a_la_chart', 'a_la_chart')
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: a_la_chart
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.9
4
+ version: 0.0.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric Redmond
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-12-28 00:00:00 -05:00
12
+ date: 2009-12-29 00:00:00 -05:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency