-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add yearly/per.. graphs + fix chartkick
- Loading branch information
1 parent
5afb33a
commit a82bb99
Showing
19 changed files
with
241 additions
and
124 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,27 @@ | ||
<%= polaris_divider %> | ||
|
||
<%= polaris_layout do |layout| %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per app (12 Months)") do %> | ||
<%= pie_chart current_user.yearly_revenue_per_product(date: filter.date) %> | ||
<%= pie_chart current_user.yearly_revenue_per_product(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-app" %> | ||
<% end %> | ||
<% end %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per country (12 Months)") do %> | ||
<%= pie_chart current_user.yearly_revenue_per_country(date: filter.date) %> | ||
<%= pie_chart current_user.yearly_revenue_per_country(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-country" %> | ||
<% end %> | ||
<% end %> | ||
<% end %> | ||
|
||
<%= polaris_layout do |layout| %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per charge type (12 Months)") do %> | ||
<%= column_chart current_user.yearly_revenue_per_charge_type(date: filter.date) %> | ||
<%= column_chart current_user.yearly_revenue_per_charge_type(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-charge-type-12-months" %> | ||
<% end %> | ||
<% end %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per charge type (All time)") do %> | ||
<%= column_chart current_user.total_revenue_per_charge_type(date: filter.date) %> | ||
<%= column_chart current_user.total_revenue_per_charge_type(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-charve-type" %> | ||
<% end %> | ||
<% end %> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<%= polaris_divider %> | ||
|
||
<%= polaris_layout do |layout| %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per plan (All time)") do %> | ||
<%= column_chart current_user.total_revenue_per_plan( | ||
date: filter.date, | ||
charge_type: filter.charge_type, | ||
app_title: filter.app | ||
), id: "revenue-per-plan" %> | ||
<% end %> | ||
<% end %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per country (12 Months)") do %> | ||
<%= pie_chart current_user.yearly_revenue_per_country(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-country" %> | ||
<% end %> | ||
<% end %> | ||
<% end %> |
File renamed without changes.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<%= polaris_divider %> | ||
|
||
<%= polaris_layout do |layout| %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per app (12 Months)") do %> | ||
<%= pie_chart current_user.yearly_revenue_per_product(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-app" %> | ||
<% end %> | ||
<% end %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per country (12 Months)") do %> | ||
<%= pie_chart current_user.yearly_revenue_per_country(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-country" %> | ||
<% end %> | ||
<% end %> | ||
<% end %> | ||
|
||
<%= polaris_layout do |layout| %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per app (12 Months)") do %> | ||
<%= column_chart current_user.yearly_revenue_per_product(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-app-column" %> | ||
<% end %> | ||
<% end %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per app (All time)") do %> | ||
<%= column_chart current_user.total_revenue_per_app(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-app-total" %> | ||
<% end %> | ||
<% end %> | ||
<% end %> |
File renamed without changes.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
<%= polaris_layout do |layout| %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Users per plan and app (#{filter.period} days)") do %> | ||
<%= column_chart current_user.total_revenue_per_plan( | ||
date: filter.date, | ||
charge_type: filter.charge_type, | ||
period: filter.period, | ||
app_title: filter.app | ||
), id: "revenue-per-plan-last-x-days" %> | ||
<% end %> | ||
<% end %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Users per plan and app (All time)") do %> | ||
<%= pie_chart current_user.total_revenue_per_plan( | ||
date: filter.date, | ||
charge_type: filter.charge_type, | ||
app_title: filter.app | ||
), id: "revenue-per-plan" %> | ||
<% end %> | ||
<% end %> | ||
<% end %> | ||
|
||
<%= polaris_divider %> | ||
|
||
<%= polaris_layout do |layout| %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per app (12 Months)") do %> | ||
<%= pie_chart current_user.yearly_revenue_per_product(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-app" %> | ||
<% end %> | ||
<% end %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per country (12 Months)") do %> | ||
<%= pie_chart current_user.yearly_revenue_per_country(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-country" %> | ||
<% end %> | ||
<% end %> | ||
<% end %> | ||
|
||
<%= polaris_layout do |layout| %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per app (12 Months)") do %> | ||
<%= column_chart current_user.yearly_revenue_per_product(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-app-column" %> | ||
<% end %> | ||
<% end %> | ||
<% layout.with_section(one_half: true) do %> | ||
<%= polaris_card(title: "Revenue per app (All time)") do %> | ||
<%= column_chart current_user.total_revenue_per_app(charge_type: filter.charge_type, date: filter.date), id: "revenue-per-app-total" %> | ||
<% end %> | ||
<% end %> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.