kaui 0.1.12 → 0.1.14

Sign up to get free protection for your applications and to get access to all the features.
@@ -61,16 +61,16 @@
61
61
  </td>
62
62
  <td><%= "INVOICE" %></td>
63
63
  <td><span class="hide" title="<%= invoice.invoice_number %>"></span>
64
- <%= "Amount:" %> <%= humanized_money_with_symbol invoice.amount_to_money(@account.currency) %><br/>
65
- <%= "Balance:" %> <%= humanized_money_with_symbol invoice.balance_to_money(@account.currency) %><br/>
64
+ <%= "Amount:" %> <%= humanized_money_with_symbol invoice.amount_to_money(@account.currency) %> (<%= @account.currency %>)<br/>
65
+ <%= "Balance:" %> <%= humanized_money_with_symbol invoice.balance_to_money(@account.currency) %> (<%= @account.currency %>)<br/>
66
66
  <% if invoice.credit_adjustment.present? && invoice.credit_adjustment > 0 %>
67
- <%= "Credit adjustment:" %> <%= humanized_money_with_symbol invoice.credit_adjustment_to_money(@account.currency) %><br/>
67
+ <%= "Credit adjustment:" %> <%= humanized_money_with_symbol invoice.credit_adjustment_to_money(@account.currency) %> (<%= @account.currency %>)<br/>
68
68
  <% end %>
69
69
  <% if invoice.credit_balance_adjustment.present? && invoice.credit_balance_adjustment > 0 %>
70
- <%= "Credit balance adjustment:" %> <%= humanized_money_with_symbol invoice.credit_balance_adjustment_to_money(@account.currency) %><br/>
70
+ <%= "Credit balance adjustment:" %> <%= humanized_money_with_symbol invoice.credit_balance_adjustment_to_money(@account.currency) %> (<%= @account.currency %>)<br/>
71
71
  <% end %>
72
72
  <% if invoice.refund_adjustment.present? && invoice.refund_adjustment < 0 %>
73
- <%= "Refund adjustment:" %> <%= humanized_money_with_symbol invoice.refund_adjustment_to_money(@account.currency) %><br/>
73
+ <%= "Refund adjustment:" %> <%= humanized_money_with_symbol invoice.refund_adjustment_to_money(@account.currency) %> (<%= @account.currency %>)<br/>
74
74
  <% end %>
75
75
  <%= "Invoice #" %>
76
76
  <%= link_to invoice.invoice_number, invoice_path(:id => invoice.invoice_id) %>
@@ -131,7 +131,7 @@
131
131
  <td>
132
132
  <%= "Adjusted:" %> <% if refund.adjusted %>yes<% else %>no<% end %><br/>
133
133
  <%= "Payment id:" %> <%= refund.payment_id %><br/>
134
- <%= "Refund Amount:" %> <%= humanized_money_with_symbol refund.amount_to_money %><br/>
134
+ <%= "Refund Amount:" %> <%= humanized_money_with_symbol refund.amount_to_money %> (<%= refund.currency %>)<br/>
135
135
  </td>
136
136
  <td>
137
137
  <% if refund.audit_logs.present? %>
@@ -168,7 +168,7 @@
168
168
  <td><%= "CHARGEBACK" %></td>
169
169
  <td>
170
170
  <%= "Payment id:" %> <%= chargeback.payment_id %><br/>
171
- <%= "Chargeback Amount:" %> <%= humanized_money_with_symbol chargeback.chargeback_amount_to_money(@account.currency) %><br/>
171
+ <%= "Chargeback Amount:" %> <%= humanized_money_with_symbol chargeback.chargeback_amount_to_money(payment.currency) %> (<%= payment.currency %>)<br/>
172
172
  </td>
173
173
  <td>
174
174
  <% if chargeback.audit_logs.present? %>
@@ -211,8 +211,8 @@
211
211
  <td>
212
212
  <span class="hide" title="<%= invoice.invoice_number %>"></span>
213
213
  <%= "Payment id:" %> <%= payment.payment_id %><br/>
214
- <%= "Total amount:" %> <%= humanized_money_with_symbol payment.amount_to_money %><br/>
215
- <%= "Paid amount:" %> <%= humanized_money_with_symbol payment.paid_amount_to_money %><br/>
214
+ <%= "Total amount:" %> <%= humanized_money_with_symbol payment.amount_to_money %> (<%= payment.currency %>)<br/>
215
+ <%= "Paid amount:" %> <%= humanized_money_with_symbol payment.paid_amount_to_money %> (<%= payment.currency %>)<br/>
216
216
  <span <% if payment.status == 'FAILED' %>class="alert-error" <% elsif payment.status == 'SUCCESS' %>class="alert-success" <% end %>>
217
217
  <%= payment.status %>
218
218
  </span>
@@ -34,9 +34,9 @@
34
34
  <% if @account.balance.nil? %>
35
35
  <dd>unknown
36
36
  <% elsif @account.balance <= 0 %>
37
- <dd><span class="label label-success" ><%= humanized_money_with_symbol @account.balance_to_money %></span>
37
+ <dd><span class="label label-success" ><%= humanized_money_with_symbol @account.balance_to_money %> (<%= @account.currency %>)</span>
38
38
  <% else %>
39
- <dd><span class="label label-important" ><%= humanized_money_with_symbol @account.balance_to_money %></span>
39
+ <dd><span class="label label-important" ><%= humanized_money_with_symbol @account.balance_to_money %> (<%= @account.currency %>)</span>
40
40
  <% end %>
41
41
  &nbsp;
42
42
  <nobr>
