Authored by yyq

Merge branch 'release/1.0' of git.yoho.cn:fe/yoho-blk into release/1.0

... ... @@ -50,15 +50,15 @@ const index = (req, res, next) => {
}).catch(next);
};
const getAddressList = (req, res) => {
addressModel.getAddressDataAsync('7566245', 20).then(result => {
const getAddressList = (req, res, next) => {
addressModel.getAddressDataAsync(req.user.uid, 20).then(result => {
if (result.data) {
let defaultAd = _.find(result.data, o => o.is_default === 'Y');
defaultAd && (defaultAd.focus = true);
}
res.send(result);
});
}).catch(next);
};
/**
... ...
... ... @@ -211,11 +211,11 @@ const helpers = {
goodsId = goodsList[0].goodsId;
goodsList.forEach(o => {
o.url = `${config.siteUrl}/product/item/${g.productId}_${o.goodsId}.html`;
o.url = `${config.siteUrl}/product/pro_${g.productId}_${o.goodsId}/${o.cnAlphabet}.html`;
});
}
g.url = `${config.siteUrl}/product/item/${g.productId}_${goodsId}.html`;
g.url = `${config.siteUrl}/product/pro_${g.productId}_${goodsId}/${g.cnAlphabet}.html`;
});
}
return list;
... ...
... ... @@ -42,7 +42,7 @@ const index = uid => {
// format goods link
theGoods.link = helper.urlFormat(
`/product/pro_${theGoods.product_id}_${theGoods.goods_id}_${theGoods.cn_alphabet}.html`);
`/product/pro_${theGoods.product_id}_${theGoods.goods_id}/${theGoods.cn_alphabet}.html`);
theGoods.last_price = parseFloat(theGoods.last_price, 10).toFixed(2);
... ...
... ... @@ -4,6 +4,7 @@ var common = require('../../common');
var query = common.queryString();
var YohoListPage = {
rootDoc: $('.yoho-product-list'),
brandsDoc: $('.yoho-product-list .brand-list'),
... ... @@ -16,7 +17,7 @@ var YohoListPage = {
require('yoho-jquery-nanoscroller');
require('../../plugins/check');
require('../../common/return-top');
require('../../common/header');
lazyload();
$('.nano').nanoScroller();
$('.yoho-ui-accordion', this.rootDoc).each(function() {
... ...
var lazyload = require('yoho-jquery-lazyload');
require('../common/header');
lazyload();
... ...
... ... @@ -257,9 +257,7 @@ function initAddressContent($el, areaCode) {
function newAddress(isInit) {
var address;
address = addressDialogFactory({
init: isInit
});
address = addressDialogFactory();
if (isInit) {
address.$el.addClass('is-init');
... ...