
Security News
Follow-up and Clarification on Recent Malicious Ruby Gems Campaign
A clarification on our recent research investigating 60 malicious Ruby gems.
Ruby On Rails gem to visualize by Google Charts MDX queries on OLAP databases using XMLA connection. Can be used with any XMLA-compliant server, like Olaper or Mondrian.
Add this line to your application's Gemfile:
gem 'olap-view'
And then execute:
$ bundle
Or install it yourself as:
$ gem install olap-view
Include Olap::View helper to application_helper.rb
include OlapViewHelper
Import olap-view Sass file (for example, application.scss
) to get all of olap-view style:
@import "olap-view/olap-view";
Add Google Charts initialize into <head>
tag in your laoyut (for examlpe, application.html.erb
):
<head>
...
<%= olap_view_charts_init %>
</head>
This gem use olap-xmla
( https://github.com/Wondersoft/olap-xmla ) and does not parse MDX, just passes it to XMLA server.
However, it can do substituting parameters in the query:
MDX_QUERY = 'SET [~ROWS_Date] AS {[DateTime].[Date].[Date].[%DATE%]}'
Olap::View.request MDX_QUERY, {'%DATE%' => '20150530'}
At the moment only available :table
, :piechart
, :barchart
and partially :combochart
charts.
Insert helper menthod to erb
file:
<%= olap_view_chart_by_mdx :table,
'SET [~ROWS_Date] AS {[DateTime].[Date].[Date].[%DATE%]}',
{'%DATE%' => '20150530'} %>
<% xmla = Olap::View.request 'SET [~ROWS_Date] AS {[DateTime].[Date].[Date].[%DATE%]}',
{'%DATE%' => '20150530'} %>
<div>
<h1>PieChart</h1>
<%= olap_view_chart_by_xmla :piechart, xmla %>
</div>
<div>
<h1>Table</h1>
<%= olap_view_chart_by_xmla :table, xmla %>
</div>
In olap_view_chart_by_mdx
and olap_view_chart_by_xmla
following properties are available:
<%= olap_view_chart_by_xmla :table, xmla, properties %>
total: true
show total string in table chart
rowspan: true
unites the cells with the same data from the dimenssions in table chart
function: "text on JS"
execute ani js code into chart template
dimension: "Source Name"
aggregate xmla data by dimesion
merge_dimensions: true
merge dimensions to one table
measures: "[Measures].[Click]"
show only selected measure from xmla data and sort by order
options: {}
Google Charts draw options
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)FAQs
Unknown package
We found that olap-view demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
A clarification on our recent research investigating 60 malicious Ruby gems.
Security News
ESLint now supports parallel linting with a new --concurrency flag, delivering major speed gains and closing a 10-year-old feature request.
Research
/Security News
A malicious Go module posing as an SSH brute forcer exfiltrates stolen credentials to a Telegram bot controlled by a Russian-speaking threat actor.