Commit 3d29cf1b authored by 勾芒's avatar 勾芒

debug

parent 87d435d5
...@@ -462,6 +462,7 @@ ...@@ -462,6 +462,7 @@
if (!isChange) { if (!isChange) {
[Customermanager manager].model.fid = returnValue[@"data"]; [Customermanager manager].model.fid = returnValue[@"data"];
[self SuccessMBProgressView:@"新增成功"]; [self SuccessMBProgressView:@"新增成功"];
[self addAddressInformationRequest];
}else }else
{ {
[self SuccessMBProgressView:@"修改成功"]; [self SuccessMBProgressView:@"修改成功"];
...@@ -480,7 +481,6 @@ ...@@ -480,7 +481,6 @@
[self SetupUserShoppingCarNumberRequest]; [self SetupUserShoppingCarNumberRequest];
[self SetupUserRequest]; [self SetupUserRequest];
[self ChangeCustomerName]; [self ChangeCustomerName];
[self addAddressInformationRequest];
} }
else else
{ {
......
...@@ -270,7 +270,7 @@ ...@@ -270,7 +270,7 @@
orderdetails.orderCode = model.orderNumber; orderdetails.orderCode = model.orderNumber;
orderdetails.sectionTitle = @[@"订单信息",@"客户信息",@"收货信息",@"商品信息",@"附件信息"]; orderdetails.sectionTitle = @[@"订单信息",@"客户信息",@"收货信息",@"商品信息",@"附件信息"];
orderdetails.isShowattachment = YES; orderdetails.isShowattachment = YES;
if ([model.orderState isEqualToString:@"006"] || [model.orderState isEqualToString:@"002"]) { if ([model.orderState isEqualToString:@"006"] || [model.orderState isEqualToString:@"002"] || [model.orderState isEqualToString:@"003"]) {
orderdetails.isShowPrintButton = YES; orderdetails.isShowPrintButton = YES;
orderdetails.isDelectedButton = NO; orderdetails.isDelectedButton = NO;
} }
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
/** /**
* 数据源 * 数据源
*/ */
@property (nonatomic,strong) TOHottagEntity *responseDatas; @property (nonatomic,strong) DataDict *responseDatas;
/** /**
......
...@@ -25,7 +25,6 @@ ...@@ -25,7 +25,6 @@
#pragma mark -UI #pragma mark -UI
- (void)uiConfigAction - (void)uiConfigAction
{ {
self.titleLabe = [[UILabel alloc]initWithFrame:CGRectMake(0, 0, self.frame.size.width, self.frame.size.height)];
self.titleLabe.textAlignment = NSTextAlignmentCenter; self.titleLabe.textAlignment = NSTextAlignmentCenter;
self.titleLabe.font = [UIFont systemFontOfSize:14]; self.titleLabe.font = [UIFont systemFontOfSize:14];
[self.contentView addSubview:self.titleLabe]; [self.contentView addSubview:self.titleLabe];
...@@ -33,10 +32,10 @@ ...@@ -33,10 +32,10 @@
#pragma mark -赋值 #pragma mark -赋值
- (void)setResponseDatas:(TOHottagEntity *)responseDatas - (void)setResponseDatas:(DataDict *)responseDatas
{ {
_responseDatas = responseDatas; _responseDatas = responseDatas;
self.titleLabe.text = _responseDatas.name; self.titleLabe.text = _responseDatas.typename;
} }
......
...@@ -223,7 +223,7 @@ ...@@ -223,7 +223,7 @@
sceneVC.conditionModel.styleEquals = nil; sceneVC.conditionModel.styleEquals = nil;
sceneVC.conditionModel.spaceEquals = nil; sceneVC.conditionModel.spaceEquals = nil;
[sceneVC.StyleButton setTitle:@"风格" forState:UIControlStateNormal]; [sceneVC.StyleButton setTitle:@"风格" forState:UIControlStateNormal];
[sceneVC.StyleButton setTitle:@"空间" forState:UIControlStateNormal]; [sceneVC.SpaceButton setTitle:@"空间" forState:UIControlStateNormal];
[sceneVC.seceneLibararyCollectionView.mj_header beginRefreshing]; [sceneVC.seceneLibararyCollectionView.mj_header beginRefreshing];
}else if ([Name isEqualToString:@"产品库"]) }else if ([Name isEqualToString:@"产品库"])
......
...@@ -155,6 +155,8 @@ ...@@ -155,6 +155,8 @@
[self.screeningDatas removeAllObjects]; [self.screeningDatas removeAllObjects];
} }
GoodsFilter *goodsStyle = [[GoodsFilter alloc]initWithDictionary:returnValue[@"data"] error:nil]; GoodsFilter *goodsStyle = [[GoodsFilter alloc]initWithDictionary:returnValue[@"data"] error:nil];
[self.screeningDatas addObject:goodsStyle.styles]; [self.screeningDatas addObject:goodsStyle.styles];
[self.screeningDatas addObject:goodsStyle.categories]; [self.screeningDatas addObject:goodsStyle.categories];
[self.screeningDatas addObject:goodsStyle.space]; [self.screeningDatas addObject:goodsStyle.space];
...@@ -517,38 +519,38 @@ ...@@ -517,38 +519,38 @@
#pragma mark -筛选 #pragma mark -筛选
- (void)ScreeningButtonClick - (void)ScreeningButtonClick
{ {
ExperienceCentreViewController *ExperienceCenter = [[self getStoryboardWithName] instantiateViewControllerWithIdentifier:@"ExperienceCentre"];
// [self presentViewController:ExperienceCenter animated:YES completion:nil];
ExperienceCenter.modalPresentationStyle = UIModalPresentationOverFullScreen;
UIPopoverPresentationController *popover = ExperienceCenter.popoverPresentationController;
popover.sourceView = ExperienceCenter.view;
[self presentViewController:ExperienceCenter animated:YES completion:nil];
// self.screenView = [[[NSBundle mainBundle] loadNibNamed:@"ScreeningView" owner:self options:nil]firstObject];
// self.screenView.frame = CGRectMake(0, 0, ScreenWidth, ScreenHeight);
// self.screenView.backgroundColor = [[UIColor blackColor] colorWithAlphaComponent:0.5];
// self.screenView.delegate = self;
// //点击手势
// UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(DismissScreenView)];
// tap.delegate = self;
// tap.cancelsTouchesInView = NO;
// [self.screenView addGestureRecognizer:tap];
// self.screenView.frame = CGRectMake(0, 0, ScreenWidth, ScreenHeight);
// [self.view.window addSubview:self.screenView];
// self.screenView.alpha = 0;
// //
// //监听Segmented菜单 // ExperienceCentreViewController *ExperienceCenter = [[self getStoryboardWithName] instantiateViewControllerWithIdentifier:@"ExperienceCentre"];
// [self.screenView.sortingSegmented addTarget:self action:@selector(sortingSegmentedClick:) forControlEvents:UIControlEventValueChanged]; //// [self presentViewController:ExperienceCenter animated:YES completion:nil];
// //
// self.selectedIndex = 0; // ExperienceCenter.modalPresentationStyle = UIModalPresentationOverFullScreen;
// [self CreateClassificationView]; // UIPopoverPresentationController *popover = ExperienceCenter.popoverPresentationController;
// // popover.sourceView = ExperienceCenter.view;
// [UIView animateWithDuration:0.2 animations:^{ // [self presentViewController:ExperienceCenter animated:YES completion:nil];
//
// self.screenView.alpha = 1; self.screenView = [[[NSBundle mainBundle] loadNibNamed:@"ScreeningView" owner:self options:nil]firstObject];
// }]; self.screenView.frame = CGRectMake(0, 0, ScreenWidth, ScreenHeight);
self.screenView.backgroundColor = [[UIColor blackColor] colorWithAlphaComponent:0.5];
self.screenView.delegate = self;
//点击手势
UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(DismissScreenView)];
tap.delegate = self;
tap.cancelsTouchesInView = NO;
[self.screenView addGestureRecognizer:tap];
self.screenView.frame = CGRectMake(0, 0, ScreenWidth, ScreenHeight);
[self.view.window addSubview:self.screenView];
self.screenView.alpha = 0;
//监听Segmented菜单
[self.screenView.sortingSegmented addTarget:self action:@selector(sortingSegmentedClick:) forControlEvents:UIControlEventValueChanged];
self.selectedIndex = 0;
[self CreateClassificationView];
[UIView animateWithDuration:0.2 animations:^{
self.screenView.alpha = 1;
}];
} }
......
...@@ -25,12 +25,10 @@ ...@@ -25,12 +25,10 @@
- (void)uiConfigAction - (void)uiConfigAction
{ {
self.titleLabe = [UIButton buttonWithType:UIButtonTypeCustom]; self.titleLabe = [UIButton buttonWithType:UIButtonTypeCustom];
self.titleLabe.frame = self.contentView.frame; self.titleLabe.frame = self.contentView.frame;
[self.titleLabe setTitleColor:kMainBlueColor forState:UIControlStateNormal]; [self.titleLabe setTitleColor:kMainBlueColor forState:UIControlStateNormal];
[self.titleLabe setBackgroundImage:TCImage(@"kamincolor") forState:UIControlStateHighlighted]; [self.titleLabe setTitleColor:[UIColor whiteColor] forState:UIControlStateSelected];
[self.titleLabe setTitleColor:[UIColor whiteColor] forState:UIControlStateHighlighted];
self.titleLabe.titleLabel.font = [UIFont systemFontOfSize:12]; self.titleLabe.titleLabel.font = [UIFont systemFontOfSize:12];
[self.contentView addSubview:self.titleLabe]; [self.contentView addSubview:self.titleLabe];
[self.titleLabe addTarget:self action:@selector(ButtonClick) forControlEvents:UIControlEventTouchUpInside]; [self.titleLabe addTarget:self action:@selector(ButtonClick) forControlEvents:UIControlEventTouchUpInside];
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
/** /**
* 数据源 * 数据源
*/ */
@property (nonatomic,strong) HotTagResponse *response; @property (nonatomic,strong) HotFilter *response;
/** /**
* 本地搜索历史 * 本地搜索历史
...@@ -139,7 +139,7 @@ ...@@ -139,7 +139,7 @@
[self RemoveMBProgressHUDLoding]; [self RemoveMBProgressHUDLoding];
if ([returnValue[@"code"] isEqualToNumber:@0]) { if ([returnValue[@"code"] isEqualToNumber:@0]) {
self.response = [[HotTagResponse alloc]initWithDictionary:returnValue[@"data"] error:nil]; self.response = [[HotFilter alloc]initWithDictionary:returnValue[@"data"] error:nil];
[self.hotCollectionView reloadData]; [self.hotCollectionView reloadData];
}else }else
...@@ -187,10 +187,10 @@ ...@@ -187,10 +187,10 @@
{ {
if ([collectionView isEqual:self.hotCollectionView]) { if ([collectionView isEqual:self.hotCollectionView]) {
[self.localSearchArray addObject:[[self.response.list objectAtIndex_opple:indexPath.item] name]]; [self.localSearchArray addObject:[[self.response.list objectAtIndex_opple:indexPath.item] typename]];
//调用商品控制器 //调用商品控制器
ProductLibraryViewController *productVC = [[self getStoryboardWithName] instantiateViewControllerWithIdentifier:@"productlibrary"]; ProductLibraryViewController *productVC = [[self getStoryboardWithName] instantiateViewControllerWithIdentifier:@"productlibrary"];
productVC.selectedCode = [[self.response.list objectAtIndex_opple:indexPath.item] fid]; productVC.selectedCode = [[self.response.list objectAtIndex_opple:indexPath.item] typecode];
[self.navigationController pushViewController:productVC animated:NO]; [self.navigationController pushViewController:productVC animated:NO];
} }
else if ([collectionView isEqual:self.historyCollectionView]) else if ([collectionView isEqual:self.historyCollectionView])
......
...@@ -61,15 +61,13 @@ ...@@ -61,15 +61,13 @@
[self dismissViewControllerAnimated:YES completion:nil]; [self dismissViewControllerAnimated:YES completion:nil];
NSData *imageData = UIImageJPEGRepresentation(self.shareImage, 1.0); NSData *imageData = UIImageJPEGRepresentation(self.shareImage, 1.0);
// 0b44439e5504e371015504f73d4f0025,0b44439e5504e371015504feae270028 // 0b44439e5504e371015504f73d4f0025,0b44439e5504e371015504feae270028
NSDictionary *parameterDict = [NSDictionary dictionaryWithObjectsAndKeys:@"0b44439e5504e371015504f73d4f0025,0b44439e5504e371015504feae270028",@"goodsIds",@"",@"title",@"",@"remark",nil]; 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) { [[NetworkRequestClassManager Manager] UploadImageWithURL:[NSString stringWithFormat:@"%@%@",ServerAddress,@"/system/shareGoods"] WithRequestType:0 WithImageDatas:imageData WithParameter:parameterDict WithReturnValueBlock:^(id returnValue) {
if ([returnValue[@"code"] isEqualToNumber:@0]) { 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"]; NSString *shareWeb = returnValue[@"data"][@"url"];
switch (sender.tag) { switch (sender.tag) {
case 101: //微信好友 case 101: //微信好友
...@@ -77,7 +75,7 @@ ...@@ -77,7 +75,7 @@
//使用UMShareToWechatSession,UMShareToWechatTimeline,UMShareToWechatFavorite分别代表微信好友、微信朋友圈、微信收藏 //使用UMShareToWechatSession,UMShareToWechatTimeline,UMShareToWechatFavorite分别代表微信好友、微信朋友圈、微信收藏
[UMSocialData defaultData].extConfig.wechatSessionData.url = shareWeb; [UMSocialData defaultData].extConfig.wechatSessionData.url = shareWeb;
[[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToWechatSession] content:ShareTitle image:nil location:nil urlResource:resource presentedController:self completion:^(UMSocialResponseEntity *response){ [[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToWechatSession] content:ShareTitle image:self.shareImage location:nil urlResource:nil presentedController:self completion:^(UMSocialResponseEntity *response){
if (response.responseCode == UMSResponseCodeSuccess) { if (response.responseCode == UMSResponseCodeSuccess) {
[self SuccessMBProgressView:@"分享微信好友成功"]; [self SuccessMBProgressView:@"分享微信好友成功"];
...@@ -90,7 +88,7 @@ ...@@ -90,7 +88,7 @@
{ {
//使用UMShareToWechatSession,UMShareToWechatTimeline,UMShareToWechatFavorite分别代表微信好友、微信朋友圈、微信收藏 //使用UMShareToWechatSession,UMShareToWechatTimeline,UMShareToWechatFavorite分别代表微信好友、微信朋友圈、微信收藏
[UMSocialData defaultData].extConfig.wechatTimelineData.url = shareWeb; [UMSocialData defaultData].extConfig.wechatTimelineData.url = shareWeb;
[[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToWechatTimeline] content:ShareTitle image:nil location:nil urlResource:resource presentedController:self completion:^(UMSocialResponseEntity *response){ [[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToWechatTimeline] content:ShareTitle image:self.shareImage location:nil urlResource:nil presentedController:self completion:^(UMSocialResponseEntity *response){
if (response.responseCode == UMSResponseCodeSuccess) { if (response.responseCode == UMSResponseCodeSuccess) {
[self SuccessMBProgressView:@"分享微信朋友圈成功"]; [self SuccessMBProgressView:@"分享微信朋友圈成功"];
...@@ -103,7 +101,7 @@ ...@@ -103,7 +101,7 @@
//自定义分享样式 //自定义分享样式
[UMSocialData defaultData].extConfig.sinaData.shareText = [NSString stringWithFormat:@"%@%@",@"欧普照明",shareWeb]; [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){ [[UMSocialDataService defaultDataService] postSNSWithTypes:@[UMShareToSina] content:ShareTitle image:self.shareImage location:nil urlResource:nil presentedController:self completion:^(UMSocialResponseEntity *shareResponse){
if (shareResponse.responseCode == UMSResponseCodeSuccess) { if (shareResponse.responseCode == UMSResponseCodeSuccess) {
[self SuccessMBProgressView:@"分享新浪微博成功"]; [self SuccessMBProgressView:@"分享新浪微博成功"];
......
...@@ -32,4 +32,6 @@ ...@@ -32,4 +32,6 @@
*/ */
@property (weak, nonatomic) IBOutlet UIButton *allSelectedButton; @property (weak, nonatomic) IBOutlet UIButton *allSelectedButton;
@end @end
...@@ -205,12 +205,12 @@ ...@@ -205,12 +205,12 @@
if (model.isSelected) { if (model.isSelected) {
goodsNumber ++; goodsNumber ++;
} }
if (goodsNumber == 0) {
self.allSelectedButton.selected = NO;
} }
if (goodsNumber == self.shopResponseArray.count) { if (goodsNumber == self.shopResponseArray.count) {
self.allSelectedButton.selected = YES; self.allSelectedButton.selected = YES;
} }else
{
self.allSelectedButton.selected = NO;
} }
[self CalculateSelectedGoodsAllprice]; [self CalculateSelectedGoodsAllprice];
[self.settlementButton setTitle:[NSString stringWithFormat:@"去结算(%ld)",goodsNumber] forState:UIControlStateNormal]; [self.settlementButton setTitle:[NSString stringWithFormat:@"去结算(%ld)",goodsNumber] forState:UIControlStateNormal];
......
...@@ -46,6 +46,7 @@ ...@@ -46,6 +46,7 @@
cell.titleLabe.backgroundColor = [UIColor whiteColor]; cell.titleLabe.backgroundColor = [UIColor whiteColor];
cell.titleLabe.textColor = kMainBlueColor; cell.titleLabe.textColor = kMainBlueColor;
[self.screeningCollectionView reloadData]; [self.screeningCollectionView reloadData];
} }
...@@ -204,6 +205,10 @@ ...@@ -204,6 +205,10 @@
//选中的key //选中的key
NSString *selectedTypecode = nil; NSString *selectedTypecode = nil;
//选中状态
// ScreeningFirstCollectionViewCell *newCell = (ScreeningFirstCollectionViewCell *)[self.screeningCollectionView cellForItemAtIndexPath:indexpath];
// newCell.titleLabe.selected = YES;
// newCell.titleLabe.backgroundColor = kMainBlueColor;
if (self.selectedIndex == 1) { if (self.selectedIndex == 1) {
......
...@@ -62,6 +62,9 @@ ...@@ -62,6 +62,9 @@
2936F28C1D014147007CA67C /* sceneScreeningCollectionViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2936F28B1D014147007CA67C /* sceneScreeningCollectionViewCell.m */; }; 2936F28C1D014147007CA67C /* sceneScreeningCollectionViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2936F28B1D014147007CA67C /* sceneScreeningCollectionViewCell.m */; };
2936F28F1D0141FD007CA67C /* ProductScreeningTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2936F28E1D0141FD007CA67C /* ProductScreeningTableViewCell.m */; }; 2936F28F1D0141FD007CA67C /* ProductScreeningTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2936F28E1D0141FD007CA67C /* ProductScreeningTableViewCell.m */; };
2936F2931D016EB2007CA67C /* SceneSelectedModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 2936F2921D016EB2007CA67C /* SceneSelectedModel.m */; }; 2936F2931D016EB2007CA67C /* SceneSelectedModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 2936F2921D016EB2007CA67C /* SceneSelectedModel.m */; };
2936F2961D017BBD007CA67C /* GoodsImageView.m in Sources */ = {isa = PBXBuildFile; fileRef = 2936F2951D017BBD007CA67C /* GoodsImageView.m */; };
2936F29A1D01868E007CA67C /* ShareGoodsViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2936F2981D01868E007CA67C /* ShareGoodsViewController.m */; };
2936F29B1D01868E007CA67C /* ShareGoodsViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2936F2991D01868E007CA67C /* ShareGoodsViewController.xib */; };
2942F8A61CDD80C2005B377E /* authenticateView.m in Sources */ = {isa = PBXBuildFile; fileRef = 2942F8A51CDD80C2005B377E /* authenticateView.m */; }; 2942F8A61CDD80C2005B377E /* authenticateView.m in Sources */ = {isa = PBXBuildFile; fileRef = 2942F8A51CDD80C2005B377E /* authenticateView.m */; };
2942F8A81CDD80CE005B377E /* authenticateView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2942F8A71CDD80CE005B377E /* authenticateView.xib */; }; 2942F8A81CDD80CE005B377E /* authenticateView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2942F8A71CDD80CE005B377E /* authenticateView.xib */; };
2949BABD1CD2EFA00049385A /* InformationTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2949BABC1CD2EFA00049385A /* InformationTableViewCell.m */; }; 2949BABD1CD2EFA00049385A /* InformationTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2949BABC1CD2EFA00049385A /* InformationTableViewCell.m */; };
...@@ -265,6 +268,11 @@ ...@@ -265,6 +268,11 @@
2936F28E1D0141FD007CA67C /* ProductScreeningTableViewCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ProductScreeningTableViewCell.m; sourceTree = "<group>"; }; 2936F28E1D0141FD007CA67C /* ProductScreeningTableViewCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ProductScreeningTableViewCell.m; sourceTree = "<group>"; };
2936F2911D016EB2007CA67C /* SceneSelectedModel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SceneSelectedModel.h; sourceTree = "<group>"; }; 2936F2911D016EB2007CA67C /* SceneSelectedModel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SceneSelectedModel.h; sourceTree = "<group>"; };
2936F2921D016EB2007CA67C /* SceneSelectedModel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SceneSelectedModel.m; sourceTree = "<group>"; }; 2936F2921D016EB2007CA67C /* SceneSelectedModel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SceneSelectedModel.m; sourceTree = "<group>"; };
2936F2941D017BBD007CA67C /* GoodsImageView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GoodsImageView.h; sourceTree = "<group>"; };
2936F2951D017BBD007CA67C /* GoodsImageView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GoodsImageView.m; sourceTree = "<group>"; };
2936F2971D01868E007CA67C /* ShareGoodsViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ShareGoodsViewController.h; sourceTree = "<group>"; };
2936F2981D01868E007CA67C /* ShareGoodsViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ShareGoodsViewController.m; sourceTree = "<group>"; };
2936F2991D01868E007CA67C /* ShareGoodsViewController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = ShareGoodsViewController.xib; sourceTree = "<group>"; };
2942F8A41CDD80C2005B377E /* authenticateView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = authenticateView.h; sourceTree = "<group>"; }; 2942F8A41CDD80C2005B377E /* authenticateView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = authenticateView.h; sourceTree = "<group>"; };
2942F8A51CDD80C2005B377E /* authenticateView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = authenticateView.m; sourceTree = "<group>"; }; 2942F8A51CDD80C2005B377E /* authenticateView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = authenticateView.m; sourceTree = "<group>"; };
2942F8A71CDD80CE005B377E /* authenticateView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = authenticateView.xib; sourceTree = "<group>"; }; 2942F8A71CDD80CE005B377E /* authenticateView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = authenticateView.xib; sourceTree = "<group>"; };
...@@ -799,6 +807,8 @@ ...@@ -799,6 +807,8 @@
2936F28B1D014147007CA67C /* sceneScreeningCollectionViewCell.m */, 2936F28B1D014147007CA67C /* sceneScreeningCollectionViewCell.m */,
2936F28D1D0141FD007CA67C /* ProductScreeningTableViewCell.h */, 2936F28D1D0141FD007CA67C /* ProductScreeningTableViewCell.h */,
2936F28E1D0141FD007CA67C /* ProductScreeningTableViewCell.m */, 2936F28E1D0141FD007CA67C /* ProductScreeningTableViewCell.m */,
2936F2941D017BBD007CA67C /* GoodsImageView.h */,
2936F2951D017BBD007CA67C /* GoodsImageView.m */,
); );
name = view; name = view;
sourceTree = "<group>"; sourceTree = "<group>";
...@@ -1024,6 +1034,9 @@ ...@@ -1024,6 +1034,9 @@
children = ( children = (
29808A621CFEC41B001D1020 /* ExperienceCentreViewController.h */, 29808A621CFEC41B001D1020 /* ExperienceCentreViewController.h */,
29808A631CFEC41B001D1020 /* ExperienceCentreViewController.m */, 29808A631CFEC41B001D1020 /* ExperienceCentreViewController.m */,
2936F2971D01868E007CA67C /* ShareGoodsViewController.h */,
2936F2981D01868E007CA67C /* ShareGoodsViewController.m */,
2936F2991D01868E007CA67C /* ShareGoodsViewController.xib */,
); );
name = Controller; name = Controller;
sourceTree = "<group>"; sourceTree = "<group>";
...@@ -1528,6 +1541,7 @@ ...@@ -1528,6 +1541,7 @@
29A938271CDAE31B00F21E54 /* ProductDetailsHeaderView.xib in Resources */, 29A938271CDAE31B00F21E54 /* ProductDetailsHeaderView.xib in Resources */,
2908870C1CE5A308000B7097 /* DateSelectedViewController.xib in Resources */, 2908870C1CE5A308000B7097 /* DateSelectedViewController.xib in Resources */,
2942F8A81CDD80CE005B377E /* authenticateView.xib in Resources */, 2942F8A81CDD80CE005B377E /* authenticateView.xib in Resources */,
2936F29B1D01868E007CA67C /* ShareGoodsViewController.xib in Resources */,
29E384BF1CE9933300888199 /* AdditionalTableViewCell.xib in Resources */, 29E384BF1CE9933300888199 /* AdditionalTableViewCell.xib in Resources */,
29807C651CD20F0F00F111B8 /* StoryboardwithCYX.storyboard in Resources */, 29807C651CD20F0F00F111B8 /* StoryboardwithCYX.storyboard in Resources */,
29EAAE901CDC3E9700C4DBA2 /* BillingInfoView.xib in Resources */, 29EAAE901CDC3E9700C4DBA2 /* BillingInfoView.xib in Resources */,
...@@ -1685,6 +1699,7 @@ ...@@ -1685,6 +1699,7 @@
29834EB41CDF1EAA001A484F /* screeningSecondView.m in Sources */, 29834EB41CDF1EAA001A484F /* screeningSecondView.m in Sources */,
29706DA61CD082990003C412 /* main.m in Sources */, 29706DA61CD082990003C412 /* main.m in Sources */,
044CD6EE1CEB771C0004A715 /* SeceneCollectionPictureCell.m in Sources */, 044CD6EE1CEB771C0004A715 /* SeceneCollectionPictureCell.m in Sources */,
2936F2961D017BBD007CA67C /* GoodsImageView.m in Sources */,
291D6A621CFFE212007891AE /* DataDictModel.m in Sources */, 291D6A621CFFE212007891AE /* DataDictModel.m in Sources */,
29A938251CDAE31200F21E54 /* ProductDetailsHeaderView.m in Sources */, 29A938251CDAE31200F21E54 /* ProductDetailsHeaderView.m in Sources */,
291D6A6B1D000A2A007891AE /* ProductScreeningCollectionViewCell.m in Sources */, 291D6A6B1D000A2A007891AE /* ProductScreeningCollectionViewCell.m in Sources */,
...@@ -1720,6 +1735,7 @@ ...@@ -1720,6 +1735,7 @@
2906B5D71CD89246000849B4 /* ClientDetailsTableViewCell.m in Sources */, 2906B5D71CD89246000849B4 /* ClientDetailsTableViewCell.m in Sources */,
29BB27801CD9DFD7009A0813 /* AboutViewController.m in Sources */, 29BB27801CD9DFD7009A0813 /* AboutViewController.m in Sources */,
29F14BAA1CF6B60D0005D3E5 /* QRView.m in Sources */, 29F14BAA1CF6B60D0005D3E5 /* QRView.m in Sources */,
2936F29A1D01868E007CA67C /* ShareGoodsViewController.m in Sources */,
29F725FE1CE1928F0072FE0E /* opple_objc_json_client.m in Sources */, 29F725FE1CE1928F0072FE0E /* opple_objc_json_client.m in Sources */,
29834EC01CDF5E4E001A484F /* ScreeningFirstCollectionViewCell.m in Sources */, 29834EC01CDF5E4E001A484F /* ScreeningFirstCollectionViewCell.m in Sources */,
29834EC51CDF76C1001A484F /* UserViewController.m in Sources */, 29834EC51CDF76C1001A484F /* UserViewController.m in Sources */,
......
...@@ -11,6 +11,8 @@ ...@@ -11,6 +11,8 @@
#import "sceneScreeningCollectionViewCell.h" #import "sceneScreeningCollectionViewCell.h"
#import "ProductScreeningTableViewCell.h" #import "ProductScreeningTableViewCell.h"
#import "SceneSelectedModel.h" #import "SceneSelectedModel.h"
#import "GoodsImageView.h"
#import "ShareGoodsViewController.h"
#define LEFTWIDTH 100 #define LEFTWIDTH 100
...@@ -29,11 +31,6 @@ ...@@ -29,11 +31,6 @@
*/ */
@property (nonatomic,strong) NSMutableArray *productDatasArray; @property (nonatomic,strong) NSMutableArray *productDatasArray;
/**
* 选中灯
*/
@property (nonatomic,strong) UIImageView *imageView;
@end @end
...@@ -93,18 +90,29 @@ ...@@ -93,18 +90,29 @@
- (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath - (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath
{ {
sceneScreeningCollectionViewCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"sceneScreeningCollectionViewCell" forIndexPath:indexPath]; sceneScreeningCollectionViewCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"sceneScreeningCollectionViewCell" forIndexPath:indexPath];
cell.selectedScrenImageView.image = [[self.sceneDatasArray objectAtIndex_opple:indexPath.item] sceneImage]; SceneSelectedModel *model = [self.sceneDatasArray objectAtIndex_opple:indexPath.item];
cell.selectedScrenImageView.image = [model sceneImage];
cell.selectedScrenImageView.layer.masksToBounds = YES; cell.selectedScrenImageView.layer.masksToBounds = YES;
cell.selectedScrenImageView.layer.cornerRadius = kCornerRadius; cell.selectedScrenImageView.layer.cornerRadius = kCornerRadius;
if (model.isSelectedState) {
cell.selectedScrenImageView.layer.borderWidth = 2.0f;
cell.selectedScrenImageView.layer.borderColor = kMainBlueColor.CGColor;
}else
{
cell.selectedScrenImageView.layer.borderWidth = 0;
}
return cell; return cell;
} }
- (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath - (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath
{ {
sceneScreeningCollectionViewCell *cell = (sceneScreeningCollectionViewCell *)[collectionView cellForItemAtIndexPath:indexPath]; for (SceneSelectedModel *model in self.sceneDatasArray) {
cell.selectedScrenImageView.layer.borderWidth = 1.0f; model.isSelectedState = NO;
cell.selectedScrenImageView.layer.borderColor = kMainBlueColor.CGColor; }
self.sceneImageView.image = [[self.sceneDatasArray objectAtIndex_opple:indexPath.item] sceneImage]; SceneSelectedModel *model = [self.sceneDatasArray objectAtIndex_opple:indexPath.item];
model.isSelectedState = YES;
self.sceneImageView.image = [model sceneImage];
[self.sceneScrollview reloadData];
} }
...@@ -120,7 +128,15 @@ ...@@ -120,7 +128,15 @@
ProductScreeningTableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"ProductScreeningTableViewCell" forIndexPath:indexPath]; ProductScreeningTableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"ProductScreeningTableViewCell" forIndexPath:indexPath];
cell.backgroundColor = [UIColor clearColor]; cell.backgroundColor = [UIColor clearColor];
cell.selectionStyle = UITableViewCellSelectionStyleNone; cell.selectionStyle = UITableViewCellSelectionStyleNone;
cell.selectedGoodsImageView.image = [[self.productDatasArray objectAtIndex_opple:indexPath.row] sceneImage]; SceneSelectedModel *model = [self.productDatasArray objectAtIndex_opple:indexPath.row];
if (model.isSelectedState) {
cell.selectedGoodsImageView.layer.borderWidth = 2.0f;
cell.selectedGoodsImageView.layer.borderColor = kMainBlueColor.CGColor;
}else
{
cell.selectedGoodsImageView.layer.borderWidth = 0;
}
cell.selectedGoodsImageView.image = [model sceneImage];
return cell; return cell;
} }
...@@ -132,17 +148,24 @@ ...@@ -132,17 +148,24 @@
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{ {
self.imageView = [[UIImageView alloc]initWithFrame:CGRectMake(200, 200, 133, 100)];
self.imageView.userInteractionEnabled = YES;
self.imageView.image = [[self.productDatasArray objectAtIndex_opple:indexPath.row] sceneImage];
[self addImageGestures:self.imageView];
[self.view addSubview:self.imageView];
}
ProductScreeningTableViewCell *cell = [tableView cellForRowAtIndexPath:indexPath];
CGRect cellRect = [cell convertRect:cell.bounds toView:self.view];
GoodsImageView *imageView = [[GoodsImageView alloc]initWithFrame:cellRect];
imageView.userInteractionEnabled = YES;
[UIView animateWithDuration:0.5 animations:^{
imageView.frame = CGRectMake(ScreenWidth/2, ScreenHeight/2, 266, 200);
}];
for (SceneSelectedModel *model in self.productDatasArray) {
model.isSelectedState = NO;
}
SceneSelectedModel *model = [self.productDatasArray objectAtIndex_opple:indexPath.row];
model.isSelectedState = YES;
imageView.image = [model sceneImage];
[self.view addSubview:imageView];
[self.productScrollview reloadData];
}
#pragma mark -返回 #pragma mark -返回
...@@ -154,16 +177,39 @@ ...@@ -154,16 +177,39 @@
#pragma mark -购物袋 #pragma mark -购物袋
- (IBAction)ShoppingBagButtonClickAction:(UIButton *)sender { - (IBAction)ShoppingBagButtonClickAction:(UIButton *)sender {
} }
#pragma mark -分享 #pragma mark -分享
- (IBAction)ShareButtonClickAction:(UIButton *)sender { - (IBAction)ShareButtonClickAction:(UIButton *)sender {
ShareGoodsViewController *shareController = [[ShareGoodsViewController alloc]init];
shareController.preferredContentSize = CGSizeMake(290, 120);
shareController.modalPresentationStyle = UIModalPresentationPopover;
UIPopoverPresentationController *popover = shareController.popoverPresentationController;
popover.permittedArrowDirections = UIPopoverArrowDirectionLeft;
popover.sourceView = shareController.view;
popover.sourceRect = CGRectMake(sender.mj_x, sender.mj_y-30, sender.mj_w, sender.mj_h);
[self presentViewController:shareController animated:YES completion:nil];
} }
#pragma mark -拍照 #pragma mark -拍照
- (IBAction)TakingPhotoButtonClickAction:(UIButton *)sender { - (IBAction)TakingPhotoButtonClickAction:(UIButton *)sender {
} }
#pragma mark -全屏 #pragma mark -全屏
- (IBAction)AmplificationButtonClickAction:(UIButton *)sender { - (IBAction)AmplificationButtonClickAction:(UIButton *)sender {
...@@ -303,56 +349,6 @@ ...@@ -303,56 +349,6 @@
#pragma mark -添加图片缩放、移动、旋转手势
- (void)addImageGestures:(UIImageView *)imageView
{
UIRotationGestureRecognizer *rotationGes = [[UIRotationGestureRecognizer alloc] initWithTarget:self action:@selector(backGroundViewRotationAction:)];
rotationGes.delegate = self;
[imageView addGestureRecognizer:rotationGes];
UIPinchGestureRecognizer *pinchGes = [[UIPinchGestureRecognizer alloc] initWithTarget:self action:@selector(backGroundViewPinchAction:)];
pinchGes.delegate =self;
[imageView addGestureRecognizer:pinchGes];
UIPanGestureRecognizer *panGes = [[UIPanGestureRecognizer alloc] initWithTarget:self action:@selector(backGroundViewPanAction:)];
[panGes setMinimumNumberOfTouches:1];
[panGes setMaximumNumberOfTouches:1];
panGes.delegate = self;
[imageView addGestureRecognizer:panGes];
}
#pragma mark 手势触发事件
-(void)backGroundViewPinchAction:(UIPinchGestureRecognizer *)gesture{
UIView *view = self.imageView;
if (gesture.state == UIGestureRecognizerStateBegan || gesture.state == UIGestureRecognizerStateChanged) {
view.transform = CGAffineTransformScale(view.transform, gesture.scale, gesture.scale);
gesture.scale = 1;
}
}
-(void)backGroundViewPanAction:(UIPanGestureRecognizer *)gesture{
if (gesture.numberOfTouches == 1) {
if (gesture.state == UIGestureRecognizerStateBegan || gesture.state == UIGestureRecognizerStateChanged) {
CGPoint transLation = [gesture translationInView:self.view];
self.imageView.center = CGPointMake(self.imageView.center.x + transLation.x, self.imageView.center.y + transLation.y);
[gesture setTranslation:CGPointZero inView:self.view];
}
}
}
-(void)backGroundViewRotationAction:(UIRotationGestureRecognizer *)gesture{
self.imageView.transform = CGAffineTransformRotate(self.imageView.transform, gesture.rotation);
gesture.rotation = 0;
}
- (void)didReceiveMemoryWarning { - (void)didReceiveMemoryWarning {
[super didReceiveMemoryWarning]; [super didReceiveMemoryWarning];
// Dispose of any resources that can be recreated. // Dispose of any resources that can be recreated.
......
//
// GoodsImageView.h
// Lighting
//
// Created by 曹云霄 on 16/6/3.
// Copyright © 2016年 上海勾芒科技有限公司. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface GoodsImageView : UIImageView<UIGestureRecognizerDelegate>
@end
//
// GoodsImageView.m
// Lighting
//
// Created by 曹云霄 on 16/6/3.
// Copyright © 2016年 上海勾芒科技有限公司. All rights reserved.
//
#import "GoodsImageView.h"
@implementation GoodsImageView
- (instancetype)initWithFrame:(CGRect)frame
{
if (self = [super initWithFrame:frame]) {
UIRotationGestureRecognizer *rotationGes = [[UIRotationGestureRecognizer alloc] initWithTarget:self action:@selector(backGroundViewRotationAction:)];
rotationGes.delegate = self;
[self addGestureRecognizer:rotationGes];
UIPinchGestureRecognizer *pinchGes = [[UIPinchGestureRecognizer alloc] initWithTarget:self action:@selector(backGroundViewPinchAction:)];
pinchGes.delegate =self;
[self addGestureRecognizer:pinchGes];
UIPanGestureRecognizer *panGes = [[UIPanGestureRecognizer alloc] initWithTarget:self action:@selector(backGroundViewPanAction:)];
[panGes setMinimumNumberOfTouches:1];
[panGes setMaximumNumberOfTouches:1];
panGes.delegate = self;
[self addGestureRecognizer:panGes];
UILongPressGestureRecognizer *longGes = [[UILongPressGestureRecognizer alloc]initWithTarget:self action:@selector(LongPressAction:)];
longGes.delegate = self;
[self addGestureRecognizer:longGes];
}
return self;
}
#pragma mark -缩放
-(void)backGroundViewPinchAction:(UIPinchGestureRecognizer *)gesture{
UIView *view = self;
if (gesture.state == UIGestureRecognizerStateBegan || gesture.state == UIGestureRecognizerStateChanged) {
view.transform = CGAffineTransformScale(view.transform, gesture.scale, gesture.scale);
gesture.scale = 1;
}
}
#pragma mark -拖拉
-(void)backGroundViewPanAction:(UIPanGestureRecognizer *)gesture{
UIView *view = gesture.view;
if (gesture.state == UIGestureRecognizerStateBegan || gesture.state == UIGestureRecognizerStateChanged) {
CGPoint translation = [gesture translationInView:view.superview];
[view setCenter:(CGPoint){view.center.x + translation.x, view.center.y + translation.y}];
[gesture setTranslation:CGPointZero inView:view.superview];
}
}
#pragma mark -旋转
-(void)backGroundViewRotationAction:(UIRotationGestureRecognizer *)gesture{
self.transform = CGAffineTransformRotate(self.transform, gesture.rotation);
gesture.rotation = 0;
}
#pragma mark -长按
- (void)LongPressAction:(UILongPressGestureRecognizer *)longPress
{
[self removeFromSuperview];
}
@end
...@@ -492,7 +492,7 @@ ...@@ -492,7 +492,7 @@
newModel.resellerInv = model.resellerInv; newModel.resellerInv = model.resellerInv;
newModel.resellerTagPrice = model.resellerTagPrice; newModel.resellerTagPrice = model.resellerTagPrice;
newModel.resellerState = model.resellerState; newModel.resellerState = model.resellerState;
newModel.categoryname = model.categoryname; newModel.categoryName = model.categoryName;
newModel.brandName = model.brandName; newModel.brandName = model.brandName;
newModel.fid = model.fid; newModel.fid = model.fid;
newModel.createDate = model.createDate; newModel.createDate = model.createDate;
......
//
// ShareGoodsViewController.h
// Lighting
//
// Created by 曹云霄 on 16/6/3.
// Copyright © 2016年 上海勾芒科技有限公司. All rights reserved.
//
#import "BaseViewController.h"
@protocol SharePicturedelegate <NSObject>
//回调
- (void)ShareProductImage:(UIImage *)image ;
/**
* 上传图片进度(显示)
*/
- (void)UploadImageProgress:(double)progress;
/**
* 上传完成
*/
- (void)UploadImageSuccess;
/**
* 上传失败
*/
- (void)UploadImageFailue;
@end
@interface ShareGoodsViewController : BaseViewController
/**
* 需要分享的图片
*/
@property (nonatomic,strong) UIImage *shareImage;
/**
* 分享的商品id
*/
@property (nonatomic,copy) NSString *goodsIds;
/**
* 代理
*/
@property (nonatomic,assign) id<SharePicturedelegate> delegate;
@end
//
// ShareGoodsViewController.m
// Lighting
//
// Created by 曹云霄 on 16/6/3.
// Copyright © 2016年 上海勾芒科技有限公司. All rights reserved.
//
#import "ShareGoodsViewController.h"
@interface ShareGoodsViewController ()
@end
@implementation ShareGoodsViewController
- (void)viewDidLoad {
[super viewDidLoad];
// Do any additional setup after loading the view from its nib.
}
- (void)didReceiveMemoryWarning {
[super didReceiveMemoryWarning];
// Dispose of any resources that can be recreated.
}
#pragma mark -分享
- (IBAction)ShareWeiChatAntWeiboAction:(UIButton *)sender {
[self dismissViewControllerAnimated:YES completion:nil];
NSData *imageData = UIImageJPEGRepresentation(self.shareImage, 1.0);
// 0b44439e5504e371015504f73d4f0025,0b44439e5504e371015504feae270028
NSDictionary *parameterDict = [NSDictionary dictionaryWithObjectsAndKeys:@"0b44439e5504e371015504f73d4f0025,0b44439e5504e371015504feae270028",@"goodsIds",@"",@"title",@"",@"remark",nil];
//上传图片
[[NetworkRequestClassManager Manager] UploadImageWithURL:[NSString stringWithFormat:@"%@%@",ServerAddress,@"/system/shareGoods"] WithRequestType:0 WithImageDatas:imageData WithParameter:parameterDict WithReturnValueBlock:^(id returnValue) {
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: //微信好友
{//自定义样式
//使用UMShareToWechatSession,UMShareToWechatTimeline,UMShareToWechatFavorite分别代表微信好友、微信朋友圈、微信收藏
[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) {
[self SuccessMBProgressView:@"分享微信好友成功"];
}
}];
}
break;
case 102://微信朋友圈
{
//使用UMShareToWechatSession,UMShareToWechatTimeline,UMShareToWechatFavorite分别代表微信好友、微信朋友圈、微信收藏
[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) {
[self SuccessMBProgressView:@"分享微信朋友圈成功"];
}
}];
}
break;
case 103://新浪微博
{
//自定义分享样式
[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) {
[self SuccessMBProgressView:@"分享新浪微博成功"];
}
}];
}
break;
default:
break;
}
}else
{
[self ErrorMBProgressView:returnValue[@"message"]];
}
}WithprogressBlock:^(double progress) {
if (progress >= 1) {
if ([self.delegate respondsToSelector:@selector(UploadImageSuccess)]) {
[self.delegate UploadImageSuccess];
}
}else
{
if ([self.delegate respondsToSelector:@selector(UploadImageProgress:)]) {
[self.delegate UploadImageProgress:progress];
}
}
} WithErrorCodeBlock:^(id errorCodeValue) {
} WithFailureBlock:^(NSError *error) {
if ([self.delegate respondsToSelector:@selector(UploadImageFailue)]) {
[self.delegate UploadImageFailue];
}
[self ErrorMBProgressView:error.localizedDescription];
}];
}
@end
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="10117" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES">
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="ShareGoodsViewController">
<connections>
<outlet property="view" destination="i5M-Pr-FkT" id="sfx-zR-JGt"/>
</connections>
</placeholder>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<view clearsContextBeforeDrawing="NO" contentMode="scaleToFill" id="i5M-Pr-FkT">
<rect key="frame" x="0.0" y="0.0" width="290" height="120"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<button opaque="NO" tag="100" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="rpz-DZ-thX">
<rect key="frame" x="17" y="20" width="80" height="80"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<inset key="titleEdgeInsets" minX="-59" minY="61" maxX="0.0" maxY="0.0"/>
<inset key="imageEdgeInsets" minX="11" minY="-22" maxX="0.0" maxY="0.0"/>
<state key="normal" title="微信" image="wechat">
<color key="titleColor" white="0.33333333333333331" alpha="1" colorSpace="calibratedWhite"/>
</state>
<connections>
<action selector="ShareWeiChatAntWeiboAction:" destination="-1" eventType="touchUpInside" id="oQJ-kM-Ca6"/>
</connections>
</button>
<button opaque="NO" tag="102" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="nwv-gn-bLJ">
<rect key="frame" x="193" y="20" width="80" height="80"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<inset key="titleEdgeInsets" minX="-59" minY="61" maxX="0.0" maxY="0.0"/>
<inset key="imageEdgeInsets" minX="11" minY="-22" maxX="0.0" maxY="0.0"/>
<state key="normal" title="微博" image="weibo">
<color key="titleColor" white="0.33333333333333331" alpha="1" colorSpace="calibratedWhite"/>
</state>
<connections>
<action selector="ShareWeiChatAntWeiboAction:" destination="-1" eventType="touchUpInside" id="uFH-1Q-GMU"/>
</connections>
</button>
<button opaque="NO" tag="101" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="z9x-vh-bIz">
<rect key="frame" x="105" y="20" width="80" height="80"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<inset key="titleEdgeInsets" minX="-59" minY="61" maxX="0.0" maxY="0.0"/>
<inset key="imageEdgeInsets" minX="11" minY="-22" maxX="0.0" maxY="0.0"/>
<state key="normal" title="微信朋友圈" image="Friends-Circle">
<color key="titleColor" white="0.33333333333333331" alpha="1" colorSpace="calibratedWhite"/>
</state>
<connections>
<action selector="ShareWeiChatAntWeiboAction:" destination="-1" eventType="touchUpInside" id="IEt-es-A3G"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="rpz-DZ-thX" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" constant="20" id="2DR-cN-FHA"/>
<constraint firstItem="nwv-gn-bLJ" firstAttribute="height" secondItem="rpz-DZ-thX" secondAttribute="height" id="5z1-k0-fZq"/>
<constraint firstItem="z9x-vh-bIz" firstAttribute="leading" secondItem="rpz-DZ-thX" secondAttribute="trailing" constant="8" id="CoU-bx-U60"/>
<constraint firstAttribute="bottom" secondItem="z9x-vh-bIz" secondAttribute="bottom" constant="20" id="I60-JS-uqx"/>
<constraint firstAttribute="trailing" secondItem="nwv-gn-bLJ" secondAttribute="trailing" constant="17" id="J8o-zb-XCs"/>
<constraint firstItem="z9x-vh-bIz" firstAttribute="height" secondItem="rpz-DZ-thX" secondAttribute="height" id="O9a-zj-XTx"/>
<constraint firstAttribute="bottom" secondItem="rpz-DZ-thX" secondAttribute="bottom" constant="20" id="PKX-Gz-Z7H"/>
<constraint firstItem="nwv-gn-bLJ" firstAttribute="width" secondItem="rpz-DZ-thX" secondAttribute="width" id="QEI-kO-Md0"/>
<constraint firstItem="z9x-vh-bIz" firstAttribute="leading" secondItem="rpz-DZ-thX" secondAttribute="trailing" constant="8" id="QSy-bA-kCg"/>
<constraint firstAttribute="bottom" secondItem="nwv-gn-bLJ" secondAttribute="bottom" constant="20" id="T7S-pu-yWb"/>
<constraint firstItem="rpz-DZ-thX" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" constant="17" id="Wtr-rA-mBx"/>
<constraint firstItem="nwv-gn-bLJ" firstAttribute="leading" secondItem="z9x-vh-bIz" secondAttribute="trailing" constant="8" id="ZhL-Kb-bqk"/>
<constraint firstItem="nwv-gn-bLJ" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" constant="20" id="dVy-iV-xhB"/>
<constraint firstItem="z9x-vh-bIz" firstAttribute="width" secondItem="rpz-DZ-thX" secondAttribute="width" id="hLP-b4-Xdo"/>
<constraint firstItem="z9x-vh-bIz" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" constant="20" id="p1r-W5-L6A"/>
<constraint firstItem="nwv-gn-bLJ" firstAttribute="leading" secondItem="z9x-vh-bIz" secondAttribute="trailing" constant="8" id="rm9-Yx-kGd"/>
</constraints>
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
<point key="canvasLocation" x="406" y="219"/>
</view>
</objects>
<resources>
<image name="Friends-Circle" width="60" height="60"/>
<image name="wechat" width="60" height="60"/>
<image name="weibo" width="60" height="60"/>
</resources>
</document>
This diff is collapsed.
...@@ -61,9 +61,8 @@ ...@@ -61,9 +61,8 @@
@end @end
@implementation DataDict @implementation RsEmployeeRequest
@synthesize typename; @synthesize employee;
@synthesize typecode;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -73,15 +72,10 @@ ...@@ -73,15 +72,10 @@
@end @end
@implementation GoodsCondition @implementation GoodsCategory
@synthesize nameLike; @synthesize fid;
@synthesize categoryEquals; @synthesize name;
@synthesize styleEquals; @synthesize children;
@synthesize spaceEquals;
@synthesize materialEqueals;
@synthesize startprice;
@synthesize endprice;
@synthesize page;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -89,6 +83,14 @@ ...@@ -89,6 +83,14 @@
} }
+(JSONKeyMapper*)keyMapper
{
return [[JSONKeyMapper alloc] initWithDictionary:@{
@"id": @"fid",
}];
}
@end @end
@implementation GoodsFilter @implementation GoodsFilter
...@@ -106,12 +108,8 @@ ...@@ -106,12 +108,8 @@
@end @end
@implementation OrderBill @implementation HotFilter
@synthesize datapage; @synthesize list;
@synthesize order;
@synthesize orderdetailList;
@synthesize consumer;
@synthesize employee;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -146,9 +144,10 @@ ...@@ -146,9 +144,10 @@
@end @end
@implementation SceneFilter @implementation SceneCondition
@synthesize styles; @synthesize styleEquals;
@synthesize space; @synthesize spaceEquals;
@synthesize page;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -158,8 +157,9 @@ ...@@ -158,8 +157,9 @@
@end @end
@implementation RsShippingAddrEntity @implementation SceneFilter
@synthesize list; @synthesize styles;
@synthesize space;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -169,10 +169,8 @@ ...@@ -169,10 +169,8 @@
@end @end
@implementation SaveShoppingCartRequest @implementation DeleteCartRequest
@synthesize consumerId; @synthesize cartIds;
@synthesize goodsId;
@synthesize count;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -194,21 +192,9 @@ ...@@ -194,21 +192,9 @@
@end @end
@implementation TOConsumerEntity @implementation RsShareResponse
@synthesize fid; @synthesize shareId;
@synthesize createName; @synthesize url;
@synthesize createBy;
@synthesize createDate;
@synthesize sysOrgCode;
@synthesize name;
@synthesize mobile;
@synthesize province;
@synthesize city;
@synthesize country;
@synthesize address;
@synthesize picture;
@synthesize lastVisitedTime;
@synthesize company;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -216,17 +202,14 @@ ...@@ -216,17 +202,14 @@
} }
+(JSONKeyMapper*)keyMapper
{
return [[JSONKeyMapper alloc] initWithDictionary:@{
@"id": @"fid",
}];
}
@end @end
@implementation VOResellerGoodsEntity @implementation TOGoodsEntity
@synthesize resellerInv;
@synthesize resellerTagPrice;
@synthesize resellerState;
@synthesize categoryName;
@synthesize brandName;
@synthesize fid; @synthesize fid;
@synthesize createDate; @synthesize createDate;
@synthesize onlineTime; @synthesize onlineTime;
...@@ -261,9 +244,6 @@ ...@@ -261,9 +244,6 @@
@synthesize lightNumber; @synthesize lightNumber;
@synthesize pictures; @synthesize pictures;
@synthesize barcode; @synthesize barcode;
@synthesize resellerId;
@synthesize categoryName;
@synthesize brandName;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -281,13 +261,18 @@ ...@@ -281,13 +261,18 @@
@end @end
@implementation TOGoodsCategoryEntity @implementation TOGoodsBrandEntity
@synthesize upperName;
@synthesize fid; @synthesize fid;
@synthesize createName;
@synthesize createBy;
@synthesize createDate;
@synthesize sysOrgCode;
@synthesize sysCompanyCode;
@synthesize code; @synthesize code;
@synthesize name; @synthesize name;
@synthesize upperId; @synthesize state;
@synthesize level; @synthesize logo;
@synthesize fdescription;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -298,6 +283,7 @@ ...@@ -298,6 +283,7 @@
+(JSONKeyMapper*)keyMapper +(JSONKeyMapper*)keyMapper
{ {
return [[JSONKeyMapper alloc] initWithDictionary:@{ return [[JSONKeyMapper alloc] initWithDictionary:@{
@"description": @"fdescription",
@"id": @"fid", @"id": @"fid",
}]; }];
} }
...@@ -305,12 +291,13 @@ ...@@ -305,12 +291,13 @@
@end @end
@implementation TOGoodsLabelCategoryEntity @implementation TOGoodsLabelEntity
@synthesize category;
@synthesize fid; @synthesize fid;
@synthesize sysOrgCode; @synthesize sysOrgCode;
@synthesize sysCompanyCode; @synthesize sysCompanyCode;
@synthesize code;
@synthesize name; @synthesize name;
@synthesize categoryId;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -353,6 +340,7 @@ ...@@ -353,6 +340,7 @@
@synthesize payType; @synthesize payType;
@synthesize consumerName; @synthesize consumerName;
@synthesize guideName; @synthesize guideName;
@synthesize resellerName;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -533,33 +521,12 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -533,33 +521,12 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@end @end
@implementation TOHottagEntity @implementation TOGoodsLabelCategoryEntity
@synthesize fid;
@synthesize name;
+(BOOL)propertyIsOptional:(NSString*)propertyName
{
return YES;
}
+(JSONKeyMapper*)keyMapper
{
return [[JSONKeyMapper alloc] initWithDictionary:@{
@"id": @"fid",
}];
}
@end
@implementation TOGoodsLabelEntity
@synthesize category;
@synthesize fid; @synthesize fid;
@synthesize sysOrgCode; @synthesize sysOrgCode;
@synthesize sysCompanyCode; @synthesize sysCompanyCode;
@synthesize code;
@synthesize name; @synthesize name;
@synthesize categoryId;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -577,18 +544,13 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -577,18 +544,13 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@end @end
@implementation TOGoodsBrandEntity @implementation TOGoodsCategoryEntity
@synthesize upperName;
@synthesize fid; @synthesize fid;
@synthesize createName;
@synthesize createBy;
@synthesize createDate;
@synthesize sysOrgCode;
@synthesize sysCompanyCode;
@synthesize code; @synthesize code;
@synthesize name; @synthesize name;
@synthesize state; @synthesize upperId;
@synthesize logo; @synthesize level;
@synthesize fdescription;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -599,7 +561,6 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -599,7 +561,6 @@ NSString * const SORTDIRECTION_DESC = @"desc";
+(JSONKeyMapper*)keyMapper +(JSONKeyMapper*)keyMapper
{ {
return [[JSONKeyMapper alloc] initWithDictionary:@{ return [[JSONKeyMapper alloc] initWithDictionary:@{
@"description": @"fdescription",
@"id": @"fid", @"id": @"fid",
}]; }];
} }
...@@ -607,12 +568,7 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -607,12 +568,7 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@end @end
@implementation TOGoodsEntity @implementation VOResellerGoodsEntity
@synthesize resellerInv;
@synthesize resellerTagPrice;
@synthesize resellerState;
@synthesize categoryname;
@synthesize brandName;
@synthesize fid; @synthesize fid;
@synthesize createDate; @synthesize createDate;
@synthesize onlineTime; @synthesize onlineTime;
...@@ -647,6 +603,9 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -647,6 +603,9 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@synthesize lightNumber; @synthesize lightNumber;
@synthesize pictures; @synthesize pictures;
@synthesize barcode; @synthesize barcode;
@synthesize resellerId;
@synthesize categoryName;
@synthesize brandName;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -664,9 +623,21 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -664,9 +623,21 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@end @end
@implementation RsShareResponse @implementation TOConsumerEntity
@synthesize shareId; @synthesize fid;
@synthesize url; @synthesize createName;
@synthesize createBy;
@synthesize createDate;
@synthesize sysOrgCode;
@synthesize name;
@synthesize mobile;
@synthesize province;
@synthesize city;
@synthesize country;
@synthesize address;
@synthesize picture;
@synthesize lastVisitedTime;
@synthesize company;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -674,10 +645,20 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -674,10 +645,20 @@ NSString * const SORTDIRECTION_DESC = @"desc";
} }
+(JSONKeyMapper*)keyMapper
{
return [[JSONKeyMapper alloc] initWithDictionary:@{
@"id": @"fid",
}];
}
@end @end
@implementation DeleteCartRequest @implementation SaveShoppingCartRequest
@synthesize cartIds; @synthesize consumerId;
@synthesize goodsId;
@synthesize count;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -687,10 +668,8 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -687,10 +668,8 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@end @end
@implementation SceneCondition @implementation RsShippingAddrEntity
@synthesize styleEquals; @synthesize list;
@synthesize spaceEquals;
@synthesize page;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -700,8 +679,12 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -700,8 +679,12 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@end @end
@implementation HotTagResponse @implementation OrderBill
@synthesize list; @synthesize datapage;
@synthesize order;
@synthesize orderdetailList;
@synthesize consumer;
@synthesize employee;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -711,10 +694,15 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -711,10 +694,15 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@end @end
@implementation GoodsCategory @implementation GoodsCondition
@synthesize fid; @synthesize nameLike;
@synthesize name; @synthesize categoryEquals;
@synthesize children; @synthesize styleEquals;
@synthesize spaceEquals;
@synthesize materialEqueals;
@synthesize startprice;
@synthesize endprice;
@synthesize page;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
...@@ -722,11 +710,15 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -722,11 +710,15 @@ NSString * const SORTDIRECTION_DESC = @"desc";
} }
+(JSONKeyMapper*)keyMapper @end
@implementation DataDict
@synthesize typename;
@synthesize typecode;
+(BOOL)propertyIsOptional:(NSString*)propertyName
{ {
return [[JSONKeyMapper alloc] initWithDictionary:@{ return YES;
@"id": @"fid",
}];
} }
...@@ -945,6 +937,7 @@ NSString * const SORTDIRECTION_DESC = @"desc"; ...@@ -945,6 +937,7 @@ NSString * const SORTDIRECTION_DESC = @"desc";
@implementation TOEmployee @implementation TOEmployee
@synthesize positions; @synthesize positions;
@synthesize picture;
@synthesize positionsName; @synthesize positionsName;
+(BOOL)propertyIsOptional:(NSString*)propertyName +(BOOL)propertyIsOptional:(NSString*)propertyName
......
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