Commit d8081bf6 authored by 勾芒's avatar 勾芒

debug

parent 0ee6510f
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="3.0" toolsVersion="10116" systemVersion="15E65" targetRuntime="iOS.CocoaTouch.iPad" propertyAccessControl="none">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="3.0" toolsVersion="10116" systemVersion="15F34" targetRuntime="iOS.CocoaTouch.iPad" propertyAccessControl="none">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>
</dependencies>
......@@ -42,28 +42,28 @@
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="发票类型:" textAlignment="right" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="Zdn-MM-Xad">
<rect key="frame" x="370" y="13" width="70" height="17"/>
<rect key="frame" x="401" y="13" width="70" height="17"/>
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="7ty-c7-Sgn">
<rect key="frame" x="432" y="13" width="170" height="17"/>
<rect key="frame" x="461" y="13" width="170" height="17"/>
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<color key="textColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="支付方式:" textAlignment="right" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="S5V-nq-hin">
<rect key="frame" x="370" y="43" width="70" height="17"/>
<rect key="frame" x="401" y="43" width="70" height="17"/>
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="MPi-P0-LEg">
<rect key="frame" x="432" y="43" width="170" height="17"/>
<rect key="frame" x="461" y="43" width="170" height="17"/>
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<color key="textColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/>
......
......@@ -47,7 +47,7 @@
switch (btnTag) {
case 100: //返回
{
[self.view removeFromSuperview];
[self dismissViewControllerAnimated:YES completion:nil];
}
break;
case 101: //购物车
......@@ -106,13 +106,13 @@
[self.leftSubView.shareBtn setBackgroundImage:[UIImage imageNamed:@"selectShare"] forState:UIControlStateNormal];
ShareViewController *shareVC = [[ShareViewController alloc]init];
shareVC.delegate = self;
shareVC.preferredContentSize = CGSizeMake(280, 150);
shareVC.preferredContentSize = CGSizeMake(280, 130);
shareVC.modalPresentationStyle = UIModalPresentationPopover;
UIPopoverPresentationController *pop = shareVC.popoverPresentationController;
// 箭头方向
pop.permittedArrowDirections = UIPopoverArrowDirectionAny;
pop.permittedArrowDirections = UIPopoverArrowDirectionLeft;
pop.sourceView = shareVC.view;
pop.barButtonItem = [[UIBarButtonItem alloc]initWithCustomView:sender];
pop.sourceRect = CGRectMake(sender.mj_x, sender.mj_y-30, sender.mj_w, sender.mj_h);
[self presentViewController:shareVC animated:YES completion:nil];
}
......@@ -369,7 +369,16 @@
[self RemoveMBProgressHUDLoding];
});
}
#pragma mark -上传图片失败
- (void)UploadImageFailue
{
dispatch_async(dispatch_get_main_queue(), ^{
self.TCHud.labelText = @"上传失败";
[self RemoveMBProgressHUDLoding];
});
}
......
......@@ -213,7 +213,8 @@
NSInteger selectedIndex;
if ([Name isEqualToString:@"体验中心"]) {
[SHARED_APPDELEGATE.window.rootViewController.view addSubview:self.followHeartView.view];
[[NSNotificationCenter defaultCenter] postNotificationName:@"FollowHeartVC" object:nil];
}else if ([Name isEqualToString:@"场景库"])
{
......
......@@ -175,9 +175,9 @@
} WithErrorCodeBlock:^(id errorCodeValue) {
} WithFailureBlock:^(id error) {
} WithFailureBlock:^(NSError *error) {
NSLog(@"%@",error);
[self ErrorMBProgressView:error.localizedDescription];
}];
}
......@@ -208,10 +208,11 @@
[self ErrorMBProgressView:@"网络连接中断"];
[self RemoveMBProgressHUDLoding];
} WithFailureBlock:^(id error) {
} WithFailureBlock:^(NSError *error) {
[self endRefreshingForTableView:self.productCollectionView];
[self RemoveMBProgressHUDLoding];
[self ErrorMBProgressView:error.localizedDescription];
}];
}
......
......@@ -135,13 +135,11 @@
}
}else
{
if (![[self.dataArray objectAtIndex_opple:indexPath.row]isEqualToString:@"体验中心"]) {
//收起右侧控制器
[SHARED_APPDELEGATE.mmdrawer toggleDrawerSide:MMDrawerSideRight animated:YES completion:^(BOOL finished) {
[self recoveryCell];
}];
}
//收起右侧控制器
[SHARED_APPDELEGATE.mmdrawer toggleDrawerSide:MMDrawerSideRight animated:YES completion:^(BOOL finished) {
[self recoveryCell];
}];
if ([self.delegate respondsToSelector:@selector(SelectedControllerWithIndex:)]) {
......
......@@ -317,6 +317,7 @@
[self ErrorMBProgressView:@"发票抬头不能为空"];
return;
}
order.billTitle = self.invoiceHeader.text;
}else if ([self.invoiceType.currentTitle isEqualToString:@"个人发票"])
{
order.billType = @"001";
......
......@@ -25,6 +25,11 @@
*/
- (void)UploadImageSuccess;
/**
* 上传失败
*/
- (void)UploadImageFailue;
@end
......
......@@ -27,7 +27,7 @@
self.weiXinFriend.tag=101;
[self.weiXinFriend addTarget:self action:@selector(sharePicture:) forControlEvents:UIControlEventTouchUpInside];
[self.view addSubview:self.weiXinFriend];
UILabel *lable1=[[UILabel alloc]initWithFrame:CGRectMake(25, 90, 60, 40)];
UILabel *lable1=[[UILabel alloc]initWithFrame:CGRectMake(25+5, 90, 60, 40)];
lable1.text=@"微信好友";
lable1.font=[UIFont systemFontOfSize:12];
[self.view addSubview:lable1];
......@@ -47,7 +47,7 @@
self.sinaMicroBlog.tag=103;
[self.sinaMicroBlog addTarget:self action:@selector(sharePicture:) forControlEvents:UIControlEventTouchUpInside];
[self.view addSubview:self.sinaMicroBlog];
UILabel *lable3=[[UILabel alloc]initWithFrame:CGRectMake(25+25+60+25+60, 90, 60, 40)];
UILabel *lable3=[[UILabel alloc]initWithFrame:CGRectMake(25+25+60+25+60+5, 90, 60, 40)];
lable3.text=@"新浪微博";
lable3.font=[UIFont systemFontOfSize:12];
[self.view addSubview:lable3];
......@@ -61,25 +61,27 @@
// if ([self.delegate respondsToSelector:@selector(ShareProductImage:)]) {
//=======
[self dismissViewControllerAnimated:YES completion:nil];
NSData *imageData = UIImageJPEGRepresentation(TCImage(@"登录"), 1.0);
NSDictionary *parameterDict = [NSDictionary dictionaryWithObjectsAndKeys:@"0b44439e54f735d10154f76373970028,0b44439e54f735d10154f76373970028,0b44439e54f735d10154f76373970028",@"goodsIds",@"",@"title",@"",@"remark",nil];
NSData *imageData = UIImageJPEGRepresentation(self.shareImage, 1.0);
NSDictionary *parameterDict = [NSDictionary dictionaryWithObjectsAndKeys:self.goodsIDs,@"goodsIds",@"",@"title",@"",@"remark",nil];
//上传图片
[[NetworkRequestClassManager Manager] UploadImageWithURL:[NSString stringWithFormat:@"%@%@",ServerAddress,@"/system/shareGoods"] WithRequestType:0 WithImageDatas:imageData WithParameter:parameterDict WithReturnValueBlock:^(id returnValue) {
//>>>>>>> d865c1bca988a9f367b133506feb2cd0442e9663
if ([returnValue[@"code"] isEqualToNumber:@0]) {
UMSocialUrlResource *resource = [[UMSocialUrlResource alloc]init];
[resource setResourceType:UMSocialUrlResourceTypeImage url:@"http://139.196.195.30:8090/opple-web/temp2/16052615120001.jpg"];
NSString *shareWeb = returnValue[@"data"][@"url"];
switch (sender.tag) {
case 101: //微信好友
{//自定义样式
UMSocialUrlResource *resource = [[UMSocialUrlResource alloc]initWithSnsResourceType:UMSocialUrlResourceTypeWeb url:returnValue[@"data"][@"url"]];
//使用UMShareToWechatSession,UMShareToWechatTimeline,UMShareToWechatFavorite分别代表微信好友、微信朋友圈、微信收藏
NSLog(@"%@",resource.url);
[[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToWechatSession] content:@"分享内嵌文字" image:TCImage(@"Icon-83.5") location:nil urlResource:resource presentedController:self completion:^(UMSocialResponseEntity *response){
[UMSocialData defaultData].extConfig.wechatSessionData.url = shareWeb;
[[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToWechatSession] content:ShareTitle image:nil location:nil urlResource:resource presentedController:self completion:^(UMSocialResponseEntity *response){
if (response.responseCode == UMSResponseCodeSuccess) {
NSLog(@"分享成功!");
[self SuccessMBProgressView:@"分享微信好友成功"];
}
}];
}
......@@ -88,9 +90,11 @@
case 102://微信朋友圈
{
//使用UMShareToWechatSession,UMShareToWechatTimeline,UMShareToWechatFavorite分别代表微信好友、微信朋友圈、微信收藏
[[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToWechatTimeline] content:@"分享内嵌文字" image:nil location:nil urlResource:nil presentedController:self completion:^(UMSocialResponseEntity *response){
[UMSocialData defaultData].extConfig.wechatTimelineData.url = shareWeb;
[[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToWechatTimeline] content:ShareTitle image:nil location:nil urlResource:resource presentedController:self completion:^(UMSocialResponseEntity *response){
if (response.responseCode == UMSResponseCodeSuccess) {
NSLog(@"分享成功!");
[self SuccessMBProgressView:@"分享微信朋友圈成功"];
}
}];
}
......@@ -99,15 +103,16 @@
{
//自定义分享样式
[[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToSina] content:@"分享内嵌文字" image:nil location:nil urlResource:nil presentedController:self completion:^(UMSocialResponseEntity *shareResponse){
[UMSocialData defaultData].extConfig.sinaData.shareText = [NSString stringWithFormat:@"%@%@",@"欧普照明",shareWeb];
[[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToSina] content:ShareTitle image:nil location:nil urlResource:resource presentedController:self completion:^(UMSocialResponseEntity *shareResponse){
if (shareResponse.responseCode == UMSResponseCodeSuccess) {
NSLog(@"分享成功!");
[self SuccessMBProgressView:@"分享新浪微博成功"];
}
}];
}
break;
default:
break;
}
......@@ -136,6 +141,11 @@
} WithErrorCodeBlock:^(id errorCodeValue) {
} WithFailureBlock:^(NSError *error) {
if ([self.delegate respondsToSelector:@selector(UploadImageFailue)]) {
[self.delegate UploadImageFailue];
}
[self ErrorMBProgressView:error.localizedDescription];
}];
}
......
......@@ -99,6 +99,9 @@
toolview.inputField.delegate = self;
self.delegate = self;
[self.tabBar addSubview:toolview];
//显示体验中心
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(ShowFollowHeart:) name:@"FollowHeartVC" object:nil];
}
......@@ -110,7 +113,7 @@
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]];
FollowHeartViewController *followVC = [storyboard instantiateViewControllerWithIdentifier:[self.identifierArray objectAtIndex_opple:3]];
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]];
......@@ -122,7 +125,6 @@
UINavigationController *searchNav = [[UINavigationController alloc]initWithRootViewController:searchVC];
UINavigationController *shoppingNav = [[UINavigationController alloc]initWithRootViewController:shoppingVC];
UINavigationController *clientNav = [[UINavigationController alloc]initWithRootViewController:clientVC];
UINavigationController *followNav = [[UINavigationController alloc]initWithRootViewController:followVC];
UINavigationController *sceneNav = [[UINavigationController alloc]initWithRootViewController:sceneVC];
UINavigationController *productNav = [[UINavigationController alloc]initWithRootViewController:productVC];
UINavigationController *customerNav = [[UINavigationController alloc]initWithRootViewController:customerVC];
......@@ -130,10 +132,10 @@
UINavigationController *cutomerorderNav = [[UINavigationController alloc]initWithRootViewController:customerOrderVC];
UINavigationController *aboutNav = [[UINavigationController alloc]initWithRootViewController:aboutVC];
self.vcArray = [NSArray arrayWithObjects:aboutNav,cutomerorderNav,allcustomerNav,customerNav,productNav,sceneNav,followNav,clientNav,shoppingNav,searchNav, nil];
self.vcArray = [NSArray arrayWithObjects:aboutNav,cutomerorderNav,allcustomerNav,customerNav,productNav,sceneNav,clientNav,shoppingNav,searchNav, nil];
self.viewControllers = self.vcArray;
SHARED_APPDELEGATE.allControllerArray = [NSArray arrayWithObjects:aboutVC,customerOrderVC,allcustomerVC,customerVC,productVC,sceneVC,followVC,clientVC,shoppingVC,searchVC, nil];
self.selectedIndex = 7;
SHARED_APPDELEGATE.allControllerArray = [NSArray arrayWithObjects:aboutVC,customerOrderVC,allcustomerVC,customerVC,productVC,sceneVC,clientVC,shoppingVC,searchVC, nil];
self.selectedIndex = 6;
}
......@@ -184,7 +186,7 @@
case 102:
[self dismissViewControllerAnimated:YES completion:nil];
self.selectedIndex = 7;
self.selectedIndex = 6;
break;
......@@ -207,7 +209,7 @@
}else
{
self.selectedIndex = 8;
self.selectedIndex = 7;
}
break;
......@@ -277,7 +279,7 @@
{
//返回根视图
[[NSNotificationCenter defaultCenter] postNotificationName:POPROOTCONTROLLER object:nil];
self.selectedIndex = 9;
self.selectedIndex = 8;
return YES;
}
......@@ -313,10 +315,20 @@
UINavigationController *navVC = (UINavigationController *)viewController;
[navVC popToRootViewControllerAnimated:NO];
}
}
#pragma mark -推出体验中心控制器
- (void)ShowFollowHeart:(NSNotification *)objc
{
UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"StoryboardwithCYX" bundle:nil];
FollowHeartViewController *followVC = [storyboard instantiateViewControllerWithIdentifier:[self.identifierArray objectAtIndex_opple:3]];
[self presentViewController:followVC animated:YES completion:nil];
}
- (void)didReceiveMemoryWarning {
[super didReceiveMemoryWarning];
......
This diff is collapsed.
......@@ -9,6 +9,10 @@
"idiom" : "universal",
"filename" : "bg-副本-6@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
......
......@@ -9,6 +9,10 @@
"idiom" : "universal",
"filename" : "2@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
......
......@@ -9,6 +9,10 @@
"idiom" : "universal",
"filename" : "4@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
......
......@@ -9,6 +9,10 @@
"idiom" : "universal",
"filename" : "5;6@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
......
......@@ -9,6 +9,10 @@
"idiom" : "universal",
"filename" : "bg-副本-7@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
......
......@@ -64,4 +64,6 @@ SPEC CHECKSUMS:
SVProgressHUD: b0830714205bea1317ea1a2ebc71e5633af334d4
UMengSocial: 48b67179c492a8cf7803fbb0438b8f55432e2fc1
COCOAPODS: 0.39.0
PODFILE CHECKSUM: ce813becb6471581d2231aa1586a015081ae7114
COCOAPODS: 1.0.0
......@@ -193,7 +193,10 @@
#define RGB(A, B, C, D) [UIColor colorWithRed:(A)/255.0 green:(B)/255.0 blue:(C)/255.0 alpha:(D)]
/**
* 一键分享显示文本
*/
#define ShareTitle @"欧立方体验中心一键分享"
#endif /* PrefixHeader_pch */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment