设置密码bug

This commit is contained in:
2014-09-26 00:03:43 +08:00
parent f36feccb80
commit febf66e89b
9 changed files with 42 additions and 30 deletions
-1
View File
@@ -18,7 +18,6 @@
* @param type type description
*/
+(void)presentLoginView;
//获取view的viewcontroller
+(UIViewController*)getCurrentViewControllerWithView:(UIView*)view;
//获取当前viewcontroller
+1 -1
View File
@@ -9,6 +9,7 @@
#import "ManagerUtil.h"
#import "LoginViewController.h"
#import "AppDelegate.h"
#import "ModifyPassWordViewController.h"
#import "DottedLineView.h"
#import <CommonCrypto/CommonDigest.h>
@implementation ManagerUtil
@@ -23,7 +24,6 @@
[app.mainViewController presentViewController:nav animated:YES completion:^{
}];
}
+(void)SetSubViewExternNone:(UIViewController *)viewController
{
@@ -20,13 +20,13 @@
<subviews>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="输入您的手机号" minimumFontSize="14" clearButtonMode="always" id="SX2-5w-3mj">
<rect key="frame" x="10" y="84" width="300" height="40"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" keyboardType="numberPad"/>
</textField>
<label hidden="YES" opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="21b-R2-QIH">
<rect key="frame" x="12" y="124" width="296" height="40"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" red="1" green="0.83810605820836981" blue="0.24953396881744794" alpha="1" colorSpace="calibratedRGB"/>
<fontDescription key="fontDescription" type="system" pointSize="22"/>
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
@@ -34,7 +34,7 @@
</label>
<view contentMode="scaleToFill" id="XWc-eN-89L">
<rect key="frame" x="10" y="130" width="300" height="120"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="贷贷不会在任何地方泄漏您的号码" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="fpY-NW-BZm">
<rect key="frame" x="11" y="0.0" width="198" height="21"/>
@@ -61,7 +61,6 @@
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<simulatedStatusBarMetrics key="simulatedStatusBarMetrics"/>
<simulatedNavigationBarMetrics key="simulatedTopBarMetrics" prompted="NO"/>
<simulatedScreenMetrics key="simulatedDestinationMetrics" type="retina4"/>
</view>
</objects>
@@ -31,6 +31,9 @@
{
[super viewDidLoad];
// Do any additional setup after loading the view from its nib.
self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"取消" style:UIBarButtonItemStyleBordered target:self action:@selector(popViewController)];
self.navigationItem.title = @"身份验证";
_isRealName = YES;
_timeSecond = 60;
_cmsBtn.enabled = NO;
@@ -67,6 +70,11 @@
[self realNameCheck];
}
-(void)popViewController
{
[self.navigationController dismissViewControllerAnimated:YES completion:nil];
}
-(void)reGetCodeTime
{
if (_timeSecond > 0 && !_cmsBtn.enabled) {
@@ -81,6 +89,7 @@
[_timer invalidate];
}
}
-(void)realNameCheck
{
DaiDaiTongTestApi* daiDaiTongTestApi = [DaiDaiTongTestApi shareInstance];
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="5056" systemVersion="13E28" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="5056" systemVersion="13E28" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="3733"/>
</dependencies>
@@ -21,35 +21,35 @@
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="iXV-eh-jNr">
<rect key="frame" x="0.0" y="54" width="320" height="568"/>
<view contentMode="scaleToFill" id="iXV-eh-jNr">
<rect key="frame" x="0.0" y="70" width="320" height="568"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="真实姓名" minimumFontSize="14" clearButtonMode="always" translatesAutoresizingMaskIntoConstraints="NO" id="D26-j2-ay9">
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="真实姓名" minimumFontSize="14" clearButtonMode="always" id="D26-j2-ay9">
<rect key="frame" x="9" y="20" width="300" height="40"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits"/>
</textField>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" enabled="NO" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="手机号" minimumFontSize="14" translatesAutoresizingMaskIntoConstraints="NO" id="6Nn-bE-uWk">
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" enabled="NO" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="手机号" minimumFontSize="14" id="6Nn-bE-uWk">
<rect key="frame" x="10" y="120" width="300" height="40"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" keyboardType="numberPad"/>
</textField>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="身份证号码" minimumFontSize="14" clearButtonMode="always" translatesAutoresizingMaskIntoConstraints="NO" id="HnT-u2-4qv">
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="身份证号码" minimumFontSize="14" clearButtonMode="always" id="HnT-u2-4qv">
<rect key="frame" x="10" y="70" width="300" height="40"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" keyboardType="numberPad"/>
</textField>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="短信验证码" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="6bZ-wv-Ayz">
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="短信验证码" minimumFontSize="17" id="6bZ-wv-Ayz">
<rect key="frame" x="10" y="174" width="139" height="40"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" keyboardType="numberPad"/>
</textField>
<button opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Mnc-JV-36d">
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" id="Mnc-JV-36d">
<rect key="frame" x="166" y="174" width="143" height="40"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<color key="backgroundColor" red="1" green="0.0" blue="0.0" alpha="1" colorSpace="calibratedRGB"/>
@@ -62,7 +62,7 @@
<action selector="cmsBtnClick:" destination="-1" eventType="touchUpInside" id="PTR-oJ-wsJ"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="YJJ-rn-OXK">
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" id="YJJ-rn-OXK">
<rect key="frame" x="9" y="233" width="300" height="45"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<color key="backgroundColor" red="1" green="0.0" blue="0.0" alpha="1" colorSpace="calibratedRGB"/>
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="5056" systemVersion="13E28" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="5056" systemVersion="13E28" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="3733"/>
</dependencies>
@@ -17,27 +17,27 @@
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="设置密码" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="qes-Vw-q4F">
<rect key="frame" x="20" y="28" width="280" height="44"/>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="设置密码" minimumFontSize="17" id="qes-Vw-q4F">
<rect key="frame" x="20" y="70" width="280" height="44"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" secureTextEntry="YES"/>
</textField>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="密码确认" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="s3w-SU-YZd">
<rect key="frame" x="20" y="109" width="280" height="44"/>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="line" placeholder="密码确认" minimumFontSize="17" id="s3w-SU-YZd">
<rect key="frame" x="20" y="149" width="280" height="44"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" secureTextEntry="YES"/>
</textField>
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="密码由6-16个字符组成,字母区分大小写" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" preferredMaxLayoutWidth="280" translatesAutoresizingMaskIntoConstraints="NO" id="0Ee-ib-6T6">
<rect key="frame" x="20" y="80" width="280" height="21"/>
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="密码由6-16个字符组成,字母区分大小写" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="0Ee-ib-6T6">
<rect key="frame" x="20" y="120" width="280" height="21"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<fontDescription key="fontDescription" type="system" pointSize="12"/>
<color key="textColor" white="0.33333333333333331" alpha="1" colorSpace="calibratedWhite"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="mWs-sA-ia8">
<rect key="frame" x="20" y="171" width="280" height="42"/>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" id="mWs-sA-ia8">
<rect key="frame" x="20" y="210" width="280" height="42"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<color key="backgroundColor" red="1" green="0.0" blue="0.0" alpha="1" colorSpace="calibratedRGB"/>
<state key="normal" title="完成">
@@ -51,6 +51,7 @@
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<simulatedStatusBarMetrics key="simulatedStatusBarMetrics"/>
<simulatedNavigationBarMetrics key="simulatedTopBarMetrics" prompted="NO"/>
<simulatedScreenMetrics key="simulatedDestinationMetrics" type="retina4"/>
</view>
</objects>
@@ -174,7 +174,9 @@
ModifyPassWordViewController* modifyPassWordViewController = [[ModifyPassWordViewController alloc] init];
modifyPassWordViewController.type = 0;
modifyPassWordViewController.phoneNum = _phoneNum;
[self.navigationController pushViewController:modifyPassWordViewController animated:YES];
[self.navigationController presentViewController:[[UINavigationController alloc] initWithRootViewController:modifyPassWordViewController] animated:YES completion:^{
}];
// SetPassWordViewController* setPassWordViewController = [[SetPassWordViewController alloc] init];
// [self.navigationController pushViewController:setPassWordViewController animated:YES];
}
@@ -183,7 +185,9 @@
ModifyPassWordViewController* modifyPassWordViewController = [[ModifyPassWordViewController alloc] init];
modifyPassWordViewController.type = 1;
modifyPassWordViewController.phoneNum = _phoneNum;
[self.navigationController pushViewController:modifyPassWordViewController animated:YES];
[self.navigationController presentViewController:[[UINavigationController alloc] initWithRootViewController:modifyPassWordViewController] animated:YES completion:^{
}];
// AuthenticationViewController* authenticationViewController = [[AuthenticationViewController alloc] init];
// [self.navigationController pushViewController:authenticationViewController animated:YES];
// SetPassWordViewController* setPassWordViewController = [[SetPassWordViewController alloc] init];
@@ -64,9 +64,9 @@
-(void)viewDidAppear:(BOOL)animated
{
[super viewDidAppear:animated];
if (_myInfoDic == nil) {
[self.tableView headerBeginRefreshing];
}
// if (_myInfoDic == nil) {
// [self.tableView headerBeginRefreshing];
// }
}
#pragma mark MJRefreshDelegate
- (void)headerRereshing