...
|
...
|
@@ -71,9 +71,10 @@ exports.orderEnsure = (req, res, next) => { |
|
|
];
|
|
|
|
|
|
/* tar note 170426 品众去除 */
|
|
|
// if (_.isUndefined(req.cookies._isNewUser)) {
|
|
|
// allPromise.push(orderModel.isNewUser(uid));
|
|
|
// }
|
|
|
/* tar note 170601 品众代码恢复 */
|
|
|
if (_.isUndefined(req.cookies._isNewUser)) {
|
|
|
allPromise.push(orderModel.isNewUser(uid));
|
|
|
}
|
|
|
|
|
|
return Promise.all(allPromise).then(result => {
|
|
|
let order = result[0];
|
...
|
...
|
@@ -81,15 +82,16 @@ exports.orderEnsure = (req, res, next) => { |
|
|
let address = result[2];
|
|
|
|
|
|
/* tar note 170426 品众去除 */
|
|
|
// let isNewUser = result[3];
|
|
|
|
|
|
// if (!_.isUndefined(isNewUser)) {
|
|
|
// if (isNewUser) {
|
|
|
// res.cookie('_isNewUser', true, actCkOpthn);
|
|
|
// } else {
|
|
|
// res.cookie('_isNewUser', false, actCkOpthn);
|
|
|
// }
|
|
|
// }
|
|
|
/* tar note 170601 品众代码恢复 */
|
|
|
let isNewUser = result[3];
|
|
|
|
|
|
if (!_.isUndefined(isNewUser)) {
|
|
|
if (isNewUser) {
|
|
|
res.cookie('_isNewUser', true, actCkOpthn);
|
|
|
} else {
|
|
|
res.cookie('_isNewUser', false, actCkOpthn);
|
|
|
}
|
|
|
}
|
|
|
|
|
|
if (order.cartUrl) {
|
|
|
logger.info(`orderEnsure: order cartUrl has value:${order.cartUrl}, order data is null`);
|
...
|
...
|
|