Commit 047c25f6b5a4659582123b443ada116b0b49c289
1 parent
d2bf43ab
Exists in
parentassistant
no message
Showing
9 changed files
with
70 additions
and
31 deletions
Show diff stats
ParentAssistant/ParentAssistant/AppDelegate.swift
| @@ -83,20 +83,12 @@ class AppDelegate: UIResponder, UIApplicationDelegate { | @@ -83,20 +83,12 @@ class AppDelegate: UIResponder, UIApplicationDelegate { | ||
| 83 | } | 83 | } |
| 84 | } | 84 | } |
| 85 | }, failHandler: { (error) in | 85 | }, failHandler: { (error) in |
| 86 | - let imageResource = ZLaunchAdImageResourceConfigure() | ||
| 87 | - imageResource.imageNameOrImageURL = "http://chatm-icon.oss-cn-beijing.aliyuncs.com/pic/pic_20170725104352981.jpg" | ||
| 88 | - imageResource.imageDuration = 5 | ||
| 89 | - imageResource.imageFrame = UIScreen.main.bounds | ||
| 90 | - adView.setImageResource(imageResource, action: { | ||
| 91 | - /// 广告点击 | ||
| 92 | - }) | ||
| 93 | - | ||
| 94 | }) | 86 | }) |
| 95 | }) | 87 | }) |
| 96 | }else{ | 88 | }else{ |
| 97 | // Thread.sleep(forTimeInterval: 5.0)//延长启动页面10秒 | 89 | // Thread.sleep(forTimeInterval: 5.0)//延长启动页面10秒 |
| 98 | let view = UIView(frame: CGRect(x: 0, y: 0, width: getScreenWidth(), height: getScreenHeight())) | 90 | let view = UIView(frame: CGRect(x: 0, y: 0, width: getScreenWidth(), height: getScreenHeight())) |
| 99 | - view.backgroundColor = UIColor.red | 91 | + view.backgroundColor = UIColor.white |
| 100 | vc.view.addSubview(view) | 92 | vc.view.addSubview(view) |
| 101 | position = 0 | 93 | position = 0 |
| 102 | let _ = Setting.save("\(AppDelegate.version())", forKey: "isFirst") | 94 | let _ = Setting.save("\(AppDelegate.version())", forKey: "isFirst") |
| @@ -110,7 +102,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate { | @@ -110,7 +102,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate { | ||
| 110 | for item in json.contentData().arrayValue { | 102 | for item in json.contentData().arrayValue { |
| 111 | NSLog("************\(HTTPServer.HOSTImage+item["fileSrc"].stringValue.addingPercentEncoding(withAllowedCharacters: .urlQueryAllowed)!)"); images.append(HTTPServer.HOSTImage+item["fileSrc"].stringValue.addingPercentEncoding(withAllowedCharacters: .urlQueryAllowed)!) | 103 | NSLog("************\(HTTPServer.HOSTImage+item["fileSrc"].stringValue.addingPercentEncoding(withAllowedCharacters: .urlQueryAllowed)!)"); images.append(HTTPServer.HOSTImage+item["fileSrc"].stringValue.addingPercentEncoding(withAllowedCharacters: .urlQueryAllowed)!) |
| 112 | } | 104 | } |
| 113 | - LaunchIntroductionView.shared(withImages: images, buttonImage: "icon_image", buttonFrame: CGRect(x: getScreenWidth()/2-551/4, y: getScreenHeight()-150, width: 551/2, height: 45)) | 105 | + LaunchIntroductionView.shared(withImages: images, buttonImage: "icon_getin", buttonFrame: CGRect(x: getScreenWidth()/2-551/4, y: getScreenHeight()-150, width: 551/2, height: 45)) |
| 114 | } | 106 | } |
| 115 | } | 107 | } |
| 116 | }, failHandler: { (error) in | 108 | }, failHandler: { (error) in |
ParentAssistant/ParentAssistant/Classes/controllers/report/ReportViewController.swift
| @@ -20,15 +20,22 @@ class ReportViewController: UIViewController { | @@ -20,15 +20,22 @@ class ReportViewController: UIViewController { | ||
| 20 | //设置顶部按钮 | 20 | //设置顶部按钮 |
| 21 | setupNavigationBar() | 21 | setupNavigationBar() |
| 22 | //设置日期页面 | 22 | //设置日期页面 |
| 23 | - setupDateView() | 23 | +// setupDateView() |
| 24 | } | 24 | } |
| 25 | // MARK: - 设置顶部按钮 | 25 | // MARK: - 设置顶部按钮 |
| 26 | func setupNavigationBar(){ | 26 | func setupNavigationBar(){ |
| 27 | self.navigationController?.navigationBar.barStyle = UIBarStyle.default// UIColorFromRGB(0xC5DAFF) | 27 | self.navigationController?.navigationBar.barStyle = UIBarStyle.default// UIColorFromRGB(0xC5DAFF) |
| 28 | let backImage = UIImage(named: "navigationBar_backgrounImage") | 28 | let backImage = UIImage(named: "navigationBar_backgrounImage") |
| 29 | self.navigationController?.navigationBar.setBackgroundImage(backImage, for: UIBarMetrics.default) | 29 | self.navigationController?.navigationBar.setBackgroundImage(backImage, for: UIBarMetrics.default) |
| 30 | + self.configTheme() | ||
| 30 | self.navigationItem.title = "报告" | 31 | self.navigationItem.title = "报告" |
| 31 | // setuptitleView() | 32 | // setuptitleView() |
| 33 | + | ||
| 34 | + } | ||
| 35 | + func setuptitleView(){ | ||
| 36 | + // MARK: - 设置顶部的titleView | ||
| 37 | + titleView = Bundle.main.loadNibNamed("ReportHeaderView", owner: nil, options: nil)![0] as! ReportHeaderView | ||
| 38 | + titleView.delegate = self | ||
| 32 | titleView.frame = CGRect(x: 0, y: 0, width: screenWidth, height: 44) | 39 | titleView.frame = CGRect(x: 0, y: 0, width: screenWidth, height: 44) |
| 33 | self.navigationItem.titleView = titleView | 40 | self.navigationItem.titleView = titleView |
| 34 | titleView.layoutSubviews() | 41 | titleView.layoutSubviews() |
| @@ -43,11 +50,6 @@ class ReportViewController: UIViewController { | @@ -43,11 +50,6 @@ class ReportViewController: UIViewController { | ||
| 43 | titleView.nameButton.setTitle("未登录", for: UIControlState.normal) | 50 | titleView.nameButton.setTitle("未登录", for: UIControlState.normal) |
| 44 | } | 51 | } |
| 45 | } | 52 | } |
| 46 | - func setuptitleView(){ | ||
| 47 | - // MARK: - 设置顶部的titleView | ||
| 48 | - titleView = Bundle.main.loadNibNamed("ReportHeaderView", owner: nil, options: nil)![0] as! ReportHeaderView | ||
| 49 | - titleView.delegate = self | ||
| 50 | - } | ||
| 51 | // MARK: - 设置日期页面 | 53 | // MARK: - 设置日期页面 |
| 52 | func setupDateView(){ | 54 | func setupDateView(){ |
| 53 | titleView.dateButton.setTitle("\(getCurrentDate())", for: UIControlState.normal) | 55 | titleView.dateButton.setTitle("\(getCurrentDate())", for: UIControlState.normal) |
| @@ -144,7 +146,7 @@ extension ReportViewController: UICollectionViewDelegate,UICollectionViewDataSou | @@ -144,7 +146,7 @@ extension ReportViewController: UICollectionViewDelegate,UICollectionViewDataSou | ||
| 144 | return CGSize(width: getScreenWidth()/7, height: getScreenWidth()/7) | 146 | return CGSize(width: getScreenWidth()/7, height: getScreenWidth()/7) |
| 145 | } | 147 | } |
| 146 | func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { | 148 | func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { |
| 147 | - return 7 | 149 | + return 0 |
| 148 | } | 150 | } |
| 149 | 151 | ||
| 150 | func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { | 152 | func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { |
ParentAssistant/ParentAssistant/Classes/util/network.swift
| @@ -85,14 +85,10 @@ final class HTTPServer{ | @@ -85,14 +85,10 @@ final class HTTPServer{ | ||
| 85 | static let shared = HTTPServer() | 85 | static let shared = HTTPServer() |
| 86 | init() {} | 86 | init() {} |
| 87 | 87 | ||
| 88 | - static let WEB_HELP="http://60.190.202.57:8101/FeedBack.aspx?userid=" | ||
| 89 | - static let WEB_ABOUT="http://60.190.202.57:8101/About.html" | ||
| 90 | - | ||
| 91 | - | ||
| 92 | let appsecret="sincere:3a530f39f99411b454e667d69693c127" | 88 | let appsecret="sincere:3a530f39f99411b454e667d69693c127" |
| 93 | static var ReleaseHOST:String!="http://campus.myjxt.com"//正式网址 | 89 | static var ReleaseHOST:String!="http://campus.myjxt.com"//正式网址 |
| 94 | - static var ReleaseHOSTWap:String!="http://hxy.myjxt.com" | ||
| 95 | - static var ReleaseHOSTImage:String!="http://60.190.202.57:8196" | 90 | + static var ReleaseHOSTWap:String!="http://parent.myjxt.com" |
| 91 | + static var ReleaseHOSTImage:String!="http://manage.myjxt.com" | ||
| 96 | static var DebugHOST:String!="http://60.190.202.57:1000"//测试网址 | 92 | static var DebugHOST:String!="http://60.190.202.57:1000"//测试网址 |
| 97 | static var DebugHOSTWap:String!="http://60.190.202.57:8101" | 93 | static var DebugHOSTWap:String!="http://60.190.202.57:8101" |
| 98 | static var DebugHOSTImage:String!="http://60.190.202.57:8196" | 94 | static var DebugHOSTImage:String!="http://60.190.202.57:8196" |
ParentAssistant/ParentAssistant/NIM/YXMessageManager.swift
| @@ -144,6 +144,13 @@ class YXMessageManager: NSObject,NIMLoginManagerDelegate,NIMSystemNotificationMa | @@ -144,6 +144,13 @@ class YXMessageManager: NSObject,NIMLoginManagerDelegate,NIMSystemNotificationMa | ||
| 144 | attachItem.ownId = AccountManager.shared.userid | 144 | attachItem.ownId = AccountManager.shared.userid |
| 145 | attachItem.save() | 145 | attachItem.save() |
| 146 | NotificationCenter.default.post(name: Notification.Name(rawValue: MessageNotification.receiveMessage), object: nil, userInfo: nil) | 146 | NotificationCenter.default.post(name: Notification.Name(rawValue: MessageNotification.receiveMessage), object: nil, userInfo: nil) |
| 147 | + }else if info["type"].stringValue=="ordermess"{//订购通知 | ||
| 148 | + let attachItem = NSManagedObject.creatWith(identifier: "Message") as! Message | ||
| 149 | + attachItem.date=Date(timeIntervalSince1970: notification.timestamp) | ||
| 150 | + attachItem.content = info["content"].stringValue | ||
| 151 | + attachItem.ownId = AccountManager.shared.userid | ||
| 152 | + attachItem.save() | ||
| 153 | + NotificationCenter.default.post(name: Notification.Name(rawValue: MessageNotification.receiveMessage), object: nil, userInfo: nil) | ||
| 147 | } | 154 | } |
| 148 | } | 155 | } |
| 149 | } | 156 | } |
ParentAssistant/ParentAssistant/Supporting Files/Assets.xcassets/icon_getin.imageset/Contents.json
0 → 100644
| @@ -0,0 +1,21 @@ | @@ -0,0 +1,21 @@ | ||
| 1 | +{ | ||
| 2 | + "images" : [ | ||
| 3 | + { | ||
| 4 | + "idiom" : "universal", | ||
| 5 | + "scale" : "1x" | ||
| 6 | + }, | ||
| 7 | + { | ||
| 8 | + "idiom" : "universal", | ||
| 9 | + "filename" : "icon.png", | ||
| 10 | + "scale" : "2x" | ||
| 11 | + }, | ||
| 12 | + { | ||
| 13 | + "idiom" : "universal", | ||
| 14 | + "scale" : "3x" | ||
| 15 | + } | ||
| 16 | + ], | ||
| 17 | + "info" : { | ||
| 18 | + "version" : 1, | ||
| 19 | + "author" : "xcode" | ||
| 20 | + } | ||
| 21 | +} | ||
| 0 | \ No newline at end of file | 22 | \ No newline at end of file |
ParentAssistant/ParentAssistant/Supporting Files/Assets.xcassets/icon_getin.imageset/icon.png
0 → 100644
2.94 KB
ParentAssistant/ParentAssistant/Supporting Files/Assets.xcassets/report/report_none_icon.imageset/Contents.json
0 → 100644
| @@ -0,0 +1,21 @@ | @@ -0,0 +1,21 @@ | ||
| 1 | +{ | ||
| 2 | + "images" : [ | ||
| 3 | + { | ||
| 4 | + "idiom" : "universal", | ||
| 5 | + "scale" : "1x" | ||
| 6 | + }, | ||
| 7 | + { | ||
| 8 | + "idiom" : "universal", | ||
| 9 | + "filename" : "baogao_back.jpg", | ||
| 10 | + "scale" : "2x" | ||
| 11 | + }, | ||
| 12 | + { | ||
| 13 | + "idiom" : "universal", | ||
| 14 | + "scale" : "3x" | ||
| 15 | + } | ||
| 16 | + ], | ||
| 17 | + "info" : { | ||
| 18 | + "version" : 1, | ||
| 19 | + "author" : "xcode" | ||
| 20 | + } | ||
| 21 | +} | ||
| 0 | \ No newline at end of file | 22 | \ No newline at end of file |
ParentAssistant/ParentAssistant/Supporting Files/Assets.xcassets/report/report_none_icon.imageset/baogao_back.jpg
0 → 100644
8.63 KB
ParentAssistant/ParentAssistant/Supporting Files/Base.lproj/Main.storyboard
| @@ -851,17 +851,16 @@ | @@ -851,17 +851,16 @@ | ||
| 851 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="A43-XP-A41"> | 851 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="A43-XP-A41"> |
| 852 | <rect key="frame" x="0.0" y="64" width="375" height="554"/> | 852 | <rect key="frame" x="0.0" y="64" width="375" height="554"/> |
| 853 | <subviews> | 853 | <subviews> |
| 854 | - <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="该功能暂不开放" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Xcu-Qc-1gt"> | ||
| 855 | - <rect key="frame" x="133.5" y="268" width="107.5" height="18"/> | ||
| 856 | - <fontDescription key="fontDescription" type="system" pointSize="15"/> | ||
| 857 | - <color key="textColor" white="0.33333333333333331" alpha="1" colorSpace="calibratedWhite"/> | ||
| 858 | - <nil key="highlightedColor"/> | ||
| 859 | - </label> | 854 | + <imageView userInteractionEnabled="NO" contentMode="center" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="report_none_icon" translatesAutoresizingMaskIntoConstraints="NO" id="UQe-Gr-lR7"> |
| 855 | + <rect key="frame" x="0.0" y="0.0" width="375" height="554"/> | ||
| 856 | + </imageView> | ||
| 860 | </subviews> | 857 | </subviews> |
| 861 | <color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/> | 858 | <color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/> |
| 862 | <constraints> | 859 | <constraints> |
| 863 | - <constraint firstItem="Xcu-Qc-1gt" firstAttribute="centerX" secondItem="A43-XP-A41" secondAttribute="centerX" id="Fwg-CW-1E4"/> | ||
| 864 | - <constraint firstItem="Xcu-Qc-1gt" firstAttribute="centerY" secondItem="A43-XP-A41" secondAttribute="centerY" id="HhT-1o-bSm"/> | 860 | + <constraint firstItem="UQe-Gr-lR7" firstAttribute="leading" secondItem="A43-XP-A41" secondAttribute="leading" id="IUB-AR-Uxa"/> |
| 861 | + <constraint firstAttribute="trailing" secondItem="UQe-Gr-lR7" secondAttribute="trailing" id="JhX-yG-EaC"/> | ||
| 862 | + <constraint firstItem="UQe-Gr-lR7" firstAttribute="top" secondItem="A43-XP-A41" secondAttribute="top" id="Uj3-Gn-cME"/> | ||
| 863 | + <constraint firstAttribute="bottom" secondItem="UQe-Gr-lR7" secondAttribute="bottom" id="aTh-Mz-V0s"/> | ||
| 865 | </constraints> | 864 | </constraints> |
| 866 | </view> | 865 | </view> |
| 867 | </subviews> | 866 | </subviews> |
| @@ -2260,6 +2259,7 @@ | @@ -2260,6 +2259,7 @@ | ||
| 2260 | <image name="navigationBar_backgrounImage" width="375" height="139"/> | 2259 | <image name="navigationBar_backgrounImage" width="375" height="139"/> |
| 2261 | <image name="report_bar_icon" width="22" height="20"/> | 2260 | <image name="report_bar_icon" width="22" height="20"/> |
| 2262 | <image name="report_bar_icon_select" width="22" height="20"/> | 2261 | <image name="report_bar_icon_select" width="22" height="20"/> |
| 2262 | + <image name="report_none_icon" width="250" height="250"/> | ||
| 2263 | <image name="test001" width="540" height="278"/> | 2263 | <image name="test001" width="540" height="278"/> |
| 2264 | <image name="test002" width="216" height="282"/> | 2264 | <image name="test002" width="216" height="282"/> |
| 2265 | <image name="test003" width="732" height="388"/> | 2265 | <image name="test003" width="732" height="388"/> |