diff --git a/GIGA.xcodeproj/project.pbxproj b/GIGA.xcodeproj/project.pbxproj index 850166e..0973647 100644 --- a/GIGA.xcodeproj/project.pbxproj +++ b/GIGA.xcodeproj/project.pbxproj @@ -31,6 +31,7 @@ 8340BFA9213E65CA008F22E4 /* GIGACommonLocalizabe.strings in Resources */ = {isa = PBXBuildFile; fileRef = 8340BFA8213E65CA008F22E4 /* GIGACommonLocalizabe.strings */; }; 8340BFAB213E665D008F22E4 /* GIGAUserLocalizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = 8340BFAA213E665D008F22E4 /* GIGAUserLocalizable.strings */; }; 8340BFAF213E739D008F22E4 /* GiGaNoNetWorkView.m in Sources */ = {isa = PBXBuildFile; fileRef = 8340BFAE213E739D008F22E4 /* GiGaNoNetWorkView.m */; }; + 834127212152AEFB001DDB36 /* GIGaMaskTimeUseRecordVC.m in Sources */ = {isa = PBXBuildFile; fileRef = 834127202152AEFB001DDB36 /* GIGaMaskTimeUseRecordVC.m */; }; 8342D9FD2131150200D16B1D /* 4481.wav in Resources */ = {isa = PBXBuildFile; fileRef = 8342D9FC2131150200D16B1D /* 4481.wav */; }; 8342FD7A2150C51100D141F4 /* GIGaFileManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 8342FD792150C51100D141F4 /* GIGaFileManager.m */; }; 8342FD7D2150F94600D141F4 /* AppVerionDescriptionVC.m in Sources */ = {isa = PBXBuildFile; fileRef = 8342FD7C2150F94600D141F4 /* AppVerionDescriptionVC.m */; }; @@ -46,6 +47,17 @@ 835060A9212D38EE007E6220 /* GiGaStartAdView.m in Sources */ = {isa = PBXBuildFile; fileRef = 835060A8212D38EE007E6220 /* GiGaStartAdView.m */; }; 835060AD212D4D0C007E6220 /* GiGaFileNanager.m in Sources */ = {isa = PBXBuildFile; fileRef = 835060AC212D4D0C007E6220 /* GiGaFileNanager.m */; }; 835060B3212D54C2007E6220 /* GiGaAdDetailViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 835060B2212D54C2007E6220 /* GiGaAdDetailViewController.m */; }; + 835147312151E4EF00B25A88 /* GIGaAboutUsVC.m in Sources */ = {isa = PBXBuildFile; fileRef = 8351472F2151E4EF00B25A88 /* GIGaAboutUsVC.m */; }; + 835147322151E4EF00B25A88 /* GIGaAboutUsVC.xib in Resources */ = {isa = PBXBuildFile; fileRef = 835147302151E4EF00B25A88 /* GIGaAboutUsVC.xib */; }; + 835147352152003700B25A88 /* GiGaFeedBackViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 835147342152003700B25A88 /* GiGaFeedBackViewController.m */; }; + 835147382152147600B25A88 /* GiGaUserInfoVC.m in Sources */ = {isa = PBXBuildFile; fileRef = 835147372152147600B25A88 /* GiGaUserInfoVC.m */; }; + 8351473C215215C500B25A88 /* GiGAUserInfoCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 8351473A215215C500B25A88 /* GiGAUserInfoCell.m */; }; + 8351473D215215C500B25A88 /* GiGAUserInfoCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 8351473B215215C500B25A88 /* GiGAUserInfoCell.xib */; }; + 8351474121521C2A00B25A88 /* GIGaChangePassVC.m in Sources */ = {isa = PBXBuildFile; fileRef = 8351473F21521C2A00B25A88 /* GIGaChangePassVC.m */; }; + 8351474221521C2A00B25A88 /* GIGaChangePassVC.xib in Resources */ = {isa = PBXBuildFile; fileRef = 8351474021521C2A00B25A88 /* GIGaChangePassVC.xib */; }; + 8351474621521CC500B25A88 /* GiGaChangePhoneNumberVC.m in Sources */ = {isa = PBXBuildFile; fileRef = 8351474421521CC500B25A88 /* GiGaChangePhoneNumberVC.m */; }; + 8351474B21523B7400B25A88 /* GIGaUserChangeMobleCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 8351474921523B7400B25A88 /* GIGaUserChangeMobleCell.m */; }; + 8351474C21523B7400B25A88 /* GIGaUserChangeMobleCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 8351474A21523B7400B25A88 /* GIGaUserChangeMobleCell.xib */; }; 8357ADC52123BEBD000816F2 /* GiGaUser.m in Sources */ = {isa = PBXBuildFile; fileRef = 8357ADC42123BEBD000816F2 /* GiGaUser.m */; }; 8357ADC92123BFCA000816F2 /* GiGaUserManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 8357ADC82123BFCA000816F2 /* GiGaUserManager.m */; }; 8357ADCD2123C091000816F2 /* GiGaNetManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 8357ADCC2123C091000816F2 /* GiGaNetManager.m */; }; @@ -223,6 +235,8 @@ 8340BFAA213E665D008F22E4 /* GIGAUserLocalizable.strings */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; path = GIGAUserLocalizable.strings; sourceTree = ""; }; 8340BFAD213E739D008F22E4 /* GiGaNoNetWorkView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiGaNoNetWorkView.h; sourceTree = ""; }; 8340BFAE213E739D008F22E4 /* GiGaNoNetWorkView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiGaNoNetWorkView.m; sourceTree = ""; }; + 8341271F2152AEFB001DDB36 /* GIGaMaskTimeUseRecordVC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GIGaMaskTimeUseRecordVC.h; sourceTree = ""; }; + 834127202152AEFB001DDB36 /* GIGaMaskTimeUseRecordVC.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GIGaMaskTimeUseRecordVC.m; sourceTree = ""; }; 8342D9FC2131150200D16B1D /* 4481.wav */ = {isa = PBXFileReference; lastKnownFileType = audio.wav; path = 4481.wav; sourceTree = ""; }; 8342FD782150C51100D141F4 /* GIGaFileManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GIGaFileManager.h; sourceTree = ""; }; 8342FD792150C51100D141F4 /* GIGaFileManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GIGaFileManager.m; sourceTree = ""; }; @@ -249,6 +263,24 @@ 835060AC212D4D0C007E6220 /* GiGaFileNanager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiGaFileNanager.m; sourceTree = ""; }; 835060B1212D54C2007E6220 /* GiGaAdDetailViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiGaAdDetailViewController.h; sourceTree = ""; }; 835060B2212D54C2007E6220 /* GiGaAdDetailViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiGaAdDetailViewController.m; sourceTree = ""; }; + 8351472E2151E4EF00B25A88 /* GIGaAboutUsVC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GIGaAboutUsVC.h; sourceTree = ""; }; + 8351472F2151E4EF00B25A88 /* GIGaAboutUsVC.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GIGaAboutUsVC.m; sourceTree = ""; }; + 835147302151E4EF00B25A88 /* GIGaAboutUsVC.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = GIGaAboutUsVC.xib; sourceTree = ""; }; + 835147332152003700B25A88 /* GiGaFeedBackViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiGaFeedBackViewController.h; sourceTree = ""; }; + 835147342152003700B25A88 /* GiGaFeedBackViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiGaFeedBackViewController.m; sourceTree = ""; }; + 835147362152147600B25A88 /* GiGaUserInfoVC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiGaUserInfoVC.h; sourceTree = ""; }; + 835147372152147600B25A88 /* GiGaUserInfoVC.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiGaUserInfoVC.m; sourceTree = ""; }; + 83514739215215C500B25A88 /* GiGAUserInfoCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiGAUserInfoCell.h; sourceTree = ""; }; + 8351473A215215C500B25A88 /* GiGAUserInfoCell.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiGAUserInfoCell.m; sourceTree = ""; }; + 8351473B215215C500B25A88 /* GiGAUserInfoCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = GiGAUserInfoCell.xib; sourceTree = ""; }; + 8351473E21521C2A00B25A88 /* GIGaChangePassVC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GIGaChangePassVC.h; sourceTree = ""; }; + 8351473F21521C2A00B25A88 /* GIGaChangePassVC.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GIGaChangePassVC.m; sourceTree = ""; }; + 8351474021521C2A00B25A88 /* GIGaChangePassVC.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = GIGaChangePassVC.xib; sourceTree = ""; }; + 8351474321521CC500B25A88 /* GiGaChangePhoneNumberVC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiGaChangePhoneNumberVC.h; sourceTree = ""; }; + 8351474421521CC500B25A88 /* GiGaChangePhoneNumberVC.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiGaChangePhoneNumberVC.m; sourceTree = ""; }; + 8351474821523B7400B25A88 /* GIGaUserChangeMobleCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GIGaUserChangeMobleCell.h; sourceTree = ""; }; + 8351474921523B7400B25A88 /* GIGaUserChangeMobleCell.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GIGaUserChangeMobleCell.m; sourceTree = ""; }; + 8351474A21523B7400B25A88 /* GIGaUserChangeMobleCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = GIGaUserChangeMobleCell.xib; sourceTree = ""; }; 8357ADC32123BEBD000816F2 /* GiGaUser.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiGaUser.h; sourceTree = ""; }; 8357ADC42123BEBD000816F2 /* GiGaUser.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiGaUser.m; sourceTree = ""; }; 8357ADC72123BFCA000816F2 /* GiGaUserManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiGaUserManager.h; sourceTree = ""; }; @@ -911,6 +943,9 @@ 83BFAE76213CDE91004EF801 /* GiGaSettingsViewCell.xib */, 83048484214FACE700603CE7 /* JobMaskButton.h */, 83048485214FACE700603CE7 /* JobMaskButton.m */, + 83514739215215C500B25A88 /* GiGAUserInfoCell.h */, + 8351473A215215C500B25A88 /* GiGAUserInfoCell.m */, + 8351473B215215C500B25A88 /* GiGAUserInfoCell.xib */, ); path = View; sourceTree = ""; @@ -928,6 +963,20 @@ 83BFAE72213CDB58004EF801 /* GiSysSettingsVC.m */, 8342FD7B2150F94600D141F4 /* AppVerionDescriptionVC.h */, 8342FD7C2150F94600D141F4 /* AppVerionDescriptionVC.m */, + 8351472E2151E4EF00B25A88 /* GIGaAboutUsVC.h */, + 8351472F2151E4EF00B25A88 /* GIGaAboutUsVC.m */, + 835147302151E4EF00B25A88 /* GIGaAboutUsVC.xib */, + 835147332152003700B25A88 /* GiGaFeedBackViewController.h */, + 835147342152003700B25A88 /* GiGaFeedBackViewController.m */, + 835147362152147600B25A88 /* GiGaUserInfoVC.h */, + 835147372152147600B25A88 /* GiGaUserInfoVC.m */, + 8351473E21521C2A00B25A88 /* GIGaChangePassVC.h */, + 8351473F21521C2A00B25A88 /* GIGaChangePassVC.m */, + 8351474021521C2A00B25A88 /* GIGaChangePassVC.xib */, + 8351474321521CC500B25A88 /* GiGaChangePhoneNumberVC.h */, + 8351474421521CC500B25A88 /* GiGaChangePhoneNumberVC.m */, + 8341271F2152AEFB001DDB36 /* GIGaMaskTimeUseRecordVC.h */, + 834127202152AEFB001DDB36 /* GIGaMaskTimeUseRecordVC.m */, ); path = Controller; sourceTree = ""; @@ -1118,6 +1167,9 @@ 838762E6214B9FA60039D241 /* GIGaUserCityViewCell.xib */, 8304847F214F488F00603CE7 /* GiGaUserJobViewCell.h */, 83048480214F488F00603CE7 /* GiGaUserJobViewCell.m */, + 8351474821523B7400B25A88 /* GIGaUserChangeMobleCell.h */, + 8351474921523B7400B25A88 /* GIGaUserChangeMobleCell.m */, + 8351474A21523B7400B25A88 /* GIGaUserChangeMobleCell.xib */, ); path = userInfoView; sourceTree = ""; @@ -1384,6 +1436,7 @@ files = ( 833DE8E42150169F009D4329 /* city.json in Resources */, 83346AC6212BBC8C0054D597 /* GiGaRegistViewController.xib in Resources */, + 8351474C21523B7400B25A88 /* GIGaUserChangeMobleCell.xib in Resources */, 838762DE214B9F140039D241 /* GIGaUserWeChatViewCell.xib in Resources */, 83BFAE6D213CD0E3004EF801 /* GiGaMineInfoViewCell.xib in Resources */, 8361B3D6212155C300238FEB /* LaunchScreen.storyboard in Resources */, @@ -1395,11 +1448,13 @@ 83BFAE78213CDE91004EF801 /* GiGaSettingsViewCell.xib in Resources */, 83346AC1212BB50A0054D597 /* PassWordResetVC.xib in Resources */, 83BDC0592147B89900E74E0D /* GiGaAnswerViewCell.xib in Resources */, + 8351473D215215C500B25A88 /* GiGAUserInfoCell.xib in Resources */, 83346AD1212BF5B70054D597 /* useragreement.html in Resources */, 838762D9214B9EF80039D241 /* GIGaUserIDViewCell.xib in Resources */, 838762E8214B9FA60039D241 /* GIGaUserCityViewCell.xib in Resources */, 8342FD8B2151095100D141F4 /* AppVersionLogoCell.xib in Resources */, 83BFAE68213CCF10004EF801 /* GiGaMineUserViewCell.xib in Resources */, + 8351474221521C2A00B25A88 /* GIGaChangePassVC.xib in Resources */, 8340BFA9213E65CA008F22E4 /* GIGACommonLocalizabe.strings in Resources */, 83835BA8212E4748001480F2 /* MAssaageCenterCell.xib in Resources */, 8361B3D3212155C300238FEB /* Assets.xcassets in Resources */, @@ -1408,6 +1463,7 @@ 8340BFAB213E665D008F22E4 /* GIGAUserLocalizable.strings in Resources */, 8342D9FD2131150200D16B1D /* 4481.wav in Resources */, 83835BB0212E4FCD001480F2 /* MessageListViewCell.xib in Resources */, + 835147322151E4EF00B25A88 /* GIGaAboutUsVC.xib in Resources */, 8342FD832150FA1500D141F4 /* AppVersionDescCell.xib in Resources */, 8338F6B12142182200B4780B /* MaskTime.png in Resources */, 83346ACF212BD7830054D597 /* GiGaWebViewController.xib in Resources */, @@ -1510,6 +1566,7 @@ 83846441214A4BFF00F12B33 /* MaskTestResultVC.m in Sources */, 83346AC5212BBC8C0054D597 /* GiGaRegistViewController.m in Sources */, 83346AD7212C18F50054D597 /* GiGaAppGaurdVC.m in Sources */, + 8351474B21523B7400B25A88 /* GIGaUserChangeMobleCell.m in Sources */, 8349585C212511040064DB6C /* AppDelegate+ThirdParty.m in Sources */, 83048481214F489000603CE7 /* GiGaUserJobViewCell.m in Sources */, 83BFAE73213CDB58004EF801 /* GiSysSettingsVC.m in Sources */, @@ -1534,6 +1591,7 @@ 8342FD7D2150F94600D141F4 /* AppVerionDescriptionVC.m in Sources */, 8357ADC92123BFCA000816F2 /* GiGaUserManager.m in Sources */, 8390116F214E20B2004CA790 /* LYSDatePickerViewController.m in Sources */, + 8351473C215215C500B25A88 /* GiGAUserInfoCell.m in Sources */, 83835BB3212E50ED001480F2 /* ActiveMesagelistVC.m in Sources */, 83835BC3212E677C001480F2 /* GiGaQuestionVC.m in Sources */, 83A2271F212AC8C100B3E75C /* GiGaUserLoginVC.m in Sources */, @@ -1541,10 +1599,13 @@ 83346ACE212BD7830054D597 /* GiGaWebViewController.m in Sources */, 8357ADD82124027D000816F2 /* GiGaUserDefault.m in Sources */, 83835BB6212E5174001480F2 /* GiGaServiceViewController.m in Sources */, + 835147352152003700B25A88 /* GiGaFeedBackViewController.m in Sources */, 8390116E214E20B2004CA790 /* LYSDateLogicViewController.m in Sources */, 8361B40721215E6F00238FEB /* GiGaHelper.m in Sources */, + 835147382152147600B25A88 /* GiGaUserInfoVC.m in Sources */, 83901175214E20B2004CA790 /* LYSDatePickerManager.m in Sources */, 83901173214E20B2004CA790 /* LYSDateBasicViewController.m in Sources */, + 8351474121521C2A00B25A88 /* GIGaChangePassVC.m in Sources */, 8392900F2134FA0A0077D2E8 /* GiGaCommentModel.m in Sources */, 8390116C214E20B2004CA790 /* LYSDatePopViewController.m in Sources */, 83835BA0212E43BD001480F2 /* GiGaMasssagesVC.m in Sources */, @@ -1568,6 +1629,7 @@ 83901179214E20B2004CA790 /* LYSDatePickerTypeBase.m in Sources */, 835060A2212D1225007E6220 /* GiGaMeViewController.m in Sources */, 8361B3CB212155C200238FEB /* AppDelegate.m in Sources */, + 8351474621521CC500B25A88 /* GiGaChangePhoneNumberVC.m in Sources */, 838388C8212F9C4200D14C53 /* GiGaLocalNotificationManager.m in Sources */, 83835BBC212E60E5001480F2 /* MessageDetailViewController.m in Sources */, 83835BCD212E856A001480F2 /* NSString+MD5.m in Sources */, @@ -1590,6 +1652,7 @@ 8392900C2134F9F80077D2E8 /* GiGaCommentView.m in Sources */, 839290062134F4240077D2E8 /* LXDanMuManager.m in Sources */, 833DE8E52150169F009D4329 /* JYAddressPicker.m in Sources */, + 834127212152AEFB001DDB36 /* GIGaMaskTimeUseRecordVC.m in Sources */, 8342FD7A2150C51100D141F4 /* GIGaFileManager.m in Sources */, 83901171214E20B2004CA790 /* LYSDatePickerLabel.m in Sources */, 838762E2214B9F580039D241 /* GiGaUserSexViewCell.m in Sources */, @@ -1597,6 +1660,7 @@ 83E40B2F21218BA0008149C4 /* GiGaUserViewController.m in Sources */, 83901170214E20B2004CA790 /* LYSDateHeaderViewController.m in Sources */, 835060A5212D3536007E6220 /* AppDelegate+GiGaConfig.m in Sources */, + 835147312151E4EF00B25A88 /* GIGaAboutUsVC.m in Sources */, 83901174214E20B2004CA790 /* LYSDateIndicatorViewController.m in Sources */, 83E40B2B21218B6F008149C4 /* GiGaExercisesViewController.m in Sources */, 8390117B214E20B2004CA790 /* LYSDatePickerHeaderView.m in Sources */, diff --git a/GIGA/Assets.xcassets/maskTime/bg_logo.imageset/bg_logo@2x.png b/GIGA/Assets.xcassets/maskTime/bg_logo.imageset/bg_logo@2x.png index a03c696..2854a36 100644 Binary files a/GIGA/Assets.xcassets/maskTime/bg_logo.imageset/bg_logo@2x.png and b/GIGA/Assets.xcassets/maskTime/bg_logo.imageset/bg_logo@2x.png differ diff --git a/GIGA/Assets.xcassets/maskTime/bg_logo.imageset/bg_logo@3x.png b/GIGA/Assets.xcassets/maskTime/bg_logo.imageset/bg_logo@3x.png index 5dcb977..06bc9d9 100644 Binary files a/GIGA/Assets.xcassets/maskTime/bg_logo.imageset/bg_logo@3x.png and b/GIGA/Assets.xcassets/maskTime/bg_logo.imageset/bg_logo@3x.png differ diff --git a/GIGA/Assets.xcassets/maskTime/usergaurd_uphand.imageset/Contents.json b/GIGA/Assets.xcassets/maskTime/usergaurd_uphand.imageset/Contents.json new file mode 100644 index 0000000..a57f5b7 --- /dev/null +++ b/GIGA/Assets.xcassets/maskTime/usergaurd_uphand.imageset/Contents.json @@ -0,0 +1,13 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "usergaurd_uphand@2x.png", + "scale" : "2x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/GIGA/Assets.xcassets/maskTime/usergaurd_uphand.imageset/usergaurd_uphand@2x.png b/GIGA/Assets.xcassets/maskTime/usergaurd_uphand.imageset/usergaurd_uphand@2x.png new file mode 100644 index 0000000..84566df Binary files /dev/null and b/GIGA/Assets.xcassets/maskTime/usergaurd_uphand.imageset/usergaurd_uphand@2x.png differ diff --git a/GIGA/Assets.xcassets/maskTime/userguard_up.imageset/Contents.json b/GIGA/Assets.xcassets/maskTime/userguard_up.imageset/Contents.json new file mode 100644 index 0000000..af274b2 --- /dev/null +++ b/GIGA/Assets.xcassets/maskTime/userguard_up.imageset/Contents.json @@ -0,0 +1,13 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "userguard_up@2x.png", + "scale" : "2x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/GIGA/Assets.xcassets/maskTime/userguard_up.imageset/userguard_up@2x.png b/GIGA/Assets.xcassets/maskTime/userguard_up.imageset/userguard_up@2x.png new file mode 100644 index 0000000..9c1b609 Binary files /dev/null and b/GIGA/Assets.xcassets/maskTime/userguard_up.imageset/userguard_up@2x.png differ diff --git a/GIGA/Assets.xcassets/userCenter/bg_change_newnumber.imageset/Contents.json b/GIGA/Assets.xcassets/userCenter/bg_change_newnumber.imageset/Contents.json new file mode 100644 index 0000000..48d7033 --- /dev/null +++ b/GIGA/Assets.xcassets/userCenter/bg_change_newnumber.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "bg_change_newnumber@2x.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/GIGA/Assets.xcassets/userCenter/bg_change_newnumber.imageset/bg_change_newnumber@2x.png b/GIGA/Assets.xcassets/userCenter/bg_change_newnumber.imageset/bg_change_newnumber@2x.png new file mode 100644 index 0000000..75f53cb Binary files /dev/null and b/GIGA/Assets.xcassets/userCenter/bg_change_newnumber.imageset/bg_change_newnumber@2x.png differ diff --git a/GIGA/Assets.xcassets/userCenter/bg_change_oldnumber.imageset/Contents.json b/GIGA/Assets.xcassets/userCenter/bg_change_oldnumber.imageset/Contents.json new file mode 100644 index 0000000..151473c --- /dev/null +++ b/GIGA/Assets.xcassets/userCenter/bg_change_oldnumber.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "bg_change_oldnumber@2x.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/GIGA/Assets.xcassets/userCenter/bg_change_oldnumber.imageset/bg_change_oldnumber@2x.png b/GIGA/Assets.xcassets/userCenter/bg_change_oldnumber.imageset/bg_change_oldnumber@2x.png new file mode 100644 index 0000000..81e45c8 Binary files /dev/null and b/GIGA/Assets.xcassets/userCenter/bg_change_oldnumber.imageset/bg_change_oldnumber@2x.png differ diff --git a/GIGA/Assets.xcassets/userCenter/btn_changephonesend.imageset/Contents.json b/GIGA/Assets.xcassets/userCenter/btn_changephonesend.imageset/Contents.json new file mode 100644 index 0000000..f24bc43 --- /dev/null +++ b/GIGA/Assets.xcassets/userCenter/btn_changephonesend.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "btn_changephonesend@2x.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/GIGA/Assets.xcassets/userCenter/btn_changephonesend.imageset/btn_changephonesend@2x.png b/GIGA/Assets.xcassets/userCenter/btn_changephonesend.imageset/btn_changephonesend@2x.png new file mode 100644 index 0000000..0633315 Binary files /dev/null and b/GIGA/Assets.xcassets/userCenter/btn_changephonesend.imageset/btn_changephonesend@2x.png differ diff --git a/GIGA/Assets.xcassets/userCenter/user_changephonewihte.imageset/Contents.json b/GIGA/Assets.xcassets/userCenter/user_changephonewihte.imageset/Contents.json new file mode 100644 index 0000000..3f2a8c2 --- /dev/null +++ b/GIGA/Assets.xcassets/userCenter/user_changephonewihte.imageset/Contents.json @@ -0,0 +1,13 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "user_changephonewihte@2x.png", + "scale" : "2x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/GIGA/Assets.xcassets/userCenter/user_changephonewihte.imageset/user_changephonewihte@2x.png b/GIGA/Assets.xcassets/userCenter/user_changephonewihte.imageset/user_changephonewihte@2x.png new file mode 100644 index 0000000..5e08da2 Binary files /dev/null and b/GIGA/Assets.xcassets/userCenter/user_changephonewihte.imageset/user_changephonewihte@2x.png differ diff --git a/GIGA/Category/SHineLabel.h b/GIGA/Category/SHineLabel.h index 4712d89..11816de 100644 --- a/GIGA/Category/SHineLabel.h +++ b/GIGA/Category/SHineLabel.h @@ -15,5 +15,7 @@ @property(nonatomic,retain) UIColor *oinsideColor; //光晕 @property(nonatomic,retain) UIColor *blurColor; +@property(nonatomic) CGFloat fontsize; + @end diff --git a/GIGA/Category/SHineLabel.m b/GIGA/Category/SHineLabel.m index 745e952..0629a75 100644 --- a/GIGA/Category/SHineLabel.m +++ b/GIGA/Category/SHineLabel.m @@ -30,8 +30,7 @@ CGContextSetTextDrawingMode(ctx, mode); NSMutableParagraphStyle *paragraStyle = [[NSMutableParagraphStyle alloc] init]; paragraStyle.alignment = NSTextAlignmentCenter; - - [self.text drawInRect:self.bounds withAttributes:@{NSFontAttributeName:[UIFont fontWithName:@"PingFangSC-Semibold" size:22],NSForegroundColorAttributeName:[UIColor whiteColor],NSKernAttributeName:@(4),NSParagraphStyleAttributeName:paragraStyle}]; + [self.text drawInRect:self.bounds withAttributes:@{NSFontAttributeName:[UIFont fontWithName:@"PingFangSC-Semibold" size:self.fontsize],NSForegroundColorAttributeName:[UIColor whiteColor],NSKernAttributeName:@(4),NSParagraphStyleAttributeName:paragraStyle}]; } -(void)dealloc{ diff --git a/GIGA/Config/ApiRequestConfig.h b/GIGA/Config/ApiRequestConfig.h index 9c3ad75..3b72786 100644 --- a/GIGA/Config/ApiRequestConfig.h +++ b/GIGA/Config/ApiRequestConfig.h @@ -21,5 +21,19 @@ #define kUploadAvator @"sys/oss/v1/upload" //版本说明 #define kAPiAPPVersion @"sys/maskversionarticle/v1/list" +//修改密码 +#define kPAiUSerEditpwd @"user/v1/editpwd" +//修改手机号 +#define kApiChangePhone @"user/v1/editmobil" +//修改手机号发送验证码 +#define kApiChangeMobleCode @"msg/sms/v1/editsendcode" +//发送验证码 +#define kApiSendPhoneCode @"msg/sms/v1/sendcode"; +//找回密码发送验证码 +#define kApiChangePassSendCode @"msg/sms/v1/retrievesendcode" +//异步验证手机验证码 +#define kApiVersifyPhoneCode @"v1/user/v1/validateSmsCode" + + #endif /* ApiRequestConfig_h */ diff --git a/GIGA/Config/GIGA.h b/GIGA/Config/GIGA.h index ed9168b..2bfbaff 100644 --- a/GIGA/Config/GIGA.h +++ b/GIGA/Config/GIGA.h @@ -49,6 +49,8 @@ UD_SYNC #define kUserLogOutNotify @"userLogOutNotify" //用户头像修改 #define kUserAvatorUpdateNoti @"userAvatorUpdate" +//用户昵称修改 +#define kUserNameUpDateNoti @"userNickNameUpdate" //微信登陆授权成功 #define kWeiXinAuthrization_Success @"WXAuthSuccess" diff --git a/GIGA/Modules/LogIn/Controller/GiGaUserLoginVC.m b/GIGA/Modules/LogIn/Controller/GiGaUserLoginVC.m index daddf1e..5f895c8 100644 --- a/GIGA/Modules/LogIn/Controller/GiGaUserLoginVC.m +++ b/GIGA/Modules/LogIn/Controller/GiGaUserLoginVC.m @@ -99,7 +99,6 @@ self.loginBtn.layer.cornerRadius = self.loginBtn.frame.size.height / 2; NSMutableAttributedString *attri = [[NSMutableAttributedString alloc] init]; - NSTextAttachment *attch = [[NSTextAttachment alloc] init]; attch.image = [UIImage imageNamed:@"ic_wechat"]; attch.bounds = CGRectMake(0,-4, 12.9, 12.5); @@ -169,13 +168,20 @@ GIGA_ShowToast(@"密码不能为空"); return; } - BOOL isPass = [GiGaHelper checkPassWord:self.passwordTextField.text]; - - if (isPass == NO) { +// BOOL isPass = [GiGaHelper checkPassWord:self.passwordTextField.text]; +// +// if (isPass == NO) { +// GIGA_ShowToast(@"请输入6-20位数字和字母组成的密码"); +// return; +// } + int leng = [GiGaHelper convertToInt: self.passwordTextField.text]; + + if (!(leng >= 6 && leng <= 20)) { GIGA_ShowToast(@"请输入6-20位数字和字母组成的密码"); return; } + [self loginWithAction:btn]; } diff --git a/GIGA/Modules/LogIn/Controller/PassWordResetVC.m b/GIGA/Modules/LogIn/Controller/PassWordResetVC.m index 49af51b..7ebfdce 100644 --- a/GIGA/Modules/LogIn/Controller/PassWordResetVC.m +++ b/GIGA/Modules/LogIn/Controller/PassWordResetVC.m @@ -153,9 +153,10 @@ return; } - BOOL isPass = [GiGaHelper checkPassWord:self.passNewTextField.text]; + //BOOL isPass = [GiGaHelper checkPassWord:self.passNewTextField.text]; + int leng = [GiGaHelper convertToInt: self.passNewTextField.text]; - if (isPass == NO) { + if (!(leng >= 6 && leng <= 20)) { GIGA_ShowToast(@"请输入6-20位数字和字母组成的密码"); return; } diff --git a/GIGA/Modules/Mask/Controller/GiGaFlingCommitVC.m b/GIGA/Modules/Mask/Controller/GiGaFlingCommitVC.m index ac2a8ac..c885b48 100644 --- a/GIGA/Modules/Mask/Controller/GiGaFlingCommitVC.m +++ b/GIGA/Modules/Mask/Controller/GiGaFlingCommitVC.m @@ -124,7 +124,11 @@ NSURL* url = [[NSURL alloc] initWithString:@"http://wsyts.s1.natapp.cc"]; //@"connectParams":@{@"token":@""} - SocketManager *manager = [[SocketManager alloc] initWithSocketURL:url config:@{@"log": @NO, @"forcePolling": @YES,@"extraHeaders":@{@"device":@"ios"},@"token":@""}]; + NSString *token = [GiGaUserDefault getCurentToken]; + if (!token) { + token = @""; + } + SocketManager *manager = [[SocketManager alloc] initWithSocketURL:url config:@{@"log": @NO, @"forcePolling": @YES,@"extraHeaders":@{@"device":@"ios"},@"token":token}]; _manager = manager; _client = manager.defaultSocket; diff --git a/GIGA/Modules/Mask/Controller/GiGaMaskTaskViewController.m b/GIGA/Modules/Mask/Controller/GiGaMaskTaskViewController.m index 6d937f2..9fa55f8 100644 --- a/GIGA/Modules/Mask/Controller/GiGaMaskTaskViewController.m +++ b/GIGA/Modules/Mask/Controller/GiGaMaskTaskViewController.m @@ -186,6 +186,7 @@ if (showAppGaurd == NO) { [self showAPPappGaurdView]; } + //[self showUserGaurdView]; } -(void)viewWillDisappear:(BOOL)animated{ @@ -198,9 +199,7 @@ - (void)viewDidLoad { [super viewDidLoad]; - // Do any additional setup after loading the view. -// [self.view addSubview:self.tableView]; -// self.tableView.backgroundColor = GIGA_MAIN_BGCOLOR; + [self setUpNav]; [self initUI]; [self addNotify]; @@ -545,7 +544,7 @@ }else{ userGuardVC.modalPresentationStyle = UIModalPresentationCurrentContext; } - userGuardVC.view.backgroundColor = [[UIColor blackColor] colorWithAlphaComponent:0.5]; + userGuardVC.view.backgroundColor = [[UIColor blackColor] colorWithAlphaComponent:0.3]; [self presentViewController:userGuardVC animated:NO completion:nil]; } diff --git a/GIGA/Modules/Mask/Controller/UserGuardViewController.m b/GIGA/Modules/Mask/Controller/UserGuardViewController.m index 88ecbdd..5fddd54 100644 --- a/GIGA/Modules/Mask/Controller/UserGuardViewController.m +++ b/GIGA/Modules/Mask/Controller/UserGuardViewController.m @@ -9,8 +9,10 @@ #import "UserGuardViewController.h" #import "Masonry.h" #import "GiGaUserDefault.h" +#import "SHineLabel.h" @interface UserGuardViewController () +@property(nonatomic,strong) UIImageView *handimage; @end @@ -27,21 +29,93 @@ -(void)creatUI{ - UIButton *dismisBtn= [UIButton buttonWithType:UIButtonTypeCustom]; +// UIButton *dismisBtn= [UIButton buttonWithType:UIButtonTypeCustom]; +// +// [dismisBtn setTitle:@"知道了" forState:UIControlStateNormal]; +// [dismisBtn setTintColor:[UIColor whiteColor]]; +// dismisBtn.backgroundColor = [[UIColor blackColor] colorWithAlphaComponent:0.1]; +// [dismisBtn addTarget:self action:@selector(dismisBtnAction) forControlEvents:UIControlEventTouchUpInside]; +// [self.view addSubview:dismisBtn]; +// +// [dismisBtn mas_makeConstraints:^(MASConstraintMaker *make) { +// make.width.mas_equalTo(100); +// make.height.mas_equalTo(60); +// make.centerX.mas_equalTo(self.view.mas_centerX); +// make.top.mas_equalTo(self.view.mas_top).offset(200); +// }]; - [dismisBtn setTitle:@"知道了" forState:UIControlStateNormal]; - [dismisBtn setTintColor:[UIColor whiteColor]]; - dismisBtn.backgroundColor = [[UIColor blackColor] colorWithAlphaComponent:0.1]; - [dismisBtn addTarget:self action:@selector(dismisBtnAction) forControlEvents:UIControlEventTouchUpInside]; - [self.view addSubview:dismisBtn]; - - [dismisBtn mas_makeConstraints:^(MASConstraintMaker *make) { - make.width.mas_equalTo(100); - make.height.mas_equalTo(60); - make.centerX.mas_equalTo(self.view.mas_centerX); - make.top.mas_equalTo(self.view.mas_top).offset(200); + //usergaurd_uphand + UIImageView *upimage = [[UIImageView alloc] init]; + upimage.image = [UIImage imageNamed:@"userguard_up"]; + [self.view addSubview:upimage]; + [upimage mas_makeConstraints:^(MASConstraintMaker *make) { + make.height.and.with.mas_equalTo(20); + make.centerX.mas_equalTo(self.view.mas_centerX).offset(10); + make.top.mas_equalTo(self.view.mas_top).offset(298); + }]; + UIImageView *handimage = [[UIImageView alloc] init]; + self.handimage = handimage; + handimage.image = [UIImage imageNamed:@"usergaurd_uphand"]; + [self.view addSubview:handimage]; + [handimage mas_makeConstraints:^(MASConstraintMaker *make) { + make.left.mas_equalTo(upimage.mas_right).offset(2); + make.size.mas_equalTo(CGSizeMake(50, 60)); + + make.top.mas_equalTo(self.view.mas_top).offset(301); + + }]; + + SHineLabel *shainLabe = [[SHineLabel alloc] init]; + [self.view addSubview:shainLabe]; + shainLabe.textColor = [UIColor whiteColor]; + shainLabe.outLineColor = [UIColor whiteColor]; + shainLabe.blurColor = [UIColor whiteColor]; + shainLabe.oinsideColor = [UIColor whiteColor]; + shainLabe.fontsize = 18; + shainLabe.text = @"按住面膜向上滑\n敷到脸部开始倒计时"; + shainLabe.numberOfLines = 0; + + [shainLabe mas_makeConstraints:^(MASConstraintMaker *make) { + make.size.mas_equalTo(CGSizeMake(222, 60)); + //make.width.mas_equalTo(222); + make.top.mas_equalTo(self.view.mas_top).offset(384); + make.centerX.mas_equalTo(self.view.mas_centerX); + }]; + + // [self creatnaima]; +} + + +- (void)viewDidAppear:(BOOL)animated +{ + [self creatnaima]; +} +-(void)creatnaima{ + + [UIView animateWithDuration:1.0 animations:^{ + [UIView setAnimationRepeatCount:MAXFLOAT]; + [self->_handimage mas_updateConstraints:^(MASConstraintMaker *make) { + make.top.mas_equalTo(201); + + }]; + [self.view layoutIfNeeded]; + } completion:^(BOOL finished) { + + [self->_handimage mas_updateConstraints:^(MASConstraintMaker *make) { + make.top.mas_equalTo(301); + + }]; + [self.view layoutIfNeeded]; + }]; +} + + + +- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event +{ + [self dismisBtnAction]; } -(void)dismisBtnAction{ diff --git a/GIGA/Modules/Mask/View/MaskTimeCircularProgressView.m b/GIGA/Modules/Mask/View/MaskTimeCircularProgressView.m index 4ca794c..d356b27 100644 --- a/GIGA/Modules/Mask/View/MaskTimeCircularProgressView.m +++ b/GIGA/Modules/Mask/View/MaskTimeCircularProgressView.m @@ -85,6 +85,7 @@ _countLabel.blurColor = [UIColor whiteColor]; _countLabel.oinsideColor = [UIColor whiteColor]; _countLabel.text = @"00:00"; + _countLabel.fontsize = 22; _countLabel.font = [UIFont fontWithName:GIGA_FONTBOLD size:22]; } return _countLabel; diff --git a/GIGA/Modules/Me/Controller/AppVerionDescriptionVC.m b/GIGA/Modules/Me/Controller/AppVerionDescriptionVC.m index 1bd51c5..2958484 100644 --- a/GIGA/Modules/Me/Controller/AppVerionDescriptionVC.m +++ b/GIGA/Modules/Me/Controller/AppVerionDescriptionVC.m @@ -22,18 +22,19 @@ - (void)viewDidLoad { [super viewDidLoad]; + [self addNavTitile:@"版本说明"]; _currntPage = 1; _totalPage = 1; + self.versionsArr = [[NSMutableArray alloc] init]; [self.view addSubview:self.tableView]; self.tableView.delegate = self; self.tableView.dataSource = self; - self.tableView.backgroundColor = [UIColor whiteColor]; + self.tableView.backgroundColor = GIGA_MAIN_BGCOLOR; self.tableView.separatorStyle = UITableViewCellSelectionStyleNone; self.tableView.sectionFooterHeight = 0; self.tableView.estimatedSectionFooterHeight= 0; self.tableView.estimatedSectionHeaderHeight = 0; - self.tableView.frame = CGRectMake(0, 1, KMainW, self.view.bounds.size.height - SAFE_NAV_HEIGHT); [self requstListDatas]; } @@ -55,8 +56,8 @@ if(!cell){ cell = [[[NSBundle mainBundle] loadNibNamed:@"AppVersionLogoCell" owner:self options:nil] lastObject]; } - return cell; + return cell; } AppVersionDescCell *cell = [tableView dequeueReusableCellWithIdentifier:@"AppVersionDescCell"]; @@ -64,6 +65,9 @@ if(!cell){ cell = [[[NSBundle mainBundle] loadNibNamed:@"AppVersionDescCell" owner:self options:nil] lastObject]; } + + VersionModel *model =self.versionsArr[indexPath.row]; + [cell loadCellDataAt:indexPath version:model]; return cell; } @@ -92,6 +96,20 @@ return 4; } + +- (UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section{ + if (section == 1) { + UIView *view = [[UIView alloc] init]; + view.backgroundColor = GIGARGB(222, 222, 222, 1); + + return view; + } + UIView *view = [[UIView alloc] init]; + view.backgroundColor = GIGARGB(222, 222, 222, 1); + return view; + +} + -(void)requstListDatas{ GiGaBaseAPiRequest *reuqest = [GiGaBaseAPiRequest initWithRequestPath:kAPiAPPVersion method:RequestPostMethod parms:@{}]; diff --git a/GIGA/Modules/Me/Controller/GIGaAboutUsVC.h b/GIGA/Modules/Me/Controller/GIGaAboutUsVC.h new file mode 100644 index 0000000..c19fd76 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GIGaAboutUsVC.h @@ -0,0 +1,17 @@ +// +// GIGaAboutUsVC.h +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGaBaseViewController.h" + +@interface GIGaAboutUsVC : GiGaBaseViewController +@property (weak, nonatomic) IBOutlet UIView *backWhiteBorderView; +@property (weak, nonatomic) IBOutlet UILabel *curentV; +@property (weak, nonatomic) IBOutlet UILabel *xieyiLab; + + +@end diff --git a/GIGA/Modules/Me/Controller/GIGaAboutUsVC.m b/GIGA/Modules/Me/Controller/GIGaAboutUsVC.m new file mode 100644 index 0000000..c0c23c1 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GIGaAboutUsVC.m @@ -0,0 +1,58 @@ +// +// GIGaAboutUsVC.m +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GIGaAboutUsVC.h" + +@interface GIGaAboutUsVC () + +@end + +@implementation GIGaAboutUsVC + +- (void)viewDidLoad { + [super viewDidLoad]; + [self addNavTitile:@"关于我们"]; + self.view.backgroundColor = GIGA_MAIN_BGCOLOR; + // Do any additional setup after loading the view from its nib. + self.backWhiteBorderView.layer.masksToBounds = YES; + self.backWhiteBorderView.layer.borderWidth = 1; + self.backWhiteBorderView.layer.cornerRadius = 2; + self.backWhiteBorderView.layer.borderColor = [UIColor whiteColor].CGColor; + NSDictionary *infoDic=[[NSBundle mainBundle] infoDictionary]; + // CFShow((__bridge CFTypeRef)(infoDic)); + NSString *app_Version=[infoDic objectForKey:@"CFBundleShortVersionString"]; + NSLog(@"app_Version%@",app_Version); + self.curentV.text = [NSString stringWithFormat:@"当前版本:%@",app_Version]; + + UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(xiyiDetail)]; + [self.xieyiLab addGestureRecognizer:tap]; + //self.xieyiLab.backgroundColor = [UIColor blueColor]; +} + +-(void)xiyiDetail{ + + +} + + +- (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 diff --git a/GIGA/Modules/Me/Controller/GIGaAboutUsVC.xib b/GIGA/Modules/Me/Controller/GIGaAboutUsVC.xib new file mode 100644 index 0000000..238905f --- /dev/null +++ b/GIGA/Modules/Me/Controller/GIGaAboutUsVC.xib @@ -0,0 +1,127 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/GIGA/Modules/Me/Controller/GIGaChangePassVC.h b/GIGA/Modules/Me/Controller/GIGaChangePassVC.h new file mode 100644 index 0000000..78f0f73 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GIGaChangePassVC.h @@ -0,0 +1,17 @@ +// +// GIGaChangePassVC.h +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGaBaseViewController.h" + +@interface GIGaChangePassVC : GiGaBaseViewController +@property (weak, nonatomic) IBOutlet UITextField *oldPassField; +@property (weak, nonatomic) IBOutlet UITextField *xinPassFiled; + +@property (weak, nonatomic) IBOutlet UITextField *reNewPassFiled; + +@end diff --git a/GIGA/Modules/Me/Controller/GIGaChangePassVC.m b/GIGA/Modules/Me/Controller/GIGaChangePassVC.m new file mode 100644 index 0000000..51d1145 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GIGaChangePassVC.m @@ -0,0 +1,101 @@ +// +// GIGaChangePassVC.m +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GIGaChangePassVC.h" +#import "GiGaBaseAPiRequest.h" + +@interface GIGaChangePassVC () + +@end + +@implementation GIGaChangePassVC + +- (void)viewDidLoad { + [super viewDidLoad]; + [self addNavTitile:@"修改密码"]; + // Do any additional setup after loading the view from its nib. + UIButton *saveBtn = [UIButton buttonWithType:UIButtonTypeCustom]; + [saveBtn addTarget:self action:@selector(doBtnAction:) forControlEvents:UIControlEventTouchUpInside]; + saveBtn.frame = CGRectMake(0, 0,40, 36); + NSAttributedString *attrititle = [GiGaHelper stringWithText:@"完成" textColor:[UIColor whiteColor] textFont:GIGA_TEXTFONTMEDIUM(16) leterSpace:0]; + [saveBtn setAttributedTitle:attrititle forState:UIControlStateNormal]; + UIBarButtonItem *saveItem = [[UIBarButtonItem alloc] initWithCustomView:saveBtn]; + self.navigationItem.rightBarButtonItem = saveItem; + +} + +- (void)didReceiveMemoryWarning { + [super didReceiveMemoryWarning]; + // Dispose of any resources that can be recreated. +} + +-(void)doBtnAction:(UIButton *)btn{ + + if (self.oldPassField.text.length == 0) { + + //[self.view makeToast:@"请输入原密码" duration:2 position:CSToastPositionTop]; + GIGA_ShowToast(@"请输入新密码"); + return; + } + + if (self.xinPassFiled.text.length == 0) { + //[self.view makeToast:@"请输入新密码" duration:2 position:CSToastPositionTop]; + GIGA_ShowToast(@"请输入新密码"); + return; + } + + int leng = [GiGaHelper convertToInt: self.xinPassFiled.text]; + if (!(leng >= 6 && leng <= 20)) { + GIGA_ShowToast(@"请输入6-20位数字和字母组成的新密码"); + return; + } + + if (self.reNewPassFiled.text.length == 0) { + GIGA_ShowToast(@"请输入新密码"); + return; + } + + + if (self.reNewPassFiled.text != self.xinPassFiled.text) { + GIGA_ShowToast(@"两次输入密码不一致!"); + return; + } + + [self newPassBtnAction:btn]; + +} + +-(void)newPassBtnAction:(UIButton *)btn{ + + btn.userInteractionEnabled = NO; + [self.view makeToastActivity:CSToastPositionCenter]; + NSDictionary *params = @{ + @"password":self.oldPassField.text, + @"newPassword":self.xinPassFiled.text, + @"newPasswordConfirm":self.reNewPassFiled.text + }; + GiGaBaseAPiRequest *requst = [GiGaBaseAPiRequest initWithRequestPath:kPAiUSerEditpwd method:RequestPostMethod parms:params]; + [requst requstDataWithResult:^(GiGaAPIResult *result) { + [self.view hideToastActivity]; + btn.userInteractionEnabled = YES; + if (result.success) { + GIGA_WIndowTost(result.message); + [self.navigationController popViewControllerAnimated:YES]; + + }else{ + if (result.code == 401) { + //token失效 + [GiGaBaseAPiRequest userTokenTimeOutGologinFromVC:self]; + } + GIGA_WIndowTost(result.message); + } + }]; + +} + +@end diff --git a/GIGA/Modules/Me/Controller/GIGaChangePassVC.xib b/GIGA/Modules/Me/Controller/GIGaChangePassVC.xib new file mode 100644 index 0000000..4bd24a2 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GIGaChangePassVC.xib @@ -0,0 +1,132 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/GIGA/Modules/Me/Controller/GIGaMaskTimeUseRecordVC.h b/GIGA/Modules/Me/Controller/GIGaMaskTimeUseRecordVC.h new file mode 100644 index 0000000..01a26e4 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GIGaMaskTimeUseRecordVC.h @@ -0,0 +1,13 @@ +// +// GIGaMaskTimeUseRecordVC.h +// GIGA +// +// Created by lianxiang on 2018/9/20. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGaBaseViewController.h" + +@interface GIGaMaskTimeUseRecordVC : GiGaBaseViewController + +@end diff --git a/GIGA/Modules/Me/Controller/GIGaMaskTimeUseRecordVC.m b/GIGA/Modules/Me/Controller/GIGaMaskTimeUseRecordVC.m new file mode 100644 index 0000000..e9f75c2 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GIGaMaskTimeUseRecordVC.m @@ -0,0 +1,38 @@ +// +// GIGaMaskTimeUseRecordVC.m +// GIGA +// +// Created by lianxiang on 2018/9/20. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GIGaMaskTimeUseRecordVC.h" + +@interface GIGaMaskTimeUseRecordVC () + +@end + +@implementation GIGaMaskTimeUseRecordVC + +- (void)viewDidLoad { + [super viewDidLoad]; + [self addNavTitile:@"历史测试"]; + // Do any additional setup after loading the view. +} + +- (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 diff --git a/GIGA/Modules/Me/Controller/GiGaChangePhoneNumberVC.h b/GIGA/Modules/Me/Controller/GiGaChangePhoneNumberVC.h new file mode 100644 index 0000000..c4d1b1e --- /dev/null +++ b/GIGA/Modules/Me/Controller/GiGaChangePhoneNumberVC.h @@ -0,0 +1,13 @@ +// +// GiGaChangePhoneNumberVC.h +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGaBaseViewController.h" + +@interface GiGaChangePhoneNumberVC : GiGaBaseViewController + +@end diff --git a/GIGA/Modules/Me/Controller/GiGaChangePhoneNumberVC.m b/GIGA/Modules/Me/Controller/GiGaChangePhoneNumberVC.m new file mode 100644 index 0000000..9d32234 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GiGaChangePhoneNumberVC.m @@ -0,0 +1,300 @@ +// +// GiGaChangePhoneNumberVC.m +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGaChangePhoneNumberVC.h" +#import "GIGaUserChangeMobleCell.h" +#import "GiGaBaseAPiRequest.h" + +//typedef NS_ENUM(NSInteger,PohoneCodeType) +//{ +// PohoneCodeTypeOld = 0,//原手机号 +// PohoneCodeTypeNew//新手机号 +// +// +//}; + +@interface GiGaChangePhoneNumberVC () +//@property(nonatomic) PohoneCodeType viewCodeType; +@property(nonatomic) BOOL nextSteep; +@property(nonatomic,copy) NSString *oldCode; +@property(nonatomic,copy) NSString *xinCode; +@end + +@implementation GiGaChangePhoneNumberVC + +- (void)viewDidLoad { + [super viewDidLoad]; + [self addNavTitile:@"修改手机号"]; + _nextSteep = NO; + // Do any additional setup after loading the view from its nib. + [self.view addSubview:self.tableView]; + self.tableView.delegate = self; + self.tableView.dataSource = self; + self.tableView.backgroundColor = [UIColor whiteColor]; + self.tableView.separatorStyle = UITableViewCellSelectionStyleNone; + self.tableView.sectionFooterHeight = 0; + self.tableView.estimatedSectionFooterHeight= 0; + self.tableView.estimatedSectionHeaderHeight = 0; + self.tableView.bounces = NO; + self.tableView.frame = CGRectMake(0,0, KMainW, self.view.bounds.size.height - SAFE_NAV_HEIGHT); + +} + +- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView{ + return 1; +} + +- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{ + + return 1; +} + +- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{ + + + GIGaUserChangeMobleCell *cell = [tableView dequeueReusableCellWithIdentifier:@"GIGaUserChangeMobleCell"]; + if(!cell){ + cell = [[[NSBundle mainBundle] loadNibNamed:@"GIGaUserChangeMobleCell" owner:self options:nil] lastObject]; + + } + [cell.codeSendBtn addTarget:self action:@selector(sendCodeBtnAction:) forControlEvents:UIControlEventTouchUpInside]; + if (_nextSteep) { + cell.numberTexFiled.userInteractionEnabled = YES; + cell.oldBtn.backgroundColor = GIGARGB(227, 227, 227, 1); + + NSAttributedString *atti1 = [GiGaHelper stringWithText:@"1.验证原号码" textColor:GIGARGB(165,165, 165, 1) textFont:GIGA_TEXTFONTMEDIUM(13) leterSpace:0]; + [cell.oldBtn setAttributedTitle:atti1 forState:UIControlStateNormal]; + + cell.xinPhoneBtn.backgroundColor = GIGARGB(227, 227, 227, 1); + NSAttributedString *atti = [GiGaHelper stringWithText:@"2.绑定新手机" textColor:GIGARGB(131, 10, 10, 1) textFont:GIGA_TEXTFONTMEDIUM(13) leterSpace:0]; + [cell.xinPhoneBtn setAttributedTitle:atti forState:UIControlStateNormal]; + + [cell.xinPhoneBtn setBackgroundImage:[UIImage imageNamed:@"user_changephonewihte"] forState:UIControlStateNormal]; + + }else{ + + cell.numberTexFiled.userInteractionEnabled = NO; + + } + + return cell; + +} + +- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath{ + return 170.f; + +} + +- (CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section{ + + return 115.f; +} + +- (CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{ + + return 0.1; +} + +- (UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section{ + UIView *view = [[UIView alloc] init]; + UIButton *nextBtn = [UIButton buttonWithType:UIButtonTypeCustom]; + nextBtn.backgroundColor = GIGARGB(181, 14, 14, 1); + nextBtn.layer.masksToBounds = YES; + nextBtn.layer.cornerRadius = 41/2; + + [nextBtn addTarget:self action:@selector(nextBtnAction:) forControlEvents:UIControlEventTouchUpInside]; + nextBtn.frame = CGRectMake((KMainW - 244)/2 , 5, 244, 41); + if (_nextSteep) { + NSAttributedString *attrititle = [GiGaHelper stringWithText:@"下一步" textColor:[UIColor whiteColor] textFont:GIGA_TEXTFONTBOLD(16) leterSpace:0]; + [nextBtn setAttributedTitle:attrititle forState:UIControlStateNormal]; + }else{ + NSAttributedString *attrititle = [GiGaHelper stringWithText:@"完成" textColor:[UIColor whiteColor] textFont:GIGA_TEXTFONTBOLD(16) leterSpace:0]; + [nextBtn setAttributedTitle:attrititle forState:UIControlStateNormal]; + } + [view addSubview:nextBtn]; + + UILabel *tishiLab = [[UILabel alloc] init]; + tishiLab.frame = CGRectMake((KMainW - 70)/2,CGRectGetMaxY(nextBtn.frame) + 32, 70, 14); + NSMutableAttributedString *attriTile = [[NSMutableAttributedString alloc] init]; + NSTextAttachment *attch = [[NSTextAttachment alloc] init]; + attch.image = [UIImage imageNamed:@"ic_love"]; + attch.bounds = CGRectMake(-2,-3, 12, 12); + NSAttributedString *imastr=[NSAttributedString attributedStringWithAttachment:attch]; + [attriTile appendAttributedString:imastr]; + + NSAttributedString *titleStr = [[NSAttributedString alloc] initWithString:@"温馨提示:" attributes:@{NSFontAttributeName:GIGA_TEXTFONTMEDIUM(10), NSForegroundColorAttributeName:GIGARGB(187, 187, 187, 1)}]; + [attriTile appendAttributedString:titleStr]; + + tishiLab.attributedText = attriTile; + [view addSubview:tishiLab]; + + + UILabel *desc =[[UILabel alloc] init]; + desc.frame = CGRectMake((KMainW - 240.f) / 2 , CGRectGetMaxY(tishiLab.frame) + 2, 240, 14); + + desc.text =@"手机号码修改成功后需要使用新的手机号进行登陆哟。"; + desc.textColor = GIGARGB(187, 187, 187, 1); + desc.font = GIGA_TEXTFONTMEDIUM(10); + [view addSubview:desc]; + + return view; +} +#pragma mark 下一步 Or 完成 +-(void)nextBtnAction:(UIButton *)btn{ + + + if (_nextSteep) { + GILog(@"完成"); + + GIGaUserChangeMobleCell *cell = [self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]]; + if (cell.numberTexFiled.text.length == 0) { + GIGA_ShowToast(@"请输入新手机号"); + return; + } + if (![GiGaHelper isPhoneNumber:cell.numberTexFiled.text]) { + GIGA_ShowToast(@"请输入正确手机号"); + return; + } + + if (cell.codeTexFiled.text.length == 0) { + GIGA_ShowToast(@"请输入新手机验证码"); + return; + } + + [self verifyPhoneCode:cell.numberTexFiled.text code:cell.codeTexFiled.text btn:btn]; + + + }else{ + GILog(@"下一步"); + + GIGaUserChangeMobleCell *cell = [self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]]; + // + if (cell.codeTexFiled.text.length == 0) { + GIGA_ShowToast(@"请输入验证码"); + return; + } + + GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + if (!user.mobile || [user.mobile isKindOfClass:[NSNull class]]) { + GILog(@"手机号为空"); + return; + } + + [self verifyPhoneCode:user.mobile code:cell.codeTexFiled.text btn:btn]; + + } +} + +-(void)finishBtn:(UIButton *)btn wtihNewPhone:(NSString *)xinNumber{ + + GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + NSString *oldphone = user.mobile; + + GiGaBaseAPiRequest *api = [GiGaBaseAPiRequest initWithRequestPath: kApiChangePhone method:RequestPostMethod parms:@{@"oldMobile":oldphone,@"newMobile":xinNumber,@"oldVerifiedCode":self.oldCode,@"newVerifiedCode":self.xinCode}]; + [api requstDataWithResult:^(GiGaAPIResult *result) { + btn.userInteractionEnabled = YES; + [self.view hideToastActivity]; + + if (result.success) { + GIGA_WIndowTost(@"手机号修改成功"); + [self.navigationController popViewControllerAnimated:YES]; + }else{ + GIGA_ShowToast(result.message); + } + }]; +} + +#pragma mark - 发送验证码 +-(void)sendCodeBtnAction:(UIButton *)btn{ + + if (_nextSteep) { + GIGaUserChangeMobleCell *cell = [self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]]; + if (cell.numberTexFiled.text.length == 0) { + GIGA_ShowToast(@"请输新手机号"); + return; + } + + self.xinCode = cell.codeTexFiled.text; + [self sendCodeWith:cell.numberTexFiled.text]; + + }else{ + + GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + if (!user.mobile || [user.mobile isKindOfClass:[NSNull class]]) { + GILog(@"手机号为空"); + return; + } + [self sendCodeWith:user.mobile]; + + } +} + +-(void)sendCodeWith:(NSString *)phone{ + NSString *utl = nil; + if (_nextSteep) { + utl= kApiChangeMobleCode; + }else{ + utl= kApiSendPhoneCode; + } + GiGaBaseAPiRequest *api = [GiGaBaseAPiRequest initWithRequestPath:utl method:RequestPostMethod parms:@{@"mobile":phone}]; + [api requstDataWithResult:^(GiGaAPIResult *result) { + if (result.success) { + GIGA_ShowToast(@"已发送"); + }else{ + GIGA_ShowToast(result.message); + } + }]; +} + +#pragma mark - 验证手机验证码 +-(void)verifyPhoneCode:(NSString *)phonenumber code:(NSString *)code btn:(UIButton *)btn +{ + btn.userInteractionEnabled = NO; + [self.view makeToastActivity:CSToastPositionCenter]; + GiGaBaseAPiRequest *api = [GiGaBaseAPiRequest initWithRequestPath:kApiVersifyPhoneCode method:RequestPostMethod parms:@{@"mobile":phonenumber,@"verifiedCode":code}]; + [api requstDataWithResult:^(GiGaAPIResult *result) { + + if (result.success) { + if (self.nextSteep) { + //验证码通过 完成 + [self finishBtn:btn wtihNewPhone:phonenumber]; + + }else{ + btn.userInteractionEnabled = YES; + [self.view hideToastActivity]; + self.nextSteep = YES; + self.oldCode = code; + [self.tableView reloadData]; + } + + }else{ + btn.userInteractionEnabled = YES; + [self.view hideToastActivity]; + GIGA_ShowToast(result.message); + } + }]; +} + + +- (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 diff --git a/GIGA/Modules/Me/Controller/GiGaFeedBackViewController.h b/GIGA/Modules/Me/Controller/GiGaFeedBackViewController.h new file mode 100644 index 0000000..981a8c0 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GiGaFeedBackViewController.h @@ -0,0 +1,13 @@ +// +// GiGaFeedBackViewController.h +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGaBaseViewController.h" + +@interface GiGaFeedBackViewController : GiGaBaseViewController + +@end diff --git a/GIGA/Modules/Me/Controller/GiGaFeedBackViewController.m b/GIGA/Modules/Me/Controller/GiGaFeedBackViewController.m new file mode 100644 index 0000000..a54fdf8 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GiGaFeedBackViewController.m @@ -0,0 +1,38 @@ +// +// GiGaFeedBackViewController.m +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGaFeedBackViewController.h" + +@interface GiGaFeedBackViewController () + +@end + +@implementation GiGaFeedBackViewController + +- (void)viewDidLoad { + [super viewDidLoad]; + [self addNavTitile:@"意见反馈"]; + // Do any additional setup after loading the view. +} + +- (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 diff --git a/GIGA/Modules/Me/Controller/GiGaMeViewController.m b/GIGA/Modules/Me/Controller/GiGaMeViewController.m index 8cf8e9c..5c2bdce 100644 --- a/GIGA/Modules/Me/Controller/GiGaMeViewController.m +++ b/GIGA/Modules/Me/Controller/GiGaMeViewController.m @@ -16,6 +16,8 @@ #import "GiGaBaseAPiRequest.h" #import "GiGaUserManager.h" #import "UIImageView+WebCache.h" +#import "GiGaUserInfoVC.h" +#import "GIGaMaskTimeUseRecordVC.h" @interface GiGaMeViewController () @property (nonatomic,strong) GiGaUser *user; @@ -39,23 +41,43 @@ self.tableView.estimatedSectionHeaderHeight = 0; self.tableView.bounces = NO; self.tableView.frame = CGRectMake(0, 1, KMainW, self.view.bounds.size.height - SAFE_NAV_HEIGHT); - [self loadUserInfo]; - NC_ADD_TARGET_NAME_OBJECT(self, @selector(userAvatorUpDate), kUserAvatorUpdateNoti, nil) ; + //[self loadUserInfo]; + GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + self.user = user; + NC_ADD_TARGET_NAME_OBJECT(self, @selector(userAvatorUpDate), kUserAvatorUpdateNoti, nil); + NC_ADD_TARGET_NAME_OBJECT(self, @selector(usersNameUpDateNoti), kUserNameUpDateNoti, nil); + +} + +- (void)viewWillAppear:(BOOL)animated{ + [super viewWillAppear:animated]; + } -(void)dealloc{ NC_REMOVE_NAME(self, kUserAvatorUpdateNoti, nil); + NC_REMOVE_NAME(self, kUserNameUpDateNoti, nil); } -(void)userAvatorUpDate{ GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + self.user = user; if (user.headImgUrl && ![user.headImgUrl isKindOfClass:[NSNull class]] ) { GiGaMineUserViewCell *cell = [self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]]; NSURL *url = [NSURL URLWithString:user.headImgUrl]; [cell.userAvator sd_setImageWithURL:url]; + + } +} + +-(void)usersNameUpDateNoti{ + GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + self.user = user; + if (user.nickName && ![user.nickName isEqualToString:@""] && ![user.nickName isKindOfClass:[NSNull class]]) { + GiGaMineUserViewCell *cell = [self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]]; + cell.userName.text = user.nickName; } - } -(void)loadUserInfo{ @@ -120,7 +142,7 @@ } if(indexPath.section == 0){ - GiGaUserViewController *userVC= [[GiGaUserViewController alloc] init]; + GiGaUserInfoVC *userVC= [[GiGaUserInfoVC alloc] init]; [self.navigationController pushViewController:userVC animated:YES]; }else{ @@ -130,6 +152,9 @@ [self.navigationController pushViewController:historyVC animated:YES]; }else if (indexPath.section == 1 && indexPath.row == 1){ + //使用记录 + GIGaMaskTimeUseRecordVC *historyVC= [[GIGaMaskTimeUseRecordVC alloc] init]; + [self.navigationController pushViewController:historyVC animated:YES]; }else{ //系统设置 diff --git a/GIGA/Modules/Me/Controller/GiGaUserInfoVC.h b/GIGA/Modules/Me/Controller/GiGaUserInfoVC.h new file mode 100644 index 0000000..9d3fb23 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GiGaUserInfoVC.h @@ -0,0 +1,13 @@ +// +// GiGaUserInfoVC.h +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGaBaseViewController.h" + +@interface GiGaUserInfoVC : GiGaBaseViewController + +@end diff --git a/GIGA/Modules/Me/Controller/GiGaUserInfoVC.m b/GIGA/Modules/Me/Controller/GiGaUserInfoVC.m new file mode 100644 index 0000000..482c945 --- /dev/null +++ b/GIGA/Modules/Me/Controller/GiGaUserInfoVC.m @@ -0,0 +1,167 @@ +// +// GiGaUserInfoVC.m +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGaUserInfoVC.h" +#import "GiGaMineUserViewCell.h" +#import "GiGAUserInfoCell.h" +#import "UIImageView+WebCache.h" +#import "GiGaUserViewController.h" +#import "GIGaChangePassVC.h" +#import "GiGaChangePhoneNumberVC.h" + +@interface GiGaUserInfoVC () +@property (nonatomic,strong) GiGaUser *user; +@end + +@implementation GiGaUserInfoVC + +- (void)viewDidLoad { + [super viewDidLoad]; + // Do any additional setup after loading the view. + [self addNavTitile:@"个人中心"]; + [self.view addSubview:self.tableView]; + self.tableView.delegate = self; + self.tableView.dataSource = self; + self.tableView.backgroundColor = [UIColor whiteColor]; + self.tableView.separatorStyle = UITableViewCellSelectionStyleNone; + self.tableView.sectionFooterHeight = 0; + self.tableView.estimatedSectionFooterHeight= 0; + self.tableView.estimatedSectionHeaderHeight = 0; + self.tableView.bounces = NO; + self.tableView.frame = CGRectMake(0, 1, KMainW, self.view.bounds.size.height - SAFE_NAV_HEIGHT); + GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + self.user = user; + NC_ADD_TARGET_NAME_OBJECT(self, @selector(userAvatorUpDate), kUserAvatorUpdateNoti, nil); + NC_ADD_TARGET_NAME_OBJECT(self, @selector(usersNameUpDateNoti), kUserNameUpDateNoti, nil); + +} + +-(void)dealloc{ + NC_REMOVE_NAME(self, kUserAvatorUpdateNoti, nil); + NC_REMOVE_NAME(self, kUserNameUpDateNoti, nil); +} + +-(void)userAvatorUpDate{ + + GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + self.user = user; + if (user.headImgUrl && ![user.headImgUrl isKindOfClass:[NSNull class]] ) { + GiGaMineUserViewCell *cell = [self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]]; + NSURL *url = [NSURL URLWithString:user.headImgUrl]; + [cell.userAvator sd_setImageWithURL:url]; + + } +} + +-(void)usersNameUpDateNoti{ + GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + self.user = user; + if (user.nickName && ![user.nickName isEqualToString:@""] && ![user.nickName isKindOfClass:[NSNull class]]) { + GiGaMineUserViewCell *cell = [self.tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:0 inSection:0]]; + cell.userName.text = user.nickName; + } +} + +- (void)didReceiveMemoryWarning { + [super didReceiveMemoryWarning]; + // Dispose of any resources that can be recreated. +} + +- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView{ + return 2; +} + +- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{ + + if (section == 0){ + return 1; + } + return 3; +} + +- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{ + if(indexPath.section ==0){ + GiGaMineUserViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"GiGaMineUserViewCell"]; + if(!cell){ + cell = [[[NSBundle mainBundle] loadNibNamed:@"GiGaMineUserViewCell" owner:self options:nil] lastObject]; + + } + + if (self.user) { + [cell loadUserinfoWith:self.user]; + } + return cell; + } + GiGAUserInfoCell *cell = [tableView dequeueReusableCellWithIdentifier:@"GiGAUserInfoCell"]; + if(!cell){ + cell = [[[NSBundle mainBundle] loadNibNamed:@"GiGAUserInfoCell" owner:self options:nil] lastObject]; + + } + [cell loadCellData:indexPath]; + return cell; + +} + +- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{ + if(indexPath.section == 1){ + [tableView deselectRowAtIndexPath:indexPath animated:YES]; + } + + if(indexPath.section == 0){ + GiGaUserViewController *userVC= [[GiGaUserViewController alloc] init]; + [self.navigationController pushViewController:userVC animated:YES]; + + }else{ + if (indexPath.section == 1 && indexPath.row == 0 ){ + GiGaUserViewController *userVC= [[GiGaUserViewController alloc] init]; + [self.navigationController pushViewController:userVC animated:YES]; + + }else if (indexPath.section == 1 && indexPath.row == 1){ + + GIGaChangePassVC *changePass = [[GIGaChangePassVC alloc] init]; + [self.navigationController pushViewController:changePass animated:YES]; + + }else{ + + GiGaChangePhoneNumberVC *changePass = [[GiGaChangePhoneNumberVC alloc] init]; + [self.navigationController pushViewController:changePass animated:YES]; + + } + } +} + +- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath{ + if(indexPath.section==0){ + return 139; + }else { + return 54; + } +} + +- (CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section{ + return 0.1; +} + +- (CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{ + if (section == 1){ + return 6; + } + return 0.1; +} + +-(UIView*)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section{ + + if (section == 1) { + UIView *view = [[UIView alloc] init]; + view.backgroundColor = GIGARGB(222, 222, 222, 1); + return view; + } + return nil; +} + +@end diff --git a/GIGA/Modules/Me/Controller/GiGaUserViewController.m b/GIGA/Modules/Me/Controller/GiGaUserViewController.m index d9e392d..36a052e 100644 --- a/GIGA/Modules/Me/Controller/GiGaUserViewController.m +++ b/GIGA/Modules/Me/Controller/GiGaUserViewController.m @@ -342,8 +342,11 @@ [self.view hideToastActivity]; if (result.success) { GIGA_ShowToast(@"修改成功"); + [[GiGaUserManager shareUser] saveUser:self.user]; + NC_POST_NAME_OBJECT(kUserNameUpDateNoti, nil); + }else{ GIGA_ShowToast(result.dic[@"msg"]); if (result.code == 401) { diff --git a/GIGA/Modules/Me/Controller/GiSysSettingsVC.m b/GIGA/Modules/Me/Controller/GiSysSettingsVC.m index 0452232..743765f 100644 --- a/GIGA/Modules/Me/Controller/GiSysSettingsVC.m +++ b/GIGA/Modules/Me/Controller/GiSysSettingsVC.m @@ -12,6 +12,8 @@ #import "GiGaUserDefault.h" #import "GiGaUserManager.h" #import "AppVerionDescriptionVC.h" +#import "GIGaAboutUsVC.h" +#import "GiGaFeedBackViewController.h" @interface GiSysSettingsVC () @@ -70,9 +72,11 @@ }]; }else if (indexPath.row == 1){ - + GiGaFeedBackViewController *feedVC = [[GiGaFeedBackViewController alloc] init]; + [self.navigationController pushViewController:feedVC animated:YES]; }else if (indexPath.row == 2){ - + GIGaAboutUsVC *usVC= [[GIGaAboutUsVC alloc] init]; + [self.navigationController pushViewController:usVC animated:YES]; }else if (indexPath.row == 3){ AppVerionDescriptionVC *verVC =[[AppVerionDescriptionVC alloc] init]; [self.navigationController pushViewController:verVC animated:YES]; diff --git a/GIGA/Modules/Me/Model/GiGaUser.h b/GIGA/Modules/Me/Model/GiGaUser.h index dc5862f..6e3e02b 100644 --- a/GIGA/Modules/Me/Model/GiGaUser.h +++ b/GIGA/Modules/Me/Model/GiGaUser.h @@ -19,6 +19,7 @@ @property(nonatomic,copy) NSString *cityName; @property(nonatomic,copy) NSString *headImgUrl; +@property(nonatomic,copy) NSString *mobile; @property(nonatomic,copy) NSString *mobileMask; @property(nonatomic,assign) NSInteger mobileStatus; @property(nonatomic,copy) NSString *mobileStatusName; diff --git a/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.h b/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.h index 460acbc..a5aee6b 100644 --- a/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.h +++ b/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.h @@ -7,8 +7,12 @@ // #import +#import "VersionModel.h" @interface AppVersionDescCell : UITableViewCell @property (weak, nonatomic) IBOutlet UILabel *VersionDescLabel; +@property (weak, nonatomic) IBOutlet UILabel *versionLabe; +@property (weak, nonatomic) IBOutlet UILabel *tempLabe; +-(void)loadCellDataAt:(NSIndexPath *)indexPath version:(VersionModel *)model; @end diff --git a/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.m b/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.m index 8d714dc..88a6e91 100644 --- a/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.m +++ b/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.m @@ -17,6 +17,13 @@ } +-(void)loadCellDataAt:(NSIndexPath *)indexPath version:(VersionModel *)model{ + self.VersionDescLabel.text = model.content; + self.versionLabe.text = model.title; + self.tempLabe.text = model.createTime; + +} + - (void)setSelected:(BOOL)selected animated:(BOOL)animated { [super setSelected:selected animated:animated]; diff --git a/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.xib b/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.xib index 2f40937..800bce2 100644 --- a/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.xib +++ b/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionDescCell.xib @@ -32,13 +32,29 @@ + + + + + + @@ -46,6 +62,8 @@ + + diff --git a/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionLogoCell.xib b/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionLogoCell.xib index 97ce20a..b2d271a 100644 --- a/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionLogoCell.xib +++ b/GIGA/Modules/Me/View/AppVerionDescCells/AppVersionLogoCell.xib @@ -40,7 +40,7 @@ - + diff --git a/GIGA/Modules/Me/View/GiGAUserInfoCell.h b/GIGA/Modules/Me/View/GiGAUserInfoCell.h new file mode 100644 index 0000000..a7239f2 --- /dev/null +++ b/GIGA/Modules/Me/View/GiGAUserInfoCell.h @@ -0,0 +1,17 @@ +// +// GiGAUserInfoCell.h +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import + +@interface GiGAUserInfoCell : UITableViewCell +@property (weak, nonatomic) IBOutlet UILabel *infoTitle; +@property (weak, nonatomic) IBOutlet UILabel *numberLabe; + +-(void)loadCellData:(NSIndexPath *)indexPath; + +@end diff --git a/GIGA/Modules/Me/View/GiGAUserInfoCell.m b/GIGA/Modules/Me/View/GiGAUserInfoCell.m new file mode 100644 index 0000000..e949b12 --- /dev/null +++ b/GIGA/Modules/Me/View/GiGAUserInfoCell.m @@ -0,0 +1,44 @@ +// +// GiGAUserInfoCell.m +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GiGAUserInfoCell.h" + +@implementation GiGAUserInfoCell + +- (void)awakeFromNib { + [super awakeFromNib]; + // Initialization code +} + +-(void)loadCellData:(NSIndexPath *)indexPath{ + if (indexPath.section == 1 && indexPath.row == 0) { + //个人信息 + self.infoTitle.text = @"个人信息"; + self.numberLabe.hidden = YES; + }else if (indexPath.section == 1 && indexPath.row == 1){ + //修改密码 + self.infoTitle.text = @"修改密码"; + self.numberLabe.hidden = YES; + }else if (indexPath.section == 1 && indexPath.row == 2){ + //修改手机 + self.infoTitle.text = @"修改手机"; + self.numberLabe.hidden = NO; + GiGaUser *user = [[GiGaUserManager shareUser] getCurrentUser]; + self.numberLabe.text = user.mobileMask; + + } + +} + +- (void)setSelected:(BOOL)selected animated:(BOOL)animated { + [super setSelected:selected animated:animated]; + + // Configure the view for the selected state +} + +@end diff --git a/GIGA/Modules/Me/View/GiGAUserInfoCell.xib b/GIGA/Modules/Me/View/GiGAUserInfoCell.xib new file mode 100644 index 0000000..7f27305 --- /dev/null +++ b/GIGA/Modules/Me/View/GiGAUserInfoCell.xib @@ -0,0 +1,72 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/GIGA/Modules/Me/View/GiGaMineInfoViewCell.xib b/GIGA/Modules/Me/View/GiGaMineInfoViewCell.xib index d7f5f92..7df9175 100644 --- a/GIGA/Modules/Me/View/GiGaMineInfoViewCell.xib +++ b/GIGA/Modules/Me/View/GiGaMineInfoViewCell.xib @@ -37,7 +37,7 @@ - + diff --git a/GIGA/Modules/Me/View/GiGaMineUserViewCell.m b/GIGA/Modules/Me/View/GiGaMineUserViewCell.m index 960cb71..6e215d3 100644 --- a/GIGA/Modules/Me/View/GiGaMineUserViewCell.m +++ b/GIGA/Modules/Me/View/GiGaMineUserViewCell.m @@ -31,10 +31,13 @@ if (user.headImgUrl && ![user.nickName isKindOfClass:[NSNull class]]) { [self.userAvator sd_setImageWithURL:[NSURL URLWithString:user.headImgUrl]]; } - if (!user.nickName && ![user.nickName isKindOfClass:[NSNull class]]) { - self.userName.text = user.nickName; - }else{ + + if (!user.nickName || [user.nickName isKindOfClass:[NSNull class]] || [user.nickName isEqualToString:@""]) { + self.userName.text = @"GIGAUser666"; + + }else{ + self.userName.text = user.nickName; } } diff --git a/GIGA/Modules/Me/View/userInfoView/GIGaUserChangeMobleCell.h b/GIGA/Modules/Me/View/userInfoView/GIGaUserChangeMobleCell.h new file mode 100644 index 0000000..bfafcd6 --- /dev/null +++ b/GIGA/Modules/Me/View/userInfoView/GIGaUserChangeMobleCell.h @@ -0,0 +1,19 @@ +// +// GIGaUserChangeMobleCell.h +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import + +@interface GIGaUserChangeMobleCell : UITableViewCell +@property (weak, nonatomic) IBOutlet UIButton *codeSendBtn; +@property (weak, nonatomic) IBOutlet UIButton *oldBtn; +@property (weak, nonatomic) IBOutlet UIButton *xinPhoneBtn; + +@property (weak, nonatomic) IBOutlet UITextField *numberTexFiled; +@property (weak, nonatomic) IBOutlet UITextField *codeTexFiled; + +@end diff --git a/GIGA/Modules/Me/View/userInfoView/GIGaUserChangeMobleCell.m b/GIGA/Modules/Me/View/userInfoView/GIGaUserChangeMobleCell.m new file mode 100644 index 0000000..86ffbd7 --- /dev/null +++ b/GIGA/Modules/Me/View/userInfoView/GIGaUserChangeMobleCell.m @@ -0,0 +1,29 @@ +// +// GIGaUserChangeMobleCell.m +// GIGA +// +// Created by lianxiang on 2018/9/19. +// Copyright © 2018年 com.giga.ios. All rights reserved. +// + +#import "GIGaUserChangeMobleCell.h" + +@implementation GIGaUserChangeMobleCell + +- (void)awakeFromNib { + [super awakeFromNib]; + // Initialization code + self.codeSendBtn.layer.masksToBounds = YES; + self.codeSendBtn.layer.cornerRadius = 2; + +} + + + +- (void)setSelected:(BOOL)selected animated:(BOOL)animated { + [super setSelected:selected animated:animated]; + + // Configure the view for the selected state +} + +@end diff --git a/GIGA/Modules/Me/View/userInfoView/GIGaUserChangeMobleCell.xib b/GIGA/Modules/Me/View/userInfoView/GIGaUserChangeMobleCell.xib new file mode 100644 index 0000000..a1fe5ce --- /dev/null +++ b/GIGA/Modules/Me/View/userInfoView/GIGaUserChangeMobleCell.xib @@ -0,0 +1,137 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +