olap-view 0.0.19 → 0.0.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d47ed5ee836d6be6b422ce2ad82afd779dee8e70
4
- data.tar.gz: 6c21c6ef7b239bfd05c682024ab286ca63a6b65c
3
+ metadata.gz: 91c60606c6113ffbdd9470f84c8a88be24b5783f
4
+ data.tar.gz: 62201cfa22e446d086dd18861bf14c0fad14770c
5
5
  SHA512:
6
- metadata.gz: 3746b2528e9263d2178e83ee27d47a70231aaadc1a6f6b0a7980e689baa7ca05919a33b4105cd9a16a912dbbc2d49844783913b10687a3e20c56f9cbbef01e0c
7
- data.tar.gz: 52c16e20f93fca55e34133df7a2e59dc2488a7d2178f78d8796abb0e27f565ddd91d10a5c7430f9975215c83c2534112db2e77d2e0cc621cf38d8501d44165e4
6
+ metadata.gz: 0e6d797a7ac8d137f4d0ebe6ff7c570a9b75f0f4f70a124c733f438d512c0828329e8a53c8ddd8f03b7516c3429e2ddea14ed04229c156d97aff45bcffe54671
7
+ data.tar.gz: 7237d27f37ca630dd9ed28688d49f0f107ad0f34dabb7edfa9106c856f3b434953ce290fcff36f2b9500a4f4a499e5556949b5df39ad35b4931cf2dfa54a0dcd
data/README.md CHANGED
@@ -87,14 +87,20 @@ In `olap_view_chart_by_mdx` and `olap_view_chart_by_xmla` following properties a
87
87
  ```
88
88
 
89
89
  `total: true` show total string in table chart
90
+
90
91
  `rowspan: true` unites the cells with the same data from the dimenssions in table chart
92
+
91
93
  `function: "text on JS"` execute ani js code into chart template
92
- `dimention: "Source Name"` aggregate xmla data by dimesion
93
- `measures: "[Measures].[Click]"` remove measure from xmla data
94
+
95
+ `dimention: "Source Name"` aggregate xmla data by dimesion
96
+
97
+ `measures: "[Measures].[Click]"` remove measure from xmla data
98
+
94
99
  `options: {}` Google Charts draw options
95
100
 
96
101
 
97
102
 
103
+
98
104
  ## Contributing
99
105
 
100
106
  1. Fork it ( https://github.com/Wondersoft/olap-view/fork )
@@ -1,9 +1,11 @@
1
1
  .google-visualization-table {
2
- .dimension{
3
- text-align: left;
4
- }
5
- .measure{
6
- text-align: right;
2
+ .google-visualization-table-td{
3
+ &.dimension{
4
+ text-align: left;
5
+ }
6
+ &.measure{
7
+ text-align: right;
8
+ }
7
9
  }
8
10
  .total{
9
11
  background: #e4e9f4;
@@ -33,9 +33,9 @@
33
33
  def olap_view_render_row row
34
34
  row.collect{|r|
35
35
  if r[:type] == 'dimension'
36
- "{v: '#{escape_javascript(r[:value] && !r[:value].empty? ? r[:value] : olap_view_i18n_options[:undefined])}', p:{className: 'google-visualization-table-td #{r[:type]}'}}"
36
+ "{v: '#{escape_javascript(r[:value] && !r[:value].empty? ? r[:value] : olap_view_i18n_options[:undefined])}', p:{'type': '#{r[:type]}', className: 'google-visualization-table-td #{r[:type]}'}}"
37
37
  else
38
- "{v: #{r[:value]}, f: '#{r[:fmt_value] || r[:value]}', p:{className: 'google-visualization-table-td #{r[:type]}'}}"
38
+ "{v: #{r[:value]}, f: '#{r[:fmt_value] || r[:value]}', p:{'type': '#{r[:type]}', className: 'google-visualization-table-td #{r[:type]}'}}"
39
39
  end
40
40
  }.join(',').html_safe
41
41
  end
@@ -18,6 +18,13 @@
18
18
 
19
19
  <%= "rowSpan('#{id}');".html_safe if properties[:rowspan] == true %>
20
20
  <%= "total(data);".html_safe if properties[:total] == true %>
21
+ addClassToTh(data);
22
+ }
23
+
24
+ function addClassToTh(data){
25
+ $('#<%= id %> table th').each(function(i, element){
26
+ $(this).addClass(data.getColumnProperties(i).type);
27
+ });
21
28
  }
22
29
 
23
30
  function rowSpan(id){
@@ -1,5 +1,5 @@
1
1
  module Olap
2
2
  module View
3
- VERSION = "0.0.19"
3
+ VERSION = "0.0.20"
4
4
  end
5
5
  end
data/olap-view.gemspec CHANGED
@@ -17,5 +17,5 @@ Gem::Specification.new do |spec|
17
17
 
18
18
  spec.add_development_dependency "bundler", "~> 1.7"
19
19
  spec.add_development_dependency "rake", "~> 10.0"
20
- spec.add_runtime_dependency "olap-xmla", '~> 0'
20
+ spec.add_runtime_dependency "olap-xmla", '~> 0.0.9'
21
21
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: olap-view
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.19
4
+ version: 0.0.20
5
5
  platform: ruby
6
6
  authors:
7
7
  - stepanovit
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-14 00:00:00.000000000 Z
11
+ date: 2016-03-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -44,14 +44,14 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '0'
47
+ version: 0.0.9
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '0'
54
+ version: 0.0.9
55
55
  description: Ruby On Rails gem to visualize by Google Charts MDX queries on OLAP databases
56
56
  using XMLA connection. Can be used with any XMLA-compliant server, like Olaper or
57
57
  Mondrian.