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
7a6398a3
Commit
7a6398a3
authored
Jan 21, 2016
by
陈俊俊
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
报表修改
parent
39619a0c
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
45 additions
and
18 deletions
+45
-18
IBTCommon.h
XFFruit/Utilities/IBTUIKit/IBTCommon.h
+1
-1
IBTCommon.m
XFFruit/Utilities/IBTUIKit/IBTCommon.m
+23
-0
SearchReportViewController.m
...ntrollers/Report/Controllers/SearchReportViewController.m
+1
-2
PasengerCell.m
XFFruit/ViewControllers/Report/Views/PasengerCell.m
+1
-1
RPassgerView.m
XFFruit/ViewControllers/Report/Views/RPassgerView.m
+3
-3
RSaleView.m
XFFruit/ViewControllers/Report/Views/RSaleView.m
+2
-2
SaleHeaderView.m
XFFruit/ViewControllers/Report/Views/SaleHeaderView.m
+3
-3
SaleViewCell.m
XFFruit/ViewControllers/Report/Views/SaleViewCell.m
+5
-5
FinishTimeView.m
XFFruit/ViewControllers/Survey/Views/FinishTimeView.m
+6
-1
No files found.
XFFruit/Utilities/IBTUIKit/IBTCommon.h
View file @
7a6398a3
...
@@ -50,5 +50,5 @@
...
@@ -50,5 +50,5 @@
+
(
NSString
*
)
getWeekFromDate
;
+
(
NSString
*
)
getWeekFromDate
;
+
(
NSInteger
)
getWeeks
:(
NSInteger
)
year
;
+
(
NSInteger
)
getWeeks
:(
NSInteger
)
year
;
+
(
NSString
*
)
weekdayStringFromDate
:(
NSDate
*
)
inputDate
;
+
(
NSString
*
)
weekdayStringFromDate
:(
NSDate
*
)
inputDate
;
+
(
NSString
*
)
countNumAndChangeformat
:(
NSString
*
)
num
;
@end
@end
XFFruit/Utilities/IBTUIKit/IBTCommon.m
View file @
7a6398a3
...
@@ -360,4 +360,27 @@
...
@@ -360,4 +360,27 @@
return
[
weekdays
objectAtIndex
:
theComponents
.
weekday
];
return
[
weekdays
objectAtIndex
:
theComponents
.
weekday
];
}
}
+
(
NSString
*
)
countNumAndChangeformat
:
(
NSString
*
)
num
{
int
count
=
0
;
long
long
int
a
=
num
.
longLongValue
;
while
(
a
!=
0
)
{
count
++
;
a
/=
10
;
}
NSMutableString
*
string
=
[
NSMutableString
stringWithString
:
num
];
NSMutableString
*
newstring
=
[
NSMutableString
string
];
while
(
count
>
3
)
{
count
-=
3
;
NSRange
rang
=
NSMakeRange
(
string
.
length
-
3
,
3
);
NSString
*
str
=
[
string
substringWithRange
:
rang
];
[
newstring
insertString
:
str
atIndex
:
0
];
[
newstring
insertString
:
@","
atIndex
:
0
];
[
string
deleteCharactersInRange
:
rang
];
}
[
newstring
insertString
:
string
atIndex
:
0
];
return
newstring
;
}
@end
@end
XFFruit/ViewControllers/Report/Controllers/SearchReportViewController.m
View file @
7a6398a3
...
@@ -123,8 +123,7 @@
...
@@ -123,8 +123,7 @@
[
IBTLoadingView
showProgressLabel
:
@"正在加载..."
];
[
IBTLoadingView
showProgressLabel
:
@"正在加载..."
];
NSDictionary
*
dict
=
@{
NSDictionary
*
dict
=
@{
@"path"
:
userUtil
.
belongOrgPath
,
@"path"
:
userUtil
.
belongOrgPath
,
@"code"
:
self
.
nameAndCode
,
@"codeOrName"
:
self
.
nameAndCode
,
@"name"
:
self
.
nameAndCode
,
@"pageNumber"
:
@
(
_currentPage
),
@"pageNumber"
:
@
(
_currentPage
),
@"pageSize"
:
@20
@"pageSize"
:
@20
};
};
...
...
XFFruit/ViewControllers/Report/Views/PasengerCell.m
View file @
7a6398a3
...
@@ -125,7 +125,7 @@
...
@@ -125,7 +125,7 @@
self
.
dqLabel
.
text
=
sale
.
orgCode
;
self
.
dqLabel
.
text
=
sale
.
orgCode
;
self
.
nameLabel
.
text
=
sale
.
orgName
;
self
.
nameLabel
.
text
=
sale
.
orgName
;
//客流量
//客流量
self
.
saleLabel
.
text
=
[
sale
.
passenger
stringValue
];
self
.
saleLabel
.
text
=
[
IBTCommon
countNumAndChangeformat
:[
sale
.
passenger
stringValue
]
];
//客流量比变化率
//客流量比变化率
if
([
sale
.
passengerChainSign
isEqualToString
:
ReportChainSignPlus
])
{
if
([
sale
.
passengerChainSign
isEqualToString
:
ReportChainSignPlus
])
{
[
self
.
lastWeekLabel
setImage
:[
UIImage
imageNamed
:
ReportChainPlusImage
]
forState
:
UIControlStateDisabled
];
[
self
.
lastWeekLabel
setImage
:[
UIImage
imageNamed
:
ReportChainPlusImage
]
forState
:
UIControlStateDisabled
];
...
...
XFFruit/ViewControllers/Report/Views/RPassgerView.m
View file @
7a6398a3
...
@@ -111,7 +111,7 @@
...
@@ -111,7 +111,7 @@
-
(
void
)
setPassengerWithCompass
:
(
Compass
*
)
compass
{
-
(
void
)
setPassengerWithCompass
:
(
Compass
*
)
compass
{
//客流数
//客流数
self
.
centerLabel
.
text
=
compass
.
passenger
?[
compass
.
passenger
stringValue
]:
@"---"
;
self
.
centerLabel
.
text
=
compass
.
passenger
?[
IBTCommon
countNumAndChangeformat
:[
compass
.
passenger
stringValue
]
]:
@"---"
;
//客流统计时间
//客流统计时间
NSString
*
weekday
=
@""
;
NSString
*
weekday
=
@""
;
...
@@ -151,7 +151,7 @@
...
@@ -151,7 +151,7 @@
if
([
IBTCommon
convertToDateFrom
:
compass
.
persalesdate
])
{
if
([
IBTCommon
convertToDateFrom
:
compass
.
persalesdate
])
{
weekday
=
[
IBTCommon
weekdayStringFromDate
:[
IBTCommon
convertToDateFrom
:
compass
.
persalesdate
]];
weekday
=
[
IBTCommon
weekdayStringFromDate
:[
IBTCommon
convertToDateFrom
:
compass
.
persalesdate
]];
}
}
self
.
dateLabel
.
text
=
compass
.
persalesdate
?[
NSString
stringWithFormat
:
@"%@%@
累计
客单价"
,
compass
.
persalesdate
,
weekday
]:
@"无"
;
self
.
dateLabel
.
text
=
compass
.
persalesdate
?[
NSString
stringWithFormat
:
@"%@%@客单价"
,
compass
.
persalesdate
,
weekday
]:
@"无"
;
//客单价环比变化率
//客单价环比变化率
if
([
compass
.
persalesChainSign
isEqualToString
:
ReportChainSignPlus
])
{
if
([
compass
.
persalesChainSign
isEqualToString
:
ReportChainSignPlus
])
{
[
self
.
lastWeekLabel
setImage
:[
UIImage
imageNamed
:
ReportChainPlusImage
]
forState
:
UIControlStateDisabled
];
[
self
.
lastWeekLabel
setImage
:[
UIImage
imageNamed
:
ReportChainPlusImage
]
forState
:
UIControlStateDisabled
];
...
@@ -184,7 +184,7 @@
...
@@ -184,7 +184,7 @@
if
([
IBTCommon
convertToDateFrom
:
compass
.
grossprofitdate
])
{
if
([
IBTCommon
convertToDateFrom
:
compass
.
grossprofitdate
])
{
weekday
=
[
IBTCommon
weekdayStringFromDate
:[
IBTCommon
convertToDateFrom
:
compass
.
grossprofitdate
]];
weekday
=
[
IBTCommon
weekdayStringFromDate
:[
IBTCommon
convertToDateFrom
:
compass
.
grossprofitdate
]];
}
}
self
.
dateLabel
.
text
=
compass
.
grossprofitdate
?[
NSString
stringWithFormat
:
@"%@%@
累计
毛利率"
,
compass
.
grossprofitdate
,
weekday
]:
@"无"
;
self
.
dateLabel
.
text
=
compass
.
grossprofitdate
?[
NSString
stringWithFormat
:
@"%@%@毛利率"
,
compass
.
grossprofitdate
,
weekday
]:
@"无"
;
//毛利率环比变化率
//毛利率环比变化率
if
([
compass
.
grossprofitChainSign
isEqualToString
:
ReportChainSignPlus
])
{
if
([
compass
.
grossprofitChainSign
isEqualToString
:
ReportChainSignPlus
])
{
[
self
.
lastWeekLabel
setImage
:[
UIImage
imageNamed
:
ReportChainPlusImage
]
forState
:
UIControlStateDisabled
];
[
self
.
lastWeekLabel
setImage
:[
UIImage
imageNamed
:
ReportChainPlusImage
]
forState
:
UIControlStateDisabled
];
...
...
XFFruit/ViewControllers/Report/Views/RSaleView.m
View file @
7a6398a3
...
@@ -154,7 +154,7 @@
...
@@ -154,7 +154,7 @@
self
.
dateLabel
.
text
=
compass
.
dataScope
?[
NSString
stringWithFormat
:
@"%@%@累计销售额"
,
compass
.
dataScope
,
weekday
]:
@"无"
;
self
.
dateLabel
.
text
=
compass
.
dataScope
?[
NSString
stringWithFormat
:
@"%@%@累计销售额"
,
compass
.
dataScope
,
weekday
]:
@"无"
;
//销售额
//销售额
self
.
centerLabel
.
text
=
compass
.
sales
?[
compass
.
sales
stringValue
]:
@"---"
;
self
.
centerLabel
.
text
=
compass
.
sales
?[
IBTCommon
countNumAndChangeformat
:[
compass
.
sales
stringValue
]
]:
@"---"
;
//销售环比变化率
//销售环比变化率
if
([
compass
.
salesChainSign
isEqualToString
:
ReportChainSignPlus
])
{
if
([
compass
.
salesChainSign
isEqualToString
:
ReportChainSignPlus
])
{
...
@@ -180,7 +180,7 @@
...
@@ -180,7 +180,7 @@
NSString
*
salesTargetStr
=
compass
.
salesTargetRate
?[
NSString
stringWithFormat
:
@"%@%%"
,
compass
.
salesTargetRate
]:
@"---"
;
NSString
*
salesTargetStr
=
compass
.
salesTargetRate
?[
NSString
stringWithFormat
:
@"%@%%"
,
compass
.
salesTargetRate
]:
@"---"
;
self
.
rateLabel
.
text
=
salesTargetStr
;
self
.
rateLabel
.
text
=
salesTargetStr
;
//单店日均销售
//单店日均销售
NSString
*
dailysalesPerStr
=
compass
.
dailysalesPerStore
?[
NSString
stringWithFormat
:
@"%@
%%
"
,
compass
.
dailysalesPerStore
]:
@"---"
;
NSString
*
dailysalesPerStr
=
compass
.
dailysalesPerStore
?[
NSString
stringWithFormat
:
@"%@"
,
compass
.
dailysalesPerStore
]:
@"---"
;
self
.
averageLabel
.
text
=
dailysalesPerStr
;
self
.
averageLabel
.
text
=
dailysalesPerStr
;
}
}
...
...
XFFruit/ViewControllers/Report/Views/SaleHeaderView.m
View file @
7a6398a3
...
@@ -53,9 +53,9 @@
...
@@ -53,9 +53,9 @@
[
self
.
contentView
addSubview
:
searLabel
];
[
self
.
contentView
addSubview
:
searLabel
];
self
.
totalLabel
=
searLabel
;
self
.
totalLabel
=
searLabel
;
CGFloat
width
=
(
ScreenSize
.
width
-
searLabel
.
right
-
3
5
)
/
3
;
CGFloat
width
=
(
ScreenSize
.
width
-
searLabel
.
right
-
2
5
)
/
3
;
rect
=
CGRectMake
(
searLabel
.
right
,
0
,
width
+
1
0
,
Sale_Header_Height
);
rect
=
CGRectMake
(
searLabel
.
right
,
0
,
width
+
2
0
,
Sale_Header_Height
);
UILabel
*
xsBtn
=
[
IBTCommon
labelWithTitle
:
@"销售额"
frame
:
rect
textFont
:
self
.
textFont
];
UILabel
*
xsBtn
=
[
IBTCommon
labelWithTitle
:
@"销售额"
frame
:
rect
textFont
:
self
.
textFont
];
xsBtn
.
textColor
=
ReportTitleColor
;
xsBtn
.
textColor
=
ReportTitleColor
;
[
self
.
contentView
addSubview
:
xsBtn
];
[
self
.
contentView
addSubview
:
xsBtn
];
...
@@ -65,7 +65,7 @@
...
@@ -65,7 +65,7 @@
bszLabel
.
textColor
=
ReportTitleColor
;
bszLabel
.
textColor
=
ReportTitleColor
;
[
self
.
contentView
addSubview
:
bszLabel
];
[
self
.
contentView
addSubview
:
bszLabel
];
rect
=
CGRectMake
(
bszLabel
.
right
,
0
,
width
-
1
0
,
Sale_Header_Height
);
rect
=
CGRectMake
(
bszLabel
.
right
,
0
,
width
-
2
0
,
Sale_Header_Height
);
UILabel
*
sclLabel
=
[
IBTCommon
labelWithTitle
:
@"达成率"
frame
:
rect
textFont
:
self
.
textFont
];
UILabel
*
sclLabel
=
[
IBTCommon
labelWithTitle
:
@"达成率"
frame
:
rect
textFont
:
self
.
textFont
];
sclLabel
.
textColor
=
ReportTitleColor
;
sclLabel
.
textColor
=
ReportTitleColor
;
[
self
.
contentView
addSubview
:
sclLabel
];
[
self
.
contentView
addSubview
:
sclLabel
];
...
...
XFFruit/ViewControllers/Report/Views/SaleViewCell.m
View file @
7a6398a3
...
@@ -68,9 +68,9 @@
...
@@ -68,9 +68,9 @@
self
.
dqLabel
=
[
IBTCommon
labelWithTitle
:
@"0101"
frame
:
rect
textFont
:
self
.
textFont
];
self
.
dqLabel
=
[
IBTCommon
labelWithTitle
:
@"0101"
frame
:
rect
textFont
:
self
.
textFont
];
[
self
.
contentView
addSubview
:
self
.
dqLabel
];
[
self
.
contentView
addSubview
:
self
.
dqLabel
];
CGFloat
width
=
(
ScreenSize
.
width
-
self
.
dqLabel
.
right
-
3
5
)
/
3
;
CGFloat
width
=
(
ScreenSize
.
width
-
self
.
dqLabel
.
right
-
2
5
)
/
3
;
rect
=
CGRectMake
(
self
.
dqLabel
.
right
,
0
,
width
+
1
0
,
Sale_Cell_Height
);
rect
=
CGRectMake
(
self
.
dqLabel
.
right
,
0
,
width
+
2
0
,
Sale_Cell_Height
);
self
.
saleLabel
=
[
IBTCommon
labelWithTitle
:
@"56,080"
frame
:
rect
textFont
:
self
.
textFont
];
self
.
saleLabel
=
[
IBTCommon
labelWithTitle
:
@"56,080"
frame
:
rect
textFont
:
self
.
textFont
];
[
self
.
contentView
addSubview
:
self
.
saleLabel
];
[
self
.
contentView
addSubview
:
self
.
saleLabel
];
...
@@ -81,12 +81,12 @@
...
@@ -81,12 +81,12 @@
[
self
.
contentView
addSubview
:
self
.
lastWeekLabel
];
[
self
.
contentView
addSubview
:
self
.
lastWeekLabel
];
rect
=
CGRectMake
(
self
.
lastWeekLabel
.
right
,
0
,
width
-
1
0
,
Sale_Cell_Height
);
rect
=
CGRectMake
(
self
.
lastWeekLabel
.
right
,
0
,
width
-
2
0
,
Sale_Cell_Height
);
self
.
rateLabel
=
[
IBTCommon
labelWithTitle
:
@"60%"
frame
:
rect
textFont
:
self
.
textFont
];
self
.
rateLabel
=
[
IBTCommon
labelWithTitle
:
@"60%"
frame
:
rect
textFont
:
self
.
textFont
];
self
.
rateLabel
.
textColor
=
GXF_COMMIT_COLOR
;
self
.
rateLabel
.
textColor
=
GXF_COMMIT_COLOR
;
[
self
.
contentView
addSubview
:
self
.
rateLabel
];
[
self
.
contentView
addSubview
:
self
.
rateLabel
];
rect
=
CGRectMake
(
self
.
rateLabel
.
right
,
0
,
3
5
,
Sale_Cell_Height
);
rect
=
CGRectMake
(
self
.
rateLabel
.
right
,
0
,
2
5
,
Sale_Cell_Height
);
self
.
detailBtn
=
[
IBTCommon
buttonWithTitle
:
@""
Image
:[
UIImage
imageNamed
:
@"more_detail"
]
frame
:
rect
fontSize
:
20
fontColor
:
ReportBgColor
];
self
.
detailBtn
=
[
IBTCommon
buttonWithTitle
:
@""
Image
:[
UIImage
imageNamed
:
@"more_detail"
]
frame
:
rect
fontSize
:
20
fontColor
:
ReportBgColor
];
self
.
detailBtn
.
titleLabel
.
font
=
[
UIFont
boldSystemFontOfSize
:
15
];
self
.
detailBtn
.
titleLabel
.
font
=
[
UIFont
boldSystemFontOfSize
:
15
];
[
self
.
contentView
addSubview
:
self
.
detailBtn
];
[
self
.
contentView
addSubview
:
self
.
detailBtn
];
...
@@ -122,7 +122,7 @@
...
@@ -122,7 +122,7 @@
self
.
saleLabel
.
textColor
=
GXF_NAVIGAYION_COLOR
;
self
.
saleLabel
.
textColor
=
GXF_NAVIGAYION_COLOR
;
}
}
//销售额
//销售额
self
.
saleLabel
.
text
=
sale
.
sales
?[
sale
.
sales
stringValue
]
:
@"0"
;
self
.
saleLabel
.
text
=
sale
.
sales
?[
IBTCommon
countNumAndChangeformat
:[
sale
.
sales
stringValue
]
]
:
@"0"
;
NSString
*
salesYoStr
=
[
NSString
stringWithFormat
:
@"%@%%"
,
sale
.
salesChainRate
];
NSString
*
salesYoStr
=
[
NSString
stringWithFormat
:
@"%@%%"
,
sale
.
salesChainRate
];
[
self
.
lastWeekLabel
setTitle
:
salesYoStr
forState
:
UIControlStateNormal
];
[
self
.
lastWeekLabel
setTitle
:
salesYoStr
forState
:
UIControlStateNormal
];
...
...
XFFruit/ViewControllers/Survey/Views/FinishTimeView.m
View file @
7a6398a3
...
@@ -234,7 +234,12 @@
...
@@ -234,7 +234,12 @@
self
.
currentYear
=
[[
self
.
dateStr
substringWithRange
:
NSMakeRange
(
0
,
4
)]
intValue
];
self
.
currentYear
=
[[
self
.
dateStr
substringWithRange
:
NSMakeRange
(
0
,
4
)]
intValue
];
self
.
selectedYear
=
self
.
currentYear
;
self
.
selectedYear
=
self
.
currentYear
;
self
.
currentMonth
=
[[
self
.
dateStr
substringWithRange
:
NSMakeRange
(
5
,
2
)]
intValue
];
if
(
self
.
dateStr
.
length
<=
6
)
{
self
.
currentMonth
=
[[
self
.
dateStr
substringWithRange
:
NSMakeRange
(
5
,
1
)]
intValue
];
}
else
{
self
.
currentMonth
=
[[
self
.
dateStr
substringWithRange
:
NSMakeRange
(
5
,
2
)]
intValue
];
}
[
pickerView
selectRow
:(
self
.
currentYear
-
kStartYear
)
inComponent
:
0
animated
:
YES
];
[
pickerView
selectRow
:(
self
.
currentYear
-
kStartYear
)
inComponent
:
0
animated
:
YES
];
...
...
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