Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
X
xffruit
Project
Project
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
张杰
xffruit
Commits
ec504896
Commit
ec504896
authored
Mar 16, 2016
by
Sandy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
采购单费用明细加到其它费用里面
parent
370b3b4b
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
38 additions
and
5 deletions
+38
-5
ICRAppMacro.h
XFFruit/Macro/ICRAppMacro.h
+2
-2
NewPurchaseViewController.m
...trollers/Purchase/Controllers/NewPurchaseViewController.m
+19
-2
BottomPurchaseView.m
XFFruit/ViewControllers/Purchase/Views/BottomPurchaseView.m
+4
-0
TopPurchaseView.m
XFFruit/ViewControllers/Purchase/Views/TopPurchaseView.m
+11
-1
NewCostViewController.m
...Controllers/Transport/Controllers/NewCostViewController.m
+2
-0
No files found.
XFFruit/Macro/ICRAppMacro.h
View file @
ec504896
...
...
@@ -23,14 +23,14 @@
#define ICR_IMAGE_BG_COLOR [UIColor colorWithW:242 a:1]
//********阿里云内部测试环境********
//
#define HTTP_REST_API_BASE_URL @"http://218.244.151.129:7580/cruiser-server/rest"
#define HTTP_REST_API_BASE_URL @"http://218.244.151.129:7580/cruiser-server/rest"
//********现场测试环境********
//#define HTTP_REST_API_BASE_URL @"http://122.224.171.126:7280/cruiser-server/rest"
//********现场正式环境*********
#define HTTP_REST_API_BASE_URL @"http://122.224.171.126:7380/cruiser-server/rest"
//
#define HTTP_REST_API_BASE_URL @"http://122.224.171.126:7380/cruiser-server/rest"
#define HTTP_REST_REPORT_BASE_URL @"http://122.224.171.126:7380"
// HTTP
...
...
XFFruit/ViewControllers/Purchase/Controllers/NewPurchaseViewController.m
View file @
ec504896
...
...
@@ -188,18 +188,35 @@ typedef enum : NSUInteger {
}
//添加商品明细,更新上部显示的费用
-
(
void
)
setProductTotalPrice
:
(
NSNotification
*
)
fication
{
//计算总金额
float
otherPrice
=
0
;
// if (_aBottomView.costVC.costArr.count == 0) {
// otherPrice = [_purchaseView.otherPriceFiled.text floatValue];
// }else{
for
(
FeeAcountDetail
*
cost
in
_aBottomView
.
costVC
.
costArr
)
{
otherPrice
+=
[
cost
.
leftmoney
floatValue
];
}
_purchaseView
.
otherPriceFiled
.
text
=
[
NSString
stringWithFormat
:
@"%.2f"
,
otherPrice
];
// }
//其他费用 + 商品总金额
float
otherPrice
=
[
_purchaseView
.
otherPriceFiled
.
text
floatValue
];
NSMutableArray
*
purchaseProduct
=
_aBottomView
.
productVC
.
productArr
;
float
totalPrice
=
0
;
for
(
PurchaseBillProduct
*
billProduct
in
purchaseProduct
)
{
totalPrice
+=
[
billProduct
.
total
floatValue
];
}
_purchaseView
.
purchasePriceLabel
.
text
=
[
NSString
stringWithFormat
:
@"%.2f"
,
totalPrice
+
otherPrice
];
_purchaseView
.
chargePurchase
=
[
NSNumber
numberWithFloat
:
otherPrice
];
_purchaseView
.
total
=
[
NSNumber
numberWithFloat
:
totalPrice
+
otherPrice
];
_purchaseView
.
chargePurchase
=
[
NSNumber
numberWithFloat
:
otherPrice
];
}
-
(
void
)
addPurchaseProduct
:
(
NSNotification
*
)
fication
{
...
...
XFFruit/ViewControllers/Purchase/Views/BottomPurchaseView.m
View file @
ec504896
...
...
@@ -138,7 +138,11 @@
[
self
.
costVC
.
tableView
reloadData
];
}
}
[[
NSNotificationCenter
defaultCenter
]
postNotificationName
:
SetProductTotalPrice
object
:
nil
];
}
//删除
-
(
void
)
refreshDelCost
:
(
FeeAcountDetail
*
)
fee
indexPath
:
(
NSIndexPath
*
)
indexPath
{
if
(
indexPath
)
{
...
...
XFFruit/ViewControllers/Purchase/Views/TopPurchaseView.m
View file @
ec504896
...
...
@@ -58,6 +58,13 @@
[
self
addSubview
:
_tableView
];
}
#pragma mark - 协议方法
-
(
CGFloat
)
tableView
:
(
UITableView
*
)
tableView
heightForRowAtIndexPath
:
(
NSIndexPath
*
)
indexPath
{
if
(
indexPath
.
row
==
4
)
{
return
0
.
01
;
}
return
44
;
}
-
(
NSInteger
)
numberOfSectionsInTableView
:
(
UITableView
*
)
tableView
{
return
1
;
}
...
...
@@ -90,13 +97,16 @@
textField
.
delegate
=
self
;
[
cell
.
contentView
addSubview
:
textField
];
self
.
otherPriceFiled
=
textField
;
self
.
otherPriceFiled
.
placeholder
=
@"请输入其他费用"
;
self
.
otherPriceFiled
.
placeholder
=
@"其他费用"
;
self
.
otherPriceFiled
.
enabled
=
NO
;
[
self
.
otherPriceFiled
addTarget
:
self
action
:
@selector
(
boxValueChanged
:
)
forControlEvents
:
UIControlEventEditingChanged
];
UILabel
*
label
=
[[
UILabel
alloc
]
initWithFrame
:
CGRectMake
(
CGRectGetMaxX
(
textField
.
frame
)
+
5
,
0
,
20
,
TableHeight
)];
label
.
text
=
@"元"
;
label
.
textColor
=
GXF_CONTENT_COLOR
;
label
.
font
=
GXF_FIFTEENTEN_SIZE
;
[
cell
.
contentView
removeAllSubViews
];
[
cell
.
contentView
addSubview
:
label
];
cell
.
alpha
=
0
;
}
else
if
(
indexPath
.
row
==
_dataArr
.
count
-
1
){
self
.
remarkTextView
=
[[
HPGrowingTextView
alloc
]
initWithFrame
:
CGRectMake
(
100
+
LeftMargin
,
0
,
ScreenSize
.
width
-
100
-
LeftMargin
*
2
-
15
,
TableHeight
)];
...
...
XFFruit/ViewControllers/Transport/Controllers/NewCostViewController.m
View file @
ec504896
...
...
@@ -101,6 +101,8 @@ typedef enum : NSUInteger {
default
:
break
;
}
[[
NSNotificationCenter
defaultCenter
]
postNotificationName
:
SetProductTotalPrice
object
:
nil
];
}
-
(
void
)
clearInfomation
{
_chooseCostLabel
.
text
=
@"选择费用类型"
;
...
...
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