killbill-deposit 1.0.5 → 2.0.0

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
  SHA256:
3
- metadata.gz: 7ad20034124fdc20423c098a933a8f72abb17749efa0140fdcaa7de1c155628d
4
- data.tar.gz: a3441c430d91c047331258b577ab2711127b962fe684dbde20978022ebfe98a8
3
+ metadata.gz: 22ee31f5dcf3eec40e39a589d78e7922173c68cfadfe1e02984e7ee3f3f6e3ed
4
+ data.tar.gz: bf0bafc7ab5bb48e27ae239b4f5a64431f8cdf663cddaaba2f8f3d9ed92d85f9
5
5
  SHA512:
6
- metadata.gz: d94d90153fa95d68a81e9f523628bbc339a18ab3a55f87f4d528564a640ea8ac02c991541fbc34dbeeabc2aa7a6879abf6c942f01a6f3d9c4ae97f4a6587f0d5
7
- data.tar.gz: 37e0906c7eea36cd9c82f71f29b8d5611339c45a4f04c8d985646370185c17c80dc34b1451d4a28f5b749c6827d7448cceb27d7b7b1dc0f3a170474712f9f2e0
6
+ metadata.gz: fc682dfb8af5b2d0dd8b6302038b956cd8a2d242f5697b1e791e705b6df4420bf5f368e94568c37013744528c70d15a43ac441281b894aea1d237b1d0a404747
7
+ data.tar.gz: 3c57bf945532c1c9499065feef7fe5929d83b0c2069866543e606086a62f36e012a099f035a279a58666e7058110e905bd9a9221fe65fa47bcabcf404c5a2d92
@@ -11,6 +11,14 @@
11
11
 
12
12
  #deposit_amount_mismatch {
13
13
  text-align: right;
14
- padding-top: 15px;
15
14
  visibility: hidden;
16
15
  }
16
+
17
+ .invoice-table-input {
18
+ border-radius: 8px !important;
19
+ height: 38px !important;
20
+ }
21
+
22
+ #invoices-table_wrapper {
23
+ margin-bottom: 0px;
24
+ }
@@ -1,33 +1,40 @@
1
- <div class="search">
2
-
3
- <div class="column-block">
4
-
5
- <h1>Invoices</h1>
6
-
7
- <table id="invoices-table" class="table table-condensed mobile-data">
8
- <thead>
9
- <tr>
10
- <th>Number</th>
11
- <th>Date</th>
12
- <th>Amount</th>
13
- <th>Balance</th>
14
- <th>Payment</th>
15
- </tr>
16
- </thead>
17
- <tbody>
18
- <tr>
19
- <td colspan="1" class="dataTables_empty">Loading data from server</td>
20
- </tr>
21
- </tbody>
22
- </table>
23
-
24
- <div id="deposit_amount_mismatch" class="text-danger">
25
- Warning! Total amount doesn't match deposit.
1
+ <div class="register add-new-custom-field-details">
2
+ <div class="">
3
+ <div class="mx-auto" style="max-width: 80rem;">
4
+ <h5 class="add-new-custom-field-title border-bottom pb-3 mb-3">
5
+ <span class="icon-container">
6
+ <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
7
+ <path d="M9.58325 9.16699H7.08325" stroke="#414651" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>
8
+ <path d="M12.0833 5.83301H7.08325" stroke="#414651" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>
9
+ <path d="M16.6666 17.917V3.33366C16.6666 2.41318 15.9204 1.66699 14.9999 1.66699H4.99992C4.07944 1.66699 3.33325 2.41318 3.33325 3.33366V17.917L6.66659 16.2503L9.99992 18.3337L13.3333 16.2503L16.6666 17.917Z" stroke="#414651" stroke-width="1.5" stroke-linejoin="round"></path>
10
+ </svg>
11
+ </span>
12
+ Invoices
13
+ </h5>
14
+ <table id="invoices-table" class="table table-condensed mobile-data">
15
+ <thead>
16
+ <tr>
17
+ <th>Number</th>
18
+ <th>Date</th>
19
+ <th>Amount</th>
20
+ <th>Balance</th>
21
+ <th>Payment</th>
22
+ </tr>
23
+ </thead>
24
+ <tbody>
25
+ <tr>
26
+ <td colspan="1" class="dataTables_empty">Loading data from server</td>
27
+ </tr>
28
+ </tbody>
29
+ </table>
30
+ <div id="deposit_amount_mismatch" class="text-danger">
31
+ Warning! Total amount doesn't match deposit.
32
+ </div>
26
33
  </div>
