Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
O
open-api
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
刘松
open-api
Commits
a7a6d6d1
Commit
a7a6d6d1
authored
Mar 26, 2019
by
yaobeibei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix auto input
parent
2d9d1c5d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
6 deletions
+12
-6
calltask.js
controllers/calltask.js
+4
-0
clue.js
controllers/clue.js
+4
-2
order.js
db/mongo/open/order.js
+4
-4
No files found.
controllers/calltask.js
View file @
a7a6d6d1
...
...
@@ -182,6 +182,8 @@ exports.list = async (ctx, next) => {
let
{
skip
=
0
,
limit
=
10
,
clue
,
callback_data
,
caller
,
start
,
bindID
,
...
...
@@ -208,6 +210,8 @@ exports.list = async (ctx, next) => {
let
conditions
=
tools
.
generateDateQuery
(
start
,
end
);
conditions
.
account
=
account
.
_id
;
if
(
clue
)
conditions
.
clue
=
clue
;
if
(
callback_data
)
conditions
.
callback_data
=
callback_data
;
if
(
bindID
)
{
conditions
.
bindID
=
bindID
;
}
...
...
controllers/clue.js
View file @
a7a6d6d1
...
...
@@ -144,7 +144,7 @@ exports.createAuto = async(ctx, next) => {
try
{
ctx
.
websocket
.
on
(
'message'
,
async
function
(
message
)
{
let
{
order
}
=
JSON
.
parse
(
message
);
let
{
order
,
start
,
end
}
=
JSON
.
parse
(
message
);
//let order = "5c8f3f30189f42000721d983";
if
(
!
tools
.
valid
(
order
))
{
ctx
.
websocket
.
send
(
JSON
.
stringify
({
type
:
'warning'
,
message
:
'订单ID 格式错误'
}));
...
...
@@ -219,7 +219,9 @@ exports.createAuto = async(ctx, next) => {
"provinces"
:
[],
"account"
:
user
.
_id
,
"url"
:
[
url
],
"exactMatch"
:
true
"exactMatch"
:
true
,
start
,
end
});
if
(
res
.
status
==
'ok'
)
{
...
...
db/mongo/open/order.js
View file @
a7a6d6d1
...
...
@@ -80,10 +80,10 @@ schema.pre('save', function (next) {
const
doc
=
this
;
let
date
=
moment
().
format
(
'YYYYMMDD'
);
let
map
=
{
'data'
:
'D'
,
'msg'
:
'M'
,
'record'
:
'R'
,
'imei'
:
'I'
'data'
:
'
O
D'
,
'msg'
:
'
O
M'
,
'record'
:
'
O
R'
,
'imei'
:
'
O
I'
}
let
suffix
=
((
map
[
doc
.
type
]
||
'U'
)
+
date
);
if
(
!
doc
.
isNew
)
next
();
...
...
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