uberbringer 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +63 -59
- data/lib/uberbringer.rb +4 -4
- data/lib/uberbringer/query_base.rb +4 -0
- data/lib/uberbringer/remedy_service.rb +4 -2
- data/lib/uberbringer/version.rb +1 -1
- metadata +12 -12
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1060e6a3d82adc7bd28400eecbfe07415e306dcf
|
4
|
+
data.tar.gz: 9e93be86a4798e60b3c3ee55f4f6728c8054deb8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 27ab10c099d605bb8d43e4043a46456530ee71d5aa4b0d30fe154de91b4d14b06c980879a9318995aef022f38487076bd78f4239f6c604be9db56ba0f5f49353
|
7
|
+
data.tar.gz: 05313b3d463a1f4e36eddd658ef7ccfb589e06b951f78528440fc0211e28926b63a2d2b7b7a44d24f5c5bcd40ff7ef8184a3be8348dcb3afc0ee44fc6bbd44ad
|
data/Gemfile.lock
CHANGED
@@ -1,59 +1,63 @@
|
|
1
|
-
PATH
|
2
|
-
remote: .
|
3
|
-
specs:
|
4
|
-
uberbringer (0.0.
|
5
|
-
fig_newton
|
6
|
-
soap-object
|
7
|
-
|
8
|
-
GEM
|
9
|
-
remote: https://rubygems.org/
|
10
|
-
specs:
|
11
|
-
akami (1.3.1)
|
12
|
-
gyoku (>= 0.4.0)
|
13
|
-
nokogiri
|
14
|
-
builder (3.2.2)
|
15
|
-
diff-lcs (1.2.5)
|
16
|
-
fig_newton (0.12)
|
17
|
-
yml_reader (>= 0.5)
|
18
|
-
gyoku (1.3.1)
|
19
|
-
builder (>= 2.1.2)
|
20
|
-
httpi (2.4.1)
|
21
|
-
rack
|
22
|
-
|
23
|
-
nokogiri (1.6.
|
24
|
-
|
25
|
-
nori (2.6.0)
|
26
|
-
rack (1.6.4)
|
27
|
-
rspec (3.
|
28
|
-
rspec-core (~> 3.
|
29
|
-
rspec-expectations (~> 3.
|
30
|
-
rspec-mocks (~> 3.
|
31
|
-
rspec-core (3.1
|
32
|
-
rspec-support (~> 3.
|
33
|
-
rspec-expectations (3.
|
34
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
35
|
-
rspec-support (~> 3.
|
36
|
-
rspec-mocks (3.
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
uberbringer (0.0.4)
|
5
|
+
fig_newton
|
6
|
+
soap-object
|
7
|
+
|
8
|
+
GEM
|
9
|
+
remote: https://rubygems.org/
|
10
|
+
specs:
|
11
|
+
akami (1.3.1)
|
12
|
+
gyoku (>= 0.4.0)
|
13
|
+
nokogiri
|
14
|
+
builder (3.2.2)
|
15
|
+
diff-lcs (1.2.5)
|
16
|
+
fig_newton (0.12)
|
17
|
+
yml_reader (>= 0.5)
|
18
|
+
gyoku (1.3.1)
|
19
|
+
builder (>= 2.1.2)
|
20
|
+
httpi (2.4.1)
|
21
|
+
rack
|
22
|
+
mini_portile2 (2.0.0)
|
23
|
+
nokogiri (1.6.7-x86-mingw32)
|
24
|
+
mini_portile2 (~> 2.0.0.rc2)
|
25
|
+
nori (2.6.0)
|
26
|
+
rack (1.6.4)
|
27
|
+
rspec (3.4.0)
|
28
|
+
rspec-core (~> 3.4.0)
|
29
|
+
rspec-expectations (~> 3.4.0)
|
30
|
+
rspec-mocks (~> 3.4.0)
|
31
|
+
rspec-core (3.4.1)
|
32
|
+
rspec-support (~> 3.4.0)
|
33
|
+
rspec-expectations (3.4.0)
|
34
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
35
|
+
rspec-support (~> 3.4.0)
|
36
|
+
rspec-mocks (3.4.0)
|
37
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
38
|
+
rspec-support (~> 3.4.0)
|
39
|
+
rspec-support (3.4.1)
|
40
|
+
savon (2.11.1)
|
41
|
+
akami (~> 1.2)
|
42
|
+
builder (>= 2.1.2)
|
43
|
+
gyoku (~> 1.2)
|
44
|
+
httpi (~> 2.3)
|
45
|
+
nokogiri (>= 1.4.0)
|
46
|
+
nori (~> 2.4)
|
47
|
+
wasabi (~> 3.4)
|
48
|
+
soap-object (0.6.7)
|
49
|
+
savon (>= 2.2.0)
|
50
|
+
wasabi (3.5.0)
|
51
|
+
httpi (~> 2.0)
|
52
|
+
nokogiri (>= 1.4.2)
|
53
|
+
yml_reader (0.6)
|
54
|
+
|
55
|
+
PLATFORMS
|
56
|
+
x86-mingw32
|
57
|
+
|
58
|
+
DEPENDENCIES
|
59
|
+
rspec (>= 2.12.0)
|
60
|
+
uberbringer!
|
61
|
+
|
62
|
+
BUNDLED WITH
|
63
|
+
1.10.6
|
data/lib/uberbringer.rb
CHANGED
@@ -9,19 +9,19 @@ require 'uberbringer/empty_response'
|
|
9
9
|
|
10
10
|
|
11
11
|
module Uberbringer
|
12
|
+
include SoapObject::Factory
|
12
13
|
|
13
14
|
def initialize
|
14
|
-
@service = RemedyService.new
|
15
15
|
@builder = QueryBuilder.new
|
16
16
|
end
|
17
17
|
|
18
18
|
def list_with_filter(criteria, options = {})
|
19
19
|
query = normalize_params(@builder.build(criteria), options)
|
20
|
-
|
20
|
+
using(RemedyService).execute_query(query)
|
21
21
|
end
|
22
22
|
|
23
23
|
def result
|
24
|
-
result =
|
24
|
+
result = using(RemedyService).body[:help_desk_query_list_service_response][:get_list_values]
|
25
25
|
return result if result.kind_of?(Array)
|
26
26
|
return [result] if result.kind_of?(Hash)
|
27
27
|
end
|
@@ -29,7 +29,7 @@ module Uberbringer
|
|
29
29
|
private
|
30
30
|
|
31
31
|
def normalize_params(query, options)
|
32
|
-
params =
|
32
|
+
params = {:start_record => 0, :max_limit => 10}.merge(options)
|
33
33
|
{
|
34
34
|
'Qualification' => query,
|
35
35
|
'startRecord' => params[:start_record],
|
@@ -64,6 +64,10 @@ module Uberbringer
|
|
64
64
|
filter_by_status(map_status(status),OPERATORS[:not_equal_to])
|
65
65
|
end
|
66
66
|
|
67
|
+
def closed_within_days(number_of_days = 7)
|
68
|
+
self << {:field => FIELD_MAPPINGS[:closed_date], :value => date_format(Date.today - number_of_days), :operator => OPERATORS[:greater_than]}
|
69
|
+
end
|
70
|
+
|
67
71
|
private
|
68
72
|
|
69
73
|
def filter_by_status(values, operator = OPERATORS[:equal_to])
|
@@ -5,8 +5,10 @@ module Uberbringer
|
|
5
5
|
|
6
6
|
wsdl FigNewton.remedy_wsdl
|
7
7
|
soap_header({'AuthenticationInfo' => {:userName => FigNewton.remedy_username, :password => FigNewton.remedy_password}})
|
8
|
-
|
9
|
-
|
8
|
+
ssl_options do |opts|
|
9
|
+
opts.verify_mode = :none
|
10
|
+
opts.version = :TLSv1
|
11
|
+
end
|
10
12
|
|
11
13
|
def execute_query(query)
|
12
14
|
begin
|
data/lib/uberbringer/version.rb
CHANGED
metadata
CHANGED
@@ -1,55 +1,55 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: uberbringer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- mosaic
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-12-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: soap-object
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: fig_newton
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rspec
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- -
|
45
|
+
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: 2.12.0
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- -
|
52
|
+
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: 2.12.0
|
55
55
|
description: Wrapper around remedy web service for easy querying
|
@@ -59,7 +59,7 @@ executables: []
|
|
59
59
|
extensions: []
|
60
60
|
extra_rdoc_files: []
|
61
61
|
files:
|
62
|
-
- .gitignore
|
62
|
+
- ".gitignore"
|
63
63
|
- Gemfile
|
64
64
|
- Gemfile.lock
|
65
65
|
- README.md
|
@@ -81,17 +81,17 @@ require_paths:
|
|
81
81
|
- lib
|
82
82
|
required_ruby_version: !ruby/object:Gem::Requirement
|
83
83
|
requirements:
|
84
|
-
- -
|
84
|
+
- - ">="
|
85
85
|
- !ruby/object:Gem::Version
|
86
86
|
version: '0'
|
87
87
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
88
88
|
requirements:
|
89
|
-
- -
|
89
|
+
- - ">="
|
90
90
|
- !ruby/object:Gem::Version
|
91
91
|
version: '0'
|
92
92
|
requirements: []
|
93
93
|
rubyforge_project:
|
94
|
-
rubygems_version: 2.
|
94
|
+
rubygems_version: 2.4.5.1
|
95
95
|
signing_key:
|
96
96
|
specification_version: 4
|
97
97
|
summary: Wrapper around remedy web service for easy querying
|