Toggle navigation
Toggle navigation
This project
Loading...
Sign in
mobile
/
YH_RNComponent
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
孙凯
8 years ago
Commit
fa6761355a0651e5d3a751c9f236a24779e5e910
1 parent
9cc4a3bc
add 优惠劵优化 review by chenlin
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
13 additions
and
12 deletions
js/brandStore/components/brandStore/brandStoreSubView/Cells/CouponCell.js
js/brandStore/containers/BrandStoreContainer.js
js/brandStore/reducers/brandStore/brandStoreActions.js
js/redPersonBrand/containers/RedPersonBrandContainer.js
js/redPersonBrand/reducers/redBrand/redBrandActions.js
js/brandStore/components/brandStore/brandStoreSubView/Cells/CouponCell.js
View file @
fa67613
...
...
@@ -75,11 +75,11 @@ export default class CouponCell extends React.Component {
frontView
=
{
width
:
cellOneFront
,
height
:
60
,
flexDirection
:
'row'
};
units
=
{
marginLeft
:
20
,
marginTop
:
20
,
width
:
15
,
height
:
20
};
unitsSize
=
{
fontSize
:
20
};
money
=
(
Platform
.
OS
===
'ios'
)
?
{
marginLeft
:
1
,
ma
rginTop
:
15
,
width
:
60
,
height
:
25
}
:
{
marginLeft
:
1
,
marginTop
:
15
,
width
:
60
,
height
:
30
};
money
=
(
Platform
.
OS
===
'ios'
)
?
{
marginLeft
:
1
,
ma
xWidth
:
60
,
marginTop
:
15
,
height
:
25
}
:
{
marginLeft
:
1
,
marginTop
:
15
,
width
:
60
,
height
:
30
};
moneySize
=
{
fontSize
:
25
};
name
=
{
marginLeft
:
1
,
marginTop
:
0
,
width
:
160
,
height
:
60
,
alignItems
:
'center'
,
justifyContent
:
'center'
,
flexDirection
:
'row'
};
name
=
{
marginLeft
:
1
0
,
marginTop
:
0
,
width
:
160
,
height
:
60
,
alignItems
:
'center'
,
justifyContent
:
'center'
,
flexDirection
:
'row'
};
nameSize
=
{
fontSize
:
15
};
statesTitleStyle
=
{
alignItems
:
'center'
,
width
:
cellOneBack
,
height
:
60
};
statesTitleStyle
=
{
alignItems
:
'center'
,
marginTop
:
5
,
width
:
cellOneBack
,
height
:
60
};
states
=
{
marginTop
:
rowData
.
status
==
1
?
6
:
10
,
fontSize
:
9
,
width
:
10
,
height
:
60
};
}
else
{
backgroundImage
=
require
(
'../../../../image/coupons_s_r.png'
);
...
...
js/brandStore/containers/BrandStoreContainer.js
View file @
fa67613
...
...
@@ -107,10 +107,11 @@ class BrandStoreContainer extends Component {
}
_onPressCoupon
(
rowData
,
resourceId
,
rowID
)
{
if
(
rowData
.
status
)
{
this
.
props
.
actions
.
getCoupon
(
rowData
.
id
);
}
else
{
if
(
rowData
.
status
==
3
)
{
this
.
props
.
actions
.
couponHasRecived
();
}
else
{
this
.
props
.
actions
.
getCoupon
(
rowData
.
id
);
}
let
param
=
{
...
...
js/brandStore/reducers/brandStore/brandStoreActions.js
View file @
fa67613
...
...
@@ -237,7 +237,7 @@ export function getShopInfo() {
}
dispatch
(
shopDataExposure
(
'YB_SHOW_CLASSICAL_SHOP_INFO'
,
params
));
ReactNative
.
NativeModules
.
YH_CommonHelper
.
logEvent
(
'YB_BRAND_SHOP_L'
,
{
SHOP_ID
:
brandStore
.
shopId
,
TEMPLATE_TYPE
:
json
.
shop_template_type
,
IS_RED
:
0
});
ReactNative
.
NativeModules
.
YH_CommonHelper
.
setShopIntro
(
json
);
})
...
...
@@ -1281,7 +1281,7 @@ export function getCoupon(couponId) {
for
(
var
i
=
0
;
i
<
list
.
length
;
i
++
)
{
let
item
=
list
[
i
];
if
(
item
.
id
==
couponId
)
{
item
.
status
=
false
;
//领取成功
item
.
status
=
3
;
//领取成功
break
;
}
}
...
...
js/redPersonBrand/containers/RedPersonBrandContainer.js
View file @
fa67613
...
...
@@ -279,10 +279,10 @@ class RedPersonBrandContainer extends Component {
}
_onPressCoupon
(
rowData
)
{
if
(
rowData
.
status
)
{
this
.
props
.
actions
.
getCoupon
(
rowData
.
id
);
}
else
{
if
(
rowData
.
status
==
3
)
{
this
.
props
.
actions
.
couponHasRecived
();
}
else
{
this
.
props
.
actions
.
getCoupon
(
rowData
.
id
);
}
}
...
...
js/redPersonBrand/reducers/redBrand/redBrandActions.js
View file @
fa67613
...
...
@@ -1047,7 +1047,7 @@ export function getCoupon(couponId) {
for
(
var
i
=
0
;
i
<
list
.
length
;
i
++
)
{
let
item
=
list
[
i
];
if
(
item
.
id
==
couponId
)
{
item
.
status
=
false
;
//领取成功
item
.
status
=
3
;
//领取成功
break
;
}
}
...
...
Please
register
or
login
to post a comment