webtranslateit-payday 1.6.0 → 1.6.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +1 -0
- data/.rubocop_todo.yml +2 -10
- data/CHANGELOG.md +12 -0
- data/Gemfile +1 -0
- data/Gemfile.lock +10 -6
- data/{lib/payday/locale/de.yml → config/locales/payday.de.yml} +0 -0
- data/{lib/payday/locale/en.yml → config/locales/payday.en.yml} +1 -0
- data/{lib/payday/locale/es.yml → config/locales/payday.es.yml} +1 -0
- data/{lib/payday/locale/fr.yml → config/locales/payday.fr.yml} +1 -0
- data/{lib/payday/locale/nl.yml → config/locales/payday.nl.yml} +0 -0
- data/{lib/payday/locale/zh-CN.yml → config/locales/payday.zh-CN.yml} +0 -0
- data/lib/payday/invoiceable.rb +2 -2
- data/lib/payday/pdf_renderer.rb +1 -1
- data/lib/payday.rb +4 -2
- data/payday.gemspec +2 -1
- data/spec/assets/svg.pdf +56 -61
- data/spec/assets/testing.pdf +32 -29
- data/spec/assets/testing_es.pdf +0 -0
- data/spec/assets/testing_predefined_amount.pdf +0 -0
- data/spec/invoice_spec.rb +15 -0
- metadata +11 -9
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 97ab005c387e2f35351a4e607c175e93e74f65351af082b1b7b00c9eb5b72215
|
4
|
+
data.tar.gz: afdb16ce7c48011a526fb920c98ae1363bad94e48e44118415cd45805c001d37
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4bd104e28920114821cd562c8c478068310d3995af4f04ea3f8dbdcb0b1bec5ed3bee893893512cbaa084340d34b7214468fbfa1be66cc5fcbebb2d8e4350274
|
7
|
+
data.tar.gz: 25583fcdd8373e6ec3fcdd76e0c6fd1b8791f9bb412e9254737caf1da0398566242e3d3661ae210e739cb31ac454bae0e45dded010d5ce87b44837f0bfbb9e46
|
data/.rubocop.yml
CHANGED
data/.rubocop_todo.yml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
# This configuration was generated by
|
2
|
-
# `rubocop --auto-gen-config`
|
3
|
-
# on 2022-
|
2
|
+
# `rubocop --auto-gen-config --exclude-limit 100`
|
3
|
+
# on 2022-08-16 13:38:41 UTC using RuboCop version 1.35.0.
|
4
4
|
# The point is for the user to remove these configuration records
|
5
5
|
# one by one as the offenses are removed from the code base.
|
6
6
|
# Note that changes in the inspected code, or installation of new
|
7
7
|
# versions of RuboCop, may require this file to be generated again.
|
8
|
-
|
9
|
-
# Offense count: 1
|
10
|
-
# Configuration parameters: AllowedConstants.
|
11
|
-
Style/Documentation:
|
12
|
-
Exclude:
|
13
|
-
- 'spec/**/*'
|
14
|
-
- 'test/**/*'
|
15
|
-
- 'lib/generators/payday/setup/setup_generator.rb'
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,17 @@
|
|
1
1
|
# CHANGELOG
|
2
2
|
|
3
|
+
## 1.6.3 (2002-08-29)
|
4
|
+
|
5
|
+
* Fix styling of Notes heading.
|
6
|
+
|
7
|
+
## 1.6.2 (2002-08-16)
|
8
|
+
|
9
|
+
* Use rubocop-performance and fix one performance issue.
|
10
|
+
|
11
|
+
## 1.6.1 (2002-08-16)
|
12
|
+
|
13
|
+
* Fix booting of Payday. It requires the module Payday to be declared.
|
14
|
+
|
3
15
|
## 1.6.0 (2002-08-16)
|
4
16
|
|
5
17
|
* Set up release-drafter.
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
webtranslateit-payday (1.6.
|
4
|
+
webtranslateit-payday (1.6.3)
|
5
5
|
activesupport (~> 7, < 8)
|
6
6
|
i18n (~> 1.12, < 2)
|
7
7
|
money (~> 6.16, < 7)
|
@@ -18,8 +18,8 @@ GEM
|
|
18
18
|
i18n (>= 1.6, < 2)
|
19
19
|
minitest (>= 5.1)
|
20
20
|
tzinfo (~> 2.0)
|
21
|
-
addressable (2.8.
|
22
|
-
public_suffix (>= 2.0.2, <
|
21
|
+
addressable (2.8.1)
|
22
|
+
public_suffix (>= 2.0.2, < 6.0)
|
23
23
|
ast (2.4.2)
|
24
24
|
coderay (1.1.3)
|
25
25
|
concurrent-ruby (1.1.10)
|
@@ -54,7 +54,7 @@ GEM
|
|
54
54
|
lumberjack (1.2.8)
|
55
55
|
matrix (0.4.2)
|
56
56
|
method_source (1.0.0)
|
57
|
-
minitest (5.16.
|
57
|
+
minitest (5.16.3)
|
58
58
|
money (6.16.0)
|
59
59
|
i18n (>= 0.6.4, <= 2)
|
60
60
|
nenv (0.3.0)
|
@@ -77,7 +77,7 @@ GEM
|
|
77
77
|
pry (0.14.1)
|
78
78
|
coderay (~> 1.1)
|
79
79
|
method_source (~> 1.0)
|
80
|
-
public_suffix (
|
80
|
+
public_suffix (5.0.0)
|
81
81
|
rainbow (3.1.1)
|
82
82
|
rb-fsevent (0.11.1)
|
83
83
|
rb-inotify (0.10.1)
|
@@ -97,7 +97,7 @@ GEM
|
|
97
97
|
diff-lcs (>= 1.2.0, < 2.0)
|
98
98
|
rspec-support (~> 3.11.0)
|
99
99
|
rspec-support (3.11.0)
|
100
|
-
rubocop (1.35.
|
100
|
+
rubocop (1.35.1)
|
101
101
|
json (~> 2.3)
|
102
102
|
parallel (~> 1.10)
|
103
103
|
parser (>= 3.1.2.1)
|
@@ -109,6 +109,9 @@ GEM
|
|
109
109
|
unicode-display_width (>= 1.4.0, < 3.0)
|
110
110
|
rubocop-ast (1.21.0)
|
111
111
|
parser (>= 3.1.1.0)
|
112
|
+
rubocop-performance (1.14.3)
|
113
|
+
rubocop (>= 1.7.0, < 2.0)
|
114
|
+
rubocop-ast (>= 0.4.0)
|
112
115
|
rubocop-rspec (2.12.1)
|
113
116
|
rubocop (~> 1.31)
|
114
117
|
ruby-progressbar (1.11.0)
|
@@ -132,6 +135,7 @@ DEPENDENCIES
|
|
132
135
|
matrix
|
133
136
|
rspec (~> 3.11.0)
|
134
137
|
rubocop
|
138
|
+
rubocop-performance
|
135
139
|
rubocop-rspec
|
136
140
|
webtranslateit-payday!
|
137
141
|
|
File without changes
|
File without changes
|
File without changes
|
data/lib/payday/invoiceable.rb
CHANGED
@@ -80,11 +80,11 @@ module Payday
|
|
80
80
|
|
81
81
|
# Iterates through the details on this invoiceable. The block given should accept
|
82
82
|
# two parameters, the detail name and the actual detail value.
|
83
|
-
def each_detail
|
83
|
+
def each_detail
|
84
84
|
return if defined?(invoice_details).nil?
|
85
85
|
|
86
86
|
invoice_details.each do |detail|
|
87
|
-
|
87
|
+
yield(detail[0], detail[1])
|
88
88
|
end
|
89
89
|
end
|
90
90
|
|
data/lib/payday/pdf_renderer.rb
CHANGED
@@ -273,7 +273,7 @@ module Payday
|
|
273
273
|
|
274
274
|
pdf.move_cursor_to(pdf.cursor - 30)
|
275
275
|
pdf.font('NotoSans') do
|
276
|
-
pdf.text(I18n.t('payday.invoice.notes', default: 'Notes', style: :bold)
|
276
|
+
pdf.text(I18n.t('payday.invoice.notes', default: 'Notes'), style: :bold)
|
277
277
|
end
|
278
278
|
pdf.line_width = 0.5
|
279
279
|
pdf.stroke_color = 'cccccc'
|
data/lib/payday.rb
CHANGED
@@ -15,5 +15,7 @@ require 'prawn-svg'
|
|
15
15
|
require 'time'
|
16
16
|
|
17
17
|
# Load translations from the locale folder
|
18
|
-
I18n.
|
19
|
-
|
18
|
+
I18n.load_path.concat(Dir[File.join('config', 'locales', '*.yml')])
|
19
|
+
|
20
|
+
module Payday
|
21
|
+
end
|
data/payday.gemspec
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = 'webtranslateit-payday'
|
5
|
-
s.version = '1.6.
|
5
|
+
s.version = '1.6.3'
|
6
6
|
s.required_ruby_version = '>= 3.1'
|
7
7
|
s.platform = Gem::Platform::RUBY
|
8
8
|
s.authors = ['Alan Johnson', 'Edouard Briere']
|
@@ -10,6 +10,7 @@ Gem::Specification.new do |s|
|
|
10
10
|
s.homepage = 'https://github.com/webtranslateit/payday'
|
11
11
|
s.summary = 'A simple library for rendering invoices.'
|
12
12
|
s.description = 'Payday is a library for rendering invoices to pdf.'
|
13
|
+
s.license = 'MIT'
|
13
14
|
|
14
15
|
s.add_dependency 'activesupport', '~> 7', '< 8'
|
15
16
|
s.add_dependency 'i18n', '~> 1.12', '< 2'
|
data/spec/assets/svg.pdf
CHANGED
@@ -17,7 +17,7 @@ endobj
|
|
17
17
|
>>
|
18
18
|
endobj
|
19
19
|
4 0 obj
|
20
|
-
<< /Length
|
20
|
+
<< /Length 48537
|
21
21
|
>>
|
22
22
|
stream
|
23
23
|
q
|
@@ -2293,8 +2293,8 @@ ET
|
|
2293
2293
|
|
2294
2294
|
BT
|
2295
2295
|
36.0 132.6 Td
|
2296
|
-
/
|
2297
|
-
<
|
2296
|
+
/F2.0 10 Tf
|
2297
|
+
<4e6f7465733a> Tj
|
2298
2298
|
ET
|
2299
2299
|
|
2300
2300
|
0.5 w
|
@@ -2349,7 +2349,7 @@ endobj
|
|
2349
2349
|
endobj
|
2350
2350
|
6 0 obj
|
2351
2351
|
<< /Type /Font
|
2352
|
-
/BaseFont /
|
2352
|
+
/BaseFont /b22dd8+NotoSans-Bold
|
2353
2353
|
/Subtype /TrueType
|
2354
2354
|
/FontDescriptor 9 0 R
|
2355
2355
|
/FirstChar 32
|
@@ -2360,7 +2360,7 @@ endobj
|
|
2360
2360
|
endobj
|
2361
2361
|
7 0 obj
|
2362
2362
|
<< /Type /Font
|
2363
|
-
/BaseFont /
|
2363
|
+
/BaseFont /5a974e+NotoSans
|
2364
2364
|
/Subtype /TrueType
|
2365
2365
|
/FontDescriptor 13 0 R
|
2366
2366
|
/FirstChar 32
|
@@ -2370,32 +2370,28 @@ endobj
|
|
2370
2370
|
>>
|
2371
2371
|
endobj
|
2372
2372
|
8 0 obj
|
2373
|
-
<< /Length1
|
2374
|
-
/Length
|
2373
|
+
<< /Length1 5564
|
2374
|
+
/Length 3659
|
2375
2375
|
/Filter [/FlateDecode]
|
2376
2376
|
>>
|
2377
2377
|
stream
|
2378
|
-
x��X
|
2379
|
-
|
2380
|
-
�
|
2381
|
-
|
2382
|
-
�
|
2383
|
-
|
2384
|
-
|
2385
|
-
|
2386
|
-
|
2387
|
-
|
2388
|
-
|
2389
|
-
|
2390
|
-
>r�b�,M�M��5x�}�8����kv���w�\�;oaWۡ7�T�m�8~��'DPIRVv�Nj�Ixm $�8&IN�j�Rz�5>�[��ǰ8��gWO��[���ѣW�W�ܹ�r��N�oX���V�g�����ƶ&S�+�hnn)9���e\m�H#ϳo�tZF���B�_�#��؞�ĵ��v-\�#��m:�NO���YWT�
|
2391
|
-
fX�*F0ˡ��'��g3Ȳ���frA�����9�Ch̗����*���
|
2392
|
-
+*�4�� j}m]>-���R�7��7�{H> ��~/��&�CJ�XcHp�I�:[0�;��4t�PϮ�����O��Í���E��ڊ�ڡ4�����Vv}`�Ɨ���_���R��$XI�X�XI,���K���cC%��j���������=������_���6�0���IA���YAa���%=������;w�K��_9���ћ��,_���6�U8n�b�����X��9������^`��K�V��kSu����N��f�;���KʝB}M���u)�!y�k���<>��>�=N�?�$���{���Uy��������s'}aڭ<4�]6�����KSh�Ǔ�HKk*�]S"��36��_�����F�ni{�������W��z�9@���6/��:`<țh�a���T�Hu���)�jY��icW}t��.+�qơo�n`�T^ja���b7 6*�AӔ�
|
2393
|
-
�t�h$����9��4��џO���M��u��ѹʎ���{Z�>;Y�v!f�n�T^v*��j0S�d�K�X��Q�Q��HV�Cs��x5�#�}1q){���;���2O��*�.��(W�*\�D�����R�^
|
2378
|
+
x��X{X�י?��xa�k�F@��Scj���8����P�@�ADt��T�I���4!�����a �<٪��j���k�eSkB��}T����7���vw�ؙ����=����������d5ɸ�̸�3��&�����䕽�֍>B�ixa���h���~�,,�*��O"ބ��"w��n�܅k�$�#l���ېQE%�e��j߅�h�{���S��]������a|��ҼwR�F���������-$��u>N8v���mn�O�3�!�sdg�-^~>����"�WOV�17��
|
2379
|
+
�Z#!��}ExN�?��VzFS'�E~B���E�%I#�a��;eT���9R � ��, ���f25-m*��IU��V�6Ǥ\�E��Hg�A�S��2Rq�]!�î�I�<�T�]�Ur�Vq8�,4��jЯ"��\��`���J���@�$] Y���I�I��0�ɤNXB�@�ԗIoK���:q���H�w�.�TGB�� �V��z�ʿ�<L��I��`+�X� E(����L´���C�FӐ����0B�>b��X"��HTt�?����3&(�^���� k!� ߃�HH69!~
|
2380
|
+
�k���f���w�P:�����Ha�Ţ��Uju��vF�g�h�F/2ѱq��!�J��R�|����D!)�ﮎ�(��F�^
|
2381
|
+
E���kH�02TII5���<�d��f�i-�*����|�e�Ml?�A�|�=�^��P�p�1V��*i
|
2382
|
+
]OK�_�����v�
|
2383
|
+
AEB|���oh��>��}ZK5�i8�������R3�G-�j��gC���؟@/��˴Z�q���??��£W��8��o�ddT��h`����;?�(�A�Jr���hy��Gh�ǘ��ެg�Ɔ%��!�B�o�r�r���ڇ�Q�|~L�$�м&ۂ���������f̾���l�*��ߞ���Yo�n��e���h�f��wt��Qc�G'�T��V���Q���<?!)g���~v9��lT�L:k��n3�7,�2�������l�>FdzӾ�~c;tHVS��}�u�Dh� ��B �:�����:F��m?I�y��͎����^���]P�Ūv(�/I��ߒ"�6���9�QɞU�)keG�c�F��M_;�*h���>�>�hw�F)�����=��!�?�/<7��N�
|
2384
|
+
7Li;���bh���B��8��e:�m�+ٞ�.� L��m��_��U����A�b5ނ: 0��[
|
2385
|
+
��D��gÃq�K����3�
|
2386
|
+
}
|
2387
|
+
�� �@���^}<�@�=[��e�
|
2388
|
+
�b���B�s��I�|�
|
2389
|
+
���O�P�������R2�
|
2394
2390
|
endstream
|
2395
2391
|
endobj
|
2396
2392
|
9 0 obj
|
2397
2393
|
<< /Type /FontDescriptor
|
2398
|
-
/FontName /
|
2394
|
+
/FontName /b22dd8+NotoSans-Bold
|
2399
2395
|
/FontFile2 8 0 R
|
2400
2396
|
/FontBBox [-619 -292 1441 1068]
|
2401
2397
|
/Flags 4
|
@@ -2417,39 +2413,38 @@ x
|
|
2417
2413
|
endstream
|
2418
2414
|
endobj
|
2419
2415
|
11 0 obj
|
2420
|
-
[259 600 600 600 600 600 600 600 600 600 600 600 285 600 600 600 571 571 571 600 600 600 600 600 600 600 285 600 600 600 600 600 600 689 671 637 740 600 548 600 600 389 331 600 600 600
|
2416
|
+
[259 600 600 600 600 600 600 600 600 600 600 600 285 600 600 600 571 571 571 600 600 600 600 600 600 600 285 600 600 600 600 600 600 689 671 637 740 600 548 600 600 389 331 600 600 600 812 600 627 795 660 550 579 755 600 600 600 600 600 600 600 600 600 600 600 604 632 514 632 590 600 600 657 305 600 600 305 981 657 619 632 600 454 497 434 657 600 855 578 568 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600]
|
2421
2417
|
endobj
|
2422
2418
|
12 0 obj
|
2423
|
-
<< /Length1
|
2424
|
-
/Length
|
2419
|
+
<< /Length1 5836
|
2420
|
+
/Length 3920
|
2425
2421
|
/Filter [/FlateDecode]
|
2426
2422
|
>>
|
2427
2423
|
stream
|
2428
|
-
x��
|
2429
|
-
P
|
2430
|
-
|
2431
|
-
|
2432
|
-
�
|
2433
|
-
|
2434
|
-
|
2435
|
-
|
2436
|
-
|
2437
|
-
|
2438
|
-
|
2439
|
-
|
2440
|
-
�
|
2441
|
-
|
2442
|
-
��
|
2443
|
-
|
2444
|
-
|
2445
|
-
|
2446
|
-
|
2447
|
-
V���G��\1,�����0�~�U1�K�?���_��Eܓ��?X�N��,��Ōbv�f�X>��E�/E�������,O��f�TX>��6�I6�+��?����`�Yds���W�m1���tXg�OE��_��i����c�S �ݍ��5X�
|
2424
|
+
x��XyXTG���{{���v��M�D��EA� H�`�� [��H7"���+�%(.��� �ѨQq��Ǚh���$1Q��w��uM����|��v�,�sNݺ ��!�X�[�Bx�&�d&���v!
|
2425
|
+
sn��$G2�<�úKƜ��E-��~��aKZr��S3`�(P�&�������@}-����(���rW��NIFX����L�����:X�cmVrf�g���AHs��d[m�3Q:�d�َ�M����-��"G�״9�>k/�;w�3��d��*:!"�@�)_mߍ���3 �����??a�OD�( I^Y�`�s�㵰�$�%���rQ:ArB�H/� �_���bc��H������ƛ%��g����XM|Q)_���7�b�T�z�@Ӏ���|Io��-�}�iI;:M:��#`܊N���[�J6���D���ۀ����@�|����
|
2426
|
+
Q
|
2427
|
+
�Ier'�,d�CLW�P7�@J6tsGH��p?�A�{�D��k��g����z#�|��k���H�@���^@�@U@�!��vuy����@_A#��@3�>GH
|
2428
|
+
�H��`��d�NB��*��
|
2429
|
+
�Buy�,�T�jj� �9C�q���uJ� ����8d!�e���fK;o�uc70_���`C��Z%�{���<��������
|
2430
|
+
3|����{��k�w�U�[WY��ܠŴ�\�.Υ��Zz���:l�A؋�3�, �<���+�LR�T�
|
2431
|
+
�6@��~�sJD�3������M�RV�x��\�/Ǵr~iI~:�}d�N�Bn����e%oږ���X�t������N'��\_1� ��y a4h�
|
2432
|
+
��h~��i��o]��3�����;WR�Ō���=�za��� w�=�TR�)��[{�נ����;�T�d�<cdaԛ͠w������y�
|
2433
|
+
���K������:.���2���`��˔�G��y�%��
|
2434
|
+
�GW�6N��c�W*��i�Gkɰ]d(M�����§�0���Ă�\��BGCtBZ� ��!sT�4ȭ�!.������[��ٛC?�;>�#���{��%~�$m���C+�z���
|
2435
|
+
UA���q���"pP���l@:C�|�l�4ӭ� |ێ��(�،'��������pF|H��*l�ix�K�C��b���e�>�ق�n,�xp\�b��|6�O���\L����>Y�������48�[�eu a�H� oA�^��� �}�!��^(�'�y���v����]��ל��������UKJC�����}������͊N�d>���/&n��I3=&0tn)��?
|
2436
|
+
���pW�_�*P��_�J?�x�����_���U��s���j��%�f9@K��C?��қ-�
|
2437
|
+
I��)�f�]�yq�+ +�v,�rB��<r�Ϡm�Z��
|
2438
|
+
Az B͋~�� 54dq�x� �ͩ'[�X�- �E<�3bd��SA<�Z�B�a����߱��y����;��&�K��Va~/v�h}�����r��P_(��c���x�`;Y���� �7�]xy݆���k�cٰkeE�j�_L
|
2439
|
+
�|�բ�ؽ|A~yŻþ>~dG�GKsl��VËw�ǣ��L1�'
|
2440
|
+
%~b�+)#ib��O��!���1ٶ��,+ze�T�r�L��,��x z
|
2441
|
+
���B;V��V9��F��\!������0�~�Uq�K����_��Uؓ��?D�V��,�����bv�f
|
2442
|
+
X>��U�/U�������,O� {��UX�� 6�69*������`�Yds���_�m���XgȏC�ٿ;���}��#8�Ig'����
|
2448
2443
|
endstream
|
2449
2444
|
endobj
|
2450
2445
|
13 0 obj
|
2451
2446
|
<< /Type /FontDescriptor
|
2452
|
-
/FontName /
|
2447
|
+
/FontName /5a974e+NotoSans
|
2453
2448
|
/FontFile2 12 0 R
|
2454
2449
|
/FontBBox [-556 -272 1321 1047]
|
2455
2450
|
/Flags 4
|
@@ -2471,7 +2466,7 @@ x
|
|
2471
2466
|
endstream
|
2472
2467
|
endobj
|
2473
2468
|
15 0 obj
|
2474
|
-
[259 269 600 600 571 600 600 600 600 600 600 600 268 600 268 600 571 571 571 571 600 571 600 600 600 571 600 600 600 600 600 600 898 639 600 631 600 600 519 600 741 600 272 600 600 600
|
2469
|
+
[259 269 600 600 571 600 600 600 600 600 600 600 268 600 268 600 571 571 571 571 600 571 600 600 600 571 600 600 600 600 600 600 898 639 600 631 600 600 519 600 741 600 272 600 600 600 600 780 604 600 600 548 556 600 600 930 600 600 600 600 600 600 600 600 600 561 600 479 615 563 600 600 618 257 600 534 257 935 618 604 615 600 413 479 360 600 600 786 600 509 470 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600]
|
2475
2470
|
endobj
|
2476
2471
|
xref
|
2477
2472
|
0 16
|
@@ -2480,22 +2475,22 @@ xref
|
|
2480
2475
|
0000000109 00000 n
|
2481
2476
|
0000000158 00000 n
|
2482
2477
|
0000000215 00000 n
|
2483
|
-
|
2484
|
-
|
2485
|
-
|
2486
|
-
|
2487
|
-
|
2488
|
-
|
2489
|
-
|
2490
|
-
|
2491
|
-
|
2492
|
-
|
2493
|
-
|
2478
|
+
0000048805 00000 n
|
2479
|
+
0000049083 00000 n
|
2480
|
+
0000049250 00000 n
|
2481
|
+
0000049413 00000 n
|
2482
|
+
0000053161 00000 n
|
2483
|
+
0000053375 00000 n
|
2484
|
+
0000054729 00000 n
|
2485
|
+
0000055643 00000 n
|
2486
|
+
0000059653 00000 n
|
2487
|
+
0000059864 00000 n
|
2488
|
+
0000061218 00000 n
|
2494
2489
|
trailer
|
2495
2490
|
<< /Size 16
|
2496
2491
|
/Root 2 0 R
|
2497
2492
|
/Info 1 0 R
|
2498
2493
|
>>
|
2499
2494
|
startxref
|
2500
|
-
|
2495
|
+
62132
|
2501
2496
|
%%EOF
|
data/spec/assets/testing.pdf
CHANGED
@@ -2807,7 +2807,7 @@ endobj
|
|
2807
2807
|
endobj
|
2808
2808
|
6 0 obj
|
2809
2809
|
<< /Type /Font
|
2810
|
-
/BaseFont /
|
2810
|
+
/BaseFont /c43434+NotoSans-Bold
|
2811
2811
|
/Subtype /TrueType
|
2812
2812
|
/FontDescriptor 17 0 R
|
2813
2813
|
/FirstChar 32
|
@@ -11657,7 +11657,7 @@ endobj
|
|
11657
11657
|
>>
|
11658
11658
|
endobj
|
11659
11659
|
14 0 obj
|
11660
|
-
<< /Length
|
11660
|
+
<< /Length 25830
|
11661
11661
|
>>
|
11662
11662
|
stream
|
11663
11663
|
q
|
@@ -13976,8 +13976,8 @@ ET
|
|
13976
13976
|
|
13977
13977
|
BT
|
13978
13978
|
36.0 262.2 Td
|
13979
|
-
/
|
13980
|
-
<
|
13979
|
+
/F2.0 10 Tf
|
13980
|
+
<4e6f7465733a> Tj
|
13981
13981
|
ET
|
13982
13982
|
|
13983
13983
|
0.5 w
|
@@ -14038,27 +14038,29 @@ endobj
|
|
14038
14038
|
>>
|
14039
14039
|
endobj
|
14040
14040
|
16 0 obj
|
14041
|
-
<< /Length1
|
14042
|
-
/Length
|
14041
|
+
<< /Length1 5888
|
14042
|
+
/Length 3823
|
14043
14043
|
/Filter [/FlateDecode]
|
14044
14044
|
>>
|
14045
14045
|
stream
|
14046
|
-
x��X
|
14047
|
-
|
14048
|
-
|
14049
|
-
|
14050
|
-
|
14051
|
-
|
14052
|
-
|
14053
|
-
|
14054
|
-
|
14055
|
-
|
14056
|
-
|
14046
|
+
x��X}XTי?�~��2à5�������5�Z�����He`�U4J��I���ٖh$�Z��%h}ҪE�F�1>ֵ�tSc��$�vU���ΙA�5�����>�=��{~��3�BB�j"����c�VL�1��/��;�(���A)�) sar=%DG����`�ׂ���j !���ܼ{5sb�0�Q���1�>����E�e���p�vb���=?�P},!r6��E��J����bl.�-r9�=�D����]%n��{!����u±����^�ΏB��+ �~���������]���D�{��$8�j|
|
14047
|
+
QkU;D��y�/�$��$EU$IyL2�4}�$`7�
|
14048
|
+
?]��i�)9j�Ќ(g��(,?^�J��*@)���p�\Ҫ�#K�vҪT�VyI���I��
|
14049
|
+
��5M�M���"�4�Hǩ\$���)H6�l��DR'����:�R����^'��'�r��|�RC��21*u$���U�Vꅮ�q�����I%nTE
|
14050
|
+
F�<��-�tD���v�T�V[�O)P>��Ƴ��4������aN=��Ӿ�N�[4�Ҧt�+I�����%K1��,q��q�>��Q�:Y��uߧ��ʾ����..ʑ��*�"]A=t-u��l3��f;
|
14051
|
+
X(H� �XN�F��Q���N�괁
|
14052
|
+
h��g��vv�y��f*1�]M��|�F�ay ����:~�>e�҄���
|
14053
|
+
�G��vǶ5/?=�}�
|
14054
|
+
�!���V �1:��o�/V^@��ק���q\��j��I�;#����<Xd��|��MPǿ���Տ):�iw8�����YR6�s����s7�F6w��?���w�����K�RME��6�m%g˴ٯ�d���q��'������C����c�8믎q��NܴS|a�*����/tKT�����F�U._\X��PV�Ǭ�տ�@R�[������{^g_��j�n
|
14055
|
+
Wv�R����H]�q��+4�m�+ٞ[��^+Y�+4�w��FW�*���z�X�1�>N�r��&�|�Nb� _�:=�9!�"*oL+Y�T��f��v��yNn�Pr(�#S����+Ah�#�}��Z��G;y!З�)�)�W�S�l�����@_K&R]��#O��@?��K�`2��"�!�(�{�g�g���iY�߇ī}���qOq{��Ş����<�}�&%��SF���x�MGF�X<�dVݘ/$.�&�b2��Bof
|
14056
|
+
Ѧ=���������)����$�������#����
|
14057
|
+
��^�= �O3 �{~� �h-C��@?�mFA'z�@��s���y�?�.���,Ɯ���
|
14058
|
+
��tX7�tqj�#���03O��Xa��
|
14059
|
+
Ɠ��t̘���1;QpL}��E���9h�b���]@�N�-�e�D$x�2�Gf��{�*=��ɮf����O<�g>����ܗ�"�E^�}Q" [�x��_^��EB�
|
14057
14060
|
endstream
|
14058
14061
|
endobj
|
14059
14062
|
17 0 obj
|
14060
14063
|
<< /Type /FontDescriptor
|
14061
|
-
/FontName /
|
14064
|
+
/FontName /c43434+NotoSans-Bold
|
14062
14065
|
/FontFile2 16 0 R
|
14063
14066
|
/FontBBox [-619 -292 1441 1068]
|
14064
14067
|
/Flags 4
|
@@ -14080,7 +14082,7 @@ x
|
|
14080
14082
|
endstream
|
14081
14083
|
endobj
|
14082
14084
|
19 0 obj
|
14083
|
-
[259 600 600 600 600 600 600 600 600 600 600 600 285 600 600 600 571 571 571 600 600 600 600 600 600 600 285 600 600 600 600 600 600 689 671 637 740 560 600 600 600 389 331 600 600 942
|
14085
|
+
[259 600 600 600 600 600 600 600 600 600 600 600 285 600 600 600 571 571 571 600 600 600 600 600 600 600 285 600 600 600 600 600 600 689 671 637 740 560 600 600 600 389 331 600 600 942 812 795 627 795 660 550 579 755 649 600 600 600 600 600 600 600 600 600 600 604 632 514 632 590 600 600 657 305 600 600 305 981 657 619 632 600 454 497 434 657 568 855 578 568 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600 600]
|
14084
14086
|
endobj
|
14085
14087
|
20 0 obj
|
14086
14088
|
<< /Length1 6252
|
@@ -14158,20 +14160,20 @@ xref
|
|
14158
14160
|
0000098164 00000 n
|
14159
14161
|
0000145952 00000 n
|
14160
14162
|
0000146232 00000 n
|
14161
|
-
|
14162
|
-
|
14163
|
-
|
14164
|
-
|
14165
|
-
|
14166
|
-
|
14167
|
-
|
14168
|
-
|
14169
|
-
|
14163
|
+
0000172116 00000 n
|
14164
|
+
0000172396 00000 n
|
14165
|
+
0000176309 00000 n
|
14166
|
+
0000176525 00000 n
|
14167
|
+
0000177879 00000 n
|
14168
|
+
0000178793 00000 n
|
14169
|
+
0000183146 00000 n
|
14170
|
+
0000183357 00000 n
|
14171
|
+
0000184711 00000 n
|
14170
14172
|
trailer
|
14171
14173
|
<< /Size 24
|
14172
14174
|
/Root 2 0 R
|
14173
14175
|
/Info 1 0 R
|
14174
14176
|
>>
|
14175
14177
|
startxref
|
14176
|
-
|
14178
|
+
185625
|
14177
14179
|
%%EOF
|
Binary file
|
Binary file
|
data/spec/invoice_spec.rb
CHANGED
@@ -184,6 +184,21 @@ module Payday # rubocop:todo Metrics/ModuleLength
|
|
184
184
|
end
|
185
185
|
end
|
186
186
|
|
187
|
+
context 'with the locale set to Spanish' do
|
188
|
+
it 'renders and invoice in Spanish' do # rubocop:todo RSpec/ExampleLength
|
189
|
+
I18n.with_locale :es do
|
190
|
+
Payday::Config.default.company_details = 'Dirección'
|
191
|
+
|
192
|
+
invoice.line_items += [
|
193
|
+
LineItem.new(price: 20, quantity: 5, description: 'Pantalones'),
|
194
|
+
LineItem.new(price: 5, quantity: 200, description: 'Sombreros')
|
195
|
+
]
|
196
|
+
|
197
|
+
expect(invoice.render_pdf).to match_binary_asset 'testing_es.pdf'
|
198
|
+
end
|
199
|
+
end
|
200
|
+
end
|
201
|
+
|
187
202
|
context 'with a mix of LineItems with price, quantity and predefined_amounts' do
|
188
203
|
let(:invoice_params) do
|
189
204
|
{
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: webtranslateit-payday
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.
|
4
|
+
version: 1.6.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alan Johnson
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2022-08-
|
12
|
+
date: 2022-08-29 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|
@@ -172,6 +172,12 @@ files:
|
|
172
172
|
- Guardfile
|
173
173
|
- README.md
|
174
174
|
- Rakefile
|
175
|
+
- config/locales/payday.de.yml
|
176
|
+
- config/locales/payday.en.yml
|
177
|
+
- config/locales/payday.es.yml
|
178
|
+
- config/locales/payday.fr.yml
|
179
|
+
- config/locales/payday.nl.yml
|
180
|
+
- config/locales/payday.zh-CN.yml
|
175
181
|
- fonts/NotoSans-Bold.ttf
|
176
182
|
- fonts/NotoSans-Regular.ttf
|
177
183
|
- lib/generators/payday/setup/USAGE
|
@@ -185,17 +191,12 @@ files:
|
|
185
191
|
- lib/payday/invoiceable.rb
|
186
192
|
- lib/payday/line_item.rb
|
187
193
|
- lib/payday/line_itemable.rb
|
188
|
-
- lib/payday/locale/de.yml
|
189
|
-
- lib/payday/locale/en.yml
|
190
|
-
- lib/payday/locale/es.yml
|
191
|
-
- lib/payday/locale/fr.yml
|
192
|
-
- lib/payday/locale/nl.yml
|
193
|
-
- lib/payday/locale/zh-CN.yml
|
194
194
|
- lib/payday/pdf_renderer.rb
|
195
195
|
- payday.gemspec
|
196
196
|
- spec/assets/default_logo.png
|
197
197
|
- spec/assets/svg.pdf
|
198
198
|
- spec/assets/testing.pdf
|
199
|
+
- spec/assets/testing_es.pdf
|
199
200
|
- spec/assets/testing_predefined_amount.pdf
|
200
201
|
- spec/assets/tiger.svg
|
201
202
|
- spec/invoice_spec.rb
|
@@ -204,7 +205,8 @@ files:
|
|
204
205
|
- spec/spec_helper.rb
|
205
206
|
- spec/support/asset_matchers.rb
|
206
207
|
homepage: https://github.com/webtranslateit/payday
|
207
|
-
licenses:
|
208
|
+
licenses:
|
209
|
+
- MIT
|
208
210
|
metadata:
|
209
211
|
rubygems_mfa_required: 'true'
|
210
212
|
post_install_message:
|