common js 冲突解决
Showing
4 changed files
with
9 additions
and
13 deletions
@@ -10,19 +10,18 @@ const isProduction = process.env.NODE_ENV === 'production'; | @@ -10,19 +10,18 @@ const isProduction = process.env.NODE_ENV === 'production'; | ||
10 | const isTest = process.env.NODE_ENV === 'test'; | 10 | const isTest = process.env.NODE_ENV === 'test'; |
11 | 11 | ||
12 | const domains = { | 12 | const domains = { |
13 | - // api: 'http://api.yoho.cn/', | ||
14 | - // service: 'http://service.yoho.cn/', | ||
15 | - // liveApi: 'http://testapi.live.yohops.com:9999/', | ||
16 | - // singleApi: 'http://api-test3.yohops.com:9999/', | ||
17 | - | ||
18 | api: 'http://api-test3.yohops.com:9999/', | 13 | api: 'http://api-test3.yohops.com:9999/', |
19 | service: 'http://service-test3.yohops.com:9999/', | 14 | service: 'http://service-test3.yohops.com:9999/', |
20 | liveApi: 'http://testapi.live.yohops.com:9999/', | 15 | liveApi: 'http://testapi.live.yohops.com:9999/', |
21 | singleApi: 'http://api-test3.yohops.com:9999/', | 16 | singleApi: 'http://api-test3.yohops.com:9999/', |
22 | 17 | ||
18 | + | ||
19 | + // api: 'http://api.yoho.yohoops.org/', | ||
20 | + // service: 'http://service.yoho.yohoops.org/', | ||
23 | // liveApi: 'http://api.live.yoho.cn/', | 21 | // liveApi: 'http://api.live.yoho.cn/', |
24 | // singleApi: 'http://single.yoho.cn/', | 22 | // singleApi: 'http://single.yoho.cn/', |
25 | 23 | ||
24 | + | ||
26 | imSocket: 'wss://imsocket.yohobuy.com:443', | 25 | imSocket: 'wss://imsocket.yohobuy.com:443', |
27 | imCs: 'https://imhttp.yohobuy.com/api', | 26 | imCs: 'https://imhttp.yohobuy.com/api', |
28 | imServer: 'https://imhttp.yohobuy.com/server' | 27 | imServer: 'https://imhttp.yohobuy.com/server' |
@@ -10,7 +10,7 @@ var $ = require('yoho-jquery'), | @@ -10,7 +10,7 @@ var $ = require('yoho-jquery'), | ||
10 | Hammer = require('yoho-hammer'), | 10 | Hammer = require('yoho-hammer'), |
11 | dialog = require('plugin/dialog'); | 11 | dialog = require('plugin/dialog'); |
12 | 12 | ||
13 | -var $input = $('#search-input input'); | 13 | +var $input = $('#search-input').find('input[name="query"]'); |
14 | 14 | ||
15 | var $clear = $('#search-input .clear-input'); | 15 | var $clear = $('#search-input .clear-input'); |
16 | 16 | ||
@@ -70,9 +70,8 @@ chHammer.on('tap', function() { | @@ -70,9 +70,8 @@ chHammer.on('tap', function() { | ||
70 | // 跳到搜索页 | 70 | // 跳到搜索页 |
71 | function goSearch(query) { | 71 | function goSearch(query) { |
72 | // 保存搜索的内容 | 72 | // 保存搜索的内容 |
73 | - | ||
74 | writeSearch.setHistoryValFun(query); | 73 | writeSearch.setHistoryValFun(query); |
75 | - document.location.href = searchUrl + '?query=' + encodeURIComponent(query); | 74 | + document.location.href = searchUrl + '?from=search&query=' + encodeURIComponent(query); |
76 | } | 75 | } |
77 | 76 | ||
78 | // 搜索输入联动 | 77 | // 搜索输入联动 |
@@ -186,12 +185,10 @@ $('.search-items .search-group').on('click', 'li', function(event) { | @@ -186,12 +185,10 @@ $('.search-items .search-group').on('click', 'li', function(event) { | ||
186 | POS_ID = 1; | 185 | POS_ID = 1; |
187 | FLR_INDEX = 1; | 186 | FLR_INDEX = 1; |
188 | } else { | 187 | } else { |
189 | - var PRD_NUM = $(this).index() + 1; | ||
190 | - | ||
191 | POS_ID = 3; | 188 | POS_ID = 3; |
192 | FLR_INDEX = 3; | 189 | FLR_INDEX = 3; |
193 | 190 | ||
194 | - yasRequest(query, PRD_NUM, 1); | 191 | + yasRequest(query, $(this).index() + 1, 1); |
195 | } | 192 | } |
196 | 193 | ||
197 | if (window._yas && window._yas.sendCustomInfo) { | 194 | if (window._yas && window._yas.sendCustomInfo) { |
@@ -31,7 +31,7 @@ var $goodsContainer = $('#goods-container'), | @@ -31,7 +31,7 @@ var $goodsContainer = $('#goods-container'), | ||
31 | var winH = $(window).height(); | 31 | var winH = $(window).height(); |
32 | 32 | ||
33 | window.$ = $; | 33 | window.$ = $; |
34 | -var $input = $('#search-input input'), | 34 | +var $input = $('#search-input').find('input[name="query"]'), |
35 | $clear = $('#search-input .clear-input'), | 35 | $clear = $('#search-input .clear-input'), |
36 | $buriedpoint = $('.buriedpoint'), | 36 | $buriedpoint = $('.buriedpoint'), |
37 | $search = $('#search'); | 37 | $search = $('#search'); |
@@ -32,7 +32,7 @@ var $goodsContainer = $('#goods-container'), | @@ -32,7 +32,7 @@ var $goodsContainer = $('#goods-container'), | ||
32 | 32 | ||
33 | var winH = $(window).height(); | 33 | var winH = $(window).height(); |
34 | 34 | ||
35 | -var $input = $('#search-input input'), | 35 | +var $input = $('#search-input').find('input[name="query"]'), |
36 | $clear = $('#search-input .clear-input'), | 36 | $clear = $('#search-input .clear-input'), |
37 | $buriedpoint = $('.buriedpoint'), | 37 | $buriedpoint = $('.buriedpoint'), |
38 | $search = $('#search'); | 38 | $search = $('#search'); |
-
Please register or login to post a comment