istox 0.1.157.11.3 → 0.1.157.11.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3d067ecdccbccbfda95b176b7fcaf3629810dc30d3c7b2f45d820ed861695bac
4
- data.tar.gz: 7ac2412f8eae5bc934970d4db789fc2cd3b67dac13a27a9164a4b97817ad46cc
3
+ metadata.gz: ad9280d41ae6de8ee941f75d80dac2ecacaf0a2e0d7d884f3d7e7839c07cbc68
4
+ data.tar.gz: e17f4f264ec1c0bc00232c32996ef7e63ab7ae38b0492201556bfbc86371e541
5
5
  SHA512:
6
- metadata.gz: 600c82875347e54e1aa6bd919e98a61aebd9322656e4f9dc086870f4e4bd7102bd38c33bf48719f1d61f8e03a74a644b6b75e91e3d2b47d881a295c2735ee0d3
7
- data.tar.gz: 9bb9ca6578621d84697f170511ba8d5d4fb591189eb9ccaf02e2657b4b6ad4323d1554be239142ea70069ff88b163743d1c7030838a6c849aaee7c95930ecbb8
6
+ metadata.gz: b48333122a8469840cd7a2d3ac308aa0a864af99c01950d568b1b99cce6ea9628f043c9845e5fe86fed83e9393a767bbda022c33a6e9316866cdf6ad756c9679
7
+ data.tar.gz: 692621c761f6df109524252d9fccf9f798a48f98ba7032b1fd6401ab875586b5e36641d7df57674fe706549eeb76c845302c1e371ed7d4f9342bce9dad2ebc49
@@ -17,11 +17,13 @@ module Istox
17
17
  end
18
18
 
19
19
  # format a money, eg. 20000.134 > SGD 20,000.14, position can be :front or :behind, abs_num: whether to absolute the number
20
- def money(input, round_mode: :half_up, precision: 2, currency:, position: :front, abs_num: false)
20
+ def money(input, round_mode: :half_up, precision: 2, currency:, position: :front, abs_num: false, hide_currency: false)
21
21
  precision = 0 if currency&.downcase == 'jpy'
22
22
 
23
23
  result = number(input, round_mode: round_mode, precision: precision, abs_num: abs_num)
24
24
 
25
+ return result if hide_currency
26
+
25
27
  return currency + ' ' + result if position == :front
26
28
 
27
29
  result + ' ' + currency
data/lib/istox/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Istox
2
- VERSION = '0.1.157.11.3'.freeze
2
+ VERSION = '0.1.157.11.4'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: istox
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.157.11.3
4
+ version: 0.1.157.11.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Siong Leng
@@ -546,7 +546,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
546
546
  - !ruby/object:Gem::Version
547
547
  version: '0'
548
548
  requirements: []
549
- rubygems_version: 3.1.3
549
+ rubygems_version: 3.2.11
550
550
  signing_key:
551
551
  specification_version: 4
552
552
  summary: istox backend shared gem