Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
I
ios1x
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
cemarose
ios1x
Commits
d9d17148
Commit
d9d17148
authored
7 years ago
by
lee
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of git.oschina.net:kollway-kollway/newcemarose
parents
2b7089a3
b56408f9
master
No related merge requests found
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
27 deletions
+4
-27
KWMWishListVC.m
iCemarose/Class/UI/NewProduct/KWMWishListVC.m
+0
-23
NewProduct.storyboard
iCemarose/Class/UI/NewProduct/NewProduct.storyboard
+0
-0
ShopCart.storyboard
iCemarose/Class/UI/ShopCart/ShopCart.storyboard
+4
-4
No files found.
iCemarose/Class/UI/NewProduct/KWMWishListVC.m
View file @
d9d17148
...
@@ -15,8 +15,6 @@
...
@@ -15,8 +15,6 @@
@interface
KWMWishListVC
()
@interface
KWMWishListVC
()
@property
(
weak
,
nonatomic
)
IBOutlet
UILabel
*
lbTotalPrice
;
@property
(
weak
,
nonatomic
)
IBOutlet
UITableView
*
tbvWish
;
@property
(
weak
,
nonatomic
)
IBOutlet
UITableView
*
tbvWish
;
@property
(
nonatomic
)
NSMutableArray
*
wishArray
;
@property
(
nonatomic
)
NSMutableArray
*
wishArray
;
...
@@ -40,12 +38,6 @@
...
@@ -40,12 +38,6 @@
-
(
void
)
viewWillAppear
:
(
BOOL
)
animated
{
-
(
void
)
viewWillAppear
:
(
BOOL
)
animated
{
[
super
viewWillAppear
:
animated
];
[
super
viewWillAppear
:
animated
];
[
self
.
navigationController
setNavigationBarHidden
:
NO
];
[
self
.
navigationController
setNavigationBarHidden
:
NO
];
[
self
setTotalPrice
];
}
-
(
IBAction
)
onClickComplete
:
(
id
)
sender
{
KWMShopCartVC
*
ShopCartVC
=
(
KWMShopCartVC
*
)[
KWMBaseVC
findControllerBy
:[
KWMShopCartVC
kwmTag
]
fromStoryboard
:
@"ShopCart"
];
[
self
.
navigationController
pushViewController
:
ShopCartVC
animated
:
YES
];
}
}
-
(
void
)
initView
{
-
(
void
)
initView
{
...
@@ -70,20 +62,6 @@
...
@@ -70,20 +62,6 @@
}
}
}
}
//计算总价格
-
(
void
)
setTotalPrice
{
NSArray
*
shopCartList
=
(
NSMutableArray
*
)[[
KWMShoppingCart
sharedInstance
]
items
];
NSDecimalNumber
*
total
=
[
NSDecimalNumber
decimalNumberWithDecimal
:
@
(
0
).
decimalValue
];
for
(
KWMShopCartModel
*
model
in
shopCartList
)
{
if
(
model
.
line_price
)
{
total
=
[
total
decimalNumberByAdding
:
model
.
line_price
.
priceValue
];
}
else
{
total
=
[
total
decimalNumberByAdding
:[
model
.
price
.
priceValue
decimalNumberByMultiplyingBy
:[
NSDecimalNumber
decimalNumberWithString
:
@
(
model
.
quantity
).
stringValue
]]];
}
}
self
.
lbTotalPrice
.
text
=
total
.
priceFormatted
;
}
#pragma mark --KWMVariantsVCDelegate
#pragma mark --KWMVariantsVCDelegate
-
(
void
)
kwm_setVariant
:
(
KWMVariantsVC
*
)
variantsVC
variant
:
(
BUYProductVariant
*
)
variant
color
:
(
KWMColor
*
)
color
count
:
(
NSInteger
)
count
{
-
(
void
)
kwm_setVariant
:
(
KWMVariantsVC
*
)
variantsVC
variant
:
(
BUYProductVariant
*
)
variant
color
:
(
KWMColor
*
)
color
count
:
(
NSInteger
)
count
{
for
(
KWMWish
*
wish
in
self
.
wishArray
){
for
(
KWMWish
*
wish
in
self
.
wishArray
){
...
@@ -138,7 +116,6 @@
...
@@ -138,7 +116,6 @@
}
}
if
(
!
error
)
{
if
(
!
error
)
{
// [this showToast:@"添加成功"];
// [this showToast:@"添加成功"];
[
this
setTotalPrice
];
//[this.btnShopCart setTitle:cart.item_count.stringValue forState:UIControlStateNormal];
//[this.btnShopCart setTitle:cart.item_count.stringValue forState:UIControlStateNormal];
//callback(YES);
//callback(YES);
}
else
{
}
else
{
...
...
This diff is collapsed.
Click to expand it.
iCemarose/Class/UI/NewProduct/NewProduct.storyboard
View file @
d9d17148
This diff is collapsed.
Click to expand it.
iCemarose/Class/UI/ShopCart/ShopCart.storyboard
View file @
d9d17148
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
</device>
</device>
<dependencies>
<dependencies>
<deployment
identifier=
"iOS"
/>
<deployment
identifier=
"iOS"
/>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"1317
3
"
/>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"1317
4
"
/>
<capability
name=
"Constraints with non-1.0 multipliers"
minToolsVersion=
"5.1"
/>
<capability
name=
"Constraints with non-1.0 multipliers"
minToolsVersion=
"5.1"
/>
<capability
name=
"documents saved in the Xcode 8 format"
minToolsVersion=
"8.0"
/>
<capability
name=
"documents saved in the Xcode 8 format"
minToolsVersion=
"8.0"
/>
</dependencies>
</dependencies>
...
@@ -1646,7 +1646,7 @@
...
@@ -1646,7 +1646,7 @@
<autoresizingMask
key=
"autoresizingMask"
widthSizable=
"YES"
heightSizable=
"YES"
/>
<autoresizingMask
key=
"autoresizingMask"
widthSizable=
"YES"
heightSizable=
"YES"
/>
<subviews>
<subviews>
<view
contentMode=
"scaleToFill"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"puG-Vo-gdd"
>
<view
contentMode=
"scaleToFill"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"puG-Vo-gdd"
>
<rect
key=
"frame"
x=
"0.0"
y=
"2
34"
width=
"375"
height=
"20
0"
/>
<rect
key=
"frame"
x=
"0.0"
y=
"2
59"
width=
"375"
height=
"15
0"
/>
<subviews>
<subviews>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"你可能关心的问题"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"T4V-4O-WbC"
>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"你可能关心的问题"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"T4V-4O-WbC"
>
<rect
key=
"frame"
x=
"128"
y=
"0.0"
width=
"120"
height=
"21"
/>
<rect
key=
"frame"
x=
"128"
y=
"0.0"
width=
"120"
height=
"21"
/>
...
@@ -1682,7 +1682,7 @@
...
@@ -1682,7 +1682,7 @@
<action
selector=
"onClickGetTime:"
destination=
"iFV-ZT-0zX"
eventType=
"touchUpInside"
id=
"27h-gg-ltV"
/>
<action
selector=
"onClickGetTime:"
destination=
"iFV-ZT-0zX"
eventType=
"touchUpInside"
id=
"27h-gg-ltV"
/>
</connections>
</connections>
</button>
</button>
<button
opaque=
"NO"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"center"
contentVerticalAlignment=
"center"
buttonType=
"roundedRect"
lineBreakMode=
"middleTruncation"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"3ni-BC-6WW"
>
<button
hidden=
"YES"
opaque=
"NO"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"center"
contentVerticalAlignment=
"center"
buttonType=
"roundedRect"
lineBreakMode=
"middleTruncation"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"3ni-BC-6WW"
>
<rect
key=
"frame"
x=
"132"
y=
"177"
width=
"110"
height=
"26"
/>
<rect
key=
"frame"
x=
"132"
y=
"177"
width=
"110"
height=
"26"
/>
<constraints>
<constraints>
<constraint
firstAttribute=
"width"
constant=
"110"
id=
"N0D-kQ-eGq"
/>
<constraint
firstAttribute=
"width"
constant=
"110"
id=
"N0D-kQ-eGq"
/>
...
@@ -1704,7 +1704,7 @@
...
@@ -1704,7 +1704,7 @@
<constraint
firstItem=
"3ni-BC-6WW"
firstAttribute=
"centerX"
secondItem=
"puG-Vo-gdd"
secondAttribute=
"centerX"
id=
"CqI-1L-ERJ"
/>
<constraint
firstItem=
"3ni-BC-6WW"
firstAttribute=
"centerX"
secondItem=
"puG-Vo-gdd"
secondAttribute=
"centerX"
id=
"CqI-1L-ERJ"
/>
<constraint
firstItem=
"3ni-BC-6WW"
firstAttribute=
"top"
secondItem=
"3iW-9e-nhE"
secondAttribute=
"bottom"
constant=
"35"
id=
"ISt-z3-thL"
/>
<constraint
firstItem=
"3ni-BC-6WW"
firstAttribute=
"top"
secondItem=
"3iW-9e-nhE"
secondAttribute=
"bottom"
constant=
"35"
id=
"ISt-z3-thL"
/>
<constraint
firstItem=
"T4V-4O-WbC"
firstAttribute=
"centerX"
secondItem=
"puG-Vo-gdd"
secondAttribute=
"centerX"
id=
"MvE-KT-EgQ"
/>
<constraint
firstItem=
"T4V-4O-WbC"
firstAttribute=
"centerX"
secondItem=
"puG-Vo-gdd"
secondAttribute=
"centerX"
id=
"MvE-KT-EgQ"
/>
<constraint
firstAttribute=
"height"
constant=
"
20
0"
id=
"Wbe-Fv-YHk"
/>
<constraint
firstAttribute=
"height"
constant=
"
15
0"
id=
"Wbe-Fv-YHk"
/>
<constraint
firstItem=
"3MF-En-1mW"
firstAttribute=
"top"
secondItem=
"T4V-4O-WbC"
secondAttribute=
"bottom"
constant=
"34"
id=
"b1r-Lb-cP7"
/>
<constraint
firstItem=
"3MF-En-1mW"
firstAttribute=
"top"
secondItem=
"T4V-4O-WbC"
secondAttribute=
"bottom"
constant=
"34"
id=
"b1r-Lb-cP7"
/>
<constraint
firstItem=
"3MF-En-1mW"
firstAttribute=
"centerX"
secondItem=
"puG-Vo-gdd"
secondAttribute=
"centerX"
id=
"sVI-Au-PtI"
/>
<constraint
firstItem=
"3MF-En-1mW"
firstAttribute=
"centerX"
secondItem=
"puG-Vo-gdd"
secondAttribute=
"centerX"
id=
"sVI-Au-PtI"
/>
<constraint
firstItem=
"3iW-9e-nhE"
firstAttribute=
"top"
secondItem=
"3MF-En-1mW"
secondAttribute=
"bottom"
constant=
"35"
id=
"wpN-Nc-3yi"
/>
<constraint
firstItem=
"3iW-9e-nhE"
firstAttribute=
"top"
secondItem=
"3MF-En-1mW"
secondAttribute=
"bottom"
constant=
"35"
id=
"wpN-Nc-3yi"
/>
...
...
This diff is collapsed.
Click to expand it.
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