Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Z
zhichan
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
蒋勇
zhichan
Commits
59d7e29f
Commit
59d7e29f
authored
Feb 21, 2020
by
庄冰
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
policysubscribe
parent
a1779af5
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
113 additions
and
0 deletions
+113
-0
center-channel/app/base/api/impl/action/policy.js
+9
-0
center-channel/app/base/service/impl/policy/policySve.js
+12
-0
center-channel/app/front/entry/public/apidoc/platform/policy.md
+92
-0
No files found.
center-channel/app/base/api/impl/action/policy.js
View file @
59d7e29f
...
...
@@ -43,6 +43,15 @@ class PolicyAPI extends APIBase {
case
"getWxSign"
:
//获取微信签名信息
opResult
=
this
.
policySve
.
getWxSign
(
action_body
.
url
);
break
;
case
"submitPolicysubscribe"
:
//提交政策订阅
opResult
=
this
.
policySve
.
reqPolicyApi
(
pobj
);
break
;
case
"delPolicysubscribe"
:
//取消政策订阅
opResult
=
this
.
policySve
.
reqPolicyApi
(
pobj
);
break
;
case
"getPolicysubscribeList"
:
//获取政策订阅列表
opResult
=
this
.
policySve
.
reqPolicyApi
(
pobj
);
break
;
default
:
opResult
=
system
.
getResult
(
null
,
"action_type参数错误"
);
break
;
...
...
center-channel/app/base/service/impl/policy/policySve.js
View file @
59d7e29f
...
...
@@ -88,6 +88,12 @@ class PolicyService{
}
}
async
reqPolicyApi
(
pobj
){
var
url
=
this
.
centerOrderUrl
+
"action/policy/springBoard"
;
var
rtn
=
await
this
.
execClient
.
execPost
(
pobj
,
url
);
var
data
=
JSON
.
parse
(
rtn
.
stdout
);
return
data
;
}
async
policyQuery
(
pobj
)
{
var
url
=
this
.
centerOrderUrl
+
"action/policy/springBoard"
;
var
rtn
=
await
this
.
execClient
.
execPost
(
pobj
,
url
);
...
...
@@ -112,5 +118,11 @@ class PolicyService{
var
data
=
JSON
.
parse
(
rtn
.
stdout
);
return
data
;
}
async
submitPolicysubscribe
(
pobj
){
var
url
=
this
.
centerOrderUrl
+
"action/policy/springBoard"
;
var
rtn
=
await
this
.
execClient
.
execPost
(
pobj
,
url
);
var
data
=
JSON
.
parse
(
rtn
.
stdout
);
return
data
;
}
}
module
.
exports
=
PolicyService
;
center-channel/app/front/entry/public/apidoc/platform/policy.md
View file @
59d7e29f
...
...
@@ -5,6 +5,9 @@
1.
[
政策需求列表
](
#getPolicyNeedList
)
1.
[
需求信息备注提交
](
#submitPolicyNeedNotes
)
1.
[
获取微信签名信息
](
#getWxSign
)
1.
[
提交政策订阅
](
#submitPolicysubscribe
)
1.
[
取消政策订阅
](
#delPolicysubscribe
)
1.
[
获取政策订阅列表
](
#getPolicysubscribeist
)
## **<a name="policyQuery"> 政策检索(H5)</a>**
[
返回到目录
](
#menu
)
...
...
@@ -216,4 +219,93 @@
"requestId"
:
"5dc78d501b6d42c2af0f157cb1cceb28"
}
```
## **<a name="submitPolicysubscribe"> 提交政策订阅</a>**
[
返回到目录
](
#menu
)
##### URL
[
/web/action/policy/springBoard
]
#### 参数格式 `JSON`
#### HTTP请求方式 `POST`
#### 渠道执行的类型 actionType:submitPolicysubscribe
```
javascript
{
"actionType"
:
"submitPolicysubscribe"
,
"actionBody"
:{
"openid"
:
"test001"
,
"policyProvince"
:
"北京市"
,
"policyTypes"
:[
"jrdk"
,
"fzbt"
]
}
}
```
#### 返回结果
```
javascript
{
"status"
:
0
,
"msg"
:
"success"
,
"data"
:
null
,
"requestId"
:
"6528d103010d406eaa91a2d391df4463"
}
```
## **<a name="delPolicysubscribe"> 取消政策订阅</a>**
[
返回到目录
](
#menu
)
##### URL
[
/web/action/policy/springBoard
]
#### 参数格式 `JSON`
#### HTTP请求方式 `POST`
#### 渠道执行的类型 actionType:delPolicysubscribe
```
javascript
{
"actionType"
:
"delPolicysubscribe"
,
"actionBody"
:{
"openid"
:
"test001"
,
"policyId"
:
"1"
}
}
```
#### 返回结果
```
javascript
{
"status"
:
0
,
"msg"
:
"success"
,
"data"
:
null
,
"requestId"
:
"6528d103010d406eaa91a2d391df4463"
}
```
## **<a name="getPolicysubscribeist"> 获取政策订阅列表</a>**
[
返回到目录
](
#menu
)
##### URL
[
/web/action/policy/springBoard
]
#### 参数格式 `JSON`
#### HTTP请求方式 `POST`
#### 渠道执行的类型 actionType:getPolicysubscribeist
```
javascript
{
"actionType"
:
"getPolicysubscribeist"
,
"actionBody"
:{
"openid"
:
"test001"
}
}
```
#### 返回结果
```
javascript
{
"status"
:
0
,
"msg"
:
"success"
,
"data"
:[
{
"id"
:
2
,
"policyProvince"
:
"北京市"
,
"policyTypes"
:
"jrdk,fzbt"
,
"created_at"
:
"2020-02-21T07:18:54.000Z"
}
],
"requestId"
:
"c41dd1cd791e4fe19765d8dcb8fa4b6e"
}
```
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