kaui 0.4.7 → 0.4.8
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.
- data/Gemfile.lock +5 -5
- data/app/controllers/kaui/analytics_controller.rb +1 -40
- data/app/helpers/kaui/killbill_helper.rb +6 -20
- data/app/models/kaui/base.rb +5 -1
- data/app/models/kaui/business_account.rb +4 -4
- data/app/models/kaui/business_field.rb +2 -2
- data/app/models/kaui/business_snapshot.rb +2 -2
- data/app/models/kaui/business_subscription_transition.rb +4 -5
- data/app/models/kaui/business_tag.rb +2 -2
- data/app/views/kaui/analytics/account_snapshot.html.erb +23 -23
- data/app/views/kaui/analytics/index.html.erb +0 -17
- data/app/views/kaui/layouts/kaui_application.html.erb +4 -4
- data/kaui.gemspec +1 -1
- data/lib/kaui/version.rb +1 -1
- metadata +6 -9
- data/app/views/kaui/analytics/accounts_over_time.html.erb +0 -9
- data/app/views/kaui/analytics/sanity.html.erb +0 -47
- data/app/views/kaui/analytics/subscriptions_over_time.html.erb +0 -9
data/Gemfile.lock
CHANGED
@@ -1,12 +1,12 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
kaui (0.4.
|
4
|
+
kaui (0.4.8)
|
5
5
|
cancan (~> 1.6.10)
|
6
6
|
d3_rails (~> 3.2.8)
|
7
7
|
devise (~> 3.0.2)
|
8
8
|
jquery-rails (~> 3.0.4)
|
9
|
-
killbill-client (~> 0.3.
|
9
|
+
killbill-client (~> 0.3.6)
|
10
10
|
money-rails (~> 0.8.1)
|
11
11
|
rails (~> 3.2.14)
|
12
12
|
rest-client (~> 1.6.7)
|
@@ -60,18 +60,18 @@ GEM
|
|
60
60
|
railties (>= 3.0, < 5.0)
|
61
61
|
thor (>= 0.14, < 2.0)
|
62
62
|
json (1.8.0)
|
63
|
-
killbill-client (0.3.
|
63
|
+
killbill-client (0.3.6)
|
64
64
|
mail (2.5.4)
|
65
65
|
mime-types (~> 1.16)
|
66
66
|
treetop (~> 1.4.8)
|
67
|
-
mime-types (1.
|
67
|
+
mime-types (1.25)
|
68
68
|
money (5.1.1)
|
69
69
|
i18n (~> 0.6.0)
|
70
70
|
money-rails (0.8.1)
|
71
71
|
activesupport (>= 3.0)
|
72
72
|
money (~> 5.1.0)
|
73
73
|
railties (>= 3.0)
|
74
|
-
multi_json (1.
|
74
|
+
multi_json (1.8.0)
|
75
75
|
mysql2 (0.3.13)
|
76
76
|
orm_adapter (0.4.0)
|
77
77
|
polyglot (0.3.3)
|
@@ -1,22 +1,7 @@
|
|
1
1
|
module Kaui
|
2
2
|
class AnalyticsController < Kaui::EngineController
|
3
|
+
|
3
4
|
def index
|
4
|
-
@slugs = []
|
5
|
-
begin
|
6
|
-
catalog = Kaui::KillbillHelper::get_full_catalog(options_for_klient)
|
7
|
-
catalog['products'].each do |product|
|
8
|
-
product['plans'].each do |plan|
|
9
|
-
name = plan['name']
|
10
|
-
plan['phases'].each do |phase|
|
11
|
-
type = phase['type']
|
12
|
-
@slugs << "#{name.downcase}-#{type.downcase}"
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
16
|
-
@product_type = catalog['name']
|
17
|
-
rescue => e
|
18
|
-
flash[:error] = "Error while retrieving catalog: #{as_string(e)}"
|
19
|
-
end
|
20
5
|
end
|
21
6
|
|
22
7
|
def account_snapshot
|
@@ -39,29 +24,5 @@ module Kaui
|
|
39
24
|
end
|
40
25
|
redirect_to account_snapshot_path(:account_id => params[:account_id])
|
41
26
|
end
|
42
|
-
|
43
|
-
def accounts_over_time
|
44
|
-
begin
|
45
|
-
@accounts = Analytics.accounts_over_time
|
46
|
-
rescue => e
|
47
|
-
flash[:error] = "Error while retrieving data: #{as_string(e)}"
|
48
|
-
@accounts = Kaui::TimeSeriesData.empty
|
49
|
-
end
|
50
|
-
end
|
51
|
-
|
52
|
-
def subscriptions_over_time
|
53
|
-
@product_type = params[:product_type]
|
54
|
-
@slug = params[:slug]
|
55
|
-
@subscriptions = Analytics.subscriptions_over_time(@product_type, @slug)
|
56
|
-
end
|
57
|
-
|
58
|
-
def sanity
|
59
|
-
begin
|
60
|
-
@sanity = Kaui::KillbillHelper::check_analytics_sanity(options_for_klient)
|
61
|
-
rescue => e
|
62
|
-
flash[:error] = "Error while checking Analytics sanity: #{as_string(e)}"
|
63
|
-
redirect_to :analytics
|
64
|
-
end
|
65
|
-
end
|
66
27
|
end
|
67
28
|
end
|
@@ -26,9 +26,10 @@ module Kaui
|
|
26
26
|
response = RestClient.send(method.to_sym, url, *args)
|
27
27
|
data = {:code => response.code}
|
28
28
|
if response.code < 300 && response.body.present?
|
29
|
-
|
29
|
+
# Hack for Analytics plugin (no content-type header returned)
|
30
|
+
begin
|
30
31
|
data[:json] = JSON.parse(response.body)
|
31
|
-
|
32
|
+
rescue => e
|
32
33
|
data[:body] = response.body
|
33
34
|
end
|
34
35
|
end
|
@@ -212,7 +213,7 @@ module Kaui
|
|
212
213
|
entitlement = KillBillClient::Model::EntitlementNoEvents.new
|
213
214
|
entitlement.subscription_id = subscription_id
|
214
215
|
# We are using same entitlement/billing policy here for now
|
215
|
-
entitlement.cancel(extract_created_by(current_user), extract_reason_code(reason), comment, nil, policy, policy, options)
|
216
|
+
entitlement.cancel(extract_created_by(current_user), extract_reason_code(reason), comment, nil, policy, policy, true, options)
|
216
217
|
end
|
217
218
|
|
218
219
|
def self.compute_previous_ctd(ctd, billing_period, options = {})
|
@@ -508,32 +509,17 @@ module Kaui
|
|
508
509
|
############## ANALYTICS ##############
|
509
510
|
|
510
511
|
def self.get_account_snapshot(account_id, options = {})
|
511
|
-
data = call_killbill :get, "/
|
512
|
+
data = call_killbill :get, "/plugins/killbill-analytics/#{account_id}", options
|
512
513
|
process_response(data, :single) { |json| Kaui::BusinessSnapshot.new(json) }
|
513
514
|
end
|
514
515
|
|
515
516
|
def self.refresh_account(account_id, current_user = nil, reason = nil, comment = nil, options = {})
|
516
517
|
call_killbill :put,
|
517
|
-
"/
|
518
|
+
"/plugins/killbill-analytics/#{account_id}",
|
518
519
|
nil,
|
519
520
|
build_audit_headers(current_user, reason, comment, options)
|
520
521
|
end
|
521
522
|
|
522
|
-
def self.get_accounts_created_over_time(options = {})
|
523
|
-
data = call_killbill :get, "/1.0/kb/analytics/accountsCreatedOverTime", options
|
524
|
-
process_response(data, :single) { |json| Kaui::TimeSeriesData.new(json) }
|
525
|
-
end
|
526
|
-
|
527
|
-
def self.get_subscriptions_created_over_time(product_type, slug, options = {})
|
528
|
-
data = call_killbill :get, "/1.0/kb/analytics/subscriptionsCreatedOverTime?productType=#{product_type}&slug=#{slug}", options
|
529
|
-
process_response(data, :single) { |json| Kaui::TimeSeriesData.new(json) }
|
530
|
-
end
|
531
|
-
|
532
|
-
def self.check_analytics_sanity(options = {})
|
533
|
-
data = call_killbill :get, "/1.0/kb/analytics/sanity", options
|
534
|
-
process_response(data, :single) { |json| Kaui::AnalyticsSanity.new(json) }
|
535
|
-
end
|
536
|
-
|
537
523
|
def self.before_all
|
538
524
|
methods.each do |method_name|
|
539
525
|
method = method(method_name)
|
data/app/models/kaui/base.rb
CHANGED
@@ -1,12 +1,12 @@
|
|
1
1
|
class Kaui::BusinessAccount < Kaui::Base
|
2
|
-
define_attr :
|
3
|
-
define_attr :
|
2
|
+
define_attr :account_external_key
|
3
|
+
define_attr :account_name
|
4
4
|
define_attr :currency
|
5
5
|
define_attr :balance
|
6
6
|
define_attr :last_invoice_date
|
7
|
-
define_attr :
|
7
|
+
define_attr :last_invoice_balance
|
8
8
|
define_attr :last_payment_status
|
9
9
|
define_attr :default_payment_method_type
|
10
10
|
define_attr :default_credit_card_type
|
11
11
|
define_attr :default_billing_address_country
|
12
|
-
end
|
12
|
+
end
|
@@ -3,7 +3,7 @@ class Kaui::BusinessSnapshot < Kaui::Base
|
|
3
3
|
has_many :business_subscription_transitions, Kaui::BusinessSubscriptionTransition
|
4
4
|
has_many :business_invoices, Kaui::BusinessInvoice
|
5
5
|
has_many :business_invoice_payments, Kaui::BusinessInvoicePayment
|
6
|
-
has_many :
|
6
|
+
has_many :business_account_transitions, Kaui::BusinessOverdueStatus
|
7
7
|
has_many :business_tags, Kaui::BusinessTag
|
8
8
|
has_many :business_fields, Kaui::BusinessField
|
9
|
-
end
|
9
|
+
end
|
@@ -1,14 +1,13 @@
|
|
1
1
|
class Kaui::BusinessSubscriptionTransition < Kaui::Base
|
2
2
|
define_attr :total_ordering
|
3
3
|
define_attr :bundle_id
|
4
|
-
define_attr :
|
4
|
+
define_attr :bundle_external_key
|
5
5
|
define_attr :account_id
|
6
|
-
define_attr :
|
6
|
+
define_attr :account_external_key
|
7
7
|
define_attr :subscription_id
|
8
8
|
|
9
9
|
define_attr :requested_timestamp
|
10
|
-
define_attr :
|
11
|
-
define_attr :category
|
10
|
+
define_attr :event
|
12
11
|
|
13
12
|
define_attr :prev_product_name
|
14
13
|
define_attr :prev_product_type
|
@@ -51,4 +50,4 @@ class Kaui::BusinessSubscriptionTransition < Kaui::Base
|
|
51
50
|
def next_mrr_to_money
|
52
51
|
Kaui::Base.to_money(next_mrr.abs, next_currency)
|
53
52
|
end
|
54
|
-
end
|
53
|
+
end
|
@@ -8,7 +8,7 @@
|
|
8
8
|
<th>Name</th>
|
9
9
|
<th>Currency</th>
|
10
10
|
<th>Balance</th>
|
11
|
-
<th>
|
11
|
+
<th>Last inv. balance</th>
|
12
12
|
<th>Last inv. date</th>
|
13
13
|
<th>Last payment status</th>
|
14
14
|
<th>Default payment method</th>
|
@@ -16,15 +16,15 @@
|
|
16
16
|
</thead>
|
17
17
|
<tbody>
|
18
18
|
<tr>
|
19
|
-
<td><%= link_to @snapshot.business_account.
|
20
|
-
<td><%= @snapshot.business_account.
|
19
|
+
<td><%= link_to @snapshot.business_account.account_external_key, Kaui.account_home_path.call(@snapshot.business_account.account_external_key) %></td>
|
20
|
+
<td><%= @snapshot.business_account.account_name %></td>
|
21
21
|
<td><%= @snapshot.business_account.currency %></td>
|
22
|
-
<td><span <% if @snapshot.business_account.balance > 0 %>class="alert-error"
|
23
|
-
<% elsif @snapshot.business_account.balance <= 0 %>class="alert-success"
|
22
|
+
<td><span <% if @snapshot.business_account.balance.present? and @snapshot.business_account.balance > 0 %>class="alert-error"
|
23
|
+
<% elsif @snapshot.business_account.balance.present? and @snapshot.business_account.balance <= 0 %>class="alert-success"
|
24
24
|
<% end %>><%= @snapshot.business_account.balance %></td>
|
25
|
-
<td><span <% if @snapshot.business_account.
|
26
|
-
<% elsif @snapshot.business_account.
|
27
|
-
<% end %>><%= @snapshot.business_account.
|
25
|
+
<td><span <% if @snapshot.business_account.last_invoice_balance.present? and @snapshot.business_account.last_invoice_balance > 0 %>class="alert-error"
|
26
|
+
<% elsif @snapshot.business_account.last_invoice_balance.present? and @snapshot.business_account.last_invoice_balance <= 0 %>class="alert-success"
|
27
|
+
<% end %>><%= @snapshot.business_account.last_invoice_balance %></td>
|
28
28
|
<td><%= @snapshot.business_account.last_invoice_date %></td>
|
29
29
|
<td><span <% if @snapshot.business_account.last_payment_status == 'FAILED' %>class="alert-error"
|
30
30
|
<% elsif @snapshot.business_account.last_payment_status == 'SUCCESS' %>class="alert-success"
|
@@ -51,14 +51,14 @@
|
|
51
51
|
</thead>
|
52
52
|
<tbody>
|
53
53
|
<% @snapshot.business_subscription_transitions.each do |business_subscription_transition| %>
|
54
|
-
<tr <% if business_subscription_transition.
|
55
|
-
<% elsif business_subscription_transition.
|
56
|
-
<% elsif business_subscription_transition.
|
57
|
-
<% elsif business_subscription_transition.
|
54
|
+
<tr <% if business_subscription_transition.event.start_with? 'START_' %>class="success"
|
55
|
+
<% elsif business_subscription_transition.event.start_with? 'CHANGE_' %>class="info"
|
56
|
+
<% elsif business_subscription_transition.event.start_with? 'PAUSE_' %>class="warning"
|
57
|
+
<% elsif business_subscription_transition.event.start_with? 'STOP_' %>class="error"
|
58
58
|
<% end %>>
|
59
|
-
<td><%= link_to Kaui.bundle_key_display_string.call(business_subscription_transition.
|
59
|
+
<td><%= link_to Kaui.bundle_key_display_string.call(business_subscription_transition.bundle_external_key), Kaui.bundle_home_path.call(business_subscription_transition.bundle_external_key) %></td>
|
60
60
|
<td><%= format_date(business_subscription_transition.requested_timestamp, @account.timezone).html_safe %></td>
|
61
|
-
<td><%= business_subscription_transition.
|
61
|
+
<td><%= business_subscription_transition.event %></td>
|
62
62
|
<td><%= format_date(business_subscription_transition.next_start_date, @account.timezone).html_safe unless business_subscription_transition.next_start_date.nil? %></td>
|
63
63
|
<td><%= business_subscription_transition.next_slug %></td>
|
64
64
|
<td><%= humanized_money business_subscription_transition.next_price_to_money unless business_subscription_transition.next_price.nil? %></td>
|
@@ -157,13 +157,13 @@
|
|
157
157
|
<td><%= business_tag.object_type %></td>
|
158
158
|
<td>
|
159
159
|
<% if business_tag.object_type == 'ACCOUNT' %>
|
160
|
-
<%= link_to business_tag.
|
160
|
+
<%= link_to business_tag.object_id, account_path(:id => business_tag.object_id) %>
|
161
161
|
<% elsif business_tag.object_type == 'INVOICE' %>
|
162
|
-
<%= link_to business_tag.
|
162
|
+
<%= link_to business_tag.object_id, invoice_path(:id => business_tag.object_id) %>
|
163
163
|
<% elsif business_tag.object_type == 'PAYMENT' %>
|
164
|
-
<%= link_to business_tag.
|
164
|
+
<%= link_to business_tag.object_id, payment_path(:id => business_tag.object_id) %>
|
165
165
|
<% elsif business_tag.object_type == 'BUNDLE' %>
|
166
|
-
<%= link_to business_tag.
|
166
|
+
<%= link_to business_tag.object_id, bundle_path(:id => business_tag.object_id) %>
|
167
167
|
<% else %>
|
168
168
|
<%= business_field.id %>
|
169
169
|
<% end %>
|
@@ -192,13 +192,13 @@
|
|
192
192
|
<td><%= business_field.object_type %></td>
|
193
193
|
<td>
|
194
194
|
<% if business_field.object_type == 'ACCOUNT' %>
|
195
|
-
<%= link_to business_field.
|
195
|
+
<%= link_to business_field.object_id, account_path(:id => business_field.object_id) %>
|
196
196
|
<% elsif business_field.object_type == 'INVOICE' %>
|
197
|
-
<%= link_to business_field.
|
197
|
+
<%= link_to business_field.object_id, invoice_path(:id => business_field.object_id) %>
|
198
198
|
<% elsif business_field.object_type == 'PAYMENT' %>
|
199
|
-
<%= link_to business_field.
|
199
|
+
<%= link_to business_field.object_id, payment_path(:id => business_field.object_id) %>
|
200
200
|
<% elsif business_field.object_type == 'BUNDLE' %>
|
201
|
-
<%= link_to business_field.
|
201
|
+
<%= link_to business_field.object_id, bundle_path(:id => business_field.object_id) %>
|
202
202
|
<% else %>
|
203
203
|
<%= business_field.id %>
|
204
204
|
<% end %>
|
@@ -208,4 +208,4 @@
|
|
208
208
|
</tr>
|
209
209
|
<% end %>
|
210
210
|
</tbody>
|
211
|
-
</table>
|
211
|
+
</table>
|
@@ -2,21 +2,6 @@
|
|
2
2
|
<h1>Analytics dashboards and data</h1>
|
3
3
|
</div>
|
4
4
|
|
5
|
-
<div class="btn-group">
|
6
|
-
<%= link_to 'Accounts over time', kaui_engine.analytics_accounts_over_time_path, { :class => 'btn btn-mini' } %>
|
7
|
-
<a class="btn btn-mini dropdown-toggle" data-toggle="dropdown" href="#">
|
8
|
-
Subscriptions over time
|
9
|
-
<span class="caret"></span>
|
10
|
-
</a>
|
11
|
-
<ul class="dropdown-menu">
|
12
|
-
<% @slugs.each do |slug| %>
|
13
|
-
<li><%= link_to slug, kaui_engine.analytics_subscriptions_over_time_path(:slug => slug, :product_type => @product_type) %></li>
|
14
|
-
<% end %>
|
15
|
-
</ul>
|
16
|
-
</div>
|
17
|
-
|
18
|
-
<hr/>
|
19
|
-
|
20
5
|
<%= form_tag account_snapshot_path, :class => "form-horizontal", :method => :get do %>
|
21
6
|
<fieldset>
|
22
7
|
<div class="control-group">
|
@@ -30,5 +15,3 @@
|
|
30
15
|
</div>
|
31
16
|
</fieldset>
|
32
17
|
<% end %>
|
33
|
-
|
34
|
-
<%= button_to "Check sanity", { :action => "sanity" }, :method => :get %>
|
@@ -12,14 +12,14 @@
|
|
12
12
|
<div class="container">
|
13
13
|
<ul class="nav">
|
14
14
|
<li <%= "class='active'" if params[:controller] == 'accounts' %>><%= link_to "Accounts", kaui_engine.accounts_path %></li>
|
15
|
-
<li <%= "class='active'" if params[:controller] == 'account_timelines' %>><%= link_to "Account timelines", kaui_engine.account_timelines_path %></li>
|
16
15
|
<li <%= "class='active'" if params[:controller] == 'bundles' %>><%= link_to "Bundles", kaui_engine.bundles_path %></li>
|
17
|
-
<li <%= "class='active'" if params[:controller] == 'subscriptions' %>><%= link_to "Subscriptions", kaui_engine.subscriptions_path %></li>
|
18
16
|
<li <%= "class='active'" if params[:controller] == 'payment_methods' %>><%= link_to "Payment methods", kaui_engine.payment_methods_path %></li>
|
19
|
-
<li <%= "class='active'" if params[:controller] == 'refunds' %>><%= link_to "Refunds", kaui_engine.refunds_path %></li>
|
20
17
|
<li <%= "class='active'" if params[:controller] == 'invoices' %>><%= link_to "Invoices", kaui_engine.invoices_path %></li>
|
21
|
-
<li <%= "class='active'" if params[:controller] == '
|
18
|
+
<li <%= "class='active'" if params[:controller] == 'refunds' %>><%= link_to "Refunds", kaui_engine.refunds_path %></li>
|
22
19
|
<li <%= "class='active'" if params[:controller] == 'tag_definitions' %>><%= link_to "Tag definitions", kaui_engine.tag_definitions_path %></li>
|
20
|
+
<li <%= "class='active'" if params[:controller] == 'analytics' %>><%= link_to "Analytics", kaui_engine.analytics_path %></li>
|
21
|
+
</ul>
|
22
|
+
<ul class="nav pull-right">
|
23
23
|
<% if user_signed_in? -%>
|
24
24
|
<li><%= link_to 'Sign out', destroy_user_session_path, method: :delete %></li>
|
25
25
|
<% end -%>
|
data/kaui.gemspec
CHANGED
@@ -27,7 +27,7 @@ Gem::Specification.new do |s|
|
|
27
27
|
s.add_dependency 'rest-client', '~> 1.6.7'
|
28
28
|
s.add_dependency 'money-rails', '~> 0.8.1'
|
29
29
|
s.add_dependency 'd3_rails', '~> 3.2.8'
|
30
|
-
s.add_dependency 'killbill-client', '~> 0.3.
|
30
|
+
s.add_dependency 'killbill-client', '~> 0.3.6'
|
31
31
|
s.add_dependency 'devise', '~> 3.0.2'
|
32
32
|
s.add_dependency 'cancan', '~> 1.6.10'
|
33
33
|
|
data/lib/kaui/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kaui
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.8
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-09-
|
12
|
+
date: 2013-09-10 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -98,7 +98,7 @@ dependencies:
|
|
98
98
|
requirements:
|
99
99
|
- - ~>
|
100
100
|
- !ruby/object:Gem::Version
|
101
|
-
version: 0.3.
|
101
|
+
version: 0.3.6
|
102
102
|
type: :runtime
|
103
103
|
prerelease: false
|
104
104
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -106,7 +106,7 @@ dependencies:
|
|
106
106
|
requirements:
|
107
107
|
- - ~>
|
108
108
|
- !ruby/object:Gem::Version
|
109
|
-
version: 0.3.
|
109
|
+
version: 0.3.6
|
110
110
|
- !ruby/object:Gem::Dependency
|
111
111
|
name: devise
|
112
112
|
requirement: !ruby/object:Gem::Requirement
|
@@ -265,10 +265,7 @@ files:
|
|
265
265
|
- app/views/kaui/accounts/index.html.erb
|
266
266
|
- app/views/kaui/accounts/show.html.erb
|
267
267
|
- app/views/kaui/analytics/account_snapshot.html.erb
|
268
|
-
- app/views/kaui/analytics/accounts_over_time.html.erb
|
269
268
|
- app/views/kaui/analytics/index.html.erb
|
270
|
-
- app/views/kaui/analytics/sanity.html.erb
|
271
|
-
- app/views/kaui/analytics/subscriptions_over_time.html.erb
|
272
269
|
- app/views/kaui/bundle_tags/_bundle_tags_table.html.erb
|
273
270
|
- app/views/kaui/bundle_tags/edit.html.erb
|
274
271
|
- app/views/kaui/bundles/index.html.erb
|
@@ -438,10 +435,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
438
435
|
version: '0'
|
439
436
|
segments:
|
440
437
|
- 0
|
441
|
-
hash:
|
438
|
+
hash: 2214569211670130331
|
442
439
|
requirements: []
|
443
440
|
rubyforge_project:
|
444
|
-
rubygems_version: 1.8.
|
441
|
+
rubygems_version: 1.8.25
|
445
442
|
signing_key:
|
446
443
|
specification_version: 3
|
447
444
|
summary: Killbill Admin UI plugin
|
@@ -1,47 +0,0 @@
|
|
1
|
-
<h2>Accounts not passing sanity checks</h2>
|
2
|
-
<table class="table table-condensed table-striped data-table right-aligned">
|
3
|
-
<thead>
|
4
|
-
<tr>
|
5
|
-
<th>Check</th>
|
6
|
-
<th>Account id</th>
|
7
|
-
<th></th>
|
8
|
-
</tr>
|
9
|
-
</thead>
|
10
|
-
<tbody>
|
11
|
-
<% @sanity.check_entitlement.each do |account_id| %>
|
12
|
-
<tr class="error">
|
13
|
-
<td>Entitlement</td>
|
14
|
-
<td><%= link_to account_id, account_path(account_id) %></td>
|
15
|
-
<td><%= button_to "Refresh!", { :action => "refresh_account", :account_id => account_id } %></td>
|
16
|
-
</tr>
|
17
|
-
<% end %>
|
18
|
-
<% @sanity.check_invoice.each do |account_id| %>
|
19
|
-
<tr class="error">
|
20
|
-
<td>Invoice</td>
|
21
|
-
<td><%= link_to account_id, account_path(account_id) %></td>
|
22
|
-
<td><%= button_to "Refresh!", { :action => "refresh_account", :account_id => account_id } %></td>
|
23
|
-
</tr>
|
24
|
-
<% end %>
|
25
|
-
<% @sanity.check_payment.each do |account_id| %>
|
26
|
-
<tr class="error">
|
27
|
-
<td>Payment</td>
|
28
|
-
<td><%= link_to account_id, account_path(account_id) %></td>
|
29
|
-
<td><%= button_to "Refresh!", { :action => "refresh_account", :account_id => account_id } %></td>
|
30
|
-
</tr>
|
31
|
-
<% end %>
|
32
|
-
<% @sanity.check_tag.each do |account_id| %>
|
33
|
-
<tr class="error">
|
34
|
-
<td>Tag</td>
|
35
|
-
<td><%= link_to account_id, account_path(account_id) %></td>
|
36
|
-
<td><%= button_to "Refresh!", { :action => "refresh_account", :account_id => account_id } %></td>
|
37
|
-
</tr>
|
38
|
-
<% end %>
|
39
|
-
<% @sanity.check_consistency.each do |account_id| %>
|
40
|
-
<tr class="error">
|
41
|
-
<td>Consistency</td>
|
42
|
-
<td><%= link_to account_id, account_path(account_id) %></td>
|
43
|
-
<td><%= button_to "Refresh!", { :action => "refresh_account", :account_id => account_id } %></td>
|
44
|
-
</tr>
|
45
|
-
<% end %>
|
46
|
-
</tbody>
|
47
|
-
</table>
|
@@ -1,9 +0,0 @@
|
|
1
|
-
<h2>Number of <%= @slug %> <%= @product_type %> subscriptions created over time</h2>
|
2
|
-
|
3
|
-
<div id="chart"></div>
|
4
|
-
|
5
|
-
<%= javascript_tag do %>
|
6
|
-
$(document).ready(function() {
|
7
|
-
drawGraph(<%=raw @subscriptions.dates.to_json %>, <%=raw @subscriptions.values.to_json %>, "chart");
|
8
|
-
});
|
9
|
-
<% end %>
|