27
34
  </div>
28
-
29
35
  </div>
30
36
 
37
+
31
38
  <%= javascript_tag do %>
32
39
  $(document).ready(function() {
33
40
  var table = $('#invoices-table').DataTable({
@@ -44,7 +51,7 @@ $(document).ready(function() {
44
51
  }
45
52
  ],
46
53
  createdRow: function(row, data, dataIndex) {
47
- $('td', row).eq(4).html('<input class="payment_amount_invoice" type="number" name="payment_amount_' + data[0] + '" id="payment_amount_' + dataIndex + '" step="any" class="form-control" value="0">')
54
+ $('td', row).eq(4).html('<input class="payment_amount_invoice form-control invoice-table-input" type="number" name="payment_amount_' + data[0] + '" id="payment_amount_' + dataIndex + '" step="any" value="0">')
48
55
  },
49
56
  drawCallback: function() {
50
57
  $('input').change(function() {
@@ -1,32 +1,32 @@
1
1
  <%= form_tag do_record_payments_path, :class => 'form-horizontal' do %>
2
- <div class="form-group">
3
- <%= label_tag :account_id, 'Account ID', :class => 'col-sm-2 control-label' %>
4
- <div class="col-sm-5">
2
+ <div class="form-group d-flex pb-3">
3
+ <%= label_tag :account_id, 'Account ID', :class => 'col-sm-3 control-label' %>
4
+ <div class="col-sm-9">
5
5
  <%= text_field_tag :account_id, @account_id, :class => 'form-control', :readonly => !@account_id.nil?, :required => true %>
6
6
  </div>
7
7
  </div>
8
- <div class="form-group">
9
- <%= label_tag :payment_amount, 'Amount Received', :class => 'col-sm-2 control-label' %>
10
- <div class="col-sm-2">
8
+ <div class="form-group d-flex pb-3">
9
+ <%= label_tag :payment_amount, 'Amount Received', :class => 'col-sm-3 control-label' %>
10
+ <div class="col-sm-9">
11
11
  <%= number_field_tag :payment_amount, nil, :step => :any, :id => 'payment_amount', :class => 'form-control', :required => true %>
12
- <p class="help-block">Currency: <%= @currency %></p>
12
+ <p class="help-block mb-0">Currency: <%= @currency %></p>
13
13
  </div>
14
14
  </div>
15
- <div class="form-group">
16
- <%= label_tag :effective_date, 'Payment Date', :class => 'col-sm-2 control-label' %>
17
- <div class="col-sm-2">
15
+ <div class="form-group d-flex pb-3">
16
+ <%= label_tag :effective_date, 'Payment Date', :class => 'col-sm-3 control-label' %>
17
+ <div class="col-sm-9">
18
18
  <%= text_field_tag :effective_date, Date.parse(Time.now.to_s).to_s, :class => 'form-control date-picker', :required => true, :data =>{:provide => 'datepicker', 'date-format': "yyyy-mm-dd"} %>
19
19
  </div>
20
20
  </div>
21
- <div class="form-group">
22
- <%= label_tag :payment_reference_number, 'Payment Ref. #', :class => 'col-sm-2 control-label' %>
23
- <div class="col-sm-10">
21
+ <div class="form-group d-flex pb-3">
22
+ <%= label_tag :payment_reference_number, 'Payment Ref. #', :class => 'col-sm-3 control-label' %>
23
+ <div class="col-sm-9">
24
24
  <%= text_field_tag :payment_reference_number, nil, :class => 'form-control', :required => true %>
25
25
  </div>
26
26
  </div>
27
- <div class="form-group">
28
- <%= label_tag :deposit_type, 'Payment Mode', :class => 'col-sm-2 control-label' %>
29
- <div class="col-sm-3">
27
+ <div class="form-group d-flex">
28
+ <%= label_tag :deposit_type, 'Payment Mode', :class => 'col-sm-3 control-label' %>
29
+ <div class="col-sm-9">
30
30
  <%= select_tag :deposit_type, options_for_select(Deposit.deposit_types), :class => 'form-control' %>
31
31
  </div>
32
32
  </div>
@@ -37,10 +37,16 @@
37
37
  <% end %>
38
38
  </div>
39
39
 
40
- <div class="form-group">
41
- <div class="col-sm-offset-2 col-sm-10">
42
- <%= submit_tag 'Save', :id => 'submit-btn', :class => 'btn btn-default' %>
43
- </div>
40
+ <div class="form-group d-flex justify-content-end pb-3 mt-3 border-top pt-3">
41
+ <%= render "kaui/components/button/button", {
42
+ label: 'Save',
43
+ variant: "outline-secondary d-inline-flex align-items-center gap-1",
44
+ type: "submit",
45
+ html_class: "kaui-dropdown custom-hover px-4",
46
+ html_options: {
47
+ id: "saveButton"
48
+ }
49
+ } %>
44
50
  </div>
45
51
  <% end %>
46
52
 
@@ -1,10 +1,17 @@
1
- <div class="register">
2
- <div class="col-md-10 col-md-offset-1">
3
-
4
- <div class="column-block">
5
- <h1>Record Payment</h1>
1
+ <div class="register add-new-custom-field-details">
2
+ <div class="">
3
+ <div class="mx-auto" style="<%= @account_id.nil? ? 'max-width: 40rem;' : 'max-width: 80rem;' %>">
4
+ <h5 class="add-new-custom-field-title border-bottom pb-3 mb-3">
5
+ <span class="icon-container">
6
+ <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
7
+ <path d="M16.6667 3.33325H3.33341C2.41294 3.33325 1.66675 4.07944 1.66675 4.99992V14.9999C1.66675 15.9204 2.41294 16.6666 3.33341 16.6666H16.6667C17.5872 16.6666 18.3334 15.9204 18.3334 14.9999V4.99992C18.3334 4.07944 17.5872 3.33325 16.6667 3.33325Z" stroke="#414651" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
8
+ <path d="M8.33325 13.3333H9.58325M12.0833 13.3333H14.9999" stroke="#414651" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
9
+ <path d="M1.66675 7.5H18.3334" stroke="#414651" stroke-width="1.5" stroke-linecap="square" stroke-linejoin="round"/>
10
+ </svg>
11
+ </span>
12
+ Record Payment
13
+ </h5>
6
14
  <%= render 'payment_form' %>
7
15
  </div>
8
-
9
16
  </div>
10
17
  </div>
@@ -0,0 +1,8 @@
1
+ <%#
2
+ This is a placeholder breadcrumb component for standalone gem usage.
3
+
4
+ This placeholder prevents "missing template" errors when running
5
+ the gem independently during development or testing.
6
+ %>
7
+
8
+ <!-- Breadcrumb placeholder for standalone gem -->
@@ -8,7 +8,7 @@ module Killbill
8
8
  class << self
9
9
  def record_payments(account_id, effective_date, payment_reference_number, deposit_type, invoice_payments, user = nil, reason = nil, comment = nil, options = {})
10
10
  payments = []
11
- invoice_payments.each do |invoice_number, payment_amount|
11
+ invoice_payments.map do |invoice_number, payment_amount|
12
12
  payments << { invoiceNumber: invoice_number, paymentAmount: payment_amount }
13
13
  end
14
14
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Deposit
4
- VERSION = '1.0.5'
4
+ VERSION = '2.0.0'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: killbill-deposit
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.5
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kill Bill core team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-04-10 00:00:00.000000000 Z
11
+ date: 2025-11-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: killbill-assets-ui
@@ -87,6 +87,7 @@ files:
87
87
  - app/views/deposit/collection/_payment_form.html.erb
88
88
  - app/views/deposit/collection/index.html.erb
89
89
  - app/views/deposit/layouts/deposit_application.html.erb
90
+ - app/views/kaui/components/button/_button.html.erb
90
91
  - config/routes.rb
91
92
  - lib/deposit.rb
92
93
  - lib/deposit/client.rb