fix 分享图列表获取bug

This commit is contained in:
yulixing 2019-07-03 14:46:22 +08:00
parent be3bad311c
commit 60e34cd9ec

View File

@ -79,7 +79,7 @@ router.post('/list', async (req, res, next) => {
if (shareType) { if (shareType) {
opt.share_type = shareType opt.share_type = shareType
} }
if (type !== '') { if (type || type === 0) {
opt.type = type opt.type = type
} }
let records let records
@ -90,7 +90,6 @@ router.post('/list', async (req, res, next) => {
} else { } else {
records = await GameShareImageModel.find(opt) records = await GameShareImageModel.find(opt)
} }
const total = await GameShareImageModel.find(opt).countDocuments() const total = await GameShareImageModel.find(opt).countDocuments()
const systemDics = await SystemDic.find({ const systemDics = await SystemDic.find({
deleted: false, deleted: false,