Showing
25 changed files
with
211 additions
and
148 deletions
@@ -12,7 +12,7 @@ const _ = require('lodash'); | @@ -12,7 +12,7 @@ const _ = require('lodash'); | ||
12 | const helpers = global.yoho.helpers; | 12 | const helpers = global.yoho.helpers; |
13 | 13 | ||
14 | 14 | ||
15 | -const list = (req, res) => { | 15 | +const list = (req, res, next) => { |
16 | let params = Object.assign({}, req.query); | 16 | let params = Object.assign({}, req.query); |
17 | let title = ''; | 17 | let title = ''; |
18 | let query = req.query.query; | 18 | let query = req.query.query; |
@@ -25,49 +25,85 @@ const list = (req, res) => { | @@ -25,49 +25,85 @@ const list = (req, res) => { | ||
25 | cartUrl: helpers.urlFormat('/cart/index/index') | 25 | cartUrl: helpers.urlFormat('/cart/index/index') |
26 | }, params); | 26 | }, params); |
27 | 27 | ||
28 | - // 品类 品牌 | ||
29 | - if (query) { | ||
30 | - domain = searchModel.getAllBrandNames(query); | ||
31 | - | ||
32 | - // 跳转到品牌商品列表页 | ||
33 | - //if (domain !== null && !params.shop_id) { | ||
34 | - // $url = Helpers::url('', array( | ||
35 | - // 'from' => 'search', | ||
36 | - // 'query' => $query | ||
37 | - //), $domain); | ||
38 | - // $this->go($url); | ||
39 | - //} | ||
40 | - | ||
41 | - } else { | ||
42 | - params.query = ''; | ||
43 | - } | ||
44 | - | ||
45 | - // 搜索是一级品类 | ||
46 | - if (isQueryFirstClass) { | ||
47 | - title = '全部' + query; | ||
48 | - } // 搜索是二级品类 | ||
49 | - else if (isQuerySecondClass) { | ||
50 | - title = query; | ||
51 | - } // 搜索其它内容 | ||
52 | - else { | 28 | + /* 判断是不是品牌, 是品牌跳到品牌列表页(显示搜索框),判断是不是品类, 是品类加导航标题(不显示搜索框) */ |
29 | + Promise.all([searchModel.getAllBrandNames(), searchModel.getClassNames()]).then((result) => { | ||
53 | if (query) { | 30 | if (query) { |
54 | - params.search = { | ||
55 | - default: query === '' ? false : query, | ||
56 | - url: '' | ||
57 | - }; | 31 | + _.forEach(result[0], function(obj) { |
32 | + if (query === obj.brandDomain) { // 精确查品牌域名 | ||
33 | + domain = query; | ||
34 | + return false; | ||
35 | + } | ||
36 | + if (query === obj.brandName) { // 精确查品牌名称 | ||
37 | + domain = obj.brandName; | ||
38 | + return false; | ||
39 | + } | ||
40 | + | ||
41 | + if (obj.brandDomain.indexOf(query) > 0) { // 模糊查品牌域名 | ||
42 | + domain = obj.brandDomain; | ||
43 | + return false; | ||
44 | + } | ||
45 | + }); | ||
46 | + | ||
47 | + // 跳转到品牌商品列表页 | ||
48 | + if (domain !== null && !params.shop_id) { | ||
49 | + let url = helpers.urlFormat('', { | ||
50 | + from: 'search', | ||
51 | + query: query | ||
52 | + | ||
53 | + }, domain); | ||
54 | + | ||
55 | + res.redirect(url); | ||
56 | + } | ||
57 | + | ||
58 | + // 品类名称为空时跳出 | ||
59 | + if (!result[1]) { | ||
60 | + return; | ||
61 | + } | ||
62 | + | ||
63 | + _.forEach(result[1].first, (obj) => { | ||
64 | + // 精确查一级品类 | ||
65 | + if (obj === query) { | ||
66 | + isQueryFirstClass = true; | ||
67 | + return false; | ||
68 | + } | ||
69 | + }); | ||
70 | + | ||
71 | + _.forEach(result[1].second, (obj) => { | ||
72 | + // 精确查二级品类 | ||
73 | + if (obj === query) { | ||
74 | + isQuerySecondClass = true; | ||
75 | + return false; | ||
76 | + } | ||
77 | + }); | ||
78 | + } else { | ||
79 | + params.query = ''; | ||
80 | + } | ||
81 | + | ||
82 | + // 搜索是一级品类 | ||
83 | + if (isQueryFirstClass) { | ||
84 | + title = '全部' + query; | ||
85 | + } else if (isQuerySecondClass) { // 搜索是二级品类 | ||
86 | + title = query; | ||
87 | + } else { // 搜索其它内容 | ||
88 | + if (query) { | ||
89 | + params.search = { | ||
90 | + default: query === '' ? false : query, | ||
91 | + url: '' | ||
92 | + }; | ||
93 | + } | ||
94 | + title = '搜索'; | ||
58 | } | 95 | } |
59 | - title = '搜索'; | ||
60 | - } | ||
61 | - | ||
62 | - res.render('search/list', { | ||
63 | - module: 'product', | ||
64 | - page: 'search-list', | ||
65 | - pageHeader: headerModel.setNav({ | ||
66 | - navTitle: title | ||
67 | - }), | ||
68 | - goodList: params, | ||
69 | - pageFooter: true | ||
70 | - }); | 96 | + |
97 | + res.render('search/list', { | ||
98 | + module: 'product', | ||
99 | + page: 'search-list', | ||
100 | + pageHeader: headerModel.setNav({ | ||
101 | + navTitle: title | ||
102 | + }), | ||
103 | + goodList: params, | ||
104 | + pageFooter: true | ||
105 | + }); | ||
106 | + }).catch(next); | ||
71 | }; | 107 | }; |
72 | 108 | ||
73 | const search = (req, res, next) => { | 109 | const search = (req, res, next) => { |
@@ -10,8 +10,6 @@ const camelCase = global.yoho.camelCase; | @@ -10,8 +10,6 @@ const camelCase = global.yoho.camelCase; | ||
10 | const productProcess = require(`${utils}/product-process`); | 10 | const productProcess = require(`${utils}/product-process`); |
11 | const _ = require('lodash'); | 11 | const _ = require('lodash'); |
12 | const api = global.yoho.API; | 12 | const api = global.yoho.API; |
13 | -const serviceAPI = global.yoho.ServiceAPI; | ||
14 | -const helpers = global.yoho.helpers; | ||
15 | 13 | ||
16 | /** | 14 | /** |
17 | * 排序转换 | 15 | * 排序转换 |
@@ -26,14 +24,6 @@ const typeCont = { | @@ -26,14 +24,6 @@ const typeCont = { | ||
26 | category: ['s_t_desc', 's_t_asc'] | 24 | category: ['s_t_desc', 's_t_asc'] |
27 | }; | 25 | }; |
28 | 26 | ||
29 | -const channelType = { | ||
30 | - boys: '1', | ||
31 | - girls: '2', | ||
32 | - kids: '3', | ||
33 | - lifestyle: '4', | ||
34 | - all: '1,2,3,4' | ||
35 | -}; | ||
36 | - | ||
37 | /** | 27 | /** |
38 | * 商品搜索接口请求 | 28 | * 商品搜索接口请求 |
39 | * @param {[object]} params | 29 | * @param {[object]} params |
@@ -81,8 +71,8 @@ const _processBrandNames = (list) => { | @@ -81,8 +71,8 @@ const _processBrandNames = (list) => { | ||
81 | list = list || []; | 71 | list = list || []; |
82 | list = camelCase(list); | 72 | list = camelCase(list); |
83 | 73 | ||
84 | - _.forEach(list, function(item) { | ||
85 | - _.forEach(item, function(obj) { | 74 | + _.forEach(list, (item) => { |
75 | + _.forEach(item, (obj) => { | ||
86 | formatData.push({ | 76 | formatData.push({ |
87 | brandDomain: obj.brandDomain, | 77 | brandDomain: obj.brandDomain, |
88 | brandName: obj.brandName | 78 | brandName: obj.brandName |
@@ -94,9 +84,40 @@ const _processBrandNames = (list) => { | @@ -94,9 +84,40 @@ const _processBrandNames = (list) => { | ||
94 | }; | 84 | }; |
95 | 85 | ||
96 | /** | 86 | /** |
87 | + * 品牌名称处理 | ||
88 | + * @param {[object]} list | ||
89 | + * @return {[object]} | ||
90 | + */ | ||
91 | +const _processClassNames = (list) => { | ||
92 | + const formatData = { | ||
93 | + first: {}, | ||
94 | + second: {} | ||
95 | + }; | ||
96 | + | ||
97 | + list = list || []; | ||
98 | + list = camelCase(list); | ||
99 | + | ||
100 | + _.forEach(list, (item) => { | ||
101 | + _.forEach(item, (obj) => { | ||
102 | + formatData.first[obj.categoryId] = obj.categoryName; | ||
103 | + | ||
104 | + if (obj.sub) { | ||
105 | + _.forEach(obj.sub, (sub) => { | ||
106 | + formatData.second[sub.categoryId] = sub.categoryName; | ||
107 | + }); | ||
108 | + } | ||
109 | + | ||
110 | + }); | ||
111 | + }); | ||
112 | + | ||
113 | + return formatData; | ||
114 | +}; | ||
115 | + | ||
116 | + | ||
117 | +/** | ||
97 | * 获取商品数据 | 118 | * 获取商品数据 |
98 | */ | 119 | */ |
99 | -const getSearchData = (params, uid) => { | 120 | +const getSearchData = (params) => { |
100 | return _searchSales(params).then((result) => { | 121 | return _searchSales(params).then((result) => { |
101 | if (result && result.code === 200) { | 122 | if (result && result.code === 200) { |
102 | return productProcess.processProductList(result.data.product_list || []); | 123 | return productProcess.processProductList(result.data.product_list || []); |
@@ -126,34 +147,34 @@ const getFilterData = (params) => { | @@ -126,34 +147,34 @@ const getFilterData = (params) => { | ||
126 | /** | 147 | /** |
127 | * 获取所有的品牌名称 | 148 | * 获取所有的品牌名称 |
128 | **/ | 149 | **/ |
129 | -const getAllBrandNames = (query) => { | 150 | +const getAllBrandNames = () => { |
130 | return api.get('', { | 151 | return api.get('', { |
131 | method: 'app.brand.brandlist' | 152 | method: 'app.brand.brandlist' |
132 | }, { | 153 | }, { |
133 | cache: true | 154 | cache: true |
134 | }).then((result) => { | 155 | }).then((result) => { |
135 | if (result && result.code === 200) { | 156 | if (result && result.code === 200) { |
136 | - let domain = null; | ||
137 | - let brandNames = _processBrandNames(result.data.brands); | ||
138 | - | ||
139 | - _.forEach(brandNames, function(obj) { | ||
140 | - // 精确查品牌域名 | ||
141 | - if (query === obj.brandDomain) { | ||
142 | - domain = query; | ||
143 | - } | ||
144 | - | ||
145 | - // 精确查品牌名称 | ||
146 | - if (query === obj.brandName) { | ||
147 | - domain = query; | ||
148 | - } | ||
149 | - | ||
150 | - // 模糊查品牌域名 | ||
151 | - //if () | ||
152 | - }); | 157 | + return _processBrandNames(result.data.brands); |
158 | + } else { | ||
159 | + logger.error('品牌名称接口返回 code 不是 200'); | ||
160 | + return {}; | ||
161 | + } | ||
162 | + }); | ||
163 | +}; | ||
153 | 164 | ||
154 | - return domain; | 165 | +/** |
166 | + * 获取所有的品类名称 | ||
167 | + **/ | ||
168 | +const getClassNames = () => { | ||
169 | + return api.get('', { | ||
170 | + method: 'app.sort.get' | ||
171 | + }, { | ||
172 | + cache: true | ||
173 | + }).then((result) => { | ||
174 | + if (result && result.code === 200) { | ||
175 | + return _processClassNames(result.data); | ||
155 | } else { | 176 | } else { |
156 | - logger.error('断码区分类接口返回 code 不是 200'); | 177 | + logger.error('品类名称接口返回 code 不是 200'); |
157 | return {}; | 178 | return {}; |
158 | } | 179 | } |
159 | }); | 180 | }); |
@@ -162,5 +183,6 @@ const getAllBrandNames = (query) => { | @@ -162,5 +183,6 @@ const getAllBrandNames = (query) => { | ||
162 | module.exports = { | 183 | module.exports = { |
163 | getSearchData, | 184 | getSearchData, |
164 | getFilterData, | 185 | getFilterData, |
165 | - getAllBrandNames | 186 | + getAllBrandNames, |
187 | + getClassNames | ||
166 | }; | 188 | }; |
@@ -5,11 +5,9 @@ | @@ -5,11 +5,9 @@ | ||
5 | */ | 5 | */ |
6 | 6 | ||
7 | var $ = require('yoho-jquery'); | 7 | var $ = require('yoho-jquery'); |
8 | - | ||
9 | var $resend = $('#resend'); | 8 | var $resend = $('#resend'); |
10 | - | ||
11 | -var tip = require('../../plugin/tip'), | ||
12 | - showTip = tip.show; | 9 | +var tip = require('../../plugin/tip'); |
10 | +var showTip = tip.show; | ||
13 | 11 | ||
14 | $resend.on('touchstart', function(e) { | 12 | $resend.on('touchstart', function(e) { |
15 | e.preventDefault(); | 13 | e.preventDefault(); |
@@ -146,7 +146,7 @@ function getQueryString(name) { | @@ -146,7 +146,7 @@ function getQueryString(name) { | ||
146 | var reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)', 'i'); | 146 | var reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)', 'i'); |
147 | var r = window.location.search.substr(1).match(reg); | 147 | var r = window.location.search.substr(1).match(reg); |
148 | 148 | ||
149 | - if (r != null) { | 149 | + if (r !== null) { |
150 | return window.unescape(r[2]); | 150 | return window.unescape(r[2]); |
151 | } | 151 | } |
152 | return null; | 152 | return null; |
@@ -240,6 +240,8 @@ function search(opt) { | @@ -240,6 +240,8 @@ function search(opt) { | ||
240 | outlets: opt.id | 240 | outlets: opt.id |
241 | }; | 241 | }; |
242 | break; | 242 | break; |
243 | + default: | ||
244 | + break; | ||
243 | } | 245 | } |
244 | 246 | ||
245 | $.extend(defaultOpt, ext); // 扩展筛选项 | 247 | $.extend(defaultOpt, ext); // 扩展筛选项 |
@@ -315,6 +317,8 @@ function search(opt) { | @@ -315,6 +317,8 @@ function search(opt) { | ||
315 | case 'discount': | 317 | case 'discount': |
316 | $container = $dgc; | 318 | $container = $dgc; |
317 | break; | 319 | break; |
320 | + default: | ||
321 | + break; | ||
318 | } | 322 | } |
319 | 323 | ||
320 | if (data === ' ') { | 324 | if (data === ' ') { |
@@ -367,6 +371,8 @@ function search(opt) { | @@ -367,6 +371,8 @@ function search(opt) { | ||
367 | window._yas(1 * new Date(), '1.0.16', 'yohobuy_m', window._ozuid, | 371 | window._yas(1 * new Date(), '1.0.16', 'yohobuy_m', window._ozuid, |
368 | '', $('.discount-goods .good-info .good-detail-img .good-thumb')); | 372 | '', $('.discount-goods .good-info .good-detail-img .good-thumb')); |
369 | break; | 373 | break; |
374 | + default: | ||
375 | + break; | ||
370 | } | 376 | } |
371 | } | 377 | } |
372 | } | 378 | } |
@@ -407,7 +413,7 @@ writeSearch.bindWirteLocal($('#search-form')); | @@ -407,7 +413,7 @@ writeSearch.bindWirteLocal($('#search-form')); | ||
407 | // 4.筛选有active时点击隐藏筛选面板并恢复点击筛选前active项的active状态 | 413 | // 4.筛选有active时点击隐藏筛选面板并恢复点击筛选前active项的active状态 |
408 | // 5.当前active为筛选并且点击其他项时,隐藏筛选面板 | 414 | // 5.当前active为筛选并且点击其他项时,隐藏筛选面板 |
409 | 415 | ||
410 | -$listNav.bind('contextmenu', function(e) { | 416 | +$listNav.bind('contextmenu', function() { |
411 | return false; | 417 | return false; |
412 | }); | 418 | }); |
413 | 419 |
@@ -17,17 +17,9 @@ function getHistoryval() { | @@ -17,17 +17,9 @@ function getHistoryval() { | ||
17 | return historyval; | 17 | return historyval; |
18 | } | 18 | } |
19 | 19 | ||
20 | -// 绑定提交前的存local操作 | ||
21 | -function bindWirteLocal($form) { | ||
22 | - $form.on('submit', function() { | ||
23 | - var query = this.query.value; | ||
24 | - | ||
25 | - setHistoryValFun(query); | ||
26 | - }); | ||
27 | -} | ||
28 | - | ||
29 | function setHistoryValFun(query) { | 20 | function setHistoryValFun(query) { |
30 | var historys; | 21 | var historys; |
22 | + | ||
31 | if (localStorage) { | 23 | if (localStorage) { |
32 | historys = localStorage.getItem(historyval); | 24 | historys = localStorage.getItem(historyval); |
33 | 25 | ||
@@ -42,6 +34,15 @@ function setHistoryValFun(query) { | @@ -42,6 +34,15 @@ function setHistoryValFun(query) { | ||
42 | } | 34 | } |
43 | } | 35 | } |
44 | 36 | ||
37 | +// 绑定提交前的存local操作 | ||
38 | +function bindWirteLocal($form) { | ||
39 | + $form.on('submit', function() { | ||
40 | + var query = this.query.value; | ||
41 | + | ||
42 | + setHistoryValFun(query); | ||
43 | + }); | ||
44 | +} | ||
45 | + | ||
45 | exports.getRanToken = getRanToken; | 46 | exports.getRanToken = getRanToken; |
46 | exports.getHistoryval = getHistoryval; | 47 | exports.getHistoryval = getHistoryval; |
47 | exports.setHistoryValFun = setHistoryValFun; | 48 | exports.setHistoryValFun = setHistoryValFun; |
@@ -124,7 +124,7 @@ | @@ -124,7 +124,7 @@ | ||
124 | 124 | ||
125 | &.chosed { | 125 | &.chosed { |
126 | border-color: #e10; | 126 | border-color: #e10; |
127 | - background: resolve('shopping-cart/right.png') no-repeat; | 127 | + background: resolve("shopping-cart/right.png") no-repeat; |
128 | background-position: bottom right; | 128 | background-position: bottom right; |
129 | background-size: 38px; | 129 | background-size: 38px; |
130 | color: #e10; | 130 | color: #e10; |
@@ -56,13 +56,13 @@ | @@ -56,13 +56,13 @@ | ||
56 | display: inline-block; | 56 | display: inline-block; |
57 | width: 52px; | 57 | width: 52px; |
58 | height: 54px; | 58 | height: 54px; |
59 | - background-image: url('/channel/click-txt.png'); | 59 | + background-image: url("/channel/click-txt.png"); |
60 | } | 60 | } |
61 | 61 | ||
62 | &.received { | 62 | &.received { |
63 | width: 113px; | 63 | width: 113px; |
64 | height: 132px; | 64 | height: 132px; |
65 | - background-image: url('/channel/received.png'); | 65 | + background-image: url("/channel/received.png"); |
66 | position: absolute; | 66 | position: absolute; |
67 | top: 0; | 67 | top: 0; |
68 | right: 0; | 68 | right: 0; |
@@ -71,7 +71,7 @@ | @@ -71,7 +71,7 @@ | ||
71 | &.zero { | 71 | &.zero { |
72 | width: 111px; | 72 | width: 111px; |
73 | height: 132px; | 73 | height: 132px; |
74 | - background-image: url('/channel/zero.png'); | 74 | + background-image: url("/channel/zero.png"); |
75 | position: absolute; | 75 | position: absolute; |
76 | top: 0; | 76 | top: 0; |
77 | right: 0; | 77 | right: 0; |
@@ -7,7 +7,7 @@ | @@ -7,7 +7,7 @@ | ||
7 | border: none; | 7 | border: none; |
8 | border-bottom: 8px solid #fff; | 8 | border-bottom: 8px solid #fff; |
9 | background-color: transparent; | 9 | background-color: transparent; |
10 | - background-image: resolve('channel/yohood.png'); | 10 | + background-image: resolve("channel/yohood.png"); |
11 | background-position-x: 26%; | 11 | background-position-x: 26%; |
12 | background-position-y: 36%; | 12 | background-position-y: 36%; |
13 | background-size: 40%; | 13 | background-size: 40%; |
@@ -17,7 +17,7 @@ | @@ -17,7 +17,7 @@ | ||
17 | #yohood:active { | 17 | #yohood:active { |
18 | border-bottom-color: #000; | 18 | border-bottom-color: #000; |
19 | background-color: rgba(255, 255, 255, 0.4); | 19 | background-color: rgba(255, 255, 255, 0.4); |
20 | - background-image: resolve('channel/yohood-tapped.png'); | 20 | + background-image: resolve("channel/yohood-tapped.png"); |
21 | 21 | ||
22 | .right-icon { | 22 | .right-icon { |
23 | color: #000; | 23 | color: #000; |
@@ -7,7 +7,7 @@ | @@ -7,7 +7,7 @@ | ||
7 | left: 50%; | 7 | left: 50%; |
8 | margin-left: -2.5rem; | 8 | margin-left: -2.5rem; |
9 | margin-top: -2.5rem; | 9 | margin-top: -2.5rem; |
10 | - background: resolve('common/404.png') no-repeat; | 10 | + background: resolve("common/404.png") no-repeat; |
11 | background-size: 100% 100%; | 11 | background-size: 100% 100%; |
12 | } | 12 | } |
13 | } | 13 | } |
@@ -97,7 +97,6 @@ | @@ -97,7 +97,6 @@ | ||
97 | 97 | ||
98 | .forward { | 98 | .forward { |
99 | width: 40px; | 99 | width: 40px; |
100 | - height: 28px; | ||
101 | float: right; | 100 | float: right; |
102 | margin-left: 45px; | 101 | margin-left: 45px; |
103 | font-size: 24px; | 102 | font-size: 24px; |
@@ -113,6 +112,6 @@ | @@ -113,6 +112,6 @@ | ||
113 | .star-class-body { | 112 | .star-class-body { |
114 | background: #333; | 113 | background: #333; |
115 | width: 100%; | 114 | width: 100%; |
116 | - font: 12px/1.5 Arial, '黑体'; | 115 | + font: 12px/1.5 Arial, "黑体"; |
117 | float: left; | 116 | float: left; |
118 | } | 117 | } |
@@ -294,7 +294,7 @@ | @@ -294,7 +294,7 @@ | ||
294 | .pic-icon { | 294 | .pic-icon { |
295 | width: 19px; | 295 | width: 19px; |
296 | height: 15px; | 296 | height: 15px; |
297 | - background: url('/guang/star/img.png') no-repeat; | 297 | + background: url("/guang/star/img.png") no-repeat; |
298 | background-size: contain; | 298 | background-size: contain; |
299 | display: inline-block; | 299 | display: inline-block; |
300 | margin: 6px 4px 0 8px; | 300 | margin: 6px 4px 0 8px; |
@@ -394,7 +394,7 @@ | @@ -394,7 +394,7 @@ | ||
394 | } | 394 | } |
395 | 395 | ||
396 | .default-avater { | 396 | .default-avater { |
397 | - background-image: resolve('guang/star/user-avatar.png'); | 397 | + background-image: resolve("guang/star/user-avatar.png"); |
398 | } | 398 | } |
399 | 399 | ||
400 | .loading-tip { | 400 | .loading-tip { |
@@ -62,8 +62,8 @@ a { | @@ -62,8 +62,8 @@ a { | ||
62 | 62 | ||
63 | @font-face { | 63 | @font-face { |
64 | font-family: "iconfont"; | 64 | font-family: "iconfont"; |
65 | - src: resolve('iconfont.eot'); /* IE9 */ | ||
66 | - src: resolve('iconfont.eot?#iefix') format('embedded-opentype'), resolve('iconfont.woff') format('woff'), resolve('iconfont.ttf') format('truetype'), resolve('iconfont.svg#iconfont') format('svg'); /* iOS 4.1- */ | 65 | + src: resolve("iconfont.eot"); /* IE9 */ |
66 | + src: resolve("iconfont.eot?#iefix") format("embedded-opentype"), resolve("iconfont.woff") format("woff"), resolve("iconfont.ttf") format("truetype"), resolve("iconfont.svg#iconfont") format("svg"); /* iOS 4.1- */ | ||
67 | } | 67 | } |
68 | 68 | ||
69 | .iconfont { | 69 | .iconfont { |
@@ -95,12 +95,12 @@ a { | @@ -95,12 +95,12 @@ a { | ||
95 | } | 95 | } |
96 | 96 | ||
97 | .order-failure { | 97 | .order-failure { |
98 | - background-image: resolve('common/order-good.jpg'); | 98 | + background-image: resolve("common/order-good.jpg"); |
99 | background-size: 100%; | 99 | background-size: 100%; |
100 | } | 100 | } |
101 | 101 | ||
102 | .good-failure { | 102 | .good-failure { |
103 | - background-image: resolve('common/order-good.jpg'); | 103 | + background-image: resolve("common/order-good.jpg"); |
104 | background-position-x: 40%; | 104 | background-position-x: 40%; |
105 | background-size: 132px !important; | 105 | background-size: 132px !important; |
106 | } | 106 | } |
@@ -13,7 +13,7 @@ | @@ -13,7 +13,7 @@ | ||
13 | background-image: linear-gradient(#383838, #505050); | 13 | background-image: linear-gradient(#383838, #505050); |
14 | 14 | ||
15 | &:before { | 15 | &:before { |
16 | - content: ''; | 16 | + content: ""; |
17 | display: block; | 17 | display: block; |
18 | background: url("/me/suggest/suggest-logo.png"); | 18 | background: url("/me/suggest/suggest-logo.png"); |
19 | width: 104px; | 19 | width: 104px; |
@@ -192,7 +192,7 @@ | @@ -192,7 +192,7 @@ | ||
192 | height: 130px; | 192 | height: 130px; |
193 | float: left; | 193 | float: left; |
194 | margin-right: 30px; | 194 | margin-right: 30px; |
195 | - background: resolve('common/loading.gif') center center no-repeat; | 195 | + background: resolve("common/loading.gif") center center no-repeat; |
196 | background-size: 50%; | 196 | background-size: 50%; |
197 | position: relative; | 197 | position: relative; |
198 | 198 | ||
@@ -227,7 +227,7 @@ | @@ -227,7 +227,7 @@ | ||
227 | float: left; | 227 | float: left; |
228 | 228 | ||
229 | &:after { | 229 | &:after { |
230 | - content: ''; | 230 | + content: ""; |
231 | display: block; | 231 | display: block; |
232 | background: url("/me/suggest/suggest-add.png"); | 232 | background: url("/me/suggest/suggest-add.png"); |
233 | width: 72px; | 233 | width: 72px; |
@@ -5,7 +5,7 @@ | @@ -5,7 +5,7 @@ | ||
5 | } | 5 | } |
6 | 6 | ||
7 | #yohood { | 7 | #yohood { |
8 | - background-image: resolve('./common/yohood.png'); | 8 | + background-image: resolve("./common/yohood.png"); |
9 | background-size: 40%; | 9 | background-size: 40%; |
10 | background-repeat: no-repeat; | 10 | background-repeat: no-repeat; |
11 | background-color: transparent; | 11 | background-color: transparent; |
@@ -43,7 +43,7 @@ body.passport-body { | @@ -43,7 +43,7 @@ body.passport-body { | ||
43 | width: 30PX; | 43 | width: 30PX; |
44 | top: 5PX; | 44 | top: 5PX; |
45 | left: 0; | 45 | left: 0; |
46 | - background: resolve('passport/go-back.png') no-repeat; | 46 | + background: resolve("passport/go-back.png") no-repeat; |
47 | background-size: 100% 100%; | 47 | background-size: 100% 100%; |
48 | } | 48 | } |
49 | .title { | 49 | .title { |
@@ -54,7 +54,7 @@ body.passport-body { | @@ -54,7 +54,7 @@ body.passport-body { | ||
54 | .img-header { | 54 | .img-header { |
55 | width: 68PX; | 55 | width: 68PX; |
56 | height: 40PX; | 56 | height: 40PX; |
57 | - background: resolve('passport/yoho-family.png') no-repeat; | 57 | + background: resolve("passport/yoho-family.png") no-repeat; |
58 | background-size: 100% 100%; | 58 | background-size: 100% 100%; |
59 | margin: 0 auto; | 59 | margin: 0 auto; |
60 | } | 60 | } |
@@ -104,7 +104,7 @@ body.passport-body { | @@ -104,7 +104,7 @@ body.passport-body { | ||
104 | height: 20PX; | 104 | height: 20PX; |
105 | right: 15PX; | 105 | right: 15PX; |
106 | top: 16PX; | 106 | top: 16PX; |
107 | - background: resolve('passport/arrow-right.png') no-repeat; | 107 | + background: resolve("passport/arrow-right.png") no-repeat; |
108 | background-size: 100% 100%; | 108 | background-size: 100% 100%; |
109 | } | 109 | } |
110 | } | 110 | } |
@@ -152,7 +152,7 @@ body.passport-body { | @@ -152,7 +152,7 @@ body.passport-body { | ||
152 | right: 10PX; | 152 | right: 10PX; |
153 | width: 16PX; | 153 | width: 16PX; |
154 | height: 16PX; | 154 | height: 16PX; |
155 | - background: resolve('passport/clear-input.png') no-repeat; | 155 | + background: resolve("passport/clear-input.png") no-repeat; |
156 | background-size: 100% 100%; | 156 | background-size: 100% 100%; |
157 | } | 157 | } |
158 | .eye { | 158 | .eye { |
@@ -161,10 +161,10 @@ body.passport-body { | @@ -161,10 +161,10 @@ body.passport-body { | ||
161 | right: 10PX; | 161 | right: 10PX; |
162 | width: 19PX; | 162 | width: 19PX; |
163 | height: 12PX; | 163 | height: 12PX; |
164 | - background: resolve('passport/eye.png') no-repeat; | 164 | + background: resolve("passport/eye.png") no-repeat; |
165 | background-size: 100% 100%; | 165 | background-size: 100% 100%; |
166 | &.close { | 166 | &.close { |
167 | - background-image: resolve('passport/eye-close.png'); | 167 | + background-image: resolve("passport/eye-close.png"); |
168 | } | 168 | } |
169 | } | 169 | } |
170 | .row { | 170 | .row { |
@@ -3,7 +3,7 @@ | @@ -3,7 +3,7 @@ | ||
3 | position: absolute; | 3 | position: absolute; |
4 | height: 31PX; | 4 | height: 31PX; |
5 | width: 26PX; | 5 | width: 26PX; |
6 | - background: resolve('passport/yoho.png'); | 6 | + background: resolve("passport/yoho.png"); |
7 | background-size: 100% 100%; | 7 | background-size: 100% 100%; |
8 | top: 10PX; | 8 | top: 10PX; |
9 | left: 15PX; | 9 | left: 15PX; |
@@ -57,20 +57,20 @@ | @@ -57,20 +57,20 @@ | ||
57 | } | 57 | } |
58 | 58 | ||
59 | .alipay { | 59 | .alipay { |
60 | - background-image: resolve('passport/alipay.png'); | 60 | + background-image: resolve("passport/alipay.png"); |
61 | } | 61 | } |
62 | 62 | ||
63 | .weibo { | 63 | .weibo { |
64 | - background-image: resolve('passport/weibo.png'); | 64 | + background-image: resolve("passport/weibo.png"); |
65 | } | 65 | } |
66 | 66 | ||
67 | .qq { | 67 | .qq { |
68 | - background-image: resolve('passport/qq.png'); | 68 | + background-image: resolve("passport/qq.png"); |
69 | } | 69 | } |
70 | 70 | ||
71 | .wechat { | 71 | .wechat { |
72 | display: none; | 72 | display: none; |
73 | - background-image: resolve('passport/wechat.png'); | 73 | + background-image: resolve("passport/wechat.png"); |
74 | } | 74 | } |
75 | } | 75 | } |
76 | } | 76 | } |
@@ -97,7 +97,7 @@ | @@ -97,7 +97,7 @@ | ||
97 | display: inline-block; | 97 | display: inline-block; |
98 | height: 12PX; | 98 | height: 12PX; |
99 | width: 12PX; | 99 | width: 12PX; |
100 | - background-image: resolve('passport/info.png'); | 100 | + background-image: resolve("passport/info.png"); |
101 | background-size: 100% 100%; | 101 | background-size: 100% 100%; |
102 | } | 102 | } |
103 | } | 103 | } |
@@ -384,13 +384,13 @@ $basicBtnC: #eb0313; | @@ -384,13 +384,13 @@ $basicBtnC: #eb0313; | ||
384 | text-align: left; | 384 | text-align: left; |
385 | 385 | ||
386 | .vip-img { | 386 | .vip-img { |
387 | - background: resolve('product/silver.png') no-repeat; | 387 | + background: resolve("product/silver.png") no-repeat; |
388 | } | 388 | } |
389 | } | 389 | } |
390 | 390 | ||
391 | &:nth-child(2) { | 391 | &:nth-child(2) { |
392 | .vip-img { | 392 | .vip-img { |
393 | - background: resolve('product/golden.png') no-repeat; | 393 | + background: resolve("product/golden.png") no-repeat; |
394 | } | 394 | } |
395 | } | 395 | } |
396 | 396 | ||
@@ -398,7 +398,7 @@ $basicBtnC: #eb0313; | @@ -398,7 +398,7 @@ $basicBtnC: #eb0313; | ||
398 | text-align: right; | 398 | text-align: right; |
399 | 399 | ||
400 | .vip-img { | 400 | .vip-img { |
401 | - background: resolve('product/platinum.png') no-repeat; | 401 | + background: resolve("product/platinum.png") no-repeat; |
402 | } | 402 | } |
403 | } | 403 | } |
404 | } | 404 | } |
@@ -7,7 +7,7 @@ | @@ -7,7 +7,7 @@ | ||
7 | margin-left: 50px; | 7 | margin-left: 50px; |
8 | width: 494px; | 8 | width: 494px; |
9 | height: 28px; | 9 | height: 28px; |
10 | - background: resolve('product/service.png') no-repeat; | 10 | + background: resolve("product/service.png") no-repeat; |
11 | background-size: cover; | 11 | background-size: cover; |
12 | } | 12 | } |
13 | 13 |
@@ -103,7 +103,8 @@ | @@ -103,7 +103,8 @@ | ||
103 | } | 103 | } |
104 | } | 104 | } |
105 | 105 | ||
106 | - .btn-intro, .btn-col { | 106 | + .btn-intro, |
107 | + .btn-col { | ||
107 | position: absolute; | 108 | position: absolute; |
108 | display: block; | 109 | display: block; |
109 | width: 124px; | 110 | width: 124px; |
@@ -133,11 +134,11 @@ | @@ -133,11 +134,11 @@ | ||
133 | } | 134 | } |
134 | 135 | ||
135 | .txt:after { | 136 | .txt:after { |
136 | - content: '收藏' | 137 | + content: "收藏"; |
137 | } | 138 | } |
138 | 139 | ||
139 | &.coled .txt:after { | 140 | &.coled .txt:after { |
140 | - content: '已收藏' | 141 | + content: "已收藏"; |
141 | } | 142 | } |
142 | } | 143 | } |
143 | 144 | ||
@@ -147,7 +148,7 @@ | @@ -147,7 +148,7 @@ | ||
147 | left: 0; | 148 | left: 0; |
148 | right: 0; | 149 | right: 0; |
149 | bottom: 0; | 150 | bottom: 0; |
150 | - background: rgba(0,0,0,.3); | 151 | + background: rgba(0, 0, 0, 0.3); |
151 | padding: 88px 0; | 152 | padding: 88px 0; |
152 | z-index: 1; | 153 | z-index: 1; |
153 | overflow: auto; | 154 | overflow: auto; |
@@ -206,8 +207,9 @@ | @@ -206,8 +207,9 @@ | ||
206 | text-align: center; | 207 | text-align: center; |
207 | font-size: 28px; | 208 | font-size: 28px; |
208 | } | 209 | } |
209 | - .bytouch{ | ||
210 | - background:#eee; | 210 | + |
211 | + .bytouch { | ||
212 | + background: #eee; | ||
211 | } | 213 | } |
212 | 214 | ||
213 | a { | 215 | a { |
@@ -89,7 +89,7 @@ | @@ -89,7 +89,7 @@ | ||
89 | width: 22px; | 89 | width: 22px; |
90 | height: 30px; | 90 | height: 30px; |
91 | display: inline-block; | 91 | display: inline-block; |
92 | - background: url('/search/hot-ico.png') no-repeat; | 92 | + background: url("/search/hot-ico.png") no-repeat; |
93 | margin-right: 20px; | 93 | margin-right: 20px; |
94 | position: relative; | 94 | position: relative; |
95 | top: 2px; | 95 | top: 2px; |
@@ -108,7 +108,7 @@ | @@ -108,7 +108,7 @@ | ||
108 | width: 26px; | 108 | width: 26px; |
109 | height: 26px; | 109 | height: 26px; |
110 | display: inline-block; | 110 | display: inline-block; |
111 | - background: url('/search/time-ico.png') no-repeat; | 111 | + background: url("/search/time-ico.png") no-repeat; |
112 | margin-right: 20px; | 112 | margin-right: 20px; |
113 | position: relative; | 113 | position: relative; |
114 | top: 2px; | 114 | top: 2px; |
@@ -118,7 +118,7 @@ | @@ -118,7 +118,7 @@ | ||
118 | width: 24px; | 118 | width: 24px; |
119 | height: 26px; | 119 | height: 26px; |
120 | display: inline-block; | 120 | display: inline-block; |
121 | - background: url('/search/del-ico.png') no-repeat; | 121 | + background: url("/search/del-ico.png") no-repeat; |
122 | } | 122 | } |
123 | 123 | ||
124 | .left { | 124 | .left { |
@@ -130,7 +130,7 @@ | @@ -130,7 +130,7 @@ | ||
130 | } | 130 | } |
131 | } | 131 | } |
132 | 132 | ||
133 | - .search-content{ | 133 | + .search-content { |
134 | clear: both; | 134 | clear: both; |
135 | padding-left: 47px; | 135 | padding-left: 47px; |
136 | box-sizing: border-box; | 136 | box-sizing: border-box; |
@@ -263,7 +263,7 @@ | @@ -263,7 +263,7 @@ | ||
263 | overflow: hidden; | 263 | overflow: hidden; |
264 | text-overflow: ellipsis; | 264 | text-overflow: ellipsis; |
265 | white-space: nowrap; | 265 | white-space: nowrap; |
266 | - border:1px solid #b8b8b8; | 266 | + border: 1px solid #b8b8b8; |
267 | border-radius: 0.2rem; | 267 | border-radius: 0.2rem; |
268 | } | 268 | } |
269 | 269 | ||
@@ -271,27 +271,27 @@ | @@ -271,27 +271,27 @@ | ||
271 | font-size: 28px; | 271 | font-size: 28px; |
272 | } | 272 | } |
273 | 273 | ||
274 | - .clear-icon{ | 274 | + .clear-icon { |
275 | float: right; | 275 | float: right; |
276 | color: #b8b8b8; | 276 | color: #b8b8b8; |
277 | border: none; | 277 | border: none; |
278 | background: white; | 278 | background: white; |
279 | } | 279 | } |
280 | 280 | ||
281 | - span{ | 281 | + span { |
282 | margin-right: 10px; | 282 | margin-right: 10px; |
283 | font-size: 14px; | 283 | font-size: 14px; |
284 | } | 284 | } |
285 | 285 | ||
286 | - .history-search{ | ||
287 | - border-bottom:1px solid #f3f3f3; | 286 | + .history-search { |
287 | + border-bottom: 1px solid #f3f3f3; | ||
288 | } | 288 | } |
289 | 289 | ||
290 | - .hot-search{ | 290 | + .hot-search { |
291 | margin-top: 20px; | 291 | margin-top: 20px; |
292 | } | 292 | } |
293 | 293 | ||
294 | - .clearfix{ | 294 | + .clearfix { |
295 | margin-left: 30px; | 295 | margin-left: 30px; |
296 | } | 296 | } |
297 | 297 |
-
Please register or login to post a comment