Commit 63fbe41ba2e27570746943fdc2cc13185a8efb44
Exists in
newLive
Merge branch 'newLive' of http://git.shunzhi.net/iosgroup/newlive into newLive
Showing
4 changed files
with
101 additions
and
34 deletions
Show diff stats
YouerLiveVideo/YouerLiveVideo/controllers/User/Setting/ChangePassWordViewController.swift
@@ -22,6 +22,7 @@ class ChangePassWordViewController: UIViewController { | @@ -22,6 +22,7 @@ class ChangePassWordViewController: UIViewController { | ||
22 | @IBOutlet weak var agrenPasswordTextFiled: UITextField! | 22 | @IBOutlet weak var agrenPasswordTextFiled: UITextField! |
23 | @IBOutlet weak var userCodeTextFiled: UITextField! | 23 | @IBOutlet weak var userCodeTextFiled: UITextField! |
24 | 24 | ||
25 | + @IBOutlet var cancleItem: UIBarButtonItem! | ||
25 | 26 | ||
26 | var scrollViewH:CGFloat = 200 | 27 | var scrollViewH:CGFloat = 200 |
27 | var user = AppDelegate.instance().accountManager | 28 | var user = AppDelegate.instance().accountManager |
@@ -29,13 +30,20 @@ class ChangePassWordViewController: UIViewController { | @@ -29,13 +30,20 @@ class ChangePassWordViewController: UIViewController { | ||
29 | self.view.endEditing(true) | 30 | self.view.endEditing(true) |
30 | } | 31 | } |
31 | 32 | ||
33 | + @IBAction func cancleAction(_ sender: UIBarButtonItem) { | ||
34 | + self.dismiss(animated: true, completion: nil) | ||
35 | + } | ||
32 | override func viewDidLoad() { | 36 | override func viewDidLoad() { |
33 | super.viewDidLoad() | 37 | super.viewDidLoad() |
34 | if user.isOnline() { | 38 | if user.isOnline() { |
39 | + self.navigationItem.rightBarButtonItem=nil | ||
35 | phonrView.isHidden=true | 40 | phonrView.isHidden=true |
36 | phoneViewHeight.constant=0 | 41 | phoneViewHeight.constant=0 |
37 | scrollViewH=150 | 42 | scrollViewH=150 |
38 | }else{ | 43 | }else{ |
44 | + self.configTheme() | ||
45 | + self.title="忘记密码" | ||
46 | + self.navigationItem.rightBarButtonItem=cancleItem | ||
39 | phonrView.isHidden=false | 47 | phonrView.isHidden=false |
40 | phoneViewHeight.constant=50 | 48 | phoneViewHeight.constant=50 |
41 | scrollViewH=200 | 49 | scrollViewH=200 |
@@ -71,23 +79,24 @@ class ChangePassWordViewController: UIViewController { | @@ -71,23 +79,24 @@ class ChangePassWordViewController: UIViewController { | ||
71 | if user.isOnline() { | 79 | if user.isOnline() { |
72 | phone=user.phone() | 80 | phone=user.phone() |
73 | }else{ | 81 | }else{ |
74 | - phone=passwordTextFiled.text! | 82 | + phone=userPhoneTextFiled.text! |
75 | } | 83 | } |
76 | SVProgressHUD.show(withStatus: "修改密码...") | 84 | SVProgressHUD.show(withStatus: "修改密码...") |
77 | SVProgressHUD.setDefaultMaskType(.black) | 85 | SVProgressHUD.setDefaultMaskType(.black) |
78 | - let parameters:Dictionary<String,AnyObject>=["f_Account":user.account() as AnyObject, | ||
79 | - "f_Mobile":phone as AnyObject, | ||
80 | - "f_UserPassword":passwordTextFiled.text! as AnyObject, | ||
81 | - "f_VerCode":userCodeTextFiled.text! as AnyObject] | 86 | + let parameters:Dictionary<String,AnyObject>=["mobile":phone as AnyObject, |
87 | + "password":passwordTextFiled.text!.md5() as AnyObject, | ||
88 | + "vercode":userCodeTextFiled.text! as AnyObject] | ||
82 | AppDelegate.instance().httpServer.getUpdatePassword(parameters: parameters) { (str, error) in | 89 | AppDelegate.instance().httpServer.getUpdatePassword(parameters: parameters) { (str, error) in |
83 | SVProgressHUD.dismiss() | 90 | SVProgressHUD.dismiss() |
84 | if error==nil { | 91 | if error==nil { |
85 | if JSON.fromString(jsonString: str)!["status"].intValue == 1{ | 92 | if JSON.fromString(jsonString: str)!["status"].intValue == 1{ |
86 | httpJsonResule(jsonString: str, error: error, successHandler: { (json) in | 93 | httpJsonResule(jsonString: str, error: error, successHandler: { (json) in |
87 | if !self.user.isOnline() { | 94 | if !self.user.isOnline() { |
88 | - NotificationCenter.default.post(name: NSNotification.Name(rawValue: "refreshLoginUser"), object: self.passwordTextFiled.text!) | 95 | + NotificationCenter.default.post(name: NSNotification.Name(rawValue: "refreshLoginUser"), object: phone) |
96 | + self.dismiss(animated: true, completion: nil) | ||
97 | + }else{ | ||
98 | + self.navigationController!.popViewController(animated: true) | ||
89 | } | 99 | } |
90 | - self.navigationController!.popViewController(animated: true) | ||
91 | AppDelegate.instance().window?.makeToast("修改成功") | 100 | AppDelegate.instance().window?.makeToast("修改成功") |
92 | }, failHandler: { (error) in | 101 | }, failHandler: { (error) in |
93 | self.view.makeToast("修改失败") | 102 | self.view.makeToast("修改失败") |
YouerLiveVideo/YouerLiveVideo/controllers/User/User.storyboard
@@ -260,10 +260,10 @@ | @@ -260,10 +260,10 @@ | ||
260 | </objects> | 260 | </objects> |
261 | <point key="canvasLocation" x="1509.5999999999999" y="-131.78410794602701"/> | 261 | <point key="canvasLocation" x="1509.5999999999999" y="-131.78410794602701"/> |
262 | </scene> | 262 | </scene> |
263 | - <!--Change Pass Word View Controller--> | 263 | + <!--忘记密码--> |
264 | <scene sceneID="opx-Sc-v2W"> | 264 | <scene sceneID="opx-Sc-v2W"> |
265 | <objects> | 265 | <objects> |
266 | - <viewController storyboardIdentifier="ChangePassWordViewControllerVC" id="HIn-e8-Pzh" customClass="ChangePassWordViewController" customModule="YouerLiveVideo" customModuleProvider="target" sceneMemberID="viewController"> | 266 | + <viewController storyboardIdentifier="ChangePassWordViewControllerVC" automaticallyAdjustsScrollViewInsets="NO" id="HIn-e8-Pzh" customClass="ChangePassWordViewController" customModule="YouerLiveVideo" customModuleProvider="target" sceneMemberID="viewController"> |
267 | <layoutGuides> | 267 | <layoutGuides> |
268 | <viewControllerLayoutGuide type="top" id="fMj-B9-eEF"/> | 268 | <viewControllerLayoutGuide type="top" id="fMj-B9-eEF"/> |
269 | <viewControllerLayoutGuide type="bottom" id="Gxk-Dg-G3D"/> | 269 | <viewControllerLayoutGuide type="bottom" id="Gxk-Dg-G3D"/> |
@@ -281,8 +281,8 @@ | @@ -281,8 +281,8 @@ | ||
281 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="PPf-BI-ZxE"> | 281 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="PPf-BI-ZxE"> |
282 | <rect key="frame" x="0.0" y="100" width="375" height="50"/> | 282 | <rect key="frame" x="0.0" y="100" width="375" height="50"/> |
283 | <subviews> | 283 | <subviews> |
284 | - <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请重复您输入的新密码" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="Qzh-5W-Fdl"> | ||
285 | - <rect key="frame" x="20" y="16.5" width="335" height="17"/> | 284 | + <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请重复您输入的新密码" textAlignment="natural" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="Qzh-5W-Fdl"> |
285 | + <rect key="frame" x="20" y="15.5" width="335" height="19"/> | ||
286 | <nil key="textColor"/> | 286 | <nil key="textColor"/> |
287 | <fontDescription key="fontDescription" type="system" pointSize="14"/> | 287 | <fontDescription key="fontDescription" type="system" pointSize="14"/> |
288 | <textInputTraits key="textInputTraits"/> | 288 | <textInputTraits key="textInputTraits"/> |
@@ -315,8 +315,8 @@ | @@ -315,8 +315,8 @@ | ||
315 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="YjI-UW-Ova"> | 315 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="YjI-UW-Ova"> |
316 | <rect key="frame" x="0.0" y="150" width="375" height="50"/> | 316 | <rect key="frame" x="0.0" y="150" width="375" height="50"/> |
317 | <subviews> | 317 | <subviews> |
318 | - <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入您收到的验证码" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="dtg-hq-Nhp"> | ||
319 | - <rect key="frame" x="20" y="17" width="147" height="17"/> | 318 | + <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入您收到的验证码" textAlignment="natural" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="dtg-hq-Nhp"> |
319 | + <rect key="frame" x="20" y="16" width="246" height="19"/> | ||
320 | <nil key="textColor"/> | 320 | <nil key="textColor"/> |
321 | <fontDescription key="fontDescription" type="system" pointSize="14"/> | 321 | <fontDescription key="fontDescription" type="system" pointSize="14"/> |
322 | <textInputTraits key="textInputTraits" keyboardType="numberPad"/> | 322 | <textInputTraits key="textInputTraits" keyboardType="numberPad"/> |
@@ -340,6 +340,12 @@ | @@ -340,6 +340,12 @@ | ||
340 | <state key="normal" title=" 获取验证码 "> | 340 | <state key="normal" title=" 获取验证码 "> |
341 | <color key="titleColor" white="1" alpha="1" colorSpace="calibratedWhite"/> | 341 | <color key="titleColor" white="1" alpha="1" colorSpace="calibratedWhite"/> |
342 | </state> | 342 | </state> |
343 | + <userDefinedRuntimeAttributes> | ||
344 | + <userDefinedRuntimeAttribute type="boolean" keyPath="layer.masksToBounds" value="YES"/> | ||
345 | + <userDefinedRuntimeAttribute type="number" keyPath="layer.cornerRadius"> | ||
346 | + <integer key="value" value="5"/> | ||
347 | + </userDefinedRuntimeAttribute> | ||
348 | + </userDefinedRuntimeAttributes> | ||
343 | <connections> | 349 | <connections> |
344 | <action selector="sendUserCodeBtnClick:" destination="HIn-e8-Pzh" eventType="touchUpInside" id="Hmd-rM-a0h"/> | 350 | <action selector="sendUserCodeBtnClick:" destination="HIn-e8-Pzh" eventType="touchUpInside" id="Hmd-rM-a0h"/> |
345 | </connections> | 351 | </connections> |
@@ -361,8 +367,8 @@ | @@ -361,8 +367,8 @@ | ||
361 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="DSL-73-rUm"> | 367 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="DSL-73-rUm"> |
362 | <rect key="frame" x="0.0" y="50" width="375" height="50"/> | 368 | <rect key="frame" x="0.0" y="50" width="375" height="50"/> |
363 | <subviews> | 369 | <subviews> |
364 | - <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入新密码" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="KOX-8X-bEC"> | ||
365 | - <rect key="frame" x="20" y="17" width="335" height="17"/> | 370 | + <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入新密码" textAlignment="natural" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="KOX-8X-bEC"> |
371 | + <rect key="frame" x="20" y="16" width="335" height="19"/> | ||
366 | <nil key="textColor"/> | 372 | <nil key="textColor"/> |
367 | <fontDescription key="fontDescription" type="system" pointSize="14"/> | 373 | <fontDescription key="fontDescription" type="system" pointSize="14"/> |
368 | <textInputTraits key="textInputTraits"/> | 374 | <textInputTraits key="textInputTraits"/> |
@@ -395,8 +401,8 @@ | @@ -395,8 +401,8 @@ | ||
395 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="b6X-Hs-kwP"> | 401 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="b6X-Hs-kwP"> |
396 | <rect key="frame" x="0.0" y="0.0" width="375" height="50"/> | 402 | <rect key="frame" x="0.0" y="0.0" width="375" height="50"/> |
397 | <subviews> | 403 | <subviews> |
398 | - <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入新密码" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="bQy-pc-aag"> | ||
399 | - <rect key="frame" x="20" y="17" width="335" height="17"/> | 404 | + <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入手机号" textAlignment="natural" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="bQy-pc-aag"> |
405 | + <rect key="frame" x="20" y="16" width="335" height="19"/> | ||
400 | <nil key="textColor"/> | 406 | <nil key="textColor"/> |
401 | <fontDescription key="fontDescription" type="system" pointSize="14"/> | 407 | <fontDescription key="fontDescription" type="system" pointSize="14"/> |
402 | <textInputTraits key="textInputTraits"/> | 408 | <textInputTraits key="textInputTraits"/> |
@@ -513,8 +519,16 @@ | @@ -513,8 +519,16 @@ | ||
513 | <action selector="editKeyboard:" destination="HIn-e8-Pzh" eventType="touchUpInside" id="Gqe-4a-Nym"/> | 519 | <action selector="editKeyboard:" destination="HIn-e8-Pzh" eventType="touchUpInside" id="Gqe-4a-Nym"/> |
514 | </connections> | 520 | </connections> |
515 | </view> | 521 | </view> |
522 | + <navigationItem key="navigationItem" title="忘记密码" id="kn3-BP-XrH"> | ||
523 | + <barButtonItem key="rightBarButtonItem" title="取消" id="Qjp-nS-fi2"> | ||
524 | + <connections> | ||
525 | + <action selector="cancleAction:" destination="HIn-e8-Pzh" id="TkS-G8-Iyw"/> | ||
526 | + </connections> | ||
527 | + </barButtonItem> | ||
528 | + </navigationItem> | ||
516 | <connections> | 529 | <connections> |
517 | <outlet property="agrenPasswordTextFiled" destination="Qzh-5W-Fdl" id="NIs-ap-xHZ"/> | 530 | <outlet property="agrenPasswordTextFiled" destination="Qzh-5W-Fdl" id="NIs-ap-xHZ"/> |
531 | + <outlet property="cancleItem" destination="Qjp-nS-fi2" id="gIx-W1-0Kq"/> | ||
518 | <outlet property="contentSizeHeight" destination="lat-Tj-mho" id="3Ro-l4-uWu"/> | 532 | <outlet property="contentSizeHeight" destination="lat-Tj-mho" id="3Ro-l4-uWu"/> |
519 | <outlet property="passwordTextFiled" destination="KOX-8X-bEC" id="Rd7-u2-mLM"/> | 533 | <outlet property="passwordTextFiled" destination="KOX-8X-bEC" id="Rd7-u2-mLM"/> |
520 | <outlet property="phoneViewHeight" destination="xsq-cP-2jd" id="yza-R9-2EJ"/> | 534 | <outlet property="phoneViewHeight" destination="xsq-cP-2jd" id="yza-R9-2EJ"/> |
@@ -527,7 +541,7 @@ | @@ -527,7 +541,7 @@ | ||
527 | </viewController> | 541 | </viewController> |
528 | <placeholder placeholderIdentifier="IBFirstResponder" id="kXj-Be-3l7" userLabel="First Responder" sceneMemberID="firstResponder"/> | 542 | <placeholder placeholderIdentifier="IBFirstResponder" id="kXj-Be-3l7" userLabel="First Responder" sceneMemberID="firstResponder"/> |
529 | </objects> | 543 | </objects> |
530 | - <point key="canvasLocation" x="776.79999999999995" y="550.97451274362822"/> | 544 | + <point key="canvasLocation" x="1716" y="550.97451274362822"/> |
531 | </scene> | 545 | </scene> |
532 | <!--History View Controller--> | 546 | <!--History View Controller--> |
533 | <scene sceneID="U2w-Je-5CE"> | 547 | <scene sceneID="U2w-Je-5CE"> |
@@ -619,5 +633,23 @@ | @@ -619,5 +633,23 @@ | ||
619 | </objects> | 633 | </objects> |
620 | <point key="canvasLocation" x="2237.5999999999999" y="-131.78410794602701"/> | 634 | <point key="canvasLocation" x="2237.5999999999999" y="-131.78410794602701"/> |
621 | </scene> | 635 | </scene> |
636 | + <!--Navigation Controller--> | ||
637 | + <scene sceneID="i2G-X9-4tF"> | ||
638 | + <objects> | ||
639 | + <navigationController storyboardIdentifier="ForgetPasswordNVC" automaticallyAdjustsScrollViewInsets="NO" id="Bvh-GB-Vld" sceneMemberID="viewController"> | ||
640 | + <toolbarItems/> | ||
641 | + <navigationBar key="navigationBar" contentMode="scaleToFill" id="Xw0-eG-MuP"> | ||
642 | + <rect key="frame" x="0.0" y="0.0" width="375" height="44"/> | ||
643 | + <autoresizingMask key="autoresizingMask"/> | ||
644 | + </navigationBar> | ||
645 | + <nil name="viewControllers"/> | ||
646 | + <connections> | ||
647 | + <segue destination="HIn-e8-Pzh" kind="relationship" relationship="rootViewController" id="4I7-9a-ckQ"/> | ||
648 | + </connections> | ||
649 | + </navigationController> | ||
650 | + <placeholder placeholderIdentifier="IBFirstResponder" id="iPu-LA-mtp" userLabel="First Responder" sceneMemberID="firstResponder"/> | ||
651 | + </objects> | ||
652 | + <point key="canvasLocation" x="776.79999999999995" y="550.97451274362822"/> | ||
653 | + </scene> | ||
622 | </scenes> | 654 | </scenes> |
623 | </document> | 655 | </document> |
YouerLiveVideo/YouerLiveVideo/controllers/User/UserCenter/Login.storyboard
@@ -78,7 +78,7 @@ | @@ -78,7 +78,7 @@ | ||
78 | </imageView> | 78 | </imageView> |
79 | <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入账号" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="IzH-dB-I9H"> | 79 | <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入账号" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="IzH-dB-I9H"> |
80 | <rect key="frame" x="36" y="18.5" width="339" height="19"/> | 80 | <rect key="frame" x="36" y="18.5" width="339" height="19"/> |
81 | - <fontDescription key="fontDescription" type="system" pointSize="13"/> | 81 | + <fontDescription key="fontDescription" type="system" pointSize="15"/> |
82 | <textInputTraits key="textInputTraits" keyboardType="numberPad"/> | 82 | <textInputTraits key="textInputTraits" keyboardType="numberPad"/> |
83 | <connections> | 83 | <connections> |
84 | <outlet property="delegate" destination="fvc-9c-Gca" id="l7n-F4-FsF"/> | 84 | <outlet property="delegate" destination="fvc-9c-Gca" id="l7n-F4-FsF"/> |
@@ -120,7 +120,7 @@ | @@ -120,7 +120,7 @@ | ||
120 | </imageView> | 120 | </imageView> |
121 | <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入密码" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="nVn-EA-yWM"> | 121 | <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入密码" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="nVn-EA-yWM"> |
122 | <rect key="frame" x="36" y="18.5" width="339" height="19"/> | 122 | <rect key="frame" x="36" y="18.5" width="339" height="19"/> |
123 | - <fontDescription key="fontDescription" type="system" pointSize="13"/> | 123 | + <fontDescription key="fontDescription" type="system" pointSize="15"/> |
124 | <textInputTraits key="textInputTraits" secureTextEntry="YES"/> | 124 | <textInputTraits key="textInputTraits" secureTextEntry="YES"/> |
125 | <connections> | 125 | <connections> |
126 | <outlet property="delegate" destination="fvc-9c-Gca" id="tMS-9N-o09"/> | 126 | <outlet property="delegate" destination="fvc-9c-Gca" id="tMS-9N-o09"/> |
@@ -175,7 +175,7 @@ | @@ -175,7 +175,7 @@ | ||
175 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="pzO-1N-Vrz"> | 175 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="pzO-1N-Vrz"> |
176 | <rect key="frame" x="16" y="182" width="343" height="30"/> | 176 | <rect key="frame" x="16" y="182" width="343" height="30"/> |
177 | <subviews> | 177 | <subviews> |
178 | - <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="设置密码或找回密码" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="v6n-Br-sBy"> | 178 | + <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="忘记密码或找回密码" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="v6n-Br-sBy"> |
179 | <rect key="frame" x="0.0" y="0.0" width="119.5" height="30"/> | 179 | <rect key="frame" x="0.0" y="0.0" width="119.5" height="30"/> |
180 | <fontDescription key="fontDescription" type="system" pointSize="13"/> | 180 | <fontDescription key="fontDescription" type="system" pointSize="13"/> |
181 | <nil key="highlightedColor"/> | 181 | <nil key="highlightedColor"/> |
@@ -185,29 +185,51 @@ | @@ -185,29 +185,51 @@ | ||
185 | <fontDescription key="fontDescription" type="system" pointSize="13"/> | 185 | <fontDescription key="fontDescription" type="system" pointSize="13"/> |
186 | <nil key="highlightedColor"/> | 186 | <nil key="highlightedColor"/> |
187 | </label> | 187 | </label> |
188 | - <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="ps0-yz-uMV"> | 188 | + <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="T7C-vv-Dor"> |
189 | <rect key="frame" x="0.0" y="0.0" width="343" height="30"/> | 189 | <rect key="frame" x="0.0" y="0.0" width="343" height="30"/> |
190 | - <fontDescription key="fontDescription" type="system" pointSize="13"/> | ||
191 | - <state key="normal"> | ||
192 | - <color key="titleColor" white="1" alpha="1" colorSpace="calibratedWhite"/> | ||
193 | - </state> | ||
194 | - <connections> | ||
195 | - <action selector="registerBtnClickAction:" destination="fvc-9c-Gca" eventType="touchUpInside" id="joQ-gk-ZzE"/> | ||
196 | - </connections> | ||
197 | - </button> | 190 | + <subviews> |
191 | + <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="ps0-yz-uMV"> | ||
192 | + <rect key="frame" x="171.5" y="0.0" width="171.5" height="30"/> | ||
193 | + <fontDescription key="fontDescription" type="system" pointSize="13"/> | ||
194 | + <state key="normal"> | ||
195 | + <color key="titleColor" white="1" alpha="1" colorSpace="calibratedWhite"/> | ||
196 | + </state> | ||
197 | + <connections> | ||
198 | + <action selector="registerBtnClickAction:" destination="fvc-9c-Gca" eventType="touchUpInside" id="joQ-gk-ZzE"/> | ||
199 | + </connections> | ||
200 | + </button> | ||
201 | + <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="xaX-gZ-zWh"> | ||
202 | + <rect key="frame" x="0.0" y="0.0" width="171.5" height="30"/> | ||
203 | + <connections> | ||
204 | + <action selector="returnPassword:" destination="fvc-9c-Gca" eventType="touchUpInside" id="WCg-Bw-Rh0"/> | ||
205 | + </connections> | ||
206 | + </button> | ||
207 | + </subviews> | ||
208 | + <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/> | ||
209 | + <constraints> | ||
210 | + <constraint firstAttribute="bottom" secondItem="xaX-gZ-zWh" secondAttribute="bottom" id="6fF-FD-MJB"/> | ||
211 | + <constraint firstItem="ps0-yz-uMV" firstAttribute="leading" secondItem="xaX-gZ-zWh" secondAttribute="trailing" id="Dys-kN-Wuj"/> | ||
212 | + <constraint firstAttribute="bottom" secondItem="ps0-yz-uMV" secondAttribute="bottom" id="ONw-ic-gJh"/> | ||
213 | + <constraint firstItem="xaX-gZ-zWh" firstAttribute="leading" secondItem="T7C-vv-Dor" secondAttribute="leading" id="SgW-zP-wM4"/> | ||
214 | + <constraint firstItem="ps0-yz-uMV" firstAttribute="top" secondItem="T7C-vv-Dor" secondAttribute="top" id="YrN-s2-zsD"/> | ||
215 | + <constraint firstItem="xaX-gZ-zWh" firstAttribute="top" secondItem="T7C-vv-Dor" secondAttribute="top" id="bZG-zy-wj2"/> | ||
216 | + <constraint firstAttribute="trailing" secondItem="ps0-yz-uMV" secondAttribute="trailing" id="mbh-g5-oXR"/> | ||
217 | + <constraint firstItem="ps0-yz-uMV" firstAttribute="width" secondItem="T7C-vv-Dor" secondAttribute="width" multiplier="1:2" id="qcM-tG-rkH"/> | ||
218 | + </constraints> | ||
219 | + </view> | ||
198 | </subviews> | 220 | </subviews> |
199 | <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/> | 221 | <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/> |
200 | <constraints> | 222 | <constraints> |
201 | - <constraint firstItem="ps0-yz-uMV" firstAttribute="top" secondItem="pzO-1N-Vrz" secondAttribute="top" id="7G1-mO-jQj"/> | ||
202 | <constraint firstAttribute="trailing" secondItem="7fx-1i-VwW" secondAttribute="trailing" id="8ot-xx-BFo"/> | 223 | <constraint firstAttribute="trailing" secondItem="7fx-1i-VwW" secondAttribute="trailing" id="8ot-xx-BFo"/> |
203 | <constraint firstAttribute="bottom" secondItem="7fx-1i-VwW" secondAttribute="bottom" id="Byb-9b-kOd"/> | 224 | <constraint firstAttribute="bottom" secondItem="7fx-1i-VwW" secondAttribute="bottom" id="Byb-9b-kOd"/> |
225 | + <constraint firstAttribute="trailing" secondItem="T7C-vv-Dor" secondAttribute="trailing" id="KF5-RM-Ush"/> | ||
226 | + <constraint firstItem="T7C-vv-Dor" firstAttribute="leading" secondItem="pzO-1N-Vrz" secondAttribute="leading" id="Owr-Ww-G6p"/> | ||
204 | <constraint firstAttribute="height" constant="30" id="TT4-WL-hYa"/> | 227 | <constraint firstAttribute="height" constant="30" id="TT4-WL-hYa"/> |
205 | <constraint firstItem="7fx-1i-VwW" firstAttribute="top" secondItem="pzO-1N-Vrz" secondAttribute="top" id="VzP-hc-s7a"/> | 228 | <constraint firstItem="7fx-1i-VwW" firstAttribute="top" secondItem="pzO-1N-Vrz" secondAttribute="top" id="VzP-hc-s7a"/> |
206 | - <constraint firstAttribute="bottom" secondItem="ps0-yz-uMV" secondAttribute="bottom" id="d8H-p3-iy8"/> | ||
207 | - <constraint firstAttribute="trailing" secondItem="ps0-yz-uMV" secondAttribute="trailing" id="eo1-LL-5jy"/> | 229 | + <constraint firstAttribute="bottom" secondItem="T7C-vv-Dor" secondAttribute="bottom" id="dPD-d5-Eqe"/> |
208 | <constraint firstAttribute="bottom" secondItem="v6n-Br-sBy" secondAttribute="bottom" id="gbJ-jU-WFB"/> | 230 | <constraint firstAttribute="bottom" secondItem="v6n-Br-sBy" secondAttribute="bottom" id="gbJ-jU-WFB"/> |
231 | + <constraint firstItem="T7C-vv-Dor" firstAttribute="top" secondItem="pzO-1N-Vrz" secondAttribute="top" id="hCd-Ju-trB"/> | ||
209 | <constraint firstItem="v6n-Br-sBy" firstAttribute="top" secondItem="pzO-1N-Vrz" secondAttribute="top" id="hj5-hs-ep4"/> | 232 | <constraint firstItem="v6n-Br-sBy" firstAttribute="top" secondItem="pzO-1N-Vrz" secondAttribute="top" id="hj5-hs-ep4"/> |
210 | - <constraint firstItem="ps0-yz-uMV" firstAttribute="leading" secondItem="pzO-1N-Vrz" secondAttribute="leading" id="uJt-wq-oTh"/> | ||
211 | <constraint firstItem="v6n-Br-sBy" firstAttribute="leading" secondItem="pzO-1N-Vrz" secondAttribute="leading" id="xdM-JA-UcQ"/> | 233 | <constraint firstItem="v6n-Br-sBy" firstAttribute="leading" secondItem="pzO-1N-Vrz" secondAttribute="leading" id="xdM-JA-UcQ"/> |
212 | </constraints> | 234 | </constraints> |
213 | </view> | 235 | </view> |
YouerLiveVideo/YouerLiveVideo/controllers/User/UserCenter/LoginViewController.swift
@@ -129,6 +129,10 @@ class LoginViewController: UIViewController,UITextFieldDelegate { | @@ -129,6 +129,10 @@ class LoginViewController: UIViewController,UITextFieldDelegate { | ||
129 | let vc = UIStoryboard(name: "Login", bundle: nil).instantiateViewController(withIdentifier: "RegisterViewControllerNV") | 129 | let vc = UIStoryboard(name: "Login", bundle: nil).instantiateViewController(withIdentifier: "RegisterViewControllerNV") |
130 | self.present(vc, animated: true, completion: nil) | 130 | self.present(vc, animated: true, completion: nil) |
131 | } | 131 | } |
132 | + @IBAction func returnPassword(_ sender: UIButton) { | ||
133 | + let vc = Story.instantiateViewControllerWithIdentifier("ForgetPasswordNVC", storyName: "User") | ||
134 | + self.present(vc!, animated: true, completion: nil) | ||
135 | + } | ||
132 | //键盘监听 | 136 | //键盘监听 |
133 | func keyboardWIllChange(noti: NSNotification){ | 137 | func keyboardWIllChange(noti: NSNotification){ |
134 | let userInfo:NSDictionary=noti.userInfo! as NSDictionary | 138 | let userInfo:NSDictionary=noti.userInfo! as NSDictionary |