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
22c1f729
Commit
22c1f729
authored
Jul 25, 2020
by
任晓松
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
商标驳回复审
parent
7386666b
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
251 additions
and
18 deletions
+251
-18
center-channel/app/base/api/impl/nmaction/name.js
+15
-17
center-channel/app/base/api/impl/opaction/tmReview.js
+48
-0
center-channel/app/base/service/impl/utilsSve/utilsDeliverSve.js
+187
-0
center-channel/app/config/routes/api.js
+1
-1
No files found.
center-channel/app/base/api/impl/nmaction/name.js
View file @
22c1f729
...
@@ -111,27 +111,25 @@ class NameAPI extends WEBBase{
...
@@ -111,27 +111,25 @@ class NameAPI extends WEBBase{
async
getNameDetail
(
pobj
){
async
getNameDetail
(
pobj
){
pobj
.
actionType
=
'getOrderDeliveryInfo'
;
pobj
.
actionType
=
'getOrderDeliveryInfo'
;
const
opResult
=
await
this
.
utilsOrderSve
.
getOrderDeliveryInfo
(
pobj
,
pobj
.
actionBody
);
const
opResult
=
await
this
.
utilsOrderSve
.
getOrderDeliveryInfo
(
pobj
,
pobj
.
actionBody
);
if
(
opResult
.
status
==
0
){
if
(
opResult
.
status
!=
0
){
if
(
!
opResult
.
data
.
hasOwnProperty
(
'result_name'
)){
return
system
.
getResult
(
null
,
opResult
.
msg
);
const
actionBody
=
await
this
.
redisClient
.
get
(
'ch'
+
JSON
.
stringify
(
pobj
.
actionBody
.
orderNo
));
if
(
actionBody
!=
null
){
const
nameResult
=
await
this
.
restPostUrl
(
JSON
.
parse
(
actionBody
),
this
.
centerCacheUrl
+
"treasure_name"
);
if
(
nameResult
.
code
==
200
){
pobj
.
actionType
=
'addOrderDelivery'
pobj
.
actionBody
=
nameResult
.
data
;
//取名结果存储
await
this
.
restPostUrl
(
pobj
,
this
.
centerOrderUrl
+
"action/nameOrder/springBoard"
);
return
system
.
getResult
(
nameResult
.
data
,
"操作成功"
)
}
}
}
else
{
if
(
opResult
.
data
.
hasOwnProperty
(
'result_name'
))
{
return
system
.
getResult
()
return
system
.
getResult
(
opResult
.
data
,
'操作成功'
);
}
}
}
else
{
let
actionBody
=
await
this
.
redisClient
.
get
(
'ch'
+
JSON
.
stringify
(
pobj
.
actionBody
.
orderNo
));
return
system
.
getResult
(
opResult
.
data
,
'操作成功'
)
if
(
!
actionBody
){
return
system
.
getResult
(
null
)
}
}
}
else
{
let
nameResult
=
await
this
.
restPostUrl
(
JSON
.
parse
(
actionBody
),
this
.
centerCacheUrl
+
"treasure_name"
);
return
system
.
getResultFail
(
''
,
opResult
.
msg
);
if
(
nameResult
.
code
==
200
){
pobj
.
actionType
=
'addOrderDelivery'
;
pobj
.
actionBody
=
nameResult
.
data
;
//取名结果存储
let
result
=
await
this
.
restPostUrl
(
pobj
,
this
.
centerOrderUrl
+
"action/nameOrder/springBoard"
);
return
system
.
getResult
(
nameResult
.
data
,
"操作成功"
);
}
}
return
system
.
getResult
(
null
,
'try again'
);
}
}
}
}
...
...
center-channel/app/base/api/impl/opaction/tmReview.js
0 → 100644
View file @
22c1f729
var
WEBBase
=
require
(
"../../web.base"
);
var
system
=
require
(
"../../../system"
);
var
settings
=
require
(
"../../../../config/settings"
);
class
tmReview
extends
WEBBase
{
constructor
()
{
super
();
this
.
utilsDeliverSve
=
system
.
getObject
(
"service.utilsSve.utilsDeliverSve"
);
}
async
springBoard
(
pobj
,
qobj
,
req
)
{
if
(
!
pobj
.
actionProcess
)
{
return
system
.
getResult
(
null
,
"actionProcess参数不能为空"
);
}
if
(
!
pobj
.
actionType
)
{
return
system
.
getResult
(
null
,
"actionType参数不能为空"
);
}
var
result
=
await
this
.
opActionProcess
(
pobj
,
pobj
.
actionType
,
req
);
return
result
;
}
async
opActionProcess
(
pobj
,
action_type
,
req
)
{
pobj
.
requestId
=
req
.
requestId
;
var
opResult
=
null
;
switch
(
action_type
)
{
case
"addReviewList"
:
//提交复审材料
opResult
=
await
this
.
utilsDeliverSve
.
addReviewList
(
pobj
,
pobj
.
actionBody
);
break
;
case
"getReOrderList"
:
//获取订单列表信息
opResult
=
await
this
.
utilsDeliverSve
.
getReOrderList
(
pobj
,
pobj
.
actionBody
);
break
;
case
"getOfficalList"
:
//获取官文列表
opResult
=
await
this
.
utilsDeliverSve
.
getOfficialList
(
pobj
,
pobj
.
actionBody
);
break
;
case
"receiveDeliveryData"
:
//接收交付中心交付数据
opResult
=
await
this
.
utilsDeliverSve
.
receiveDeliveryInfo
(
pobj
,
pobj
.
actionBody
);
break
;
default
:
opResult
=
system
.
getResult
(
null
,
"action_type参数错误"
);
break
;
}
return
opResult
;
}
}
module
.
exports
=
tmReview
;
\ No newline at end of file
center-channel/app/base/service/impl/utilsSve/utilsDeliverSve.js
0 → 100644
View file @
22c1f729
const
system
=
require
(
"../../../system"
);
const
AppServiceBase
=
require
(
"../../app.base"
);
const
settings
=
require
(
"../../../../config/settings"
);
class
utilsDeliverSve
extends
AppServiceBase
{
constructor
()
{
super
();
this
.
centerOrderUrl
=
settings
.
centerOrderUrl
();
}
/**
* 交付中心推送接口
* @param pobj
* @returns {Promise<*>}
*/
async
pushDeliver
(
pobj
){
var
verifyResult
=
await
this
.
verifyParam
(
pobj
.
actionBody
);
if
(
verifyResult
.
status
!=
0
)
{
return
await
this
.
disposePushResultFail
(
pobj
,
verifyResult
,
"fq->pushAliBusiness2Fq->verifyResult"
,
this
.
pushlogFailType
.
FQ
);
}
let
params
=
verifyResult
.
data
;
const
url
=
this
.
centerOrderUrl
+
"action/tmreview/springBoard"
;
var
result
=
await
this
.
opClientPost
(
pobj
,
url
,
params
);
return
await
this
.
disposePushResult
(
pobj
,
result
,
"fq->pushAliBusiness2Fq->result"
,
this
.
pushlogFailType
.
FQ
);
}
/**
* 推送方法及日志记录
* @param pobj
* @param url
* @param key
* @param secret
* @param params
* @returns {Promise<{msg: *, data, status: number}|{msg: *, data, bizmsg: *|string, status: number}>}
*/
async
opClientPost
(
pobj
,
url
,
params
)
{
try
{
var
rtn
=
await
this
.
restClient
.
execDeliveryPost
(
params
,
url
);
if
(
!
rtn
||
!
rtn
.
stdout
)
{
return
system
.
getResult
(
null
,
"restPost data is empty"
);
}
var
result
=
JSON
.
parse
(
rtn
.
stdout
);
if
(
result
.
status
!=
0
)
{
return
system
.
getResult
(
null
,
"推送失败,失败原因:"
+
rtn
.
errorMsg
+
",selfrequestId="
+
pobj
.
requestId
+
",requestId="
+
rtn
.
requestId
);
}
return
system
.
getResultSuccess
(
null
,
"推送成功"
);
}
catch
(
e
)
{
//日志记录
this
.
logCtl
.
error
({
appid
:
pobj
.
appInfo
?
pobj
.
appInfo
.
uapp_id
||
""
:
""
,
appkey
:
pobj
.
appInfo
?
pobj
.
appInfo
.
uapp_key
||
""
:
""
,
requestId
:
pobj
.
requestId
||
""
,
op
:
"service/impl/utilsSve/utilsDeliverSve/opClientPost"
,
content
:
"error:"
+
e
.
stack
,
// clientIp: pobj.clientIp,
optitle
:
pobj
.
opType
+
"推送操作异常->deviler->opClientPost"
,
});
return
system
.
getResult
(
null
,
"推送操作异常->delivery->opClientPost->error:"
+
e
.
stack
);
}
}
/**
* 参数信息重组
* @param pobj
* @returns {Promise<{msg: *, data, status: number}>}
*/
async
verifyParam
(
actionBody
)
{
let
verify
=
system
.
getResultSuccess
();
let
deliveryData
=
""
;
let
orderNo
=
""
;
let
tradeStatus
=
''
;
let
applicant
=
{};
if
(
actionBody
.
delivery_content
){
deliveryData
=
actionBody
.
delivery_content
[
0
].
deliveryContent
;
orderNo
=
actionBody
.
delivery_content
[
0
].
sourceOrderNo
;
}
if
(
actionBody
.
deliveryData
){
deliveryData
=
actionBody
.
deliveryData
;
orderNo
=
actionBody
.
orderNo
;
}
if
(
deliveryData
.
deliveryStatusName
){
tradeStatus
=
deliveryData
.
deliveryStatusName
;
}
if
(
Object
.
keys
(
deliveryData
.
applyUser
).
length
==
0
||
Object
.
keys
(
deliveryData
.
askForData
).
length
==
0
){
tradeStatus
=
"待完善材料"
;
}
else
{
tradeStatus
=
"待审核"
;
}
applicant
=
{
"askforId"
:
deliveryData
.
apply
.
askforId
,
//申请号
"applicantName"
:
deliveryData
.
apply
.
applicantName
,
// 申请公司姓名
"applicantType"
:
deliveryData
.
apply
.
applicantType
||
''
,
// 申请人类型: 企业 个人
"usccode"
:
deliveryData
.
apply
.
usccode
,
//唯一社会信用代码
"agentName"
:
deliveryData
.
apply
.
agentName
,
//代理机构
"tradeImg"
:
deliveryData
.
apply
.
tradeImg
,
//商标图样
"tradeType"
:
deliveryData
.
apply
.
tradeType
,
"licenseAddr"
:
deliveryData
.
applyUser
.
licenseAddr
||
''
,
// 营业执照地址
"licenseDir"
:
deliveryData
.
applyUser
.
licenseDir
||
''
,
//营业执照文件
"duty"
:
deliveryData
.
applyUser
.
duty
||
""
,
// 负责人职务
"tel"
:
deliveryData
.
applyUser
.
tel
||
""
,
// 联系人电话
"addr"
:
deliveryData
.
applyUser
.
addr
||
""
,
// 联系人地址
"entrust"
:
deliveryData
.
applyUser
.
entrust
||
""
,
// 代理委托书
"country"
:
deliveryData
.
applyUser
.
country
||
""
,
// 申请人国籍
"dutyName"
:
deliveryData
.
applyUser
.
dutyName
||
""
,
// 负责人姓名
"contactsName"
:
deliveryData
.
applyUser
.
contactsName
||
''
,
// 联系人姓名
"email"
:
deliveryData
.
applyUser
.
email
||
''
,
// 联系人邮箱
"mailCode"
:
deliveryData
.
applyUser
.
mailCode
||
''
// 邮政编码
}
let
postData
=
{
orderId
:
orderNo
,
askforId
:
deliveryData
.
apply
.
askforId
,
tradeType
:
deliveryData
.
apply
.
tradeType
,
tradeImg
:
deliveryData
.
apply
.
tradeImg
,
tradeStatus
:
tradeStatus
,
usccode
:
deliveryData
.
apply
.
usccode
,
agentName
:
deliveryData
.
apply
.
agentName
,
trademarkRejInfo
:
deliveryData
.
trademarkRejInfo
,
applicant
:
applicant
,
askForData
:
deliveryData
.
askForData
,
supData
:
deliveryData
.
supData
}
verify
.
data
=
postData
;
return
verify
;
}
/**
* 提交复审申请单
* @param pobj
* @param actionBody
* @returns {Promise<void>}
*/
async
addReviewList
(
pobj
,
actionBody
){
//参数重组
let
verifyResult
=
await
this
.
verifyParam
(
pobj
.
actionBody
);
if
(
verifyResult
.
status
!=
0
)
{
return
await
this
.
disposePushResultFail
(
pobj
,
verifyResult
,
"delivery->pushDelivery->verifyResult"
,
""
);
}
//修改交付信息
const
url
=
this
.
centerOrderUrl
+
"action/tmreview/springBoard"
;
let
result
=
await
this
.
restPostUrl
(
pobj
,
url
);
if
(
result
.
status
!==
0
){
return
system
.
getResult
(
null
,
'更新失败'
)
}
return
result
;
}
/**
* 商标驳回复审控制台列表+模糊查询
* @param pobj
* @param actionBody
* @returns {Promise<void>}
*/
async
getReOrderList
(
pobj
,
actionBody
){
let
url
=
this
.
centerOrderUrl
+
"action/tmreview/springBoard"
;
let
result
=
await
this
.
restPostUrl
(
pobj
,
url
);
return
result
;
}
/**
* 获取官文列表
* @param pobj
* @param actionBody
* @returns {Promise<void>}
*/
async
getOfficialList
(
pobj
,
actionBody
){
let
url
=
this
.
centerOrderUrl
+
'action/tmreview/springBoard'
;
const
result
=
await
this
.
restPostUrl
(
pobj
,
url
);
return
result
;
}
/**
* 接收交付中心信息
* @returns {Promise<void>}
*/
async
receiveDeliveryInfo
(
pobj
,
actionBody
){
//修改交付信息
const
url
=
this
.
centerOrderUrl
+
"action/tmreview/springBoard"
;
pobj
.
actionType
=
'addReviewList'
;
let
result
=
await
this
.
restPostUrl
(
pobj
,
url
);
if
(
result
.
status
!==
0
){
return
system
.
getResult
(
null
,
result
.
msg
)
}
return
result
;
}
}
module
.
exports
=
utilsDeliverSve
;
\ No newline at end of file
center-channel/app/config/routes/api.js
View file @
22c1f729
...
@@ -242,7 +242,7 @@ module.exports = function (app) {
...
@@ -242,7 +242,7 @@ module.exports = function (app) {
"getOrderDeliveryFlowInfo"
,
"getOrderDeliveryFlowList"
,
"getOrderLogInfo"
,
"updateContacts"
,
"updateTmOrder"
,
"delOrder"
,
"getOrderDeliveryFlowInfo"
,
"getOrderDeliveryFlowList"
,
"getOrderLogInfo"
,
"updateContacts"
,
"updateTmOrder"
,
"delOrder"
,
"submitProgramme"
,
"getProgrammeListByUser"
,
"getProgrammeInfoByNeedNo"
,
"abolishProgramme"
,
"getAliPayInfo"
,
"submitProgramme"
,
"getProgrammeListByUser"
,
"getProgrammeInfoByNeedNo"
,
"abolishProgramme"
,
"getAliPayInfo"
,
"getPaidLogoListByUser"
,
"getCollectibleLogoListByUser"
,
"collectLogo"
,
"getLogoMaterial"
,
"cancelCollectLogo"
,
"icpNotify"
,
"createName"
,
"getNameDetail"
,
"orderConfirm"
,
"getPaidLogoListByUser"
,
"getCollectibleLogoListByUser"
,
"collectLogo"
,
"getLogoMaterial"
,
"cancelCollectLogo"
,
"icpNotify"
,
"createName"
,
"getNameDetail"
,
"orderConfirm"
,
"orderTotalSum"
,
"collect"
,
"reg"
,
"orderCheck"
"orderTotalSum"
,
"collect"
,
"reg"
,
"orderCheck"
,
"getReOrderList"
,
"getOfficalList"
];
];
if
(
lst
.
indexOf
(
req
.
body
.
actionType
)
>=
0
)
{
if
(
lst
.
indexOf
(
req
.
body
.
actionType
)
>=
0
)
{
var
userpin
=
req
.
headers
[
"userpin"
]
||
""
;
var
userpin
=
req
.
headers
[
"userpin"
]
||
""
;
...
...
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