Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
O
Opple-iOS
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
张杰
Opple-iOS
Commits
d662c6ea
Commit
d662c6ea
authored
Jul 28, 2016
by
曹云霄
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
debug
parent
c7d75cd2
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
174 additions
and
184 deletions
+174
-184
AllCustomerViewController.m
Lighting/Class/AllCustomerViewController.m
+4
-2
ClientDetailsTableViewCell.m
Lighting/Class/ClientDetailsTableViewCell.m
+1
-1
ClientViewController.m
Lighting/Class/ClientViewController.m
+104
-125
ClientdetailsViewController.m
Lighting/Class/ClientdetailsViewController.m
+2
-1
CommodityListTableViewCell.m
Lighting/Class/CommodityListTableViewCell.m
+1
-1
CustomerOrderViewController.m
Lighting/Class/CustomerOrderViewController.m
+2
-1
ProductLibraryViewController.m
Lighting/Class/ProductLibraryViewController.m
+2
-1
SceneLibraryViewController.m
Lighting/Class/SceneLibraryViewController.m
+2
-1
ShoppingViewController.m
Lighting/Class/Shoppingcart/ShoppingViewController.m
+0
-1
CustomTabbarController.m
Lighting/Class/Tabbar/CustomTabbarController.m
+40
-43
Toolview.m
Lighting/Class/Tabbar/Toolview.m
+0
-1
Info.plist
Lighting/Lighting/Info.plist
+8
-0
BaseViewController.m
Lighting/Tools/BaseViewController.m
+3
-1
QRViewController.m
Lighting/Tools/QRViewController.m
+1
-3
SceneViewController.m
Lighting/Tools/SceneViewController.m
+4
-2
No files found.
Lighting/Class/AllCustomerViewController.m
View file @
d662c6ea
...
...
@@ -121,7 +121,6 @@
headerRefresh
.
lastUpdatedTimeLabel
.
hidden
=
YES
;
self
.
allCustomerTableview
.
mj_header
=
headerRefresh
;
[
self
.
allCustomerTableview
.
mj_header
beginRefreshing
];
self
.
allCustomerTableview
.
mj_footer
.
automaticallyHidden
=
YES
;
//上拉加载
self
.
allCustomerTableview
.
mj_footer
=
[
MJRefreshAutoNormalFooter
footerWithRefreshingBlock
:
^
{
...
...
@@ -136,6 +135,7 @@
[
self
getShoppersAssociatedCustomer
:
self
.
conditionModel
isRemove
:
NO
];
}
}];
self
.
allCustomerTableview
.
mj_footer
.
automaticallyHidden
=
YES
;
}
...
...
@@ -253,7 +253,9 @@
UIPopoverPresentationController
*
pop
=
datevc
.
popoverPresentationController
;
pop
.
permittedArrowDirections
=
UIPopoverArrowDirectionAny
;
pop
.
sourceView
=
datevc
.
view
;
dispatch_async
(
dispatch_get_main_queue
(),
^
{
[
self
presentViewController
:
datevc
animated
:
YES
completion
:
nil
];
});
}
...
...
Lighting/Class/ClientDetailsTableViewCell.m
View file @
d662c6ea
...
...
@@ -27,7 +27,7 @@
self
.
goodsCraneQuotation
.
text
=
[
NSString
stringWithFormat
:
@"¥%.2f"
,[
_model
.
goods
.
tagPrice
floatValue
]];
self
.
goodsSpecifications
.
text
=
_model
.
goods
.
size
;
self
.
clinchPrice
.
text
=
[
NSString
stringWithFormat
:
@"¥%.2f"
,[
_model
.
goods
.
costPrice
floatValue
]];
self
.
goodsNumber
.
text
=
[
NSString
stringWithFormat
:
@"%
d"
,
_model
.
goodsNum
];
self
.
goodsNumber
.
text
=
[
NSString
stringWithFormat
:
@"%
ld"
,(
long
)
_model
.
goodsNum
];
self
.
goodsPrice
.
text
=
[
NSString
stringWithFormat
:
@"¥%.2f"
,[
_model
.
goods
.
costPrice
floatValue
]
*
_model
.
goodsNum
];
...
...
Lighting/Class/ClientViewController.m
View file @
d662c6ea
This diff is collapsed.
Click to expand it.
Lighting/Class/ClientdetailsViewController.m
View file @
d662c6ea
...
...
@@ -156,7 +156,6 @@
headerRefresh
.
stateLabel
.
hidden
=
YES
;
headerRefresh
.
lastUpdatedTimeLabel
.
hidden
=
YES
;
self
.
ClientdetailsTableview
.
mj_header
=
headerRefresh
;
self
.
ClientdetailsTableview
.
mj_footer
.
automaticallyHidden
=
YES
;
//进入刷新状态
[
self
.
ClientdetailsTableview
.
mj_header
beginRefreshing
];
//上拉加载
...
...
@@ -195,6 +194,8 @@
}
}
}];
self
.
ClientdetailsTableview
.
mj_footer
.
automaticallyHidden
=
YES
;
}
-
(
UITableViewCell
*
)
tableView
:
(
UITableView
*
)
tableView
cellForRowAtIndexPath
:
(
NSIndexPath
*
)
indexPath
...
...
Lighting/Class/CommodityListTableViewCell.m
View file @
d662c6ea
...
...
@@ -24,7 +24,7 @@
self
.
goodsName
.
text
=
_model
.
goods
.
name
;
self
.
specifications
.
text
=
_model
.
goods
.
size
;
self
.
goodsCode
.
text
=
_model
.
goods
.
code
;
self
.
goodsNumber
.
text
=
[
NSString
stringWithFormat
:
@"数量 X%
d"
,
_model
.
goodsNum
];
self
.
goodsNumber
.
text
=
[
NSString
stringWithFormat
:
@"数量 X%
ld"
,(
long
)
_model
.
goodsNum
];
self
.
clinchPrice
.
text
=
[
NSString
stringWithFormat
:
@"成交价 ¥%.2f"
,[
_model
.
costPrice
floatValue
]];
//计算总价格
NSInteger
number
=
_model
.
goodsNum
;
...
...
Lighting/Class/CustomerOrderViewController.m
View file @
d662c6ea
...
...
@@ -111,7 +111,6 @@
headerRefresh
.
lastUpdatedTimeLabel
.
hidden
=
YES
;
self
.
customerOrderTableView
.
mj_header
=
headerRefresh
;
[
self
.
customerOrderTableView
.
mj_header
beginRefreshing
];
self
.
customerOrderTableView
.
mj_footer
.
automaticallyHidden
=
YES
;
//上拉加载
self
.
customerOrderTableView
.
mj_footer
=
[
MJRefreshAutoNormalFooter
footerWithRefreshingBlock
:
^
{
...
...
@@ -126,6 +125,8 @@
[
weakSelf
getGuideAllcustomerOrder
:
NO
WithorderBill
:
weakSelf
.
model
];
}
}];
self
.
customerOrderTableView
.
mj_footer
.
automaticallyHidden
=
YES
;
}
...
...
Lighting/Class/ProductLibraryViewController.m
View file @
d662c6ea
...
...
@@ -284,7 +284,6 @@
headerRefresh
.
lastUpdatedTimeLabel
.
hidden
=
YES
;
self
.
productCollectionView
.
mj_header
=
headerRefresh
;
[
self
.
productCollectionView
.
mj_header
beginRefreshing
];
self
.
productCollectionView
.
mj_footer
.
automaticallyHidden
=
YES
;
//上拉加载
self
.
productCollectionView
.
mj_footer
=
[
MJRefreshAutoNormalFooter
footerWithRefreshingBlock
:
^
{
...
...
@@ -344,6 +343,8 @@
}
}
}];
self
.
productCollectionView
.
mj_footer
.
automaticallyHidden
=
YES
;
}
...
...
Lighting/Class/SceneLibraryViewController.m
View file @
d662c6ea
...
...
@@ -144,7 +144,6 @@
headerRefresh
.
lastUpdatedTimeLabel
.
hidden
=
YES
;
self
.
seceneLibararyCollectionView
.
mj_header
=
headerRefresh
;
[
self
.
seceneLibararyCollectionView
.
mj_header
beginRefreshing
];
self
.
seceneLibararyCollectionView
.
mj_footer
.
automaticallyHidden
=
YES
;
//上拉加载
self
.
seceneLibararyCollectionView
.
mj_footer
=
[
MJRefreshAutoNormalFooter
footerWithRefreshingBlock
:
^
{
...
...
@@ -160,6 +159,8 @@
[
self
getSceneLibrarydatas
:
self
.
conditionModel
isRemove
:
NO
];
}
}];
self
.
seceneLibararyCollectionView
.
mj_footer
.
automaticallyHidden
=
YES
;
}
#pragma mark -获取场景筛选数据
...
...
Lighting/Class/Shoppingcart/ShoppingViewController.m
View file @
d662c6ea
...
...
@@ -187,7 +187,6 @@
{
ProductDetailsViewController
*
productDetails
=
[[
self
getStoryboardWithName
]
instantiateViewControllerWithIdentifier
:
@"productdetails"
];
productDetails
.
goodsID
=
[[
self
.
shopResponseArray
objectAtIndex_opple
:
indexPath
.
row
]
goodsId
];
// productDetails.inventory = [[self.shopResponseArray objectAtIndex_opple:indexPath.row] inv];
[
self
.
navigationController
pushViewController
:
productDetails
animated
:
YES
];
}
...
...
Lighting/Class/Tabbar/CustomTabbarController.m
View file @
d662c6ea
...
...
@@ -22,6 +22,7 @@
#import "BaseViewController.h"
#import "QRViewController.h"
#import "ExperienceCentreViewController.h"
#import <AVFoundation/AVFoundation.h>
@interface
CustomTabbarController
()
<
TabbarButtonClickdelegate
,
ChangpasswordDelegate
,
CancelButtondelegate
,
UITextFieldDelegate
>
...
...
@@ -37,6 +38,11 @@
*/
@property
(
nonatomic
,
strong
)
NSArray
*
vcArray
;
/**
* 工具栏
*/
@property
(
nonatomic
,
strong
)
Toolview
*
toolview
;
@end
@implementation
CustomTabbarController
...
...
@@ -94,12 +100,11 @@
-
(
void
)
uiConfigAction
{
self
.
tabBar
.
frame
=
CGRectMake
(
Zero
,
Zero
,
ScreenWidth
,
NavigationHeight
);
Toolview
*
toolview
=
[[
Toolview
alloc
]
initWithFrame
:
CGRectMake
(
Zero
,
Zero
,
ScreenWidth
,
NavigationHeight
)];
toolview
.
delegate
=
self
;
toolview
.
inputField
.
delegate
=
self
;
self
.
toolview
=
[[
Toolview
alloc
]
initWithFrame
:
CGRectMake
(
Zero
,
Zero
,
ScreenWidth
,
NavigationHeight
)];
self
.
toolview
.
delegate
=
self
;
self
.
toolview
.
inputField
.
delegate
=
self
;
self
.
delegate
=
self
;
[
self
.
tabBar
addSubview
:
toolview
];
[
self
.
tabBar
addSubview
:
self
.
toolview
];
//显示体验中心
[[
NSNotificationCenter
defaultCenter
]
addObserver
:
self
selector
:
@selector
(
ShowFollowHeart
:
)
name
:
@"FollowHeartVC"
object
:
nil
];
}
...
...
@@ -113,7 +118,6 @@
SearchViewController
*
searchVC
=
[
storyboard
instantiateViewControllerWithIdentifier
:[
self
.
identifierArray
objectAtIndex_opple
:
0
]];
ShoppingViewController
*
shoppingVC
=
[
storyboard
instantiateViewControllerWithIdentifier
:[
self
.
identifierArray
objectAtIndex_opple
:
1
]];
ClientViewController
*
clientVC
=
[
storyboard
instantiateViewControllerWithIdentifier
:[
self
.
identifierArray
objectAtIndex_opple
:
2
]];
SceneLibraryViewController
*
sceneVC
=
[
storyboard
instantiateViewControllerWithIdentifier
:[
self
.
identifierArray
objectAtIndex_opple
:
4
]];
ProductLibraryViewController
*
productVC
=
[
storyboard
instantiateViewControllerWithIdentifier
:[
self
.
identifierArray
objectAtIndex_opple
:
5
]];
CustomerManagementViewController
*
customerVC
=
[
storyboard
instantiateViewControllerWithIdentifier
:[
self
.
identifierArray
objectAtIndex_opple
:
6
]];
...
...
@@ -142,9 +146,7 @@
#pragma mark -移除系统自带的UITabBarButton
-
(
void
)
viewWillLayoutSubviews
{
[
super
viewWillLayoutSubviews
];
for
(
UIView
*
view
in
self
.
tabBar
.
subviews
)
{
if
([
view
isKindOfClass
:
NSClassFromString
(
@"UITabBarButton"
)])
{
[
view
removeFromSuperview
];
}
...
...
@@ -155,13 +157,14 @@
#pragma amrk -TabbarButtonClickdelegate代理
-
(
void
)
ButtonClickAction
:
(
NSInteger
)
Buttontag
withButton
:
(
UIButton
*
)
button
{
[
self
.
toolview
.
inputField
resignFirstResponder
];
[
self
dismissViewControllerAnimated
:
NO
completion
:
nil
];
_Newbutton
=
button
;
switch
(
Buttontag
)
{
//右侧视图
case
100
:
[
self
dismissViewControllerAnimated
:
YES
completion
:
nil
];
[
SHARED_APPDELEGATE
.
mmdrawer
toggleDrawerSide
:
MMDrawerSideRight
animated
:
YES
completion
:
nil
];
break
;
...
...
@@ -185,7 +188,6 @@
//我的客户
case
102
:
[
self
dismissViewControllerAnimated
:
YES
completion
:
nil
];
self
.
selectedIndex
=
6
;
break
;
...
...
@@ -193,7 +195,6 @@
//购物车
case
103
:
[
self
dismissViewControllerAnimated
:
YES
completion
:
nil
];
//必须设置当前客户才能跳转到购物车
if
(
!
[
Shoppersmanager
manager
].
currentCustomer
)
{
...
...
@@ -255,12 +256,26 @@
}];
}
#pragma mark -二维码扫描
-
(
void
)
QrcodeButtonClick
{
__weak
typeof
(
self
)
weakSelf
=
self
;
//判断权限
AVAuthorizationStatus
status
=
[
AVCaptureDevice
authorizationStatusForMediaType
:
AVMediaTypeVideo
];
if
(
status
!=
AVAuthorizationStatusAuthorized
)
{
UIAlertController
*
alertVC
=
[
UIAlertController
alertControllerWithTitle
:
@"提示"
message
:
@"请在iPad的“设置-隐私-相机”选项中,允许欧立方访问你的相机"
preferredStyle
:
UIAlertControllerStyleAlert
];
[
alertVC
addAction
:[
UIAlertAction
actionWithTitle
:
@"去设置"
style
:
UIAlertActionStyleDestructive
handler
:
^
(
UIAlertAction
*
_Nonnull
action
)
{
NSURL
*
url
=
[
NSURL
URLWithString
:
@"prefs:root=com.gomore.opple"
];
dispatch_after
(
0
.
2
,
dispatch_get_main_queue
(),
^
{
[[
UIApplication
sharedApplication
]
openURL
:
url
];
});
}]];
[
alertVC
addAction
:[
UIAlertAction
actionWithTitle
:
@"知道了"
style
:
UIAlertActionStyleCancel
handler
:
^
(
UIAlertAction
*
_Nonnull
action
)
{
[
weakSelf
dismissViewControllerAnimated
:
YES
completion
:
nil
];
}]];
[
self
presentViewController
:
alertVC
animated
:
YES
completion
:
nil
];
}
else
{
QRViewController
*
qrVC
=
[[
QRViewController
alloc
]
initWithScanCompleteHandler
:
^
(
NSString
*
url
)
{
[
self
dismissViewControllerAnimated
:
YES
completion
:
^
{
...
...
@@ -269,7 +284,10 @@
self
.
selectedIndex
=
4
;
}];
}];
[
self
presentViewController
:
qrVC
animated
:
YES
completion
:
nil
];
dispatch_async
(
dispatch_get_main_queue
(),
^
{
[
weakSelf
presentViewController
:
qrVC
animated
:
YES
completion
:
nil
];
});
}
}
...
...
@@ -287,7 +305,6 @@
#pragma mark -Search按钮
-
(
BOOL
)
textFieldShouldReturn
:
(
UITextField
*
)
textField
{
//搜索
if
(
textField
.
text
.
length
!=
0
)
{
...
...
@@ -340,28 +357,8 @@
UIPopoverPresentationController
*
popover
=
ExperienceCenter
.
popoverPresentationController
;
popover
.
sourceView
=
ExperienceCenter
.
view
;
[
self
presentViewController
:
ExperienceCenter
animated
:
YES
completion
:
nil
];
// FollowHeartViewController *followVC = [storyboard instantiateViewControllerWithIdentifier:[self.identifierArray objectAtIndex_opple:3]];
// [self presentViewController:followVC animated:YES completion:nil];
}
}
#pragma mark -禁止跳转
//- (void)
-
(
void
)
didReceiveMemoryWarning
{
[
super
didReceiveMemoryWarning
];
// Dispose of any resources that can be recreated.
}
/*
#pragma mark - Navigation
// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
// Get the new view controller using [segue destinationViewController].
// Pass the selected object to the new view controller.
}
*/
@end
Lighting/Class/Tabbar/Toolview.m
View file @
d662c6ea
...
...
@@ -184,7 +184,6 @@
}
}
//点击代理
if
([
self
.
delegate
respondsToSelector
:
@selector
(
ButtonClickAction
:
withButton
:
)])
{
...
...
Lighting/Lighting/Info.plist
View file @
d662c6ea
...
...
@@ -40,6 +40,14 @@
<
string
>
wb1111393286
<
/string
>
<
/
a
rr
a
y
>
<
/
d
i
c
t
>
<
d
i
c
t
>
<
k
e
y
>
CFBundleTypeRole
<
/k
e
y
>
<
string
>
Editor
<
/string
>
<
k
e
y
>
CFBundleURLSchemes
<
/k
e
y
>
<
a
rr
a
y
>
<
string
>
prefs
<
/string
>
<
/
a
rr
a
y
>
<
/
d
i
c
t
>
<
/
a
rr
a
y
>
<
k
e
y
>
LSApplicationQueriesSchemes
<
/k
e
y
>
<
a
rr
a
y
>
...
...
Lighting/Tools/BaseViewController.m
View file @
d662c6ea
...
...
@@ -487,7 +487,9 @@
[
self
dismissViewControllerAnimated
:
YES
completion
:
nil
];
}]];
dispatch_async
(
dispatch_get_main_queue
(),
^
{
[
self
presentViewController
:
alertVC
animated
:
YES
completion
:
nil
];
});
}
...
...
Lighting/Tools/QRViewController.m
View file @
d662c6ea
...
...
@@ -134,10 +134,8 @@
_device
=
[
AVCaptureDevice
defaultDeviceWithMediaType
:
AVMediaTypeVideo
];
// Input
_input
=
[
AVCaptureDeviceInput
deviceInputWithDevice
:
self
.
device
error
:
nil
];
// Output
_output
=
[[
AVCaptureMetadataOutput
alloc
]
init
];
[
_output
setMetadataObjectsDelegate
:
self
queue
:
dispatch_get_main_queue
()];
...
...
Lighting/Tools/SceneViewController.m
View file @
d662c6ea
...
...
@@ -289,7 +289,6 @@
headerRefresh
.
lastUpdatedTimeLabel
.
hidden
=
YES
;
self
.
sceneOrProductClollectionView
.
mj_header
=
headerRefresh
;
[
self
.
sceneOrProductClollectionView
.
mj_header
beginRefreshing
];
self
.
sceneOrProductClollectionView
.
mj_footer
.
automaticallyHidden
=
YES
;
//上拉加载
self
.
sceneOrProductClollectionView
.
mj_footer
=
[
MJRefreshAutoNormalFooter
footerWithRefreshingBlock
:
^
{
...
...
@@ -306,6 +305,8 @@
[
weakSelf
getSceneLibrarydatas
:
weakSelf
.
conditionModel
isRemove
:
NO
];
}
}];
self
.
sceneOrProductClollectionView
.
mj_footer
.
automaticallyHidden
=
YES
;
}
...
...
@@ -382,7 +383,6 @@
headerRefresh
.
lastUpdatedTimeLabel
.
hidden
=
YES
;
self
.
sceneOrProductClollectionView
.
mj_header
=
headerRefresh
;
[
self
.
sceneOrProductClollectionView
.
mj_header
beginRefreshing
];
self
.
sceneOrProductClollectionView
.
mj_footer
.
automaticallyHidden
=
YES
;
//上拉加载
self
.
sceneOrProductClollectionView
.
mj_footer
=
[
MJRefreshAutoNormalFooter
footerWithRefreshingBlock
:
^
{
...
...
@@ -399,6 +399,8 @@
[
weakSelf
getGoodsListDatasisRemove
:
NO
Withobject
:
weakSelf
.
goodsModel
];
}
}];
self
.
sceneOrProductClollectionView
.
mj_footer
.
automaticallyHidden
=
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