xeroizer-float 2.15.3.7 → 2.15.3.8
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/xeroizer/http.rb +1 -1
- data/lib/xeroizer/models/line_item.rb +2 -1
- data/xeroizer-float.gemspec +2 -2
- metadata +2 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.15.3.
|
1
|
+
2.15.3.8
|
data/lib/xeroizer/http.rb
CHANGED
@@ -18,6 +18,7 @@ module Xeroizer
|
|
18
18
|
string :tax_type
|
19
19
|
decimal :tax_amount
|
20
20
|
decimal :line_amount, :calculated => true
|
21
|
+
decimal :discount_rate
|
21
22
|
|
22
23
|
has_many :tracking, :model_name => 'TrackingCategoryChild'
|
23
24
|
|
@@ -31,7 +32,7 @@ module Xeroizer
|
|
31
32
|
def line_amount(summary_only = false)
|
32
33
|
return attributes[:line_amount] if summary_only || @line_amount_set
|
33
34
|
|
34
|
-
BigDecimal((quantity * unit_amount).to_s).round(2) if quantity && unit_amount
|
35
|
+
BigDecimal((quantity * unit_amount * (100.0 - discount_rate)).to_s).round(2) if quantity && unit_amount
|
35
36
|
end
|
36
37
|
|
37
38
|
end
|
data/xeroizer-float.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "xeroizer-float"
|
8
|
-
s.version = "2.15.3.
|
8
|
+
s.version = "2.15.3.8"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Wayne Robinson", "Philip Roberts"]
|
12
|
-
s.date = "2013-02-
|
12
|
+
s.date = "2013-02-20"
|
13
13
|
s.description = "Ruby library for the Xero accounting system API."
|
14
14
|
s.email = "wayne.robinson@gmail.com"
|
15
15
|
s.extra_rdoc_files = [
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xeroizer-float
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.15.3.
|
4
|
+
version: 2.15.3.8
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2013-02-
|
13
|
+
date: 2013-02-20 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: builder
|