Authored by biao

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

... ... @@ -44,7 +44,7 @@ $('.search-entry').click(function() {
$searchWrap.show();
});
$searchForm.on('keyup', '#search-key', function(e) {
$searchKey.keyup(function(e) {
var key = $searchKey.val();
if (e.which === 13) {
... ... @@ -60,6 +60,23 @@ $searchForm.on('keyup', '#search-key', function(e) {
}
});
// ie8输入框提示特殊处理
if ($.browser && $.browser.msie && parseInt($.browser.version, 10) === 8) {
$searchKey.focus(function() {
var key = $searchKey.val();
if (key === 'search') {
$searchKey.val('').css('color', '#fff');
}
}).blur(function() {
var key = $searchKey.val();
if ($.trim(key) === '') {
$searchKey.val('search').css('color', '#aaa');
}
});
}
$clearInput.click(function() {
$searchKey.val('');
$(this).hide();
... ...
var lazyload = require('yoho-jquery-lazyload');
var Handlebars = require('yoho-handlebars');
var tpl = '{{#each products}}' +
'<div class="goods-info" data-skn="{{productSkn}}">' +
'<a href="{{url}}" target="_blank">' +
'<img class="lazy thumb" src="{{defaultImages}}" style="display: block;">' +
'</a>' +
'<div class="desc">' +
'<a class="name" href="{{url}}" target="_blank">{{productName}}</a>' +
'<p class="price">¥{{salesPrice}}</p>' +
'</div>' +
'</div>' +
'{{/each}}';
var tplFn = Handlebars.compile(tpl);
require('../common/header');
require('./list/favorite');
var tplFn = require('../../tpl/product/shop-goods.hbs');
// require('../common/header');
// require('./list/favorite');
lazyload();
$(function() {
... ...
{{#each products}}
<div class="goods-info" data-skn="{{productSkn}}">
<a href="{{url}}" target="_blank">
<img class="lazy thumb" src="{{defaultImages}}" style="display: block;">
</a>
<div class="desc">
<a class="name" href="{{url}}" target="_blank">{{productName}}</a>
<p class="price">{{salesPrice}}</p>
</div>
</div>
{{/each}}
... ...