ubill 0.1.1 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +1 -1
- data/lib/ubill/invoice.rb +17 -4
- data/lib/ubill/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 19061eeff34de42457b509953beb27e3fc11685aa052d3ac4adcbaa441eb3987
|
4
|
+
data.tar.gz: be2306c0b4556e3f91071f447366143d6cbfd8957474700d4b1c489d3a821da3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ea3bf18d1d4c1950786796c1e64961d5c61070e3e21f044eea7e5fbbac52e15400ed513918b37cd9810eab368f5ab7a6b5acc66b0c325c4273299bdda900b2dd
|
7
|
+
data.tar.gz: 3fbff914a714388bc10b4eaa166d39e4c77c0675d29adb2349ec70b646c2fe795587e58e03df60f619006332d350b985999064dbab936c94a320f84b090d1420
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -80,7 +80,7 @@ doc = Ubill::Invoice.new do
|
|
80
80
|
subject("Rechnung R1234567890", "Rechnungsdatum 01.01.2100")
|
81
81
|
# recipient address
|
82
82
|
recipient(
|
83
|
-
|
83
|
+
organisation: "Spielvereinigung Demoburg e.V.",
|
84
84
|
name: "Tobi Ornottobi",
|
85
85
|
department: "Dept. Purchase",
|
86
86
|
street_1: "Highwaytohell 2",
|
data/lib/ubill/invoice.rb
CHANGED
@@ -12,18 +12,19 @@ module Ubill
|
|
12
12
|
COLOR_SECONDARY = "777777"
|
13
13
|
EXTERNAL_FONTS_DIR = File.join(__dir__, "fonts")
|
14
14
|
|
15
|
-
def initialize
|
16
|
-
super
|
15
|
+
def initialize
|
16
|
+
super()
|
17
17
|
@recipient = {}
|
18
18
|
@subject = ""
|
19
19
|
@subject_info = ""
|
20
20
|
@positions = [["#", "Beschreibung", "Einzelpreis", "Menge", "Gesamt"]]
|
21
21
|
@total = ""
|
22
22
|
@due = ""
|
23
|
+
@addendum = ""
|
23
24
|
|
24
25
|
load_external_font_families
|
25
26
|
|
26
|
-
|
27
|
+
yield(self) if block_given?
|
27
28
|
end
|
28
29
|
|
29
30
|
def recipient(**options)
|
@@ -53,6 +54,10 @@ module Ubill
|
|
53
54
|
@due = value
|
54
55
|
end
|
55
56
|
|
57
|
+
def addendum(value)
|
58
|
+
@addendum = value
|
59
|
+
end
|
60
|
+
|
56
61
|
|
57
62
|
def config
|
58
63
|
Ubill.config
|
@@ -126,6 +131,9 @@ module Ubill
|
|
126
131
|
pad 9.mm do
|
127
132
|
describe_positions
|
128
133
|
end
|
134
|
+
pad 2.mm do
|
135
|
+
describe_addendum
|
136
|
+
end
|
129
137
|
pad 2.mm do
|
130
138
|
describe_terms
|
131
139
|
end
|
@@ -150,7 +158,7 @@ module Ubill
|
|
150
158
|
|
151
159
|
def describe_address
|
152
160
|
@recipient.each_with_filter(
|
153
|
-
:
|
161
|
+
:organisation, :name, [:firstname, :lastname], :department, :street_1, :street_2, [:zip, :city], :country
|
154
162
|
) do |key, value|
|
155
163
|
move_down 0.3.cm if key.is_a?(Array) && key.eql?([:zip, :city])
|
156
164
|
text value, size: 10
|
@@ -198,6 +206,11 @@ module Ubill
|
|
198
206
|
end
|
199
207
|
end
|
200
208
|
|
209
|
+
def describe_addendum
|
210
|
+
font_size 10
|
211
|
+
text @addendum
|
212
|
+
end
|
213
|
+
|
201
214
|
def describe_terms
|
202
215
|
font_size 10
|
203
216
|
text "Es wird gemäß §19 Abs. 1 Umsatzsteuergesetz keine Umsatzsteuer erhoben. Der Gesamtbetrag der Rechnung ist zahlbar bis zum #{@due} ohne Abzug. Wenn nicht anders angegeben, entspricht das Leistungsdatum dem Rechnungsdatum."
|
data/lib/ubill/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ubill
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- couchbelag
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-05-
|
11
|
+
date: 2023-05-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: prawn
|