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
63f083cb
Commit
63f083cb
authored
May 19, 2020
by
宋毅
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tj
parent
5355c4a2
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
175 additions
and
168 deletions
+175
-168
fqboss/app/base/db/models/trademark.js
+3
-2
fqboss/app/base/service/impl/orderSve.js
+40
-51
fqboss/app/base/service/impl/trademarkSve.js
+85
-71
fqboss/app/config/localsettings.js
+45
-44
fqboss/app/config/routes/web.js
+2
-0
No files found.
fqboss/app/base/db/models/trademark.js
View file @
63f083cb
...
...
@@ -116,8 +116,9 @@ module.exports = (db, DataTypes) => {
businessId
:
DataTypes
.
STRING
(
50
),
//业务ID
channelOrderListInfo
:
DataTypes
.
STRING
(
500
),
//渠道服务单号对应的订单列表信息
channelPric
:
DataTypes
.
DECIMAL
(
12
,
2
),
//渠道商标单个大类的价格
nclCount
:
DataTypes
.
INTEGER
,
nclPublicExpense
:
DataTypes
.
DECIMAL
(
12
,
2
),
nclCount
:
DataTypes
.
INTEGER
,
nclPublicExpense
:
DataTypes
.
DECIMAL
(
12
,
2
),
principal
:
DataTypes
.
STRING
(
100
),
//提报主体
},
{
paranoid
:
true
,
//假的删除
underscored
:
true
,
...
...
fqboss/app/base/service/impl/orderSve.js
View file @
63f083cb
...
...
@@ -1053,7 +1053,7 @@ class OrderService extends ServiceBase {
"needId"
:
tm
.
needId
||
""
,
"channelOrderListInfo"
:
nclone
.
channelOrderListInfo
||
tm
.
channelOrderListInfo
||
""
,
"nclCount"
:
nclthreeobjCount
,
"principal"
:
apply
.
principal
||
""
,
};
var
trademark
=
await
self
.
trademarkDao
.
create
(
tmobj
,
t
);
}
...
...
@@ -1512,8 +1512,19 @@ class OrderService extends ServiceBase {
var
channelorder
=
obj
.
channelorder
;
var
self
=
this
;
var
tm
=
obj
.
tm
;
var
apply
=
obj
.
apply
;
tm
[
"tmSourceType"
]
=
"16"
;
if
(
obj
.
channelCode
==
"ali_zcsubmit"
)
{
if
(
!
apply
.
principal
)
{
result
.
code
=
"-95"
;
result
.
msg
=
"提报主体不能为空"
;
return
result
;
}
if
([
"知域互联科技有限公司"
,
"阿里巴巴科技(北京)有限公司"
].
indexOf
(
apply
.
principal
)
<
0
)
{
result
.
code
=
"-97"
;
result
.
msg
=
"提报主体不正确,请选择正确的提报主体"
;
return
result
;
}
tm
[
"tmSourceType"
]
=
"32"
;
if
(
!
obj
.
needId
)
{
result
.
code
=
"-100"
;
...
...
@@ -1522,24 +1533,7 @@ class OrderService extends ServiceBase {
}
tm
[
"needId"
]
=
obj
.
needId
;
}
// else if (obj.channelCode == "1688") {
// tm["tmSourceType"] = "64";
// if (!obj.needId) {
// result.code = "-110";
// result.msg = "1688需求ID不能为空";
// return result;
// }
// tm["needId"] = obj.needId;
// }else if (obj.channelCode == "jd") {
// tm["tmSourceType"] = "128";
// if (!obj.needId) {
// result.code = "-110";
// result.msg = "jd需求ID不能为空";
// return result;
// }
// tm["needId"] = obj.needId;
// }
var
judgeRes
=
self
.
trademarkDao
.
judgeChannelCode
(
obj
.
channelCode
);
//判断渠道码
var
judgeRes
=
self
.
trademarkDao
.
judgeChannelCode
(
obj
.
channelCode
);
//判断其他渠道码
if
(
judgeRes
)
{
tm
[
"tmSourceType"
]
=
judgeRes
;
if
(
!
obj
.
needId
)
{
...
...
@@ -1550,7 +1544,7 @@ class OrderService extends ServiceBase {
tm
[
"needId"
]
=
obj
.
needId
;
}
tm
[
"channelOrderListInfo"
]
=
channelorder
.
order_nos
&&
channelorder
.
order_nos
.
length
>
0
?
channelorder
.
order_nos
.
join
(
','
)
:
""
;
var
apply
=
obj
.
apply
;
var
user
=
obj
.
user
;
var
app
=
obj
.
app
;
var
nclones
=
obj
.
nclones
||
null
;
...
...
@@ -1594,12 +1588,12 @@ class OrderService extends ServiceBase {
}
//获取已提交的商标信息 用作校验重复提交
var
oldtms
=
await
this
.
trademarkDao
.
model
.
findAll
({
where
:
{
channelOrderNum
:
obj
.
channelOrderNum
,
applyName
:
apply
.
applyName
,
tmName
:
tm
.
tmName
},
raw
:
true
where
:
{
channelOrderNum
:
obj
.
channelOrderNum
,
applyName
:
apply
.
applyName
,
tmName
:
tm
.
tmName
},
raw
:
true
});
var
oldNclOneCodes
=
[];
//已提交商标尼斯集合
if
(
oldtms
&&
oldtms
.
length
>
0
)
{
for
(
var
a
=
0
;
a
<
oldtms
.
length
;
a
++
)
{
if
(
oldtms
&&
oldtms
.
length
>
0
)
{
for
(
var
a
=
0
;
a
<
oldtms
.
length
;
a
++
)
{
var
oldtm
=
oldtms
[
a
];
oldNclOneCodes
.
push
(
oldtm
.
nclOneCodes
);
}
...
...
@@ -1608,12 +1602,12 @@ class OrderService extends ServiceBase {
var
selectNclThreeCount
=
0
;
for
(
let
index
=
0
;
index
<
nclones
.
length
;
index
++
)
{
const
element
=
nclones
[
index
];
if
(
element
.
code
&&
oldNclOneCodes
.
length
>
0
)
{
if
(
oldNclOneCodes
.
indexOf
(
element
.
code
)
>=
0
)
{
if
(
element
.
code
&&
oldNclOneCodes
.
length
>
0
)
{
if
(
oldNclOneCodes
.
indexOf
(
element
.
code
)
>=
0
)
{
return
{
code
:
"-260"
,
msg
:
"已存在第"
+
element
.
code
+
"类的商标,不能重复提交"
};
}
}
var
nclList
=
null
;
if
(
typeof
(
element
)
==
"string"
)
{
nclList
=
JSON
.
parse
(
element
);
...
...
@@ -1788,12 +1782,12 @@ class OrderService extends ServiceBase {
// return checkRes;
// }
// }
if
(
orderItem
.
created_at
&&
orderItem
.
orderSourceType
!=
"8"
)
{
if
(
orderItem
.
created_at
&&
orderItem
.
orderSourceType
!=
"8"
)
{
var
time
=
new
Date
(
orderItem
.
created_at
).
getTime
();
if
(
time
>
1576339199000
)
{
//2019-12-14 23:59:59
if
(
time
>
1576339199000
)
{
//2019-12-14 23:59:59
var
usable_order_no_class_count
=
channelorder
.
usable_order_no_class_count
;
//有效渠道订单列表
var
checkRes
=
await
this
.
checkChannelUsableOrder
(
usable_order_no_class_count
,
nclones
);
//校验有效订单
if
(
checkRes
.
code
!=
1
)
{
var
checkRes
=
await
this
.
checkChannelUsableOrder
(
usable_order_no_class_count
,
nclones
);
//校验有效订单
if
(
checkRes
.
code
!=
1
)
{
return
checkRes
;
}
}
...
...
@@ -1861,7 +1855,7 @@ class OrderService extends ServiceBase {
// if (orderItem.channelCode == "1688" || orderItem.channelCode == "jd") {
// tm["tmStatus"] = "WAITCONFIRM";
// }
var
judgeRes
=
self
.
trademarkDao
.
judgeChannelCode
(
orderItem
.
channelCode
);
//判断渠道码
var
judgeRes
=
self
.
trademarkDao
.
judgeChannelCode
(
orderItem
.
channelCode
);
//判断
其他
渠道码
if
(
judgeRes
)
{
tm
[
"tmStatus"
]
=
"WAITCONFIRM"
;
}
...
...
@@ -1880,6 +1874,16 @@ class OrderService extends ServiceBase {
}
tm
[
"tmSourceType"
]
=
"16"
;
if
(
orderItem
.
channelCode
==
"ali_zcsubmit"
)
{
if
(
!
apply
.
principal
)
{
result
.
code
=
"-95"
;
result
.
msg
=
"提报主体不能为空"
;
return
result
;
}
if
([
"知域互联科技有限公司"
,
"阿里巴巴科技(北京)有限公司"
].
indexOf
(
apply
.
principal
)
<
0
)
{
result
.
code
=
"-97"
;
result
.
msg
=
"提报主体不正确,请选择正确的提报主体"
;
return
result
;
}
tm
[
"tmSourceType"
]
=
"32"
;
if
(
!
channelorder
.
needId
)
{
result
.
code
=
"-150"
;
...
...
@@ -1888,23 +1892,7 @@ class OrderService extends ServiceBase {
}
tm
[
"needId"
]
=
channelorder
.
needId
;
}
// else if (orderItem.channelCode == "1688") {
// tm["tmSourceType"] = "64";
// if (!channelorder.needId) {
// result.code = "-160";
// result.msg = "1688需求ID不能为空!";
// return result;
// }
// tm["needId"] = channelorder.needId;
// }else if (orderItem.channelCode == "jd") {
// tm["tmSourceType"] = "128";
// if (!channelorder.needId) {
// result.code = "-160";
// result.msg = "jd需求ID不能为空!";
// return result;
// }
// tm["needId"] = channelorder.needId;
// }
if
(
judgeRes
)
{
tm
[
"tmSourceType"
]
=
judgeRes
;
if
(
!
channelorder
.
needId
)
{
...
...
@@ -1955,6 +1943,7 @@ class OrderService extends ServiceBase {
"businessId"
:
oldTmList
&&
oldTmList
.
length
>
0
?
oldTmList
[
0
].
businessId
:
""
,
"channelOrderListInfo"
:
nclone
.
channelOrderListInfo
||
tm
.
channelOrderListInfo
||
""
,
"nclCount"
:
nclthreeobjCount
,
"principal"
:
apply
.
principal
,
};
// console.log(tmobj);
var
trademark
=
await
self
.
trademarkDao
.
create
(
tmobj
,
t
);
...
...
@@ -1998,9 +1987,9 @@ class OrderService extends ServiceBase {
var
tms
=
await
self
.
trademarkDao
.
model
.
findAll
({
where
:
{
orderNum
:
order
.
orderNum
},
raw
:
true
});
var
tmE
=
tms
[
0
];
var
remainder
=
channelorder
.
remainder
;
if
(
tmE
&&
tmE
.
tmSourceType
&&
tmE
.
tmSourceType
==
'64'
)
{
//1688渠道不需要判断渠道订单
if
(
tmE
&&
tmE
.
tmSourceType
&&
tmE
.
tmSourceType
==
'64'
)
{
//1688渠道不需要判断渠道订单
tm
[
"channelPayStatus"
]
=
tmE
.
channelPayStatus
;
}
else
{
}
else
{
if
(
!
remainder
)
{
return
{
code
:
"-203"
,
msg
:
"渠道订单产品数量有误"
};
}
else
if
(
nclones
.
length
>
Number
(
remainder
))
{
...
...
fqboss/app/base/service/impl/trademarkSve.js
View file @
63f083cb
...
...
@@ -24,52 +24,52 @@ class TrademarkService extends ServiceBase {
this
.
execClient
=
system
.
getObject
(
"util.execClient"
);
this
.
channelreceiveDao
=
system
.
getObject
(
"db.channelreceiveDao"
);
this
.
tm_submit_status
=
{
"WAITARTIFICIALEXAMINE"
:
"等待人工审核"
,
"1"
:
"商标注册申请书"
,
"2"
:
"补证通知"
,
"3"
:
"已受理"
,
"4"
:
"不予受理"
,
"5"
:
"同日申请补送证据"
,
"6"
:
"同日申请协商"
,
"7"
:
"全部驳回"
,
"8"
:
"部分驳回"
,
"9"
:
"初步审定公告"
,
"10"
:
"商家异议"
,
"11"
:
"裁定通知"
,
"12"
:
"已下发纸质注册证"
,
"13"
:
"已下发注册证"
,
"14"
:
"同日申请抽签"
,
"15"
:
"申请审查意见"
,
"FILELIST"
:
"交文清单"
,
"ENVLOPE"
:
"信封正反面"
,
"NOTAPPROVAL"
:
"不予核准"
,
"APPROVAL"
:
"核准通知"
,
"READY"
:
"资料准备"
,
"DOCFINISH"
:
"资料齐全"
,
"AWAITCHECK"
:
"等待审核"
,
"WAITCOMMIT"
:
"待提交"
,
"COMMITED"
:
"人工已提交"
,
"ROBOT"
:
"已提交"
,
"ROBOTPAY"
:
"已提交(待校验)"
,
"RECVCOMMIT"
:
"已收提交"
,
"FILLEXCEPTION"
:
"填报异常"
,
"DISCARDED"
:
"废弃"
,
"ALICUSTOMERREJECTED"
:
"客户反馈(待修改重新同步)"
,
"REQALIERROR"
:
"阿里接口错误(需峰擎系统处理)"
,
"SUBALITM"
:
"已提交阿里(待补全信息)"
,
"SUBALITMOK"
:
"已补全信息(待确认商标)"
,
"SUBALIPAY"
:
"已提交阿里(待支付)"
,
"WAITALIREVIEW"
:
"待阿里审核(已支付)"
,
"ALIAUDITNOT"
:
"阿里云审不通过(修改可以重新推送阿里)"
,
"ALIAUDITYES"
:
"阿里审核通过"
,
"ALIPAYREFUND"
:
"已失败退款(阿里)"
,
"ALIPAPERS2"
:
"需要补正(阿里)"
,
"ALIPAPERS4"
:
"已补正(阿里)"
,
"ALIPAPERS5"
:
"超时未补正(阿里)"
,
"ALIPAPERS6"
:
"补正已递交(阿里)"
,
//1688
"WAITCONFIRM"
:
"等待客户确认"
,
"CONFIRMFAIL"
:
"方案不通过"
"WAITARTIFICIALEXAMINE"
:
"等待人工审核"
,
"1"
:
"商标注册申请书"
,
"2"
:
"补证通知"
,
"3"
:
"已受理"
,
"4"
:
"不予受理"
,
"5"
:
"同日申请补送证据"
,
"6"
:
"同日申请协商"
,
"7"
:
"全部驳回"
,
"8"
:
"部分驳回"
,
"9"
:
"初步审定公告"
,
"10"
:
"商家异议"
,
"11"
:
"裁定通知"
,
"12"
:
"已下发纸质注册证"
,
"13"
:
"已下发注册证"
,
"14"
:
"同日申请抽签"
,
"15"
:
"申请审查意见"
,
"FILELIST"
:
"交文清单"
,
"ENVLOPE"
:
"信封正反面"
,
"NOTAPPROVAL"
:
"不予核准"
,
"APPROVAL"
:
"核准通知"
,
"READY"
:
"资料准备"
,
"DOCFINISH"
:
"资料齐全"
,
"AWAITCHECK"
:
"等待审核"
,
"WAITCOMMIT"
:
"待提交"
,
"COMMITED"
:
"人工已提交"
,
"ROBOT"
:
"已提交"
,
"ROBOTPAY"
:
"已提交(待校验)"
,
"RECVCOMMIT"
:
"已收提交"
,
"FILLEXCEPTION"
:
"填报异常"
,
"DISCARDED"
:
"废弃"
,
"ALICUSTOMERREJECTED"
:
"客户反馈(待修改重新同步)"
,
"REQALIERROR"
:
"阿里接口错误(需峰擎系统处理)"
,
"SUBALITM"
:
"已提交阿里(待补全信息)"
,
"SUBALITMOK"
:
"已补全信息(待确认商标)"
,
"SUBALIPAY"
:
"已提交阿里(待支付)"
,
"WAITALIREVIEW"
:
"待阿里审核(已支付)"
,
"ALIAUDITNOT"
:
"阿里云审不通过(修改可以重新推送阿里)"
,
"ALIAUDITYES"
:
"阿里审核通过"
,
"ALIPAYREFUND"
:
"已失败退款(阿里)"
,
"ALIPAPERS2"
:
"需要补正(阿里)"
,
"ALIPAPERS4"
:
"已补正(阿里)"
,
"ALIPAPERS5"
:
"超时未补正(阿里)"
,
"ALIPAPERS6"
:
"补正已递交(阿里)"
,
//1688
"WAITCONFIRM"
:
"等待客户确认"
,
"CONFIRMFAIL"
:
"方案不通过"
};
}
...
...
@@ -523,18 +523,18 @@ class TrademarkService extends ServiceBase {
}
else
{
pushObj
[
"opNotes"
]
=
"已提交"
;
}
if
(
tm
.
tmSourceType
==
"1024"
)
{
//center-channel
if
(
tm
.
tmSourceType
==
"1024"
)
{
//center-channel
var
channelPushObj
=
{
orderNo
:
tm
.
channelOrderNum
,
orderNo
:
tm
.
channelOrderNum
,
tbCode
:
keyCode
,
tmStatus
:
param
.
tmStatus
,
tmStatusName
:
this
.
tm_submit_status
[
param
.
tmStatus
]
tmStatusName
:
this
.
tm_submit_status
[
param
.
tmStatus
]
}
if
(
param
.
submitTime
)
{
channelPushObj
[
"submitTime"
]
=
param
.
submitTime
;
}
self
.
channelreceiveDao
.
updateChannelTmStatus
(
channelPushObj
);
}
else
{
}
else
{
self
.
updateChannelTmStatus
(
pushObj
);
}
// self.updateChannelTmStatus(pushObj);
...
...
@@ -618,22 +618,22 @@ class TrademarkService extends ServiceBase {
channelOrderNum
:
tm
.
channelOrderNum
,
tmRegistNum
:
code
}
if
(
tm
.
tmSourceType
==
"1024"
)
{
//center-channel
if
(
tm
.
tmSourceType
==
"1024"
)
{
//center-channel
var
channelPushObj
=
{
orderNo
:
tm
.
channelOrderNum
,
orderNo
:
tm
.
channelOrderNum
,
tbCode
:
proxyCode
,
tmStatus
:
stateCode
,
tmStatusName
:
this
.
tm_submit_status
[
stateCode
],
registNumInfo
:{
tmStatusName
:
this
.
tm_submit_status
[
stateCode
],
registNumInfo
:
{
tmRegistNum
:
code
,
//商标申请号
}
}
self
.
channelreceiveDao
.
updateChannelTmStatus
(
channelPushObj
);
// self.channelreceiveDao.updateChannelTmStatus(pushObj);
}
else
{
}
else
{
self
.
updateChannelTmStatus
(
pushObj
);
}
}
}
// if(tm && tm.id && tm.tmSourceType == "64"){
...
...
@@ -848,7 +848,7 @@ class TrademarkService extends ServiceBase {
"proxyCode"
,
"tmRegistNum"
,
"creatAuthorizeStuff"
,
"sealAuthorizeStuff"
,
"voiceUrl"
,
"tmStatus"
,
"user_id"
,
"colorizedPicUrl"
,
"descUrl"
,
"partnerMobile"
,
"userName"
,
"applyName"
,
"parentProxyCode"
,
"parentTmRegistNum"
,
"newProxyCode"
,
"newTmRegistNum"
,
"remarkInfo"
,
"opRemarkInfo"
,
"channelOrderNum"
,
"app_code"
,
"tmSourceType"
,
"channelUserId"
,
"mobile"
,
"channelPayStatus"
,
"businessId"
,
"needId"
,
"channelOrderListInfo"
];
"channelUserId"
,
"mobile"
,
"channelPayStatus"
,
"businessId"
,
"needId"
,
"channelOrderListInfo"
,
"principal"
];
var
sqlWhere
=
null
;
if
(
id
)
{
sqlWhere
=
{
where
:
{
id
:
id
},
attributes
:
paramAttributes
,
raw
:
true
};
...
...
@@ -864,7 +864,7 @@ class TrademarkService extends ServiceBase {
"proxyCode"
,
"tmRegistNum"
,
"creatAuthorizeStuff"
,
"sealAuthorizeStuff"
,
"voiceUrl"
,
"tmStatus"
,
"user_id"
,
"colorizedPicUrl"
,
"descUrl"
,
"partnerMobile"
,
"userName"
,
"applyName"
,
"parentProxyCode"
,
"parentTmRegistNum"
,
"newProxyCode"
,
"newTmRegistNum"
,
"remarkInfo"
,
"opRemarkInfo"
,
"channelOrderNum"
,
"app_code"
,
"tmSourceType"
,
"channelUserId"
,
"mobile"
,
"channelPayStatus"
,
"businessId"
,
"needId"
,
"channelOrderListInfo"
];
"channelUserId"
,
"mobile"
,
"channelPayStatus"
,
"businessId"
,
"needId"
,
"channelOrderListInfo"
,
"principal"
];
var
sqlWhere
=
{
where
:
{
id
:
{
[
this
.
db
.
Op
.
in
]:
ids
}
},
paramAttributes
,
raw
:
true
};
return
await
this
.
dao
.
model
.
findAll
(
sqlWhere
);
}
...
...
@@ -879,7 +879,7 @@ class TrademarkService extends ServiceBase {
"proxyCode"
,
"tmRegistNum"
,
"creatAuthorizeStuff"
,
"sealAuthorizeStuff"
,
"voiceUrl"
,
"tmStatus"
,
"user_id"
,
"colorizedPicUrl"
,
"descUrl"
,
"partnerMobile"
,
"userName"
,
"applyName"
,
"parentProxyCode"
,
"parentTmRegistNum"
,
"newProxyCode"
,
"newTmRegistNum"
,
"remarkInfo"
,
"opRemarkInfo"
,
"channelOrderNum"
,
"app_code"
,
"tmSourceType"
,
"channelUserId"
,
"mobile"
,
"channelPayStatus"
,
"businessId"
,
"needId"
,
"channelOrderListInfo"
];
"channelUserId"
,
"mobile"
,
"channelPayStatus"
,
"businessId"
,
"needId"
,
"channelOrderListInfo"
,
"principal"
];
if
(
type
==
"1"
)
{
return
this
.
dao
.
model
.
findAll
({
where
:
{
channelOrderNum
:
channelOrderNum
},
paramAttributes
,
raw
:
true
});
}
...
...
@@ -1130,6 +1130,17 @@ class TrademarkService extends ServiceBase {
}
}
}
var
principalName
=
1
;
var
tmNameType
=
1
;
//1:⽂字 2:图⽚ 3:图⽂
if
(
element
.
principal
&&
element
.
principal
==
"知域互联科技有限公司"
)
{
principalName
=
2
;
}
if
(
element
.
tmFormType
==
"4"
)
{
tmNameType
=
2
;
}
else
if
(
element
.
tmFormType
==
"5"
)
{
tmNameType
=
3
;
}
var
subParam
=
{
BizId
:
item
.
businessId
||
""
,
IntentionBizId
:
item
.
needId
,
...
...
@@ -1141,6 +1152,8 @@ class TrademarkService extends ServiceBase {
TmComment
:
item
.
tmName
,
//商标说明
serviceOrderNo
:
item
.
channelOrderNum
,
reqOnlyCode
:
item
.
reqOnlyCode
,
PrincipalName
:
principalName
,
TmNameType
:
tmNameType
,
};
var
submitTm
=
await
rc
.
post
(
"SaveTradeMarkProductSolution"
,
subParam
);
//返回值
...
...
@@ -1156,7 +1169,7 @@ class TrademarkService extends ServiceBase {
if
(
submitTm
.
Code
==
"200"
)
{
// "SUBALITM": "已提交阿里(待补全信息)",
await
this
.
dao
.
updateByWhere
({
businessId
:
submitTm
.
data
.
BizId
,
tmStatus
:
"SUBALITM"
,
channelPric
:
submitTm
.
OrderPrice
||
0
},
{
where
:
{
id
:
item
.
id
}
});
var
tmApplyInfo
=
await
this
.
opAliTmApplyInfo
(
submitTm
,
item
,
applier
,
customer
,
rc
);
var
tmApplyInfo
=
await
this
.
opAliTmApplyInfo
(
submitTm
,
item
,
applier
,
customer
,
rc
,
principalName
);
if
(
tmApplyInfo
.
Code
==
"200"
)
{
// "SUBALITMOK": "已补全信息(待确认商标)",
await
this
.
dao
.
updateByWhere
({
tmStatus
:
"SUBALITMOK"
},
{
where
:
{
id
:
item
.
id
}
});
...
...
@@ -1170,7 +1183,7 @@ class TrademarkService extends ServiceBase {
if
(
item
.
businessId
&&
submitTm
.
errorCode
==
"TRADEMARK.PRODUCT.DUPLICATE"
)
{
submitTm
.
data
[
"BizId"
]
=
item
.
businessId
;
if
(
item
.
tmStatus
==
"SUBALITM"
)
{
var
tmApplyInfo
=
await
this
.
opAliTmApplyInfo
(
submitTm
,
item
,
applier
,
customer
,
rc
);
var
tmApplyInfo
=
await
this
.
opAliTmApplyInfo
(
submitTm
,
item
,
applier
,
customer
,
rc
,
principalName
);
if
(
tmApplyInfo
.
Code
==
"200"
)
{
// "SUBALITMOK": "已补全信息(待确认商标)",
await
this
.
dao
.
updateByWhere
({
tmStatus
:
"SUBALITMOK"
},
{
where
:
{
id
:
item
.
id
}
});
...
...
@@ -1213,7 +1226,7 @@ class TrademarkService extends ServiceBase {
await
this
.
dao
.
updateByWhere
({
opRemarkInfo
:
"阿里返回:errorCode="
+
returnResult
.
errorCode
+
"errorMsg="
+
returnResult
.
errorMsg
},
{
where
:
{
id
:
item
.
id
}
});
}
}
async
opAliTmApplyInfo
(
submitTm
,
item
,
applier
,
customer
,
rc
)
{
//阿里补全注册⽅案-申请⼈信息---本类用
async
opAliTmApplyInfo
(
submitTm
,
item
,
applier
,
customer
,
rc
,
principalName
)
{
//阿里补全注册⽅案-申请⼈信息---本类用
var
bizIDList
=
[
submitTm
.
data
.
BizId
];
var
reqParam
=
{
BizIds
:
JSON
.
stringify
(
bizIDList
),
...
...
@@ -1238,6 +1251,7 @@ class TrademarkService extends ServiceBase {
PassportOssKey
:
""
,
LegalNoticeOssKey
:
item
.
descUrl
||
""
,
//法律声明
serviceOrderNo
:
item
.
channelOrderNum
,
PrincipalName
:
principalName
,
};
var
tmDetailResult
=
await
rc
.
post
(
"SaveTradeMarkMaterialDetail"
,
reqParam
);
this
.
opSaveLog
(
"请求阿里补全商标接信息接口返回错误----error"
,
reqParam
,
item
,
tmDetailResult
);
...
...
@@ -1444,18 +1458,18 @@ class TrademarkService extends ServiceBase {
try
{
var
reqParam
=
{};
reqParam
=
{
"appkey"
:
"201911131657"
,
"secret"
:
"eeb18393aade40149287b024d8ba0850"
"appkey"
:
"201911131657"
,
"secret"
:
"eeb18393aade40149287b024d8ba0850"
};
if
(
channelCode
==
"jd"
)
{
if
(
channelCode
==
"jd"
)
{
reqParam
=
{
"appkey"
:
"201911251551"
,
"secret"
:
"56006077354d48858026c80c0e10bef6"
"appkey"
:
"201911251551"
,
"secret"
:
"56006077354d48858026c80c0e10bef6"
};
}
var
rtn
=
await
this
.
execClient
.
execPost
(
reqParam
,
reqTokenUrl
);
if
(
!
rtn
.
stdout
)
{
return
{
status
:
-
1
,
msg
:
"获取token失败"
};
return
{
status
:
-
1
,
msg
:
"获取token失败"
};
}
var
tokenResult
=
JSON
.
parse
(
rtn
.
stdout
);
if
(
tokenResult
.
status
==
0
)
{
...
...
@@ -1464,15 +1478,15 @@ class TrademarkService extends ServiceBase {
return
tokenResult
;
}
catch
(
e
)
{
await
this
.
oplogSve
.
createDb
({
logLevel
:
"error"
,
logLevel
:
"error"
,
optitle
:
"获取token---异常"
,
op
:
reqTokenUrl
,
content
:
JSON
.
stringify
(
e
.
stack
),
clientIp
:
""
});
return
{
status
:
-
1
,
msg
:
"获取token失败"
};
return
{
status
:
-
1
,
msg
:
"获取token失败"
};
}
}
//推送渠道商标状态修改信息
async
updateChannelTmStatus
(
obj
)
{
...
...
fqboss/app/config/localsettings.js
View file @
63f083cb
var
settings
=
{
redis
:{
var
settings
=
{
redis
:
{
host
:
"43.247.184.32"
,
port
:
8967
,
password
:
"Gongsibao2018"
,
db
:
11
,
db
:
11
,
},
database
:{
dbname
:
"fqboss"
,
database
:
{
dbname
:
"fqboss"
,
user
:
"write"
,
password
:
"write"
,
// user: "root",
...
...
@@ -17,43 +17,43 @@ var settings={
// port: 3306,
port
:
8899
,
dialect
:
'mysql'
,
operatorsAliases
:
false
,
pool
:
{
max
:
5
,
min
:
0
,
acquire
:
90000000
,
idle
:
1000000
},
debug
:
false
,
dialectOptions
:
{
requestTimeout
:
999999
,
// instanceName:'DEV'
}
//设置MSSQL超时时间
}
},
// database:{
// dbname : "fqboss",
// user: "write",
// password: "write",
// config: {
// host: '43.247.184.35',
// port: 8899,
// dialect: 'mysql',
// operatorsAliases: false,
// pool: {
// max: 5,
// min: 0,
// acquire: 90000000,
// idle: 1000000
// },
// debug:false,
// dialectOptions:{
// requestTimeout: 999999,
// // instanceName:'DEV'
// } //设置MSSQL超时时间
// }
// },
reqEsDevUrl
:
"http://43.247.184.94:7200/"
,
reqHomePageDevUrl
:
"http://192.168.18.232:3000/"
operatorsAliases
:
false
,
pool
:
{
max
:
5
,
min
:
0
,
acquire
:
90000000
,
idle
:
1000000
},
debug
:
false
,
dialectOptions
:
{
requestTimeout
:
999999
,
// instanceName:'DEV'
}
//设置MSSQL超时时间
}
},
// database:{
// dbname : "fqboss",
// user: "write",
// password: "write",
// config: {
// host: '43.247.184.35',
// port: 8899,
// dialect: 'mysql',
// operatorsAliases: false,
// pool: {
// max: 5,
// min: 0,
// acquire: 90000000,
// idle: 1000000
// },
// debug:false,
// dialectOptions:{
// requestTimeout: 999999,
// // instanceName:'DEV'
// } //设置MSSQL超时时间
// }
// },
reqEsDevUrl
:
"http://43.247.184.94:7200/"
,
reqHomePageDevUrl
:
"http://192.168.18.232:3000/"
};
module
.
exports
=
settings
;
module
.
exports
=
settings
;
\ No newline at end of file
fqboss/app/config/routes/web.js
View file @
63f083cb
...
...
@@ -256,6 +256,8 @@ module.exports = function (app) {
req
.
url
.
indexOf
(
"userCtl/loginByMobile"
)
>
0
||
req
.
url
.
indexOf
(
"userCtl/checkUserInfo"
)
>
0
||
req
.
url
.
indexOf
(
"metaCtl/getUiConfig"
)
>
0
||
req
.
url
.
indexOf
(
"ncloneCtl/getNcl"
)
>
0
||
req
.
url
.
indexOf
(
"orderCtl/getChannelOrderByOrderNum"
)
>
0
||
(
req
.
headers
.
access_source
==
"zqq1571212637509"
&&
(
...
...
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