elmas 2.1.0 → 2.2.0

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
  SHA1:
3
- metadata.gz: e421ff5c7b4f08353819e71867737f45ae1174fb
4
- data.tar.gz: 011198e09daaacb28d7f0549a005a20d455f8259
3
+ metadata.gz: 818a1665f4b2ae23eca605aba398730fde734570
4
+ data.tar.gz: 18357b39ae918d983c4531a474bbd99f36d91ba0
5
5
  SHA512:
6
- metadata.gz: 44eb556375f882d31e23a5a71492edf59f39026a4ba348e3562d4246eef3f1c3f086b838f41b08e74d1ebd503445b199e848f232de8a24bec8b4f24b189b066a
7
- data.tar.gz: a544e1cb604941a50e8f23e139d26f0df7540e2816ce19814cd804f3d20114fdabfd7dad2409db3b5ee0bcaeab7cff23a9937118085e96a788278ca6ea969ac8
6
+ metadata.gz: 60c11e7d10cb6b0e98ec3e32b23e3aad596436da6b854c13f87ae4e83ed45a84bfc0804d2f6d8851222d647a2fa39c8e7117939cceeef64bb1e9eaf373585d2d
7
+ data.tar.gz: 9d2fb32e48142181b837e2dc9a16a9b095ce38c61b59bbf65898e6690df19e1486cd6c392cb2ca15f1eb40bcc28bf5e6de3ecef906657112d34342d68f76dcd7
data/.drone.yaml ADDED
@@ -0,0 +1,12 @@
1
+ cache:
2
+ mount:
3
+ - bundler
4
+ build:
5
+ image: ruby:2.2.3
6
+ cache:
7
+ - bundler
8
+ commands:
9
+ - apt-get update -qq
10
+ - apt-get install -y -qq build-essential &>/dev/null
11
+ - bundle install --jobs $(nproc) --path bundler
12
+ - ./script/ci
data/Changelog.md CHANGED
@@ -1,14 +1,25 @@
1
- 1.0.0
1
+ ## 2.1.0
2
2
 
3
- Use 'proper' date format for ExactOnline
4
- Don't add quotes to integers when filtering
5
- Raise error on invalid request
6
- Add project and time tracking functionality
3
+ - Allow filtering with 'greater_than' and 'less_than'
4
+ - Set proper endpoint for the AgingReceivablesList
7
5
 
8
- 0.2.0
6
+ ## 2.0.0
9
7
 
10
- First official release, used within Hoppinger, basic functionality and resources Hoppinger needed.
8
+ - Pagination for resources
9
+ - Implement receivables and aging receivables list resources
10
+ - Filter by array
11
11
 
12
- 0.1.0
12
+ ## 1.0.0
13
13
 
14
- Dev release
14
+ - Use 'proper' date format for ExactOnline
15
+ - Don't add quotes to integers when filtering
16
+ - Raise error on invalid request
17
+ - Add project and time tracking functionality
18
+
19
+ ## 0.2.0
20
+
21
+ - First official release, used within Hoppinger, basic functionality and resources Hoppinger needed.
22
+
23
+ ## 0.1.0
24
+
25
+ - Dev release
data/README.md CHANGED
@@ -114,10 +114,10 @@ using `find_by`. Filters accept a single value or an array of values.
114
114
 
115
115
  ```ruby
116
116
  # Find the account with code 123
117
- accounts = Elmas::Account.new(code: '123').find_by(filter: [:code])
117
+ accounts = Elmas::Account.new(code: '123').find_by(filters: [:code])
118
118
 
119
119
  # Find the accounts with code 123 and 345
120
- accounts = Elmas::Account.new(code: ['123', '345']).find_by(filter: [:code])
120
+ accounts = Elmas::Account.new(code: ['123', '345']).find_by(filters: [:code])
121
121
  ```
122
122
 
123
123
  You can also match on values "greater than" or "less than" by specifying `gt` or `lt`:
@@ -138,7 +138,7 @@ Filters and sorting can also be combined
138
138
 
139
139
  ```ruby
140
140
  # Return accounts with code 123 and 345 sorted by first name
141
- accounts = Elmas::Account.new(code: ['123', '345']).find_by(filter: [:code], order_by: :first_name)
141
+ accounts = Elmas::Account.new(code: ['123', '345']).find_by(filters: [:code], order_by: :first_name)
142
142
  ```
143
143
 
144
144
  To find an individual record by its ID the `find` method can be used
data/lib/elmas.rb CHANGED
@@ -39,6 +39,8 @@ require "elmas/resources/document"
39
39
  require "elmas/resources/document_attachment"
40
40
  require "elmas/resources/mailbox"
41
41
  require "elmas/resources/vat_code"
42
+ require "elmas/resources/general_journal_entry"
43
+ require "elmas/resources/general_journal_entry_line"
42
44
 
43
45
  module Elmas
44
46
  extend Config
@@ -9,7 +9,7 @@ module Elmas
9
9
  :serial_number, :asset, :cost_center, :cost_unit, :description, :notes,
10
10
  :project, :quantity, :serial_number, :subscription, :tracking_number,
11
11
  :VAT_amount_FC, :VAT_base_amount_DC, :VAT_base_amount_FC, :VAT_code,
12
- :VAT_percentage
12
+ :VAT_percentage, :account
13
13
  ]
14
14
  end
15
15
  end
@@ -0,0 +1,17 @@
1
+ module Elmas
2
+ class GeneralJournalEntry
3
+ include Elmas::Resource
4
+
5
+ def base_path
6
+ "generaljournalentry/GeneralJournalEntries"
7
+ end
8
+
9
+ def mandatory_attributes
10
+ [:journal_code, :general_journal_entry_lines]
11
+ end
12
+
13
+ def other_attributes
14
+ [:financial_period, :financial_year, :currency, :exchange_rate, :reversal]
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,9 @@
1
+ module Elmas
2
+ class GeneralJournalEntryLine < Elmas::BaseEntryLine
3
+ include Elmas::Resource
4
+
5
+ def base_path
6
+ "generaljournalentry/GeneralJournalEntryLines"
7
+ end
8
+ end
9
+ end
data/lib/elmas/version.rb CHANGED
@@ -1,7 +1,7 @@
1
1
  module Elmas
2
2
  class Version
3
3
  MAJOR = 2
4
- MINOR = 1
4
+ MINOR = 2
5
5
  PATCH = 0
6
6
 
7
7
  class << self
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: elmas
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marthyn
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-01 00:00:00.000000000 Z
11
+ date: 2016-04-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -219,6 +219,7 @@ executables: []
219
219
  extensions: []
220
220
  extra_rdoc_files: []
221
221
  files:
222
+ - ".drone.yaml"
222
223
  - ".gitignore"
223
224
  - ".rspec"
224
225
  - ".rubocop.yml"
@@ -253,6 +254,8 @@ files:
253
254
  - lib/elmas/resources/costunit.rb
254
255
  - lib/elmas/resources/document.rb
255
256
  - lib/elmas/resources/document_attachment.rb
257
+ - lib/elmas/resources/general_journal_entry.rb
258
+ - lib/elmas/resources/general_journal_entry_line.rb
256
259
  - lib/elmas/resources/gl_account.rb
257
260
  - lib/elmas/resources/item.rb
258
261
  - lib/elmas/resources/item_group.rb