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
b1ca2084
Commit
b1ca2084
authored
Jul 29, 2020
by
任晓松
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
商标驳回复审
parent
abd7e34f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
47 additions
and
69 deletions
+47
-69
center-order/app/base/db/impl/dbcorder/orderofficialDao.js
+3
-3
center-order/app/base/db/models/dbcorder/orderofficial.js
+1
-1
center-order/app/base/service/impl/dbcorder/orderdeliverSve.js
+43
-65
No files found.
center-order/app/base/db/impl/dbcorder/order
delivery
officialDao.js
→
center-order/app/base/db/impl/dbcorder/orderofficialDao.js
View file @
b1ca2084
const
system
=
require
(
"../../../system"
);
const
Dao
=
require
(
"../../dao.base"
);
class
Order
deliveryo
fficialDao
extends
Dao
{
class
Order
O
fficialDao
extends
Dao
{
constructor
()
{
super
(
Dao
.
getModelName
(
Order
deliveryo
fficialDao
));
super
(
Dao
.
getModelName
(
Order
O
fficialDao
));
}
}
module
.
exports
=
Order
deliveryo
fficialDao
;
module
.
exports
=
Order
O
fficialDao
;
center-order/app/base/db/models/dbcorder/order
O
fficial.js
→
center-order/app/base/db/models/dbcorder/order
o
fficial.js
View file @
b1ca2084
...
...
@@ -2,7 +2,7 @@ const system = require("../../../system");
const
settings
=
require
(
"../../../../config/settings"
);
const
uiconfig
=
system
.
getUiConfig2
(
settings
.
appKey
);
module
.
exports
=
(
db
,
DataTypes
)
=>
{
return
db
.
define
(
"order
O
fficial"
,
{
return
db
.
define
(
"order
o
fficial"
,
{
sourceNo
:
DataTypes
.
STRING
(
128
),
// 订单号
channelUserId
:
DataTypes
.
STRING
(
128
),
// 用户id
officialInfo
:
DataTypes
.
JSON
// 官文信息
...
...
center-order/app/base/service/impl/dbcorder/orderdeliverSve.js
View file @
b1ca2084
const
system
=
require
(
"../../../system"
);
const
settings
=
require
(
"../../../../config/settings"
);
const
uiconfig
=
system
.
getUiConfig2
(
settings
.
appKey
);
const
ServiceBase
=
require
(
"../../sve.base"
);
const
uuidv4
=
require
(
'uuid/v4'
);
class
OrderInfoService
extends
ServiceBase
{
constructor
()
{
...
...
@@ -11,7 +9,7 @@ class OrderInfoService extends ServiceBase {
this
.
orderproductDao
=
system
.
getObject
(
"db.dbcorder.orderproductDao"
);
this
.
ordercontactsDao
=
system
.
getObject
(
"db.dbcorder.ordercontactsDao"
);
this
.
orderReceiptVoucherDao
=
system
.
getObject
(
"db.dbcpay.orderreceiptvoucherDao"
);
this
.
officialDao
=
system
.
getObject
(
"db.dbcorder.order
delivery
officialDao"
);
this
.
officialDao
=
system
.
getObject
(
"db.dbcorder.orderofficialDao"
);
this
.
centerChannelUrl
=
settings
.
centerChannelUrl
();
}
...
...
@@ -180,23 +178,12 @@ class OrderInfoService extends ServiceBase {
const
applyUser
=
actionBody
.
deliveryData
.
applyUser
;
//复审证据材料
const
askForData
=
actionBody
.
deliveryData
.
askForData
;
//商标驳回信息
const
trademarkRejInfo
=
actionBody
.
deliveryData
.
trademarkRejInfo
;
//补充材料
const
supData
=
actionBody
.
deliveryData
.
supData
;
//申请信息校验
let
re1
=
await
this
.
checkApply
(
apply
);
if
(
re1
.
status
!=
0
)
{
return
re1
;
}
//商标驳回信息校验
let
re2
=
await
this
.
checkRejInfo
(
trademarkRejInfo
);
if
(
re2
.
status
!=
0
)
{
return
re2
;
}
if
(
Object
.
keys
(
applyUser
).
length
===
0
||
Object
.
keys
(
askForData
).
length
===
0
)
{
var
deliveryStatusName
=
"待完善材料"
;
var
recDate
=
""
;
...
...
@@ -206,7 +193,6 @@ class OrderInfoService extends ServiceBase {
var
recDate
=
deliveryData
.
reDate
||
""
;
var
askforDate
=
deliveryData
.
askforDate
||
""
;
}
pobj
.
actionBody
.
deliveryData
.
deliveryStatusName
=
deliveryStatusName
;
pobj
.
actionBody
.
deliveryData
.
reDate
=
recDate
;
pobj
.
actionBody
.
deliveryData
.
askforDate
=
askforDate
;
...
...
@@ -221,9 +207,15 @@ class OrderInfoService extends ServiceBase {
* @param orderNo
*/
addOrderDelivery
(
data
,
orderNo
)
{
var
sql
=
"INSERT INTO `c_order_delivery` (`sourceOrderNo`,`deliveryContent`) VALUE('"
+
orderNo
+
"','"
+
JSON
.
stringify
(
data
)
+
"')"
;
this
.
customQuery
(
sql
);
try
{
var
sql
=
"INSERT INTO `c_order_delivery` (`sourceOrderNo`,`deliveryContent`) VALUE('"
+
orderNo
+
"','"
+
JSON
.
stringify
(
data
)
+
"')"
;
this
.
customQuery
(
sql
);
return
system
.
getResultSuccess
();
}
catch
(
e
)
{
return
system
.
getResultFail
();
}
}
/**
...
...
@@ -233,16 +225,20 @@ class OrderInfoService extends ServiceBase {
* @returns {Promise<{msg: *, data: (*|null), status: number}>}
*/
async
submitReview
(
pobj
,
actionBody
)
{
var
packagingTmResult
=
await
this
.
packagingTmReDeliveryData
(
pobj
,
pobj
.
actionBody
);
if
(
packagingTmResult
.
status
!=
0
)
{
return
packagingTmResult
;
try
{
var
packagingTmResult
=
await
this
.
packagingTmReDeliveryData
(
pobj
,
pobj
.
actionBody
);
if
(
packagingTmResult
.
status
!=
0
)
{
return
packagingTmResult
;
}
const
orderNo
=
actionBody
.
orderNo
;
const
deliveryData
=
JSON
.
stringify
(
pobj
.
actionBody
.
deliveryData
);
let
sql
=
`UPDATE c_order_delivery SET deliveryContent ='
${
deliveryData
}
' where sourceOrderNo='
${
orderNo
}
'`
;
sql
=
sql
.
replace
(
'
\
n'
,
''
);
const
result
=
await
this
.
customUpdate
(
sql
);
return
system
.
getResultSuccess
();
}
catch
(
e
)
{
return
system
.
getResultFail
();
}
const
orderNo
=
actionBody
.
orderNo
;
const
deliveryData
=
JSON
.
stringify
(
pobj
.
actionBody
.
deliveryData
);
let
sql
=
`UPDATE c_order_delivery SET deliveryContent ='
${
deliveryData
}
' where sourceOrderNo='
${
orderNo
}
'`
;
sql
=
sql
.
replace
(
'
\
n'
,
''
);
const
result
=
await
this
.
customUpdate
(
sql
);
return
system
.
getResultSuccess
();
}
//申请信息校验
...
...
@@ -271,29 +267,6 @@ class OrderInfoService extends ServiceBase {
return
system
.
getResultSuccess
();
}
//复审证据材料校验
async
checkRejInfo
(
trademarkRejInfo
)
{
if
(
!
trademarkRejInfo
.
noticeDate
){
return
system
.
getResult
(
null
,
'收到通知书日期不能为空'
);
}
if
(
!
trademarkRejInfo
.
noticeMode
){
return
system
.
getResult
(
null
,
'通知的方式不能为空'
);
}
if
(
!
[
"电子版"
,
"纸质版"
].
includes
(
trademarkRejInfo
.
noticeMode
)){
return
system
.
getResult
(
null
,
'通知书的类型错误'
)
}
if
(
!
trademarkRejInfo
.
zhichanNumber
){
return
system
.
getResult
(
null
,
'知识产权局发文号不能为空'
);
}
if
(
!
trademarkRejInfo
.
rejNotice
){
return
system
.
getResult
(
null
,
'商标驳回通知书不能为空'
);
}
if
(
!
trademarkRejInfo
.
quotedTrademark
){
return
system
.
getResult
(
null
,
'引证商标不能为空'
);
}
return
system
.
getResultSuccess
()
}
/**
* 商标驳回复审列表 + 模糊查询
* @param pobj
...
...
@@ -325,7 +298,7 @@ class OrderInfoService extends ServiceBase {
}
if
(
actionBody
.
applicantName
){
sql
+=
` and json_extract(deliveryContent,'$.applyUser.applicantName') like '%
${
actionBody
.
applicantName
}
%'`
;
sqlCount
+=
` and json_extract(deliveryContent,'$.applyUser.applicantName') like '%
${
actionBody
.
applicantName
}
'%
`
;
sqlCount
+=
` and json_extract(deliveryContent,'$.applyUser.applicantName') like '%
${
actionBody
.
applicantName
}
%'
`
;
}
if
(
actionBody
.
status
){
sql
+=
` and json_extract(deliveryContent,'$.deliveryStatusName')='
${
actionBody
.
status
}
'`
;
...
...
@@ -421,21 +394,26 @@ class OrderInfoService extends ServiceBase {
if
(
!
actionBody
.
orderNo
){
return
system
.
getResult
(
null
,
'orderNo can not be empty'
);
}
let
orderSql
=
`select channelUserId from c_order_info where orderNo = '
${
actionBody
.
orderNo
}
'`
;
let
list
=
await
this
.
customQuery
(
orderSql
);
if
(
!
list
||
list
.
length
==
0
)
{
return
system
.
getResult
(
null
,
"订单数据为空,30200"
);
}
let
orderItem
=
list
[
0
];
let
officialData
=
{
serviceNo
:
actionBody
.
orderNo
,
channelUserId
:
orderItem
.
channelUserId
,
officialInfo
:
JSON
.
parse
(
actionBody
.
officialData
),
created_at
:
new
Date
(),
updated_at
:
new
Date
()
try
{
let
orderSql
=
`select channelUserId from c_order_info where orderNo = '
${
actionBody
.
orderNo
}
'`
;
let
list
=
await
this
.
customQuery
(
orderSql
);
if
(
!
list
||
list
.
length
==
0
)
{
return
system
.
getResult
(
null
,
"订单数据为空,30200"
);
}
let
orderItem
=
list
[
0
];
let
data
=
{
serviceNo
:
actionBody
.
orderNo
,
channelUserId
:
orderItem
.
channelUserId
,
officialInfo
:
actionBody
.
officialData
,
created_at
:
new
Date
(),
updated_at
:
new
Date
()
}
await
this
.
officialDao
.
create
(
data
);
return
system
.
getResultSuccess
();
}
catch
(
e
)
{
return
system
.
getResultFail
();
}
await
this
.
officialDao
.
create
(
officialData
,
""
);
}
}
...
...
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