Authored by 郝肖肖

common js 冲突解决

... ... @@ -10,19 +10,18 @@ const isProduction = process.env.NODE_ENV === 'production';
const isTest = process.env.NODE_ENV === 'test';
const domains = {
// api: 'http://api.yoho.cn/',
// service: 'http://service.yoho.cn/',
// liveApi: 'http://testapi.live.yohops.com:9999/',
// singleApi: 'http://api-test3.yohops.com:9999/',
api: 'http://api-test3.yohops.com:9999/',
service: 'http://service-test3.yohops.com:9999/',
liveApi: 'http://testapi.live.yohops.com:9999/',
singleApi: 'http://api-test3.yohops.com:9999/',
// api: 'http://api.yoho.yohoops.org/',
// service: 'http://service.yoho.yohoops.org/',
// liveApi: 'http://api.live.yoho.cn/',
// singleApi: 'http://single.yoho.cn/',
imSocket: 'wss://imsocket.yohobuy.com:443',
imCs: 'https://imhttp.yohobuy.com/api',
imServer: 'https://imhttp.yohobuy.com/server'
... ...
... ... @@ -10,7 +10,7 @@ var $ = require('yoho-jquery'),
Hammer = require('yoho-hammer'),
dialog = require('plugin/dialog');
var $input = $('#search-input input');
var $input = $('#search-input').find('input[name="query"]');
var $clear = $('#search-input .clear-input');
... ... @@ -70,9 +70,8 @@ chHammer.on('tap', function() {
// 跳到搜索页
function goSearch(query) {
// 保存搜索的内容
writeSearch.setHistoryValFun(query);
document.location.href = searchUrl + '?query=' + encodeURIComponent(query);
document.location.href = searchUrl + '?from=search&query=' + encodeURIComponent(query);
}
// 搜索输入联动
... ... @@ -186,12 +185,10 @@ $('.search-items .search-group').on('click', 'li', function(event) {
POS_ID = 1;
FLR_INDEX = 1;
} else {
var PRD_NUM = $(this).index() + 1;
POS_ID = 3;
FLR_INDEX = 3;
yasRequest(query, PRD_NUM, 1);
yasRequest(query, $(this).index() + 1, 1);
}
if (window._yas && window._yas.sendCustomInfo) {
... ...
... ... @@ -31,7 +31,7 @@ var $goodsContainer = $('#goods-container'),
var winH = $(window).height();
window.$ = $;
var $input = $('#search-input input'),
var $input = $('#search-input').find('input[name="query"]'),
$clear = $('#search-input .clear-input'),
$buriedpoint = $('.buriedpoint'),
$search = $('#search');
... ...
... ... @@ -32,7 +32,7 @@ var $goodsContainer = $('#goods-container'),
var winH = $(window).height();
var $input = $('#search-input input'),
var $input = $('#search-input').find('input[name="query"]'),
$clear = $('#search-input .clear-input'),
$buriedpoint = $('.buriedpoint'),
$search = $('#search');
... ...