stekker_zaptec 1.0.1 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rspec +2 -0
- data/Gemfile.lock +1 -1
- data/README.md +4 -6
- data/bin/console +1 -1
- data/lib/{zaptec.rb → stekker_zaptec.rb} +0 -0
- data/lib/zaptec/constants.rb +2 -0
- data/lib/zaptec/version.rb +1 -1
- metadata +3 -7
- data/StekkerWeb/gems/zaptec/.gitignore +0 -11
- data/StekkerWeb/gems/zaptec/.rspec +0 -3
- data/StekkerWeb/gems/zaptec/.rubocop.yml +0 -1
- data/StekkerWeb/gems/zaptec/.ruby-version +0 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b93472771162eced218695ad47612b8d001d0b562669077af092de5ac5733d81
|
4
|
+
data.tar.gz: 78d184fb7979d966be2944c575a70444372555ea78101163f78c8565b5a90cec
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d9930219d2b59aea5968498626b3289e40762a83afdfbd177605e4909ec9424cf588ca62f29b6162bce63803f4a4dd4a1ee06631451251cc547fb8678712bfc4
|
7
|
+
data.tar.gz: 5674b39478d6d644036f4ea5e85794e5331ef0440775d83ee21c46e36fd98e0f77e5b09d5e112f9c0238a7269fbf784a52449f08a55a05c9e8738bf870af2b07
|
data/.rspec
CHANGED
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -24,17 +24,17 @@ goals.
|
|
24
24
|
|
25
25
|
Add this line to your application's Gemfile:
|
26
26
|
|
27
|
-
|
27
|
+
```ruby
|
28
|
+
gem "stekker_zaptec"
|
28
29
|
```
|
29
30
|
|
30
|
-
```ruby
|
31
31
|
And then execute:
|
32
32
|
|
33
33
|
$ bundle install
|
34
34
|
|
35
35
|
Or install it yourself as:
|
36
36
|
|
37
|
-
$ gem install
|
37
|
+
$ gem install stekker_zaptec
|
38
38
|
|
39
39
|
## Usage
|
40
40
|
|
@@ -45,10 +45,8 @@ $ bin/console
|
|
45
45
|
```
|
46
46
|
|
47
47
|
```ruby
|
48
|
-
require "zaptec"
|
49
|
-
|
50
48
|
client = Zaptec::Client.new
|
51
|
-
client.
|
49
|
+
client.authorize(username: "username@example.com", password: "password")
|
52
50
|
# #<Zaptec::Credentials:0x000000011c35d708
|
53
51
|
|
54
52
|
# Get a list of chargers
|
data/bin/console
CHANGED
File without changes
|
data/lib/zaptec/constants.rb
CHANGED
@@ -4,6 +4,8 @@ module Zaptec
|
|
4
4
|
def observation_state_id_to_name(state_id:, device_type:)
|
5
5
|
device_type_observation_ids(device_type)
|
6
6
|
.fetch(state_id)
|
7
|
+
rescue KeyError
|
8
|
+
"Unknown state id '#{state_id}' (device type '#{device_type}')"
|
7
9
|
end
|
8
10
|
|
9
11
|
def charger_operation_mode_to_name(operation_mode)
|
data/lib/zaptec/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: stekker_zaptec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Team Stekker
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-02-
|
11
|
+
date: 2023-02-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activemodel
|
@@ -82,14 +82,10 @@ files:
|
|
82
82
|
- Gemfile.lock
|
83
83
|
- README.md
|
84
84
|
- Rakefile
|
85
|
-
- StekkerWeb/gems/zaptec/.gitignore
|
86
|
-
- StekkerWeb/gems/zaptec/.rspec
|
87
|
-
- StekkerWeb/gems/zaptec/.rubocop.yml
|
88
|
-
- StekkerWeb/gems/zaptec/.ruby-version
|
89
85
|
- bin/console
|
90
86
|
- bin/setup
|
91
87
|
- data/constants.json
|
92
|
-
- lib/
|
88
|
+
- lib/stekker_zaptec.rb
|
93
89
|
- lib/zaptec/charger.rb
|
94
90
|
- lib/zaptec/client.rb
|
95
91
|
- lib/zaptec/constants.rb
|
@@ -1 +0,0 @@
|
|
1
|
-
../../.rubocop.yml
|
@@ -1 +0,0 @@
|
|
1
|
-
../../.ruby-version
|