Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
U
utils
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
library
utils
Commits
44915748
Verified
Commit
44915748
authored
Jan 22, 2019
by
Cui
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add new message type [MASS] alias CUSTOMER
parent
7908c975
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
1 deletion
+2
-1
structs.go
sender/structs.go
+1
-1
wrapper.go
sender/wrapper.go
+1
-0
No files found.
sender/structs.go
View file @
44915748
...
@@ -9,7 +9,7 @@ type MessageStruct struct {
...
@@ -9,7 +9,7 @@ type MessageStruct struct {
AppId
string
`json:"appId" bson:"appId"`
AppId
string
`json:"appId" bson:"appId"`
SmsAppId
int
`json:"smsAppId" bson:"smsAppId"`
SmsAppId
int
`json:"smsAppId" bson:"smsAppId"`
SmsAppKey
string
`json:"smsAppKey" bson:"smsAppKey"`
SmsAppKey
string
`json:"smsAppKey" bson:"smsAppKey"`
Action
string
Action
string
`json:"action" bson:"action"`
// 推送类型 OneTime_Push,Timing_Push,Delay_Push,Nomal_Push
Retry
int
`json:"retry"`
Retry
int
`json:"retry"`
PushCount
int
`json:"pushCount"`
PushCount
int
`json:"pushCount"`
...
...
sender/wrapper.go
View file @
44915748
...
@@ -14,6 +14,7 @@ func Sender(accessToken string, message MessageStruct) (int, string) {
...
@@ -14,6 +14,7 @@ func Sender(accessToken string, message MessageStruct) (int, string) {
switch
message
.
MessageType
{
switch
message
.
MessageType
{
case
"CUSTOMER"
:
case
"CUSTOMER"
:
case
"MASS"
:
var
cmi
CustomerMessageInterface
var
cmi
CustomerMessageInterface
err
:=
json
.
Unmarshal
(
message
.
MessageData
,
&
cmi
)
err
:=
json
.
Unmarshal
(
message
.
MessageData
,
&
cmi
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment