kaui 4.0.27 → 4.0.28

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: c47eb567efa6cc63312500bf5c3b9d14c7ee2aad9e20e2211badc2fe5812c669
4
- data.tar.gz: a711e1b5e1edf9525bade23dd0a1ff5ffdc9d86b0516f38ba051e8c8c1f07fc8
3
+ metadata.gz: 1e729c6fc5b318da0970ac53952495ace863cb116267af5774c235aa2012e14c
4
+ data.tar.gz: 1a7fb48b4e653dd6d4a136f37e297cd66ce2ee1fc33ab89cf2adec6e1eacd35a
5
5
  SHA512:
6
- metadata.gz: e7b440f6de6e78902d8f32322afc5fa57d548c042f8d76187126eb74b4a78f9ae29b346f4b250448ea3b8299b572cc230e4340efbab2f3de9585459e58c3b9a0
7
- data.tar.gz: 19f73d170488453def09356e5f55fb495dd4a12f9c1933cf012ae84d1c9cfd8521d8459d1b8b77d43610924243cf0a2399582ca3a48a598de7f0ce09091cf7bf
6
+ metadata.gz: 9a3eed6c7fe79ef695471e02db83ab562e7da2e355f712d9876f971a28db4b86fa9de278c5925aded58a183009555c87f30dadbc0568ac6386b4c5d929c9d0bc
7
+ data.tar.gz: 45bd2f51b5de3217c0bc50edf837456b797d99cd568e96cd5c674cbd4812c82418d51c90c6449ee7e830af8c28e86c61529df9554c958b7e4f9b9d9d6f798189
@@ -0,0 +1,29 @@
1
+ <svg width="32" height="32" viewBox="-1 -1 38.5 38.5" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M8.96891 13.6363L17.1663 16.2316L19.867 20.7179L7.22926 20.294L5.87472 17.7276C4.70442 15.5102 6.6717 12.9089 8.96891 13.6363Z" fill="url(#paint0_linear_5656_117635)"/>
3
+ <path d="M2.73109 18.8862L23.0656 19.4261L31.0472 32.6526C31.9039 34.0722 30.9562 35.9453 29.3786 35.9506L14.6421 36C12.8282 36.0061 11.0908 35.2177 9.83259 33.8178L0.749744 23.712C-0.899153 21.8774 0.354861 18.8231 2.73109 18.8862Z" fill="url(#paint1_linear_5656_117635)"/>
4
+ <path d="M20.5179 0.919922L15.7246 7.75567L23.189 11.3725L24.8913 4.89582L20.5179 0.919922Z" fill="url(#paint2_linear_5656_117635)"/>
5
+ <path d="M27.5141 34.8764L15.4574 13.4093C14.4372 11.5929 14.565 9.35199 15.785 7.66255C16.4888 6.68792 17.8875 6.54241 18.778 7.35118L34.1718 21.3321C36.1567 23.1348 36.5779 26.0884 35.1757 28.371L31.1361 34.9469C30.2983 36.3107 28.2978 36.2717 27.5141 34.8764Z" fill="url(#paint3_linear_5656_117635)"/>
6
+ <path d="M32.0753 11.0799L21.0977 3.84213C19.1972 2.5891 20.3796 -0.360792 22.623 0.0364992L27.8828 0.967948C29.1553 1.19329 30.1995 2.09954 30.5986 3.32489L32.9165 10.4422C33.0801 10.9445 32.5171 11.3713 32.0753 11.0799Z" fill="url(#paint4_linear_5656_117635)"/>
7
+ <defs>
8
+ <linearGradient id="paint0_linear_5656_117635" x1="6.3713" y1="14.584" x2="17.3232" y2="20.2038" gradientUnits="userSpaceOnUse">
9
+ <stop stop-color="#004EEB"/>
10
+ <stop offset="1" stop-color="#2970FF"/>
11
+ </linearGradient>
12
+ <linearGradient id="paint1_linear_5656_117635" x1="1.04487" y1="21.155" x2="29.4032" y2="32.4876" gradientUnits="userSpaceOnUse">
13
+ <stop stop-color="#2970FF"/>
14
+ <stop offset="1" stop-color="#7CD4FD"/>
15
+ </linearGradient>
16
+ <linearGradient id="paint2_linear_5656_117635" x1="19.8881" y1="9.67384" x2="23.8884" y2="4.93559" gradientUnits="userSpaceOnUse">
17
+ <stop stop-color="#A6EF67"/>
18
+ <stop offset="1" stop-color="#FDE172"/>
19
+ </linearGradient>
20
+ <linearGradient id="paint3_linear_5656_117635" x1="15.1997" y1="8.83686" x2="29.3077" y2="34.3257" gradientUnits="userSpaceOnUse">
21
+ <stop stop-color="#A6EF67"/>
22
+ <stop offset="1" stop-color="#15B79E"/>
23
+ </linearGradient>
24
+ <linearGradient id="paint4_linear_5656_117635" x1="20.833" y1="1.40851" x2="32.7401" y2="9.43028" gradientUnits="userSpaceOnUse">
25
+ <stop stop-color="#FDE172"/>
26
+ <stop offset="1" stop-color="#EAAA08"/>
27
+ </linearGradient>
28
+ </defs>
29
+ </svg>
@@ -30,11 +30,23 @@ function searchParseOperatorText(text) {
30
30
  function getUrlParams() {
31
31
  var params = {};
32
32
  var advanceSearchQuery = new URLSearchParams(window.location.search).get('advance_search_query');
33
- var queryString = advanceSearchQuery !== null ? advanceSearchQuery : window.location.search.substring(1).replace(/ac_id/g, 'account_id');
33
+ // URLSearchParams already decoded advance_search_query (e.g. 'name[like]=%test%'), so it must not be decoded
34
+ // again: decodeURIComponent throws on the bare '%' of a LIKE value, which aborts the table's draw handler
35
+ // and leaves the DataTables loading indicator on screen.
36
+ var alreadyDecoded = advanceSearchQuery !== null;
37
+ var queryString = alreadyDecoded ? advanceSearchQuery : window.location.search.substring(1).replace(/ac_id/g, 'account_id');
38
+ var decode = function(s) {
39
+ if (alreadyDecoded) return s;
40
+ try {
41
+ return decodeURIComponent(s);
42
+ } catch (e) {
43
+ return s;
44
+ }
45
+ };
34
46
  var regex = /([^&=]+)=([^&]*)/g;
35
47
  var m;
36
48
  while (m = regex.exec(queryString)) {
37
- params[decodeURIComponent(m[1])] = decodeURIComponent(m[2]);
49
+ params[decode(m[1])] = decode(m[2]);
38
50
  }
39
51
  return params;
40
52
  }
@@ -442,7 +454,15 @@ $(document).ready(function() {
442
454
  var searches = getSavedSearches();
443
455
  var params = searches[name];
444
456
  if (params) {
445
- var newUrl = window.location.protocol + "//" + window.location.host + window.location.pathname + '?' + params;
457
+ var query;
458
+ if (params.indexOf('_q=1') === 0) {
459
+ // Advanced search: same URL format as the Apply button (see _advanced_search_filterbar.html.erb),
460
+ // which is the one understood by the accounts, invoices and payments pages
461
+ query = 'advance_search_query=' + encodeURIComponent(decodeURIComponent(params));
462
+ } else {
463
+ query = params;
464
+ }
465
+ var newUrl = window.location.protocol + "//" + window.location.host + window.location.pathname + '?' + query;
446
466
  window.location.href = newUrl;
447
467
  }
448
468
  });
@@ -108,7 +108,7 @@ $(document).ready(function() {
108
108
  url: "<%= accounts_pagination_path(:ordering => @ordering, :format => :json) %>",
109
109
  headers: {"X-CSRF-Token": $("meta[name='csrf-token']").attr("content")},
110
110
  data: function(d) {
111
- d.advance_search_query = "<%= j(@advance_search_query.to_s) %>";
111
+ d.advance_search_query = "<%= raw j(@advance_search_query.to_s) %>"; // raw: ERB would turn '&' into '&amp;'; j() already makes it safe for a JS string
112
112
  return d;
113
113
  },
114
114
  dataSrc: function(json) {
@@ -4,6 +4,7 @@
4
4
  <meta name="viewport" content="width=device-width, initial-scale=1">
5
5
 
6
6
  <title>Kaui</title>
7
+ <%= favicon_link_tag 'kaui/favicon.svg', rel: 'icon', type: 'image/svg+xml' %>
7
8
  <%= stylesheet_link_tag 'application', :media => 'all' %>
8
9
  <%= javascript_include_tag 'application' %>
9
10
 
data/lib/kaui/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Kaui
4
- VERSION = '4.0.27'
4
+ VERSION = '4.0.28'
5
5
  end
data/lib/kaui.rb CHANGED
@@ -172,7 +172,7 @@ module Kaui
172
172
  values = fields.map do |attr|
173
173
  case attr
174
174
  when 'auth_amount', 'captured_amount', 'purchased_amount', 'refunded_amount', 'credited_amount'
175
- view_context.humanized_money_with_symbol(payment&.send(attr.downcase))
175
+ view_context.humanized_money_with_symbol(payment&.send("#{attr.downcase}_to_money"))
176
176
  when 'payment_number'
177
177
  view_context.link_to(payment.payment_number, view_context.url_for(controller: :payments, action: :show, account_id: payment.account_id, id: payment.payment_id))
178
178
  when 'payment_date'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kaui
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.27
4
+ version: 4.0.28
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: 2026-10-06 00:00:00.000000000 Z
11
+ date: 2026-10-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: actionpack
@@ -339,6 +339,7 @@ files:
339
339
  - app/assets/images/kaui/duck.png
340
340
  - app/assets/images/kaui/eye-off.svg
341
341
  - app/assets/images/kaui/eye.svg
342
+ - app/assets/images/kaui/favicon.svg
342
343
  - app/assets/images/kaui/file-upload.svg
343
344
  - app/assets/images/kaui/generate.svg
344
345
  - app/assets/images/kaui/header/account.svg
@@ -735,7 +736,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
735
736
  - !ruby/object:Gem::Version
736
737
  version: '0'
737
738
  requirements: []
738
- rubygems_version: 3.4.10
739
+ rubygems_version: 3.4.19
739
740
  signing_key:
740
741
  specification_version: 4
741
742
  summary: Killbill Admin UI mountable engine