...
|
...
|
@@ -352,7 +352,7 @@ define('yohood', function(require, exports) { |
|
|
$(".search-btn").trigger("click.search");
|
|
|
});
|
|
|
$(".search-btn").bind("click.search", function() {
|
|
|
var brand = encodeURIComponent($.trim($("input[type=text]").val()));
|
|
|
var brand = $.trim($("input[type=text]").val());
|
|
|
var template = '<ul class="brand-list cooperation-list clearfix">{li}</ul>';
|
|
|
var noSearchTemplate = '<div class="no-search" style="display:block;"><p>未搜索到“{brand}”的相关品牌</p><a href="javascript:;" class="all_brand"><查看全部品牌</a></div>';
|
|
|
var html = '';
|
...
|
...
|
@@ -360,7 +360,7 @@ define('yohood', function(require, exports) { |
|
|
type: "post",
|
|
|
url: "/brand/getbrand",
|
|
|
data: {
|
|
|
brand: brand
|
|
|
brand: encodeURIComponent(brand)
|
|
|
},
|
|
|
success: function(data) {
|
|
|
var brands = data.data;
|
...
|
...
|
@@ -372,7 +372,7 @@ define('yohood', function(require, exports) { |
|
|
});
|
|
|
$(".brand-content").html(template.replace('{li}', html));
|
|
|
} else {
|
|
|
$(".brand-content").html(noSearchTemplate.replace('{brand}', decodeURIComponent(brand)));
|
|
|
$(".brand-content").html(noSearchTemplate.replace('{brand}', tools.escapeHTML(brand) ));
|
|
|
}
|
|
|
}
|
|
|
});
|
...
|
...
|
|