wechat-jsapi 0.1.1 → 0.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: aa94a91d29d581087e7e1ee293c66e0be9bfa759
4
- data.tar.gz: f3f89efc91113bd9bebd62079c5fa4c6471c965e
3
+ metadata.gz: aa2aa289708afa2d120dec5ceb9ba85e8c246650
4
+ data.tar.gz: c6a7ecc48c7603fbaddfe5c554ec985dc1a198d5
5
5
  SHA512:
6
- metadata.gz: 12ff93b44a45a34693e121e457230495a0473e11a9f1fc22025893dee6cf631b4ec4c54598673b8f235e0471b92f6187b5bc6af7ea1c4a69d3c7fadebd76fec4
7
- data.tar.gz: 4e86ed09953196620e9821e459d01e98e82dea13da5bee3cbe475904aabafb1b7b642fd1bbaf0f86dabfaed0262e369154eb5098703a0febb4b09dfa0e4b4ead
6
+ metadata.gz: 8ebf461a257255367f5cf29a5ff191dbe48d4df9a418c1c51721f737f7d0790047758a4ae20b4426d645225cf0785f9b9353a22d0a8ef8471207326459d27402
7
+ data.tar.gz: e7ddf76b8bfecf8091944583c4de6f729c033a8fc48c6db76515a1b03e09aeb5f8f105cb8d16a0d0eca892f3a17563d03f35ffcb0b45ea0305b72a9755df55d6
@@ -5,6 +5,9 @@
5
5
  2. Ticket wrapper class
6
6
 
7
7
  ## v0.1.1
8
- 1. Improve the Ruby Gem Specification to depend on [wechat-core](https://github.com/topbitdu/wechat-core) v0.4
9
- 2. Improve the Signature class for the argument validation
8
+ 1. Improved the Ruby Gem Specification to depend on [wechat-core](https://github.com/topbitdu/wechat-core) v0.4
9
+ 2. Improved the Signature class for the argument validation
10
10
  3. Improve the Ticket wrapper class for the argument validation & HTTP request
11
+
12
+ ## v0.1.2
13
+ 1. Improve the Ticket wrapper class for the HTTP request
@@ -1,30 +1,42 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- wechat-jsapi (0.1)
5
- wechat-core (~> 0.3)
4
+ wechat-jsapi (0.1.1)
5
+ wechat-core (~> 0.4)
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
9
9
  specs:
10
- diff-lcs (1.2.5)
11
- httpclient (2.8.0)
10
+ activesupport (5.0.2)
11
+ concurrent-ruby (~> 1.0, >= 1.0.2)
12
+ i18n (~> 0.7)
13
+ minitest (~> 5.1)
14
+ tzinfo (~> 1.1)
15
+ concurrent-ruby (1.0.5)
16
+ diff-lcs (1.3)
17
+ httpclient (2.8.3)
18
+ i18n (0.8.1)
19
+ minitest (5.10.1)
12
20
  rake (10.5.0)
13
- rspec (3.4.0)
14
- rspec-core (~> 3.4.0)
15
- rspec-expectations (~> 3.4.0)
16
- rspec-mocks (~> 3.4.0)
17
- rspec-core (3.4.4)
18
- rspec-support (~> 3.4.0)
19
- rspec-expectations (3.4.0)
21
+ rspec (3.5.0)
22
+ rspec-core (~> 3.5.0)
23
+ rspec-expectations (~> 3.5.0)
24
+ rspec-mocks (~> 3.5.0)
25
+ rspec-core (3.5.4)
26
+ rspec-support (~> 3.5.0)
27
+ rspec-expectations (3.5.0)
20
28
  diff-lcs (>= 1.2.0, < 2.0)
21
- rspec-support (~> 3.4.0)
22
- rspec-mocks (3.4.1)
29
+ rspec-support (~> 3.5.0)
30
+ rspec-mocks (3.5.0)
23
31
  diff-lcs (>= 1.2.0, < 2.0)
24
- rspec-support (~> 3.4.0)
25
- rspec-support (3.4.1)
26
- wechat-core (0.3)
27
- httpclient (~> 2.7)
32
+ rspec-support (~> 3.5.0)
33
+ rspec-support (3.5.0)
34
+ thread_safe (0.3.6)
35
+ tzinfo (1.2.2)
36
+ thread_safe (~> 0.1)
37
+ wechat-core (0.4.1)
38
+ activesupport (>= 4.2)
39
+ httpclient (>= 2.8)
28
40
 
29
41
  PLATFORMS
30
42
  ruby
@@ -36,4 +48,4 @@ DEPENDENCIES
36
48
  wechat-jsapi!
37
49
 
38
50
  BUNDLED WITH
39
- 1.12.5
51
+ 1.13.6
data/ROADMAP.md CHANGED
@@ -8,3 +8,6 @@
8
8
  1. Improve the Ruby Gem Specification to depend on [wechat-core](https://github.com/topbitdu/wechat-core) v0.4
9
9
  2. Improve the Signature class for the argument validation
10
10
  3. Improve the Ticket wrapper class for the argument validation & HTTP request
11
+
12
+ ## v0.1.2
13
+ 1. Improve the Ticket wrapper class for the HTTP request
@@ -1,3 +1,11 @@
1
+ ##
2
+ # Singature 类提供生成JS-SDK权限验证的签名的方法。如:
3
+ # link = 'https://product-wechat.company.com/home'
4
+ # ticket = // your ticket
5
+ # timestamp = Time.now.to_i.to_s
6
+ # nonce = SecureRandom.hex 8
7
+ # singature = Wechat::JSAPI::Signature.create link, ticket, timestamp, nonce
8
+
1
9
  class Wechat::JSAPI::Signature
2
10
 
3
11
  extend Wechat::Core::Common
@@ -1,3 +1,7 @@
1
+ ##
2
+ # Ticket 类提供根据访问令牌 access_token 获取 JSAPI Ticket 的方法。如:
3
+ # jsapi_ticket = Wechat::JSAPI::Ticket.create access_token
4
+
1
5
  class Wechat::JSAPI::Ticket
2
6
 
3
7
  extend Wechat::Core::Common
@@ -17,8 +21,7 @@ class Wechat::JSAPI::Ticket
17
21
 
18
22
  assert_present! :access_token, access_token
19
23
 
20
- message = get_json "https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_token=#{access_token}&type=jsapi"
21
- message.body
24
+ get_json "https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_token=#{access_token}&type=jsapi"
22
25
 
23
26
  end
24
27
 
@@ -1,5 +1,5 @@
1
1
  module Wechat
2
2
  module JSAPI
3
- VERSION = '0.1.1'.freeze
3
+ VERSION = '0.1.2'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wechat-jsapi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Topbit Du
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-01-20 00:00:00.000000000 Z
11
+ date: 2017-03-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler