-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdict.go
More file actions
56 lines (55 loc) · 1.41 KB
/
dict.go
File metadata and controls
56 lines (55 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
package gwechat
import "github.com/og/go-dict"
type dictStruct struct {
PayOrderQuery struct{
TradeState struct {
SUCCESS string `dict:"SUCCESS"note:"支付成功"`
REFUND string `dict:"REFUND"note:"转入退款"`
NOTPAY string `dict:"NOTPAY"note:"未支付"`
CLOSED string `dict:"CLOSED"note:"已关闭"`
REVOKED string `dict:"REVOKED"note:"已撤销(刷卡支付)"`
USERPAYING string `dict:"USERPAYING"note:"用户支付中"`
PAYERROR string `dict:"PAYERROR"note:"支付失败(其他原因,如银行返回失败)"`
}
}
PayUnifiedOrder struct{
DeviceInfo struct{
WEB string `dict:"WEB"`
}
SignType struct{
MD5 string `dict:"MD5"`
HMAC string `dict:"HMAC"`
SHA256 string `dict:"SHA256"`
}
FeeType struct{
CNY string `dict:"CNY"`
}
TradeType struct{
JSAPI string `dict:"JSAPI";note:"jsapi支付或小程序支付"`
NATIVE string `dict:"NATIVE"`
APP string `dict:"APP"`
MWEB string `dict:"MWEB";note:"H5支付"`
MICROPAY string `dict:"MICROPAY";note:"付款码支付"`
}
}
WebRedirectAuthorize struct{
Scope struct{
SnsapiBase string `dict:"snsapi_base"`
SnsapiUserinfo string `dict:"snsapi_userinfo"`
}
}
WebUserInfo struct{
Lang struct{
ZHCN string `dict:"zh_CN"`
ZHTW string `dict:"zh_TW"`
EN string `dict:"en"`
}
}
}
var dict = dictStruct{}
func init () {
gdict.Fill(&dict)
}
func Dict() dictStruct {
return dict
}