@@ -20,15 +20,15 @@ async function articleList(req, res, next) {
20
20
}
21
21
if ( req . query . justOriginal == 'true' ) {
22
22
let term = 'articleNature = 0'
23
- whereSql = whereSql ? whereSql + `AND ${ term } ` : `WHERE ${ term } `
23
+ whereSql = whereSql ? whereSql + `AND ${ term } ` : `WHERE ${ term } `
24
24
}
25
25
if ( req . query . dateTime ) {
26
26
let term = `DATE_FORMAT(articleCreateTime, '%Y-%m') = '${ req . query . dateTime } '`
27
- whereSql = whereSql ? whereSql + `AND ${ term } ` : `WHERE ${ term } `
27
+ whereSql = whereSql ? whereSql + `AND ${ term } ` : `WHERE ${ term } `
28
28
}
29
29
if ( req . query . columnId ) {
30
30
let term = `articleColumn = ${ req . query . columnId } `
31
- whereSql = whereSql ? whereSql + `AND ${ term } ` : `WHERE ${ term } `
31
+ whereSql = whereSql ? whereSql + `AND ${ term } ` : `WHERE ${ term } `
32
32
}
33
33
if ( req . query . author ) {
34
34
let articleAuthorId = req . query . author
@@ -37,7 +37,7 @@ async function articleList(req, res, next) {
37
37
articleAuthorId = authorInfo [ 0 ] . authorId
38
38
}
39
39
let term = `articleAuthorId = '${ articleAuthorId } '`
40
- whereSql = whereSql ? whereSql + `AND ${ term } ` : `WHERE ${ term } `
40
+ whereSql = whereSql ? whereSql + `AND ${ term } ` : `WHERE ${ term } `
41
41
}
42
42
totalSql = `SELECT * FROM vue_blog ${ whereSql } `
43
43
selectSql = `SELECT ${ selectTableHead } FROM vue_blog ${ whereSql } ${ orderSql } `
0 commit comments