@@ -61,9 +61,9 @@
61
61
  <% if @account.cba.nil? %>
62
62
  <dd>unknown
63
63
  <% elsif @account.cba >= 0 %>
64
- <dd><span class="label label-success" ><%= humanized_money_with_symbol @account.cba_to_money %></span>
64
+ <dd><span class="label label-success" ><%= humanized_money_with_symbol @account.cba_to_money %> (<%= @account.currency %>)</span>
65
65
  <% else %>
66
- <dd><span class="label label-important" ><%= humanized_money_with_symbol @account.cba_to_money %></span>
66
+ <dd><span class="label label-important" ><%= humanized_money_with_symbol @account.cba_to_money %> (<%= @account.currency %>)</span>
67
67
  <% end %>
68
68
  </dd>
69
69
  <dt>Notified for inv?</dt>
@@ -9,9 +9,9 @@
9
9
  <dt>Target date:</dt>
10
10
  <dd><%= format_date(@invoice.target_date).html_safe %>&nbsp;</dd>
11
11
  <dt>Amount:</dt>
12
- <dd><%= humanized_money_with_symbol @invoice.amount_to_money(@account.currency) %>&nbsp;</dd>
12
+ <dd><%= humanized_money_with_symbol @invoice.amount_to_money(@account.currency) %> (<%= @account.currency %>)&nbsp;</dd>
13
13
  <dt>Balance:</dt>
14
- <dd><%= humanized_money_with_symbol @invoice.balance_to_money(@account.currency) %>&nbsp;</dd>
14
+ <dd><%= humanized_money_with_symbol @invoice.balance_to_money(@account.currency) %> (<%= @account.currency %>)&nbsp;</dd>
15
15
  </dl>
16
16
  <div class="page-header">
17
17
  <h3>Invoice items</h3>
@@ -58,7 +58,7 @@
58
58
  <td onClick="hightlightLinkedItems('<%= item.invoice_item_id %>', '<%= item.linked_invoice_item_id %>'); return false;"><%= format_date(item.end_date).html_safe if item.end_date %></td>
59
59
  <td onClick="hightlightLinkedItems('<%= item.invoice_item_id %>', '<%= item.linked_invoice_item_id %>'); return false;"><%= format_date(sub.charged_through_date).html_safe if sub.present? %></td>
60
60
  <td onClick="hightlightLinkedItems('<%= item.invoice_item_id %>', '<%= item.linked_invoice_item_id %>'); return false;"><%= sub.price_list.downcase.capitalize if sub.present? and sub.price_list.present? %></td>
61
- <td onClick="hightlightLinkedItems('<%= item.invoice_item_id %>', '<%= item.linked_invoice_item_id %>'); return false;"><%= humanized_money_with_symbol item.amount_to_money %></td>
61
+ <td onClick="hightlightLinkedItems('<%= item.invoice_item_id %>', '<%= item.linked_invoice_item_id %>'); return false;"><%= humanized_money_with_symbol item.amount_to_money %> (<%= item.currency %>)</td>
62
62
  <td>
63
63
  <nobr>
64
64
  <%= link_to "Adjust",
@@ -70,7 +70,7 @@
70
70
  kaui_engine.invoice_item_path(item.invoice_item_id, :account_id => @invoice.account_id, :invoice_id => @invoice.invoice_id),
71
71
  :confirm => 'Are you sure?',
72
72
  :method => :delete,
73
- :class => "btn btn-mini #{"disabled" unless item.description =~ /account credit/ and item.amount > 0 and item.linked_invoice_item_id.nil? and !@cba_items_not_deleteable.include?(item.invoice_item_id)}" %>
73
+ :class => "btn btn-mini #{"disabled" unless item.description =~ /account credit/ and item.amount > 0 and item.linked_invoice_item_id.nil? and !@cba_items_not_deleteable.include?(item.invoice_item_id) and @invoice.balance - item.amount >= 0}" %>
74
74
  </nobr>
75
75
  </td>
76
76
  </tr>
@@ -20,8 +20,8 @@
20
20
  <tr>
21
21
  <td><%= format_date(payment.requested_date).html_safe if payment.requested_date.present? %></td>
22
22
  <td><%= format_date(payment.effective_date).html_safe if payment.effective_date.present? %></td>
23
- <td><%= humanized_money_with_symbol payment.amount_to_money %></td>
24
- <td><%= humanized_money_with_symbol payment.paid_amount_to_money %></td>
23
+ <td><%= humanized_money_with_symbol payment.amount_to_money %> (<%= payment.currency %>)</td>
24
+ <td><%= humanized_money_with_symbol payment.paid_amount_to_money %> (<%= payment.currency %>)</td>
25
25
  <td></td>
26
26
  <td><%= payment.ext_first_payment_id_ref %> <%= " / " if payment.ext_second_payment_id_ref.present? %> <%= payment.ext_second_payment_id_ref %></td>
27
27
  <td><%= payment.retry_count %></td>
@@ -29,7 +29,7 @@
29
29
  </div>
30
30
  </div>
31
31
  <div class="control-group">
32
- <%= label_tag :policy, "Policy (leave blank for default):", :class => "control-label" %>
32
+ <%= label_tag :policy, "Policy Override (leave blank for default; select an option to force plan change):", :class => "control-label" %>
33
33
  <div class="controls">
34
34
  <%= select_tag :policy, options_for_select(['', 'IMMEDIATE', 'END_OF_TERM']) %>
35
35
  </div>
data/lib/kaui/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Kaui
2
- VERSION = "0.1.12"
2
+ VERSION = "0.1.14"
3
3
  end