mellat 0.1.3.7.0 → 0.1.3.7.1
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/.gitignore +1 -2
- data/lib/mellat.rb +1 -1
- data/lib/mellat/respond.rb +2 -2
- data/lib/mellat/verification.rb +35 -0
- data/lib/mellat/version.rb +1 -1
- data/mellat-0.1.3.2.gem +0 -0
- data/mellat-0.1.3.3.gem +0 -0
- data/mellat-0.1.3.4.gem +0 -0
- data/mellat-0.1.3.5.gem +0 -0
- data/mellat.gemspec +0 -1
- metadata +8 -17
- data/lib/mellat/plug/bank_name.rb +0 -23
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 0638175e64ca888ba8bec6957939f5aa96a1414d
|
|
4
|
+
data.tar.gz: db3d5143898d62e1cab3a0104c121861b022aadb
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 021da3ac04ba7490056a79a941c5793297fc708835646d09699f0621a1b414645e10dbf15ab3c60ed21ca7d8c0c1a58f20b5ae6ab023cd2863dbb941d9e3ae9d
|
|
7
|
+
data.tar.gz: d7ba93f170d5e45b9b7f90316c61640af4d8a45f42417d54be90419ab1eb65996135ae0ce837037a8a4f2c41658b3a9cec801e0e44d0b5fd90f44edd44e45286
|
data/.gitignore
CHANGED
data/lib/mellat.rb
CHANGED
data/lib/mellat/respond.rb
CHANGED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
require "savon"
|
|
2
|
+
|
|
3
|
+
module Mellat
|
|
4
|
+
|
|
5
|
+
class BpVerifyRequest
|
|
6
|
+
attr_accessor :orderId, :amount, :localDate, :localTime, :additionalData, :payerId, :callBackUrl
|
|
7
|
+
attr_reader :respond
|
|
8
|
+
|
|
9
|
+
def initialize(args = {})
|
|
10
|
+
@orderId = args.fetch(:orderId)
|
|
11
|
+
@saleOrderId = args.fetch(:saleOrderId)
|
|
12
|
+
@saleReferenceId = args.fetch(:saleReferenceId)
|
|
13
|
+
@terminalId = Mellat.configuration.terminalId
|
|
14
|
+
@userName = Mellat.configuration.userName
|
|
15
|
+
@userPassword = Mellat.configuration.userPassword
|
|
16
|
+
@response = RespondBpPayRequest.new()
|
|
17
|
+
@wsdl = Savon.client(wsdl: Mellat.configuration.wsdl, pretty_print_xml: true,namespace: 'http://interfaces.core.sw.bps.com/')
|
|
18
|
+
end
|
|
19
|
+
|
|
20
|
+
def call
|
|
21
|
+
response = @wsdl.call :bp_verify_request, message: {
|
|
22
|
+
'terminalId' => @terminalId,
|
|
23
|
+
'userName' => @userName,
|
|
24
|
+
'userPassword' => @userPassword,
|
|
25
|
+
'orderId' => @orderId,
|
|
26
|
+
'saleOrderId' => @saleOrderId,
|
|
27
|
+
'saleReferenceId'=> @saleReferenceId,
|
|
28
|
+
}
|
|
29
|
+
# @response.validate()
|
|
30
|
+
return response.body
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
end
|
data/lib/mellat/version.rb
CHANGED
data/mellat-0.1.3.2.gem
ADDED
|
Binary file
|
data/mellat-0.1.3.3.gem
ADDED
|
Binary file
|
data/mellat-0.1.3.4.gem
ADDED
|
Binary file
|
data/mellat-0.1.3.5.gem
ADDED
|
Binary file
|
data/mellat.gemspec
CHANGED
|
@@ -17,7 +17,6 @@ Gem::Specification.new do |spec|
|
|
|
17
17
|
# to allow pushing to a single host or delete this section to allow pushing to any host.
|
|
18
18
|
|
|
19
19
|
spec.add_dependency 'savon', ['~> 2.0']
|
|
20
|
-
spec.add_dependency 'i18n', ['~> 0.8.0']
|
|
21
20
|
|
|
22
21
|
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
|
23
22
|
f.match(%r{^(test|spec|features)/})
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: mellat
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.3.7.
|
|
4
|
+
version: 0.1.3.7.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- mohammad mahmoudi
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2016-12-11 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: savon
|
|
@@ -24,20 +24,6 @@ dependencies:
|
|
|
24
24
|
- - "~>"
|
|
25
25
|
- !ruby/object:Gem::Version
|
|
26
26
|
version: '2.0'
|
|
27
|
-
- !ruby/object:Gem::Dependency
|
|
28
|
-
name: i18n
|
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
|
30
|
-
requirements:
|
|
31
|
-
- - "~>"
|
|
32
|
-
- !ruby/object:Gem::Version
|
|
33
|
-
version: 0.8.0
|
|
34
|
-
type: :runtime
|
|
35
|
-
prerelease: false
|
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
37
|
-
requirements:
|
|
38
|
-
- - "~>"
|
|
39
|
-
- !ruby/object:Gem::Version
|
|
40
|
-
version: 0.8.0
|
|
41
27
|
- !ruby/object:Gem::Dependency
|
|
42
28
|
name: rspec
|
|
43
29
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -88,6 +74,7 @@ extensions: []
|
|
|
88
74
|
extra_rdoc_files: []
|
|
89
75
|
files:
|
|
90
76
|
- ".gitignore"
|
|
77
|
+
- ".idea/vcs.xml"
|
|
91
78
|
- CODE_OF_CONDUCT.md
|
|
92
79
|
- Gemfile
|
|
93
80
|
- LICENSE.txt
|
|
@@ -99,11 +86,15 @@ files:
|
|
|
99
86
|
- lib/generators/mellat/install_generator.rb
|
|
100
87
|
- lib/generators/templates/mellat_initializer.rb
|
|
101
88
|
- lib/mellat.rb
|
|
102
|
-
- lib/mellat/plug/bank_name.rb
|
|
103
89
|
- lib/mellat/plug/unique_bank_code.rb
|
|
104
90
|
- lib/mellat/requisition.rb
|
|
105
91
|
- lib/mellat/respond.rb
|
|
92
|
+
- lib/mellat/verification.rb
|
|
106
93
|
- lib/mellat/version.rb
|
|
94
|
+
- mellat-0.1.3.2.gem
|
|
95
|
+
- mellat-0.1.3.3.gem
|
|
96
|
+
- mellat-0.1.3.4.gem
|
|
97
|
+
- mellat-0.1.3.5.gem
|
|
107
98
|
- mellat.gemspec
|
|
108
99
|
homepage: https://github.com/mm580486/mellat
|
|
109
100
|
licenses:
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
# encoding: utf-8
|
|
2
|
-
require 'mellat/plug/unique_bank_code'
|
|
3
|
-
module Mellat
|
|
4
|
-
|
|
5
|
-
module BankName
|
|
6
|
-
def to_bank
|
|
7
|
-
id=self.to_s[0...6]
|
|
8
|
-
return Mellat::UniqueBankCode::IDS[id]
|
|
9
|
-
end
|
|
10
|
-
end
|
|
11
|
-
|
|
12
|
-
end
|
|
13
|
-
|
|
14
|
-
class Integer
|
|
15
|
-
# Patch Integer class to include `to_bank` method
|
|
16
|
-
include Mellat::BankName
|
|
17
|
-
|
|
18
|
-
end
|
|
19
|
-
|
|
20
|
-
class String
|
|
21
|
-
# Patch Integer class to include `to_bank` method
|
|
22
|
-
include Mellat::BankName
|
|
23
|
-
end
|