Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yoho-blk
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
1
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Plain Diff
Browse Files
Authored by
zhangxiaoru
9 years ago
Commit
54526989c5600d60a04ec879b6bddcf27738e423
2 parents
e90c8652
38cf318d
detail
Hide whitespace changes
Inline
Side-by-side
Showing
28 changed files
with
120 additions
and
75 deletions
apps/me/controllers/currency.js
apps/me/models/currency.js
apps/me/models/menu-crumb-handler.js
apps/me/router.js
apps/me/views/action/index.hbs
apps/me/views/partial/currency.hbs
apps/me/views/partial/order/table-body.hbs
apps/me/views/partial/setting/act/step1.hbs
apps/passport/views/action/login/index.hbs
apps/product/views/action/shop-index.hbs
apps/shopping/models/order.js
config/common.js
doraemon/views/partial/header.hbs
public/js/common/header.js
public/js/me/currency.page.js
public/js/me/refund.page.js
public/scss/_base.css
public/scss/components/_dialog.css
public/scss/components/_goods.css
public/scss/components/_header.css
public/scss/me/order/_table.css
public/scss/me/setting/_act.css
public/scss/passport/_login.css
public/scss/product/_item.css
public/scss/product/_shop.css
public/scss/shopping/_cart-products.css
public/scss/shopping/_edit-color-size.css
public/webpack.config.js
apps/me/controllers/currency.js
View file @
5452698
/**
* [个人中心]
yoho
币
* [个人中心]
有货
币
* @author: jiangmin
* @date: 2016/07/11
*/
...
...
@@ -36,7 +36,7 @@ const getDate = (time)=> {
};
/**
*
yoho
币页面加载
*
有货
币页面加载
*/
const
index
=
(
req
,
res
,
next
)
=>
{
let
uid
=
req
.
user
.
uid
;
...
...
@@ -67,12 +67,12 @@ const index = (req, res, next) => {
page
:
'currency'
,
isMe
:
true
,
content
:
{
nav
:
mcHandler
.
getMeCrumb
(
'我的YOHO币'
),
navigation
:
mcHandler
.
getSideMenu
(
'我的YOHO币'
),
nav
:
mcHandler
.
getMeCrumb
(
'我的有货币'
),
navigation
:
mcHandler
.
getSideMenu
(
'我的有货币'
),
banner
:
thumb
,
currency
:
true
,
tabs
:
result
[
0
].
list
.
tabs
,
title
:
'我的
YOHO
币'
,
title
:
'我的
有货
币'
,
currentYear
:
new
Date
().
getFullYear
(),
data
:
result
[
0
].
list
.
coinList
,
paginationOpts
:
result
[
0
].
list
.
paginationOpts
,
...
...
apps/me/models/currency.js
View file @
5452698
/**
* [个人中心]
YOHO
币
* [个人中心]
有货
币
* @author: jiangmin
* @date: 2016/07/11
*/
...
...
@@ -10,7 +10,7 @@ const api = global.yoho.API;
const
camelCase
=
global
.
yoho
.
camelCase
;
/**
*
yoho
币列表数据
*
有货
币列表数据
* @param uid
* @param page
* @param queryType
...
...
@@ -87,7 +87,7 @@ const yohoCoinList = (uid, page, queryType, beginTime) => {
};
/**
*
yoho
币总数
*
有货
币总数
* @returns {*}
*/
const
yohoCoinTotal
=
(
uid
)
=>
{
...
...
@@ -105,7 +105,7 @@ const yohoCoinTotal = (uid)=> {
};
/**
* 获取
yoho
币相关数据
* 获取
有货
币相关数据
* @param uid
* @param page
* @param queryType
...
...
apps/me/models/menu-crumb-handler.js
View file @
5452698
...
...
@@ -57,7 +57,7 @@ const navigation = [
},
{
link
:
url
(
'/me/currency'
),
name
:
'我的
YOHO
币'
name
:
'我的
有货
币'
},
{
link
:
url
(
'/me/setting'
),
...
...
apps/me/router.js
View file @
5452698
...
...
@@ -56,7 +56,7 @@ router.post('/address/default', auth, address.setDefaultAddress);
router
.
get
(
'/address/list'
,
address
.
getAddressList
);
// 获取地址列表
router
.
get
(
'/address/areas/:areaId'
,
address
.
getAddressData
);
// 个人中心首页/
YOHO
币
// 个人中心首页/
有货
币
router
.
get
(
'/currency'
,
auth
,
currency
.
index
);
// 个人中心首页/个人设置
...
...
apps/me/views/action/index.hbs
View file @
5452698
...
...
@@ -60,7 +60,7 @@
{{>
message
}}
{{/if}}
{{!-- 我的
YOHO
币 --}}
{{!-- 我的
有货
币 --}}
{{#if
currency
}}
{{>
currency
}}
{{/if}}
...
...
apps/me/views/partial/currency.hbs
View file @
5452698
...
...
@@ -5,7 +5,7 @@
</div>
<div
class=
"inline-block total-yohocoin"
>
<div
class=
"current-yohocoin"
>
目前可用
YOHO
币:
<span
class=
"blue"
>
{{
num
.
yohocoin_num
}}
个
</span></div>
<div
class=
"current-yohocoin"
>
目前可用
有货
币:
<span
class=
"blue"
>
{{
num
.
yohocoin_num
}}
个
</span></div>
<div
class=
"left-yohocoin"
>
{{
currentYear
}}
年12月31日即将过期:
<span
class=
"blue"
>
{{
num
.
nearExpCoinNum
}}
个
</span></div>
</div>
</div>
...
...
apps/me/views/partial/order/table-body.hbs
View file @
5452698
...
...
@@ -20,13 +20,13 @@
</div>
<div
class=
"common-column special-border operation"
>
{{#if
showPayButton
}}
<div
class=
"pay-operation"
>
<div
class=
"pay-operation
{{#
unless
showLeftTime
}}
marginhack
{{/
unless
}}
"
>
{{#if
isOnlinePaid
}}
{{#if
showLeftTime
}}
<span
class=
"iconfont hide-when-invalid"
>

</span><p
class=
"left-time"
data-left=
"
{{
payLefttime
}}
"
></p>
{{/if}}
<a
href=
"
{{
payUrl
}}
"
>
<span
class=
"btn red hide-when-invalid"
>
立即付款
</span>
<span
class=
"btn red hide-when-invalid
"
>
立即付款
</span>
</a>
{{/if}}
<p
class=
"subtext cancel"
>
取消订单
</p>
...
...
@@ -46,7 +46,7 @@
<p
class=
"subtext express"
>
物流进度
</p>
{{/if}}
<div
class=
"buy-operation
{{#
unless
showBuyBtn
}}
hide
{{/
unless
}}
"
>
<div
class=
"buy-operation
{{#
unless
showBuyBtn
}}
hide
{{/
unless
}}
{{#
unless
showPayButton
}}
marginhack
{{/
unless
}}
"
>
<span
class=
"btn black buy"
>
再次购买
</span>
<p
class=
"subtext delete"
>
删除订单
</p>
</div>
...
...
apps/me/views/partial/setting/act/step1.hbs
View file @
5452698
...
...
@@ -4,7 +4,7 @@
<div
class=
"progress-text"
>
<span>
验证身份
</span>
<span
class=
"gray-text"
>
{{
proTitle
}}
</span>
<span
class=
"gray-text"
>
完成
</span>
<span
class=
"gray-text
pad66
"
>
完成
</span>
</div>
{{#if
isShowMobile
}}
<div
class=
"operate1"
>
...
...
apps/passport/views/action/login/index.hbs
View file @
5452698
{{>
sign-header
}}
<div
class=
"login-page passport-page"
>
{{#
passport
}}
<form
method=
'post'
onsubmit=
'return false;'
>
<ul>
<li
class=
"clearfix"
>
<div
class=
"title"
>
登录 SIGN IN
</div>
...
...
@@ -51,8 +52,7 @@
<span
class=
"iconfont"
>

</span>
<em></em>
</span>
<a
id=
"login-btn"
class=
"btn login-btn"
>
登录
</a>
<input
type=
"submit"
id=
"login-btn"
class=
"btn login-btn"
value=
'登录'
/>
</li>
<li
class=
"clearfix"
>
...
...
@@ -93,5 +93,6 @@
</li>
</ul>
<input
id=
"country-code-hide"
name=
"countryCode"
type=
"hidden"
value=
"
{{
countryCode
}}
"
>
</form>
{{/
passport
}}
</div>
...
...
apps/product/views/action/shop-index.hbs
View file @
5452698
...
...
@@ -115,8 +115,8 @@
{{#
each
editorial
}}
<div
class=
"editorial-info"
>
<a
href=
"
{{
url
}}
"
target=
"_blank"
>
<img
class=
"lazy thumb"
alt=
"
{{
title
}}
"
data-original=
"
{{
image
src
368
340
}}
"
width=
"368"
height=
"340"
style=
"display: block;"
>
<img
class=
"lazy thumb"
alt=
"
{{
title
}}
"
data-original=
"
{{
image
src
368
240
2
}}
"
width=
"368"
height=
"240"
style=
"display: block;"
>
</a>
<div
class=
"desc"
>
<a
class=
"name"
href=
"
{{
url
}}
"
target=
"_blank"
>
{{
title
}}
</a>
...
...
apps/shopping/models/order.js
View file @
5452698
...
...
@@ -88,7 +88,7 @@ const index = uid => {
* @param number uid user id
* @param number $deliveryWay 配送方式,1表示普通快递,2表示顺丰速运
* @param int $paymentType 支付方式,1表示在线支付,2表示货到付款
* @param number $yohoCoin 使用的
YOHO
币数量
* @param number $yohoCoin 使用的
有货
币数量
* */
const
_computeApi
=
(
uid
,
deliveryWay
,
paymentType
,
yohoCoin
)
=>
api
.
get
(
''
,
{
method
:
'app.Shopping.compute'
,
...
...
@@ -110,7 +110,7 @@ const compute = (uid, yohoCoin) => {
let
coin
;
//
YOHO
币稀释
//
有货
币稀释
if
(
yohoCoin
)
{
coin
=
yohoCoin
/
100
;
}
...
...
config/common.js
View file @
5452698
...
...
@@ -23,11 +23,8 @@ module.exports = {
cookieDomain
:
'yohoblk.com'
,
domains
:
{
singleApi
:
'http://192.168.102.31:8092/'
,
api
:
'http://api-test2.yohops.com:9999/'
,
service
:
'http://service-test2.yohops.com:9999/'
,
// api: 'http://api.yoho.yohoops.org/',
// service: 'http://service.yoho.yohoops.org/',
api
:
'http://api.yoho.yohoops.org/'
,
service
:
'http://service.yoho.yohoops.org/'
,
search
:
'http://192.168.102.216:8080/yohosearch/'
},
useOneapm
:
false
,
...
...
doraemon/views/partial/header.hbs
View file @
5452698
...
...
@@ -20,7 +20,7 @@
<a
href=
"
{{
..
/
siteUrl
}}
/me"
>
{{
userName
}}
</a>
<a
href=
"
{{
..
/
siteUrl
}}
/passport/logout"
>
[退出]
</a>
{{^}}
<a
href=
"
{{
..
/
siteUrl
}}
/passport/login"
>
登录
</a>
|
<a
href=
"
{{
..
/
siteUrl
}}
/passport/login"
>
登录
</a>
|
<a
href=
"
{{
..
/
siteUrl
}}
/passport/reg"
>
注册
</a>
{{/if}}
</li>
...
...
@@ -46,7 +46,7 @@
</a>
<div
class=
"mini-bag-box sub-wrapper bag-empty"
>
<div
class=
"bag-goods"
>
<d
l
class=
"mini-goods-list"
></dl
>
<d
iv
class=
"mini-goods-list-wrap nano"
><div
class=
"nano-content"
><dl
class=
"mini-goods-list"
></dl></div></div
>
<div
class=
"go-bag-btn"
>
<a
href=
"
{{
..
/
siteUrl
}}
/shopping/cart"
>
去购物车结算
</a>
</div>
...
...
public/js/common/header.js
View file @
5452698
...
...
@@ -15,6 +15,9 @@ var $searchWrap = $('.search-wrapper'),
var
goodsTpl
=
require
(
'../../tpl/common/bag-goods.hbs'
);
require
(
'yoho-jquery-nanoscroller'
);
var
delayer
;
function
handelProduct
(
data
)
{
...
...
@@ -63,6 +66,7 @@ function refreshBag() {
$bagGoodsList
.
empty
();
$miniBag
.
addClass
(
'bag-empty'
);
}
$
(
'.nano'
).
nanoScroller
({
disableResize
:
true
});
}
}
...
...
public/js/me/currency.page.js
View file @
5452698
/**
* [个人中心]
YOHO
币
* [个人中心]
有货
币
* @author: jiangmin
* @date: 2016/07/11
*/
...
...
public/js/me/refund.page.js
View file @
5452698
...
...
@@ -19,7 +19,7 @@ var $applyBtn = $('#apply-btn');
var
orderCode
=
$
(
'#order-code'
).
val
()
||
0
,
specialReason
=
$refundTable
.
data
()
||
{},
payInfo
=
{
// 退款信息
type
:
$refundType
.
find
(
'.type-item.cur'
).
data
(
'id'
)
// 1--原卡返回 2--银行卡 3--支付宝 4--
yoho
币
type
:
$refundType
.
find
(
'.type-item.cur'
).
data
(
'id'
)
// 1--原卡返回 2--银行卡 3--支付宝 4--
有货
币
};
var
imgBoxTpl
=
require
(
'../../tpl/me/thumbnail.hbs'
);
...
...
public/scss/_base.css
View file @
5452698
...
...
@@ -245,8 +245,8 @@ a {
.body-mask
{
position
:
fixed
;
z-index
:
100
;
background
:
#1d1d1d
;
opacity
:
0.3
;
background
:
#000
;
opacity
:
0.4
;
top
:
0
;
left
:
0
;
}
...
...
public/scss/components/_dialog.css
View file @
5452698
...
...
@@ -5,9 +5,9 @@
left
:
50%
;
min-height
:
130px
;
min-width
:
420px
;
background
:
#f
8f8f8
;
background
:
#f
fffff
;
z-index
:
1001
;
border
:
1px
solid
#8f8f8f
;
/*border: 1px solid #8f8f8f;*/
.close
{
padding
:
5px
;
...
...
public/scss/components/_goods.css
View file @
5452698
.goods-info
{
width
:
274px
;
margin-right
:
18px
;
.thumb
{
width
:
100%
;
height
:
366px
;
}
.desc
{
text-align
:
center
;
}
.name
{
font-size
:
14px
;
line-height
:
50px
;
}
.price
{
font-size
:
16px
;
font-weight
:
bold
;
}
}
.goods-info
{
width
:
274px
;
margin-right
:
18px
;
.thumb
{
width
:
100%
;
height
:
366px
;
}
.desc
{
text-align
:
center
;
}
.name
{
font-size
:
14px
;
line-height
:
50px
;
display
:
block
;
margin-top
:
-2px
;
}
.price
{
font-size
:
16px
;
font-weight
:
bold
;
display
:
block
;
margin-top
:
-2px
;
}
}
...
...
public/scss/components/_header.css
View file @
5452698
...
...
@@ -172,7 +172,7 @@
background
:
#fff
;
}
.mini-goods-list
{
.mini-goods-list
-wrap
{
width
:
340px
;
max-height
:
350px
;
display
:
block
;
...
...
@@ -235,6 +235,9 @@
.del-good-btn
{
cursor
:
pointer
;
color
:
#999
;
&:hover{
color
:
#1b1b1b
;
}
}
}
}
...
...
public/scss/me/order/_table.css
View file @
5452698
...
...
@@ -212,7 +212,7 @@
.btn
{
display
:
inline-block
;
margin-bottom
:
1
4
px
;
margin-bottom
:
1
8
px
;
cursor
:
pointer
;
&.black
{
...
...
@@ -220,6 +220,14 @@
}
}
.marginhack
{
margin-top
:
-4px
;
.black{
margin-top
:
0
;
}
}
p
{
margin-bottom
:
$
space
;
line-height
:
20px
;
...
...
public/scss/me/setting/_act.css
View file @
5452698
...
...
@@ -22,13 +22,17 @@
background-repeat
:
no-repeat
;
}
.progress-text
{
margin-left
:
48
px
;
margin-left
:
62
px
;
span
{
padding
:
0
50px
;
}
.gray-text
{
color
:
#d3d3d3
;
padding
:
0
38px
;
}
.pad66
{
padding-left
:
66px
;
}
}
.operate1
,
...
...
public/scss/passport/_login.css
View file @
5452698
...
...
@@ -55,6 +55,7 @@
height
:
$
item-height
;
width
:
$
item-width
;
line-height
:
@
height
;
border
:
none
;
}
.captcha-component
{
...
...
public/scss/product/_item.css
View file @
5452698
...
...
@@ -58,9 +58,15 @@
text-align
:
center
;
}
.trade-wrapper
{
text-align
:
center
;
}
.brand-name
{
font-size
:
24px
;
font-weight
:
bold
;
margin
:
0
40px
;
line-height
:
1.3
;
}
.name
{
...
...
@@ -88,12 +94,14 @@
}
.option-content
{
width
:
226px
;
/*width: 226px;*/
margin
:
0
auto
;
padding
:
40px
0
20px
;
display
:
inline-block
;
>
p
{
line-height
:
50px
;
text-align
:
left
;
}
.title
{
...
...
@@ -102,17 +110,22 @@
}
.color-list
{
width
:
246px
;
min-width
:
226px
;
max-width
:
300px
;
.color-item
{
float
:
left
;
margin-right
:
20px
;
margin-bottom
:
10px
;
&:last-child{
margin-right
:
0
;
}
}
}
.size-list
{
width
:
236px
;
min-width
:
226px
;
max-width
:
300px
;
li
{
height
:
34px
;
...
...
@@ -125,6 +138,9 @@
border
:
1px
solid
#f0f0f0
;
font-weight
:
bold
;
cursor
:
pointer
;
&:last-child{
margin-right
:
0
;
}
}
.disable
{
...
...
public/scss/product/_shop.css
View file @
5452698
...
...
@@ -117,7 +117,7 @@
.goods-info
{
float
:
left
;
width
:
272px
;
margin
:
2
5
px
10px
;
margin
:
2
6
px
10px
;
border-width
:
1px
;
.desc
{
...
...
public/scss/shopping/_cart-products.css
View file @
5452698
...
...
@@ -2,9 +2,6 @@ $hoverColor: #379ed6;
.blk-cart-page
{
.pros-group
{
/*margin-bottom: 30px;
border-top: 1px solid #eee;*/
&:first-child
{
border-top
:
none
;
}
...
...
@@ -22,9 +19,10 @@ $hoverColor: #379ed6;
font-weight
:
normal
!important
;
display
:
inline-block
!important
;
}
&
:hover
{
cursor
:
pointer
;
border
:
1px
dashed
#
e92601
;
border
:
1px
dashed
#
3ca1db
;
}
}
}
...
...
@@ -75,6 +73,7 @@ $hoverColor: #379ed6;
.checked
{
display
:
inline-block
;
}
.not-checked
{
display
:
none
;
}
...
...
@@ -96,7 +95,6 @@ $hoverColor: #379ed6;
font-size
:
18px
;
font-weight
:
bold
;
line-height
:
50px
;
overflow
:
hidden
;
text-overflow
:
ellipsis
!important
;
white-space
:
nowrap
!important
;
...
...
@@ -175,18 +173,21 @@ $hoverColor: #379ed6;
.editable
{
padding
:
5px
0
;
width
:
20
0px
;
width
:
18
0px
;
position
:
relative
;
.iconfont
{
display
:
none
;
}
.sizes-list
{
width
:
195px
;
}
.colors-list
{
width
:
195px
;
}
.size-item
{
height
:
20px
;
border
:
1px
solid
#e8e8e8
;
...
...
@@ -220,22 +221,26 @@ $hoverColor: #379ed6;
}
}
}
.mr20
{
margin-right
:
20px
;
}
.mr10
{
margin-right
:
10px
;
}
.mb10
{
margin-bottom
:
10px
;
}
.mb20
{
margin-bottom
:
20px
;
}
.mb30
{
margin-bottom
:
30px
;
}
}
.invalid-pros
{
...
...
public/scss/shopping/_edit-color-size.css
View file @
5452698
.blk-cart-page
{
.edit-color-size
{
position
:
absolute
;
left
:
1
8
0px
;
left
:
1
9
0px
;
width
:
354px
;
border
:
2px
solid
#bbb
;
top
:
-113px
;
...
...
public/webpack.config.js
View file @
5452698
...
...
@@ -25,7 +25,9 @@ shelljs.ls(path.join(__dirname, '/js/**/*.page.js')).forEach((f) => {
'yoho-jquery-lazyload'
,
'yoho-slider'
,
'yoho-jquery-accordion'
,
'yoho-jquery-nanoscroller'
'yoho-jquery-nanoscroller'
,
'yoho-jquery-placeholder'
,
'yoho-jquery-dotdotdot'
];
});
...
...
Please
register
or
login
to post a comment