rally-wsapi 0.2.0 → 0.3.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 +4 -4
- data/README.md +2 -2
- data/VERSION +1 -1
- data/lib/wsapi/session.rb +9 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3a273989e21a486fff6edbc02b95331380ca7246
|
4
|
+
data.tar.gz: d1293eb20e41a39ce327081ef8d532dd72d3934b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9fe7cf15bf3a74f4bf7f56219853ddc737b8790c53566062d21342a7769446d4027c0dc72692c1c41036e449e66092353ad44881a353bcd049732c3e664f2a9f
|
7
|
+
data.tar.gz: b6d00147c3f1e4f77f5c11afe845ca667597da0f428c3197341c9264d71eb459145b54a499818e029aa6eb1dfcb75b93cc916d3751211aa8caa91e345dda1992
|
data/README.md
CHANGED
@@ -51,9 +51,9 @@ get_user_by_username(username)
|
|
51
51
|
|
52
52
|
#### Get users by query
|
53
53
|
```
|
54
|
-
get_users(query_string)
|
54
|
+
get_users(query_string = nil)
|
55
55
|
```
|
56
|
-
See WSAPI documentation for details about query_string syntax
|
56
|
+
If the query_string is present, applies it to the request. Otherwise returns all users. See WSAPI documentation for details about query_string syntax.
|
57
57
|
|
58
58
|
#### Get the subscription of the authenticated user
|
59
59
|
```
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.3.0
|
data/lib/wsapi/session.rb
CHANGED
@@ -78,9 +78,15 @@ module Wsapi
|
|
78
78
|
Mapper.get_object(response)
|
79
79
|
end
|
80
80
|
|
81
|
-
def get_users(query)
|
82
|
-
|
83
|
-
|
81
|
+
def get_users(query = nil)
|
82
|
+
fetch_with_pages do |page_query|
|
83
|
+
if query
|
84
|
+
query_hash = { query: "(#{query})" }
|
85
|
+
wsapi_get(wsapi_resource_url("User"), query_hash.merge(page_query))
|
86
|
+
else
|
87
|
+
wsapi_get(wsapi_resource_url("Users"), page_query)
|
88
|
+
end
|
89
|
+
end
|
84
90
|
end
|
85
91
|
|
86
92
|
def get_user(id)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rally-wsapi
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Antti Pitkänen
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-
|
12
|
+
date: 2015-02-12 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rake
|