Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mr-julyedu
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
baiguangyao
mr-julyedu
Commits
23e35a50
Commit
23e35a50
authored
Jun 04, 2019
by
zhanghaozhe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
购物车命名
parent
3b1fa6e0
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
17 additions
and
16 deletions
+17
-16
src/components/shopCart/card.scss
+3
-2
src/components/shopCart/cartItem.js
+3
-3
src/components/shopCart/cartList.js
+6
-6
src/components/shopCart/index.js
+2
-2
src/components/shopCart/store/index.js
+0
-0
src/router/router-config.js
+3
-3
No files found.
src/components/shopCar
d
/card.scss
→
src/components/shopCar
t
/card.scss
View file @
23e35a50
...
...
@@ -152,10 +152,11 @@
}
}
.cart-footer
{
position
:
fixed
;
bottom
:
0
;
left
:
0
;
width
:
100%
;
display
:
flex
;
position
:
absolute
;
bottom
:
0
;
justify-content
:
space-between
;
border-top
:
1px
solid
#eee
;
background-color
:rgba
(
255
,
255
,
255
,
.7
)
;
...
...
src/components/shopCar
d/card
Item.js
→
src/components/shopCar
t/cart
Item.js
View file @
23e35a50
...
...
@@ -3,7 +3,7 @@ import { Checkbox } from 'antd-mobile';
import
OrderList
from
'@/common/OrderList'
;
class
Car
d
Item
extends
Component
{
class
Car
t
Item
extends
Component
{
// 构造函数
constructor
(
props
)
{
super
(
props
)
...
...
@@ -62,4 +62,4 @@ class CardItem extends Component {
)
}
}
export
default
CardItem
;
\ No newline at end of file
export
default
CartItem
;
\ No newline at end of file
src/components/shopCar
d/card
List.js
→
src/components/shopCar
t/cart
List.js
View file @
23e35a50
import
React
,
{
Component
}
from
'react'
import
Car
dItem
from
'./card
Item'
import
Car
tItem
from
'./cart
Item'
class
ShopCard
extends
Component
{
render
()
{
...
...
@@ -12,17 +12,17 @@ class ShopCard extends Component {
this
.
props
.
data
.
length
>
0
?
this
.
props
.
data
.
map
((
item
,
i
)
=>
{
return
(
<
Car
dItem
index
=
{
i
}
<
Car
tItem
index
=
{
i
}
changeStock
=
{(
id
,
val
)
=>
{
this
.
props
.
changeStock
(
id
,
val
)
}}
}}
checkChange
=
{(
id
,
val
)
=>
{
this
.
props
.
checkChange
(
id
,
val
)
}}
}}
getCartList
=
{()
=>
{
this
.
props
.
getCartList
()
}}
key
=
{
i
}
item
=
{
item
}
><
/CardItem
>
}}
key
=
{
i
}
item
=
{
item
}
/
>
)
})
:
<
div
className
=
"cart-tip"
>
暂无商品
<
/div
>
...
...
src/components/shopCar
d
/index.js
→
src/components/shopCar
t
/index.js
View file @
23e35a50
...
...
@@ -2,7 +2,7 @@ import React, { Component } from 'react'
import
{
connect
}
from
'react-redux'
import
{
Checkbox
,
NavBar
}
from
'antd-mobile'
//组件
import
ShopCar
d
from
'./card
List.js'
import
ShopCar
t
from
'./cart
List.js'
import
Loading
from
'@common/Loading'
//css
...
...
@@ -144,7 +144,7 @@ class Cart extends Component {
this
.
state
.
loading
?
<
Loading
/>
:
<
ShopCar
d
getCartList
=
{
this
.
getCartList
}
changeStock
=
{
this
.
changeStock
}
checkChange
=
{
this
.
checkChange
}
data
=
{
this
.
state
.
data
}
/
>
<
ShopCar
t
getCartList
=
{
this
.
getCartList
}
changeStock
=
{
this
.
changeStock
}
checkChange
=
{
this
.
checkChange
}
data
=
{
this
.
state
.
data
}
/
>
}
...
...
src/components/shopCar
d
/store/index.js
→
src/components/shopCar
t
/store/index.js
View file @
23e35a50
File moved
src/router/router-config.js
View file @
23e35a50
...
...
@@ -11,7 +11,7 @@ import Search from '@/components/search/index'
import
SearchResult
from
'@/components/search/search-result'
import
Detail
from
'@/components/detail/index'
import
Examination
from
'@/components/examination'
import
ShopCar
d
from
'@/components/shopCard/index
'
;
import
ShopCar
t
from
'@/components/shopCart
'
;
import
BargainMiddlePage
from
'@/components/bargainMiddlePage'
;
import
Passport
from
'@/components/passport'
...
...
@@ -70,8 +70,8 @@ export default [
component
:
Coupons
},
{
path
:
'/shopcar
d
'
,
component
:
ShopCar
d
path
:
'/shopcar
t
'
,
component
:
ShopCar
t
},
{
path
:
'/bargain-middle-page'
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment