...
|
...
|
@@ -26,7 +26,7 @@ const component = { |
|
|
const id = req.params[0];
|
|
|
|
|
|
let params = {
|
|
|
uid: req.user.uid || 8050378,
|
|
|
uid: req.user.uid || 0,
|
|
|
article_id: id,
|
|
|
client_type: 'h5'
|
|
|
};
|
...
|
...
|
@@ -66,10 +66,9 @@ const component = { |
|
|
favorite(req, res, next) {
|
|
|
const params = {
|
|
|
article_id: req.params[0],
|
|
|
uid: req.user.uid || 8050378
|
|
|
uid: req.user.uid || 0
|
|
|
};
|
|
|
|
|
|
/*
|
|
|
if (!req.user.id) {
|
|
|
res.json({
|
|
|
code: 403
|
...
|
...
|
@@ -77,7 +76,7 @@ const component = { |
|
|
|
|
|
return;
|
|
|
}
|
|
|
*/
|
|
|
|
|
|
model.favorite(params, 'true' === req.query.flag).then(result => {
|
|
|
res.json(result);
|
|
|
}).catch(next);
|
...
|
...
|
@@ -93,7 +92,7 @@ const component = { |
|
|
misc(req, res, next) {
|
|
|
const params = {
|
|
|
article_id: req.params[0],
|
|
|
uid: req.user.uid || 8050378,
|
|
|
uid: req.user.uid || 0,
|
|
|
udid: req.sessionID
|
|
|
};
|
|
|
|
...
|
...
|
|