Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
Dui123
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
王天宇
Dui123
Commits
87891d01
Commit
87891d01
authored
Nov 04, 2021
by
wty
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更新prod4
parent
80f1570e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
14 deletions
+1
-14
query.js
server/routes/query.js
+1
-14
No files found.
server/routes/query.js
View file @
87891d01
...
@@ -39,21 +39,8 @@ getMysql.then(Mysql => {
...
@@ -39,21 +39,8 @@ getMysql.then(Mysql => {
router
.
get
(
'/queryToolBox'
,
(
req
,
res
)
=>
{
router
.
get
(
'/queryToolBox'
,
(
req
,
res
)
=>
{
let
{
isFollow
,
type_id
}
=
req
.
query
let
SQL
=
`SELECT toolbox.*, type_childtype_toolbox.child_type_id, type_childtype_toolbox.type_id FROM type_childtype_toolbox INNER JOIN toolbox ON type_childtype_toolbox.toolbox_id = toolbox.toolbox_id`
let
SQL
=
`SELECT toolbox.*, type_childtype_toolbox.child_type_id, type_childtype_toolbox.type_id FROM type_childtype_toolbox INNER JOIN toolbox ON type_childtype_toolbox.toolbox_id = toolbox.toolbox_id`
Mysql
.
query
(
SQL
,
[],
(
err
,
result
)
=>
{
if
(
isFollow
)
{
// type_id = JSON.parse(type_id)
if
(
Array
.
isArray
(
type_id
)
&&
!
type_id
.
length
){
res
.
send
({
success
:
true
,
data
:
[]
})
}
SQL
=
'SELECT * FROM toolbox WHERE toolbox_id IN (?)'
}
Mysql
.
query
(
SQL
,
[
type_id
],
(
err
,
result
)
=>
{
if
(
err
)
{
if
(
err
)
{
res
.
send
({
res
.
send
({
success
:
false
,
success
:
false
,
...
...
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