simplemdm 1.0.0 → 1.1.2

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: 94d0daa10a153b75d7ab2b308143d760e327b926
4
- data.tar.gz: 703be9145e4736bc439aa9be99f1dace8c6e27f7
3
+ metadata.gz: 9cf1cb4994ed69aced823f1bc776e6a8669a4f75
4
+ data.tar.gz: 3c180793805786316f12a5f929b3db4202f66e02
5
5
  SHA512:
6
- metadata.gz: 56deca1f114634998ec4b70ae5f7b58d7a7e4b47d2177566edb098c34f9fea7e0561c98026bedb17e3c3d0e930e669d68d39764f1b9f1e486b5ba48c42847688
7
- data.tar.gz: fbb7236ca0464bdb64e1f33f9653b2574591f2f2289feaefc555f784ec7724d8a4da6b79b98b282e5876722a8d122208180ed7a9c4b21e296ba01f90a6b340a9
6
+ metadata.gz: a7b71c8e55d2ec04821afa933efecdbc18b211dbefe7c9e8cf395f92f991cd7a8d164c696b3f2088bb9e8023e5d53b8b4faecd10ac8027b114095dde4e028ffb
7
+ data.tar.gz: e8349f56422f9525f013da9ad21149b8c30b3fbcdf0accb345dcb59003c479b10bea51dd9ecf9861a06cc5bdfd2fac2b6ac2eab0bbd4ce516495fdabc20c12df
@@ -13,5 +13,18 @@ module SimpleMDM
13
13
  build hash['data']
14
14
  end
15
15
 
16
+ def add_device(device)
17
+ raise "The object you provided is not a device" unless device.kind_of?(SimpleMDM::Device)
18
+
19
+ hash, code = fetch("device_groups/#{self.id}/devices/#{device.id}", :post)
20
+
21
+ if code == 204
22
+ self['device_ids'] = self['device_ids'] | [device.id]
23
+ true
24
+ else
25
+ false
26
+ end
27
+ end
28
+
16
29
  end
17
30
  end
@@ -1,3 +1,3 @@
1
1
  module SimpleMDM
2
- VERSION = "1.0.0".freeze
2
+ VERSION = "1.1.2".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simplemdm
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Taylor Boyko
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-07-01 00:00:00.000000000 Z
11
+ date: 2016-08-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -113,7 +113,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
113
113
  version: '0'
114
114
  requirements: []
115
115
  rubyforge_project:
116
- rubygems_version: 2.4.6
116
+ rubygems_version: 2.6.6
117
117
  signing_key:
118
118
  specification_version: 4
119
119
  summary: Ruby bindings for the SimpleMDM API.