quovo 1.0.5 → 1.0.6

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
  SHA1:
3
- metadata.gz: 5d08203e16ec477510fc40f0d97bace48b9e54ee
4
- data.tar.gz: ce632cd0675812c08eea9de7a802520f54242038
3
+ metadata.gz: 015834e67e9d507f24aca056b1a11d495350dd63
4
+ data.tar.gz: b243f7e0eabd42dfa884bdc72329cc7ecdff9647
5
5
  SHA512:
6
- metadata.gz: daa8fce11d923bea0c6ed3c2d1d032fdef70071620d59c7970b4cba946b5bbee6f5b77ebc0947454dda07d4e9f97e508709d842d167bd7dde27ae6f0ba78f77b
7
- data.tar.gz: 971e0408e788f61483bb1abe53063ba398e66563b0c8b81ce18d5cb221b712ce31f3ab15a47988b6297fa72a31fdd75f583dcaef2a8796b136b0df628fa753f3
6
+ metadata.gz: 6aa7971341b1c946a9322b71ee4c681542e32a26086df677220f03e0062b5422c1bcd0d8ac2be683c6e62436bc2fca397ffad8a67bc7e874fd5b4f9a3844eb26
7
+ data.tar.gz: ccfd7a3905f20146361d7529b84b48ba533f5b40917459680cb72ccf8745d4046ffbf9f2904dcf1530ded3d5cbc0d80b89c3a41fb6ef6dc96e8e9e067781c231
data/README.md CHANGED
@@ -130,7 +130,6 @@ Hook is a registered callback that invokes when web request happens.
130
130
 
131
131
  ### History
132
132
  ```ruby
133
- client.history.all(options)
134
133
  client.history.for_user(user_id, options)
135
134
  client.history.for_account(account_id, options)
136
135
  client.history.for_portfolio(portfolio_id, options)
@@ -140,7 +139,13 @@ Hook is a registered callback that invokes when web request happens.
140
139
  # start_date: - filters out history before this date
141
140
  # end_date: - filters out history after this date
142
141
  # start_id: - filters out history before this id
143
- # end_id: - filters out history after this id
142
+ # end_id: - filters out history after this id
143
+ ```
144
+ #### Update transaction (read more [here](https://new.quovo.com/api/docs/index.html#update-a-transaction))
145
+ ```
146
+ client.history.update_transaction(id, options)
147
+ # Options:
148
+ # expense_category: new expense_category
144
149
  ```
145
150
 
146
151
  ### Portfolios
@@ -5,14 +5,6 @@ module Quovo
5
5
  using Quovo::Refinements::Require
6
6
  using Quovo::Refinements::Permit
7
7
 
8
- def all(params = {})
9
- params.permit!(:start_date, :end_date, :start_id, :end_id, :count)
10
- api(:get, '/history', params)
11
- .fetch('history')
12
- .cast(Transaction)
13
- .sort_by(&:sort_key)
14
- end
15
-
16
8
  def for_user(id, params = {})
17
9
  id.require!(as: :id)
18
10
  params.permit!(:start_date, :end_date, :start_id, :end_id, :count)
@@ -39,6 +31,14 @@ module Quovo
39
31
  .cast(Transaction)
40
32
  .sort_by(&:sort_key)
41
33
  end
34
+
35
+ def update_transaction(id, params = {})
36
+ id.require!(as: :id)
37
+ params.permit!(:expense_category)
38
+ api(:put, "/history/#{id}", params)
39
+ .fetch('history')
40
+ .cast(Transaction)
41
+ end
42
42
  end
43
43
  end
44
44
  end
@@ -1,3 +1,3 @@
1
1
  module Quovo
2
- VERSION = '1.0.5'.freeze
2
+ VERSION = '1.0.6'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: quovo
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.5
4
+ version: 1.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alex Gorkunov
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-07-21 00:00:00.000000000 Z
12
+ date: 2016-09-29 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: Quovo RESTful API client, configurable, thread-safe and well-tested
15
15
  email: