Commit ff09757f authored by Sandy's avatar Sandy

新增项目报表切换页面

parent 69f92aa8
...@@ -19,6 +19,10 @@ ...@@ -19,6 +19,10 @@
19000E911CC71DD200DF8D71 /* MyToolBar.m in Sources */ = {isa = PBXBuildFile; fileRef = 19000E901CC71DD200DF8D71 /* MyToolBar.m */; }; 19000E911CC71DD200DF8D71 /* MyToolBar.m in Sources */ = {isa = PBXBuildFile; fileRef = 19000E901CC71DD200DF8D71 /* MyToolBar.m */; };
19000E941CC74DB000DF8D71 /* SalesInputTotalVIew.m in Sources */ = {isa = PBXBuildFile; fileRef = 19000E931CC74DB000DF8D71 /* SalesInputTotalVIew.m */; }; 19000E941CC74DB000DF8D71 /* SalesInputTotalVIew.m in Sources */ = {isa = PBXBuildFile; fileRef = 19000E931CC74DB000DF8D71 /* SalesInputTotalVIew.m */; };
19000E961CC74DC800DF8D71 /* SalesInputTotalView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 19000E951CC74DC800DF8D71 /* SalesInputTotalView.xib */; }; 19000E961CC74DC800DF8D71 /* SalesInputTotalView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 19000E951CC74DC800DF8D71 /* SalesInputTotalView.xib */; };
190AFD9C1CF41798002698FC /* VankeFloorDetailWebViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 190AFD9A1CF41798002698FC /* VankeFloorDetailWebViewController.m */; };
190AFD9D1CF41798002698FC /* VankeFloorDetailWebViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 190AFD9B1CF41798002698FC /* VankeFloorDetailWebViewController.xib */; };
190AFDA41CF4434F002698FC /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 190AFDA31CF4434F002698FC /* WebKit.framework */; };
190AFDAC1CF55F30002698FC /* ScrollMultipleWebView.m in Sources */ = {isa = PBXBuildFile; fileRef = 190AFDAB1CF55F30002698FC /* ScrollMultipleWebView.m */; };
1912FCDD1CCDDF4B004CF976 /* VankeShopModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 1912FCDC1CCDDF4B004CF976 /* VankeShopModel.m */; }; 1912FCDD1CCDDF4B004CF976 /* VankeShopModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 1912FCDC1CCDDF4B004CF976 /* VankeShopModel.m */; };
1912FCE01CCDE0C4004CF976 /* LoginShopsInstance.m in Sources */ = {isa = PBXBuildFile; fileRef = 1912FCDF1CCDE0C4004CF976 /* LoginShopsInstance.m */; }; 1912FCE01CCDE0C4004CF976 /* LoginShopsInstance.m in Sources */ = {isa = PBXBuildFile; fileRef = 1912FCDF1CCDE0C4004CF976 /* LoginShopsInstance.m */; };
1912FCE31CCDECF8004CF976 /* PaymentTypeModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 1912FCE21CCDECF8004CF976 /* PaymentTypeModel.m */; }; 1912FCE31CCDECF8004CF976 /* PaymentTypeModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 1912FCE21CCDECF8004CF976 /* PaymentTypeModel.m */; };
...@@ -744,6 +748,12 @@ ...@@ -744,6 +748,12 @@
19000E921CC74DB000DF8D71 /* SalesInputTotalVIew.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SalesInputTotalVIew.h; sourceTree = "<group>"; }; 19000E921CC74DB000DF8D71 /* SalesInputTotalVIew.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SalesInputTotalVIew.h; sourceTree = "<group>"; };
19000E931CC74DB000DF8D71 /* SalesInputTotalVIew.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SalesInputTotalVIew.m; sourceTree = "<group>"; }; 19000E931CC74DB000DF8D71 /* SalesInputTotalVIew.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SalesInputTotalVIew.m; sourceTree = "<group>"; };
19000E951CC74DC800DF8D71 /* SalesInputTotalView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = SalesInputTotalView.xib; sourceTree = "<group>"; }; 19000E951CC74DC800DF8D71 /* SalesInputTotalView.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = SalesInputTotalView.xib; sourceTree = "<group>"; };
190AFD991CF41798002698FC /* VankeFloorDetailWebViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VankeFloorDetailWebViewController.h; sourceTree = "<group>"; };
190AFD9A1CF41798002698FC /* VankeFloorDetailWebViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = VankeFloorDetailWebViewController.m; sourceTree = "<group>"; };
190AFD9B1CF41798002698FC /* VankeFloorDetailWebViewController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = VankeFloorDetailWebViewController.xib; sourceTree = "<group>"; };
190AFDA31CF4434F002698FC /* WebKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WebKit.framework; path = System/Library/Frameworks/WebKit.framework; sourceTree = SDKROOT; };
190AFDAA1CF55F30002698FC /* ScrollMultipleWebView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScrollMultipleWebView.h; sourceTree = "<group>"; };
190AFDAB1CF55F30002698FC /* ScrollMultipleWebView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ScrollMultipleWebView.m; sourceTree = "<group>"; };
1912FCDB1CCDDF4B004CF976 /* VankeShopModel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VankeShopModel.h; sourceTree = "<group>"; }; 1912FCDB1CCDDF4B004CF976 /* VankeShopModel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VankeShopModel.h; sourceTree = "<group>"; };
1912FCDC1CCDDF4B004CF976 /* VankeShopModel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = VankeShopModel.m; sourceTree = "<group>"; }; 1912FCDC1CCDDF4B004CF976 /* VankeShopModel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = VankeShopModel.m; sourceTree = "<group>"; };
1912FCDE1CCDE0C4004CF976 /* LoginShopsInstance.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LoginShopsInstance.h; sourceTree = "<group>"; }; 1912FCDE1CCDE0C4004CF976 /* LoginShopsInstance.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LoginShopsInstance.h; sourceTree = "<group>"; };
...@@ -1962,6 +1972,7 @@ ...@@ -1962,6 +1972,7 @@
isa = PBXFrameworksBuildPhase; isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
190AFDA41CF4434F002698FC /* WebKit.framework in Frameworks */,
C1D58B2C1BB1BC9200D297FE /* QuartzCore.framework in Frameworks */, C1D58B2C1BB1BC9200D297FE /* QuartzCore.framework in Frameworks */,
C1D58B241BB1BC9200D297FE /* CoreMedia.framework in Frameworks */, C1D58B241BB1BC9200D297FE /* CoreMedia.framework in Frameworks */,
C1D58B201BB1BC9200D297FE /* AVFoundation.framework in Frameworks */, C1D58B201BB1BC9200D297FE /* AVFoundation.framework in Frameworks */,
...@@ -2058,6 +2069,8 @@ ...@@ -2058,6 +2069,8 @@
C10F180D1BF7ACA80065F18C /* Macro */, C10F180D1BF7ACA80065F18C /* Macro */,
C1E0AD791C12FC7200DE6BB9 /* SRMonthPicker */, C1E0AD791C12FC7200DE6BB9 /* SRMonthPicker */,
C1555F981C04D39600C80B55 /* UIPopoverList */, C1555F981C04D39600C80B55 /* UIPopoverList */,
190AFDAA1CF55F30002698FC /* ScrollMultipleWebView.h */,
190AFDAB1CF55F30002698FC /* ScrollMultipleWebView.m */,
); );
path = 3rd; path = 3rd;
sourceTree = "<group>"; sourceTree = "<group>";
...@@ -2596,6 +2609,9 @@ ...@@ -2596,6 +2609,9 @@
C19BBC0B1BBE861700831290 /* VankeFloorDetailBoardPhoto_iPhone.h */, C19BBC0B1BBE861700831290 /* VankeFloorDetailBoardPhoto_iPhone.h */,
C19BBC0C1BBE861700831290 /* VankeFloorDetailBoardPhoto_iPhone.m */, C19BBC0C1BBE861700831290 /* VankeFloorDetailBoardPhoto_iPhone.m */,
C19BBC0D1BBE861700831290 /* VankeFloorDetailBoardPhoto_iPhone.xml */, C19BBC0D1BBE861700831290 /* VankeFloorDetailBoardPhoto_iPhone.xml */,
190AFD991CF41798002698FC /* VankeFloorDetailWebViewController.h */,
190AFD9A1CF41798002698FC /* VankeFloorDetailWebViewController.m */,
190AFD9B1CF41798002698FC /* VankeFloorDetailWebViewController.xib */,
C16BA6201BD393B7001ACB26 /* VankePassengerDetailBoard_iPhone.h */, C16BA6201BD393B7001ACB26 /* VankePassengerDetailBoard_iPhone.h */,
C16BA6211BD393B7001ACB26 /* VankePassengerDetailBoard_iPhone.m */, C16BA6211BD393B7001ACB26 /* VankePassengerDetailBoard_iPhone.m */,
C16BA6221BD393B7001ACB26 /* VankePassengerDetailBoard_iPhone.xml */, C16BA6221BD393B7001ACB26 /* VankePassengerDetailBoard_iPhone.xml */,
...@@ -2684,6 +2700,7 @@ ...@@ -2684,6 +2700,7 @@
C1D58B181BB1BC9200D297FE /* Frameworks */ = { C1D58B181BB1BC9200D297FE /* Frameworks */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
190AFDA31CF4434F002698FC /* WebKit.framework */,
C1D58B191BB1BC9200D297FE /* UIKit.framework */, C1D58B191BB1BC9200D297FE /* UIKit.framework */,
C1D58B1B1BB1BC9200D297FE /* Foundation.framework */, C1D58B1B1BB1BC9200D297FE /* Foundation.framework */,
C1D58B1D1BB1BC9200D297FE /* CoreGraphics.framework */, C1D58B1D1BB1BC9200D297FE /* CoreGraphics.framework */,
...@@ -4380,6 +4397,7 @@ ...@@ -4380,6 +4397,7 @@
C19ADE401BC8147800206213 /* search@2x.png in Resources */, C19ADE401BC8147800206213 /* search@2x.png in Resources */,
C1A06A0E1BE10B080082006F /* sale_input@2x.png in Resources */, C1A06A0E1BE10B080082006F /* sale_input@2x.png in Resources */,
C19AC8A81C1735E600DE260E /* wave_line@2x.png in Resources */, C19AC8A81C1735E600DE260E /* wave_line@2x.png in Resources */,
190AFD9D1CF41798002698FC /* VankeFloorDetailWebViewController.xib in Resources */,
C11786501C0B3A5900DB7E4B /* red_point@2x.png in Resources */, C11786501C0B3A5900DB7E4B /* red_point@2x.png in Resources */,
19000E8A1CC6215000DF8D71 /* HistoryTopView.xib in Resources */, 19000E8A1CC6215000DF8D71 /* HistoryTopView.xib in Resources */,
C1A06A091BE10B080082006F /* bill.png in Resources */, C1A06A091BE10B080082006F /* bill.png in Resources */,
...@@ -4765,6 +4783,7 @@ ...@@ -4765,6 +4783,7 @@
C1D598841BB44B2000D297FE /* CSSParser.m in Sources */, C1D598841BB44B2000D297FE /* CSSParser.m in Sources */,
C1D5987C1BB44B2000D297FE /* UITextView+BeeUIStyle.m in Sources */, C1D5987C1BB44B2000D297FE /* UITextView+BeeUIStyle.m in Sources */,
C1D599181BB44B2100D297FE /* UIScrollView+XMLParser.m in Sources */, C1D599181BB44B2100D297FE /* UIScrollView+XMLParser.m in Sources */,
190AFDAC1CF55F30002698FC /* ScrollMultipleWebView.m in Sources */,
C16BA62A1BD3952E001ACB26 /* VankePassengerFlowAPI.m in Sources */, C16BA62A1BD3952E001ACB26 /* VankePassengerFlowAPI.m in Sources */,
C10F18131BF7ACA80065F18C /* NSMutableArray+SafeInsert.m in Sources */, C10F18131BF7ACA80065F18C /* NSMutableArray+SafeInsert.m in Sources */,
C1D5995F1BB44B2100D297FE /* Bee_HTTPResponse2.m in Sources */, C1D5995F1BB44B2100D297FE /* Bee_HTTPResponse2.m in Sources */,
...@@ -4781,6 +4800,7 @@ ...@@ -4781,6 +4800,7 @@
C1D598BB1BB44B2000D297FE /* UIView+LifeCycle.m in Sources */, C1D598BB1BB44B2000D297FE /* UIView+LifeCycle.m in Sources */,
C1D5996C1BB44B2100D297FE /* Bee_Reachability.m in Sources */, C1D5996C1BB44B2100D297FE /* Bee_Reachability.m in Sources */,
C1D598EE1BB44B2000D297FE /* UIView+LayoutParser.m in Sources */, C1D598EE1BB44B2000D297FE /* UIView+LayoutParser.m in Sources */,
190AFD9C1CF41798002698FC /* VankeFloorDetailWebViewController.m in Sources */,
C1D599421BB44B2100D297FE /* NSDictionary+BeeExtension.mm in Sources */, C1D599421BB44B2100D297FE /* NSDictionary+BeeExtension.mm in Sources */,
C1D5991F1BB44B2100D297FE /* Bee_Cache.mm in Sources */, C1D5991F1BB44B2100D297FE /* Bee_Cache.mm in Sources */,
C1D5992E1BB44B2100D297FE /* BeeDatabase+BeeActiveRecord.m in Sources */, C1D5992E1BB44B2100D297FE /* BeeDatabase+BeeActiveRecord.m in Sources */,
...@@ -5238,8 +5258,8 @@ ...@@ -5238,8 +5258,8 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = NO; CLANG_ENABLE_MODULES = NO;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = NO; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = NO;
CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_IDENTITY = "iPhone Distribution";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
COMPRESS_PNG_FILES = NO; COMPRESS_PNG_FILES = NO;
ENABLE_STRICT_OBJC_MSGSEND = NO; ENABLE_STRICT_OBJC_MSGSEND = NO;
GCC_PREFIX_HEADER = vanke/vanke.pch; GCC_PREFIX_HEADER = vanke/vanke.pch;
...@@ -5265,8 +5285,8 @@ ...@@ -5265,8 +5285,8 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = NO; CLANG_ENABLE_MODULES = NO;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = NO; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = NO;
CODE_SIGN_IDENTITY = "iPhone Developer: Fanfan Cui (7S27LB84E2)"; CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer: Fanfan Cui (7S27LB84E2)"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COMPRESS_PNG_FILES = NO; COMPRESS_PNG_FILES = NO;
ENABLE_STRICT_OBJC_MSGSEND = NO; ENABLE_STRICT_OBJC_MSGSEND = NO;
GCC_PREFIX_HEADER = vanke/vanke.pch; GCC_PREFIX_HEADER = vanke/vanke.pch;
......
//
// ScrollMultipleWebView.h
// vanke
//
// Created by Z on 16/5/25.
// Copyright © 2016年 gomore. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface ScrollMultipleWebView : UIScrollView
- (instancetype)initWithFrame:(CGRect)frame webViewUrls:(NSArray *)arrUrls;
- (void)updateUrls:(NSArray *)arrUrls;
/** 设置pagecontrol颜色 必须调用,且必须在addSubview之后调用,可以为nil, */
- (void)setPageControlBackgroundColor:(UIColor *)bgColor;
@end
//
// ScrollMultipleWebView.m
// vanke
//
// Created by Z on 16/5/25.
// Copyright © 2016年 gomore. All rights reserved.
//
#import "ScrollMultipleWebView.h"
#import <WebKit/WebKit.h>
@interface ScrollMultipleWebView ()<WKNavigationDelegate, UIScrollViewDelegate>
@property (nonatomic, strong) NSArray *arrUrls;
@property (nonatomic, strong) NSMutableArray *arrWebViews;
@property (nonatomic, strong) NSMutableArray *arrReqs;
@property (nonatomic, strong) NSMutableDictionary *dicFlag;
@property (nonatomic, strong) NSURLRequest *currentReq;
@property (nonatomic, strong) UIPageControl *pageCtrl;
@end
@implementation ScrollMultipleWebView
- (instancetype)initWithFrame:(CGRect)frame webViewUrls:(NSArray *)arrUrls
{
self = [super initWithFrame:frame];
if (self) {
self.arrUrls = arrUrls;
self.delegate = self;
self.contentSize = CGSizeMake(arrUrls.count * frame.size.width, 0);
self.pagingEnabled = YES;
self.showsVerticalScrollIndicator = NO;
CGFloat width = frame.size.width;
CGFloat height = frame.size.height;
for (int i = 0; i < arrUrls.count; i++) {
NSString *jScript;
if (SCREEN_WIDTH != 320) {
jScript = @"var meta = document.createElement('meta');meta.setAttribute('name', 'viewport');meta.setAttribute('content', 'width=device-width, maximum-scale=2.0, user-scalable=no');document.getElementsByTagName('head')[0].appendChild(meta);";
}else{
jScript = @"var meta = document.createElement('meta');meta.setAttribute('name', 'viewport');meta.setAttribute('content', 'width=410, maximum-scale=2.0, user-scalable=no');document.getElementsByTagName('head')[0].appendChild(meta);";
}
WKUserScript *wkUScript = [[WKUserScript alloc] initWithSource:jScript injectionTime:WKUserScriptInjectionTimeAtDocumentEnd forMainFrameOnly:YES];
WKUserContentController *wkUController = [[WKUserContentController alloc] init];
[wkUController addUserScript:wkUScript];
WKWebViewConfiguration *wkWebConfig = [[WKWebViewConfiguration alloc] init];
wkWebConfig.userContentController = wkUController;
WKWebView *webView = [[WKWebView alloc] initWithFrame:CGRectMake(i * frame.size.width, 0, frame.size.width, frame.size.height)
configuration:wkWebConfig
];
NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:arrUrls[i]]];
[self.arrReqs addObject:request];
[self.arrWebViews addObject:webView];
if (i == 0){
[webView loadRequest:request];
self.currentReq = request;
};
[self addSubview:webView];
}
}
return self;
}
- (void)setPageControlBackgroundColor:(UIColor *)bgColor
{
self.pageCtrl = [[UIPageControl alloc] initWithFrame:CGRectMake(0, SCREEN_HEIGHT - 20, self.superview.width, 20)];
NSLog(@"superview.width = %f, screen.width = %f", self.superview.width,SCREEN_WIDTH);
self.pageCtrl.numberOfPages = self.arrUrls.count;
self.pageCtrl.currentPage = 0;
self.pageCtrl.currentPageIndicatorTintColor = [UIColor colorWithWhite:0.500 alpha:0.407];
self.pageCtrl.pageIndicatorTintColor = [UIColor grayColor];
if (bgColor) {
self.pageCtrl.backgroundColor = bgColor;
}
[self.superview addSubview:self.pageCtrl];
}
- (void)scrollViewDidEndDecelerating:(UIScrollView *)scrollView {
NSInteger index = scrollView.contentOffset.x / SCREEN_WIDTH;
self.pageCtrl.currentPage = index;
NSURLRequest *req = [NSURLRequest requestWithURL:[NSURL URLWithString:self.arrUrls[index]]];
WKWebView *webView = self.arrWebViews[index];
self.currentReq = req;
[webView loadRequest:req];
}
- (void)updateUrls:(NSArray *)arrUrls{
self.arrUrls = arrUrls;
for (int i = 0; i < arrUrls.count; i++) {
NSURLRequest *req = self.arrReqs[i];
if ([req isEqual:self.currentReq]) {
WKWebView *web = self.arrWebViews[i];
[web loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:arrUrls[i]]]];
}
}
}
- (NSMutableArray *)arrWebViews {
if (!_arrWebViews) {
_arrWebViews = [NSMutableArray array];
}
return _arrWebViews;
}
- (NSMutableArray *)arrReqs {
if (!_arrReqs) {
_arrReqs = [NSMutableArray array];
}
return _arrReqs;
}
- (NSMutableDictionary *)dicFlag {
if (!_dicFlag) {
_dicFlag = [NSMutableDictionary dictionary];
}
return _dicFlag;
}
- (void)webView:(WKWebView *)webView didFinishNavigation:(WKNavigation *)navigation {
[webView sizeToFit];
}
/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
// Drawing code
}
*/
@end
...@@ -17,11 +17,11 @@ ...@@ -17,11 +17,11 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>1.2.1</string> <string>1.2.2</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>1.2.1</string> <string>1.2.2</string>
<key>LSRequiresIPhoneOS</key> <key>LSRequiresIPhoneOS</key>
<true/> <true/>
<key>NSAppTransportSecurity</key> <key>NSAppTransportSecurity</key>
......
...@@ -21,16 +21,20 @@ ...@@ -21,16 +21,20 @@
// 百度天气服务地址 // 百度天气服务地址
#define VANKE_BAIDU_WEATHER_SERVER_URL @"http://api.map.baidu.com/telematics/v3/weather" #define VANKE_BAIDU_WEATHER_SERVER_URL @"http://api.map.baidu.com/telematics/v3/weather"
// 后台服务基准地址 // 正式环境
//#define VANKE_SERVER_BASE_URL @"http://140.206.62.178:8080/wanke-server/rest" //#define VANKE_SERVER_BASE_URL @"http://140.206.62.178:8080/wanke-server/rest" //正式
// 测试环境 // 测试环境
//#define VANKE_SERVER_BASE_URL @"http://218.244.151.129:7580/wanke-server/rest" #define VANKE_SERVER_BASE_URL @"http://218.244.151.129:7580/wanke-server/rest"
#define VANKE_SERVER_BASE_URL @"http://139.196.39.77:8080/wanke-server/rest" //#define VANKE_SERVER_BASE_URL @"http://139.196.39.77:8080/wanke-server/rest"
// 后台多媒体文件基准地址 // 后台多媒体文件基准地址
#define VANKE_SERVER_MEDIA_BASE_URL @"http://140.206.62.178:8080" //#define VANKE_SERVER_MEDIA_BASE_URL @"http://140.206.62.178:8080" //正式
#define VANKE_SERVER_MEDIA_BASE_URL @"http://192.168.199.198:8080" //川哥环境
//#define VANKE_SERVER_MEDIA_BASE_URL @"http://218.244.151.129:7580"
// 后台服务企业认证码 // 后台服务企业认证码
#define VANKE_AUTHENTI_CODE @"211534962" #define VANKE_AUTHENTI_CODE @"211534962"
......
//
// VankeFloorDetailWebViewController.h
// vanke
//
// Created by Z on 16/5/24.
// Copyright © 2016年 gomore. All rights reserved.
//
#import "IBTUIViewController.h"
#import "VankeFloorListBoardCell_iPhone.h"
@interface VankeFloorDetailWebViewController : IBTUIViewController
- (instancetype)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil FloorValue:(FloorCellValue *)value date:(NSString *)date;
@end
//
// VankeFloorDetailWebViewController.m
// vanke
//
// Created by Z on 16/5/24.
// Copyright © 2016年 gomore. All rights reserved.
//
#import "VankeFloorDetailWebViewController.h"
#import "VankeConfig.h"
#import "UIImageView+WebCache.h"
#import "VankeCommonModel.h"
#import "ScrollMultipleWebView.h"
#import <WebKit/WebKit.h>
@interface VankeFloorDetailWebViewController ()<WKNavigationDelegate>
@property (strong, nonatomic) IBOutlet UIImageView *imgViewTop;
@property (strong, nonatomic) IBOutlet UILabel *labelProjectName;
@property (weak, nonatomic) IBOutlet UILabel *labelDate;
@property (nonatomic, strong) FloorCellValue *floorValue;
@property (nonatomic, strong) NSString *strSelectDate;
@property (nonatomic, strong) ScrollMultipleWebView *webView;
@property (nonatomic, strong) UIDatePicker *datePicker;
@end
@implementation VankeFloorDetailWebViewController
- (instancetype)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil FloorValue:(FloorCellValue *)value date:(NSString *)date {
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
if (self) {
self.floorValue = value;
self.strSelectDate = date;
}
return self;
}
- (void)viewDidLoad {
[super viewDidLoad];
self.view.backgroundColor = [UIColor whiteColor];
self.title = self.floorValue.project.projectName;
self.labelProjectName.text = self.floorValue.project.projectName;
NSString *imgUrl = [NSString stringWithFormat:@"%@/%@", VANKE_SERVER_MEDIA_BASE_URL, self.floorValue.project.picture];
[self.imgViewTop sd_setImageWithURL:[NSURL URLWithString:imgUrl] placeholderImage:[UIImage imageNamed:@"floor-def"]];
UIBarButtonItem *btnRightBar = [[UIBarButtonItem alloc] initWithTitle:@"日期" style:UIBarButtonItemStyleDone target:self action:@selector(actionSelectDate)];
btnRightBar.tintColor = [UIColor whiteColor];
self.navigationItem.rightBarButtonItem = btnRightBar;
[self setUpWebView];
// Do any additional setup after loading the view from its nib.
}
/** 选择日期 */
- (void)actionSelectDate {
UIAlertController *alertController = [UIAlertController alertControllerWithTitle:@"\n\n\n\n\n\n\n\n\n\n\n" message:nil preferredStyle:UIAlertControllerStyleActionSheet];
UIDatePicker *picker;
[alertController.view addSubview:self.datePicker];
[alertController addAction:({
UIAlertAction *action = [UIAlertAction actionWithTitle:@"确定" style:UIAlertActionStyleDefault handler:^(UIAlertAction *action) {
NSDateFormatter *df = [[NSDateFormatter alloc] init];
[df setDateFormat:@"yyyy-MM-dd"];
NSString *dateStr = [df stringFromDate:self.datePicker.date];
self.strSelectDate = dateStr;
[self.webView updateUrls:[self getUrlArr]];
}];
action;
})];
UIPopoverPresentationController *popoverController = alertController.popoverPresentationController;
popoverController.sourceView = self.view;
popoverController.sourceRect = [self.view bounds];
[self presentViewController:alertController animated:YES completion:nil];
}
- (UIDatePicker *)datePicker {
if (!_datePicker) {
_datePicker = [[UIDatePicker alloc] init];
_datePicker.datePickerMode = UIDatePickerModeDate;
NSDate *yesterday = [[NSDate alloc]initWithTimeIntervalSinceNow:-24*60*60];
_datePicker.maximumDate = yesterday;
_datePicker.locale = [NSLocale localeWithLocaleIdentifier:@"zh-Hans"];
[_datePicker setDatePickerMode:UIDatePickerModeDate];
}
return _datePicker;
}
- (void)setUpWebView {
[self.webView removeFromSuperview];
self.labelDate.text = self.strSelectDate;
NSArray *urls = [self getUrlArr];
self.webView = [[ScrollMultipleWebView alloc] initWithFrame:CGRectMake(0, 190.0 + 64, SCREEN_WIDTH, SCREEN_HEIGHT - (190 + 64)) webViewUrls:urls];
[self.view addSubview:self.webView];
[self.webView setPageControlBackgroundColor:nil];
}
- (NSArray *)getUrlArr {
NSString *formatdischart = [NSString stringWithFormat:@"%@/wanke-web/chart/formatdischart.thor?projectid=%@", VANKE_SERVER_MEDIA_BASE_URL,self.floorValue.project.projectId];
NSString *passengersaleschart = [NSString stringWithFormat:@"%@/wanke-web/chart/passengersaleschart.thor?projectid=%@&passengerflowdate=%@",VANKE_SERVER_MEDIA_BASE_URL, self.floorValue.project.projectId, self.strSelectDate];
NSString *flow = [NSString stringWithFormat:@"%@/wanke-web/chart/formatflowchart.thor?projectEquals=%@&salesDateEquals=%@&dimensionTypeEquals=flow", VANKE_SERVER_MEDIA_BASE_URL,self.floorValue.project.projectId,self.strSelectDate];
NSString *sale = [NSString stringWithFormat:@"%@/wanke-web/chart/formatflowchart.thor?projectEquals=%@&salesDateEquals=%@&dimensionTypeEquals=sale", VANKE_SERVER_MEDIA_BASE_URL,self.floorValue.project.projectId,self.strSelectDate];
return @[formatdischart, passengersaleschart, flow, sale];
}
- (void)viewDidLayoutSubviews {
// self.imgViewTop.frame = CGRectMake(0, 64, SCREEN_WIDTH, 220.0 * (SCREEN_WIDTH / 375.0));
}
- (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
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="9532" systemVersion="15D21" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES">
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="9530"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="VankeFloorDetailWebViewController">
<connections>
<outlet property="imgViewTop" destination="8hJ-MZ-YSk" id="BuS-2N-lZW"/>
<outlet property="labelDate" destination="MCn-rG-VxR" id="5kq-g3-lXB"/>
<outlet property="labelProjectName" destination="CIS-IL-rau" id="2jV-Ze-K6r"/>
<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="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="8hJ-MZ-YSk">
<rect key="frame" x="0.0" y="64" width="375" height="190"/>
<constraints>
<constraint firstAttribute="height" constant="190" id="hcr-zq-dSd"/>
</constraints>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="MCn-rG-VxR">
<rect key="frame" x="329" y="227" width="38" height="18"/>
<fontDescription key="fontDescription" type="system" pointSize="15"/>
<color key="textColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="2049@海上传奇" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="CIS-IL-rau">
<rect key="frame" x="8" y="224" width="125" height="21"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="CIS-IL-rau" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" constant="8" id="BCc-K4-Dv6"/>
<constraint firstItem="8hJ-MZ-YSk" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" constant="64" id="C2j-1J-Ufe"/>
<constraint firstItem="MCn-rG-VxR" firstAttribute="bottom" secondItem="CIS-IL-rau" secondAttribute="bottom" id="D9L-FE-887"/>
<constraint firstItem="CIS-IL-rau" firstAttribute="top" secondItem="8hJ-MZ-YSk" secondAttribute="bottom" constant="-30" id="Mb6-AS-ged"/>
<constraint firstAttribute="trailing" secondItem="MCn-rG-VxR" secondAttribute="trailing" constant="8" id="NFj-6i-Nyg"/>
<constraint firstItem="8hJ-MZ-YSk" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" id="f8v-jO-Akg"/>
<constraint firstAttribute="trailing" secondItem="8hJ-MZ-YSk" secondAttribute="trailing" id="hon-Bc-82v"/>
</constraints>
<simulatedScreenMetrics key="simulatedDestinationMetrics" type="retina47"/>
<point key="canvasLocation" x="308.5" y="69.5"/>
</view>
</objects>
</document>
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
#import "VankeFloorListBoardCell_iPhone.h" #import "VankeFloorListBoardCell_iPhone.h"
#import "VankePassengerDetailBoard_iPhone.h" #import "VankePassengerDetailBoard_iPhone.h"
#import "VankePassengerListBoardCell_iPhone.h" #import "VankePassengerListBoardCell_iPhone.h"
#import "VankeFloorDetailWebViewController.h"
@interface VankeFloorListBoard_iPhone () <UISearchBarDelegate> @interface VankeFloorListBoard_iPhone () <UISearchBarDelegate>
@end @end
...@@ -183,7 +183,11 @@ ON_SIGNAL3( VankeFloorListBoard_iPhone, searchBar, signal ) ...@@ -183,7 +183,11 @@ ON_SIGNAL3( VankeFloorListBoard_iPhone, searchBar, signal )
ON_SIGNAL3( VankeFloorListBoardCell_iPhone, mask, signal ) ON_SIGNAL3( VankeFloorListBoardCell_iPhone, mask, signal )
{ {
FloorCellValue *cellValue = signal.sourceCell.data; FloorCellValue *cellValue = signal.sourceCell.data;
[self showDetailView:cellValue]; // [self showDetailView:cellValue];
VankeFloorDetailWebViewController *detailWebVC = [[VankeFloorDetailWebViewController alloc] initWithNibName:@"VankeFloorDetailWebViewController" bundle:nil FloorValue:cellValue date:_salesDate];
[self.navigationController pushViewController:detailWebVC animated:YES];
} }
#pragma mark VankePassengerListBoardCell_iPhone #pragma mark VankePassengerListBoardCell_iPhone
......
...@@ -177,13 +177,17 @@ ON_SIGNAL3( VankeServiceSaleCell_iPhone, btnHistoryMask, signal ) { ...@@ -177,13 +177,17 @@ ON_SIGNAL3( VankeServiceSaleCell_iPhone, btnHistoryMask, signal ) {
} }
ON_SIGNAL3(VankeServiceBoardCell_iPhone, mask, signal) { ON_SIGNAL3(VankeServiceBoardCell_iPhone, mask, signal) {
VankeServiceBoardCell_iPhone *cell = (VankeServiceBoardCell_iPhone *)signal.sourceCell;
if ([@"昨日客流" eq:[cell name]]) { [[VankeAppBoard_iPhone sharedInstance] hideMenu];
[[VankeAppBoard_iPhone sharedInstance] hideMenu]; [self showListView: CELL_TYPE_FLOOR];
[self showListView: CELL_TYPE_PASSENGER];
} else { // VankeServiceBoardCell_iPhone *cell = (VankeServiceBoardCell_iPhone *)signal.sourceCell;
[GEToast showWithText:@"正在研发中..." bottomOffset:50.0f duration:1.0f]; // if ([@"昨日客流" eq:[cell name]]) {
} // [[VankeAppBoard_iPhone sharedInstance] hideMenu];
// [self showListView: CELL_TYPE_PASSENGER];
// } else {
// [GEToast showWithText:@"正在研发中..." bottomOffset:50.0f duration:1.0f];
// }
} }
#pragma mark - VankeProjectSummaryModel #pragma mark - VankeProjectSummaryModel
......
...@@ -45,10 +45,6 @@ ...@@ -45,10 +45,6 @@
self.cellDataDic = [NSMutableDictionary dictionary]; self.cellDataDic = [NSMutableDictionary dictionary];
self.view.backgroundColor = [UIColor whiteColor]; self.view.backgroundColor = [UIColor whiteColor];
if ([LoginShopsInstance shareInstance].arrShops.count > 0) {
self.shop = [LoginShopsInstance shareInstance].arrShops[0];
}
[self setUpNavigationBar]; [self setUpNavigationBar];
[self setUpTopView]; [self setUpTopView];
...@@ -152,9 +148,9 @@ ON_WILL_APPEAR( signal ) ...@@ -152,9 +148,9 @@ ON_WILL_APPEAR( signal )
NSString *strTime = [df stringFromDate:[NSDate date]]; NSString *strTime = [df stringFromDate:[NSDate date]];
topView.textfieldDate.text = strTime; topView.textfieldDate.text = strTime;
WS(weakSelf)
topView.nameTapActionBlock = ^{ topView.nameTapActionBlock = ^{
[self chooseShopAction]; [weakSelf chooseShopAction];
}; };
[self.view addSubview:topView]; [self.view addSubview:topView];
...@@ -297,6 +293,7 @@ ON_WILL_APPEAR( signal ) ...@@ -297,6 +293,7 @@ ON_WILL_APPEAR( signal )
[self.navigationController pushViewController:history animated:YES]; [self.navigationController pushViewController:history animated:YES];
} }
//获取支付方式
- (void)setUpData { - (void)setUpData {
ICRHTTPController *httpCtrl = [ICRHTTPController sharedController]; ICRHTTPController *httpCtrl = [ICRHTTPController sharedController];
...@@ -321,6 +318,8 @@ ON_WILL_APPEAR( signal ) ...@@ -321,6 +318,8 @@ ON_WILL_APPEAR( signal )
- (void)submit { - (void)submit {
if (self.shop == nil) { if (self.shop == nil) {
UIAlertView *alertView = [[UIAlertView alloc] initWithTitle:@"提示" message:@"请选择店铺!" delegate:nil cancelButtonTitle:@"确定" otherButtonTitles:nil, nil];
[alertView show];
}else{ }else{
......
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