Showing
1 changed file
with
11 additions
and
18 deletions
| @@ -97,20 +97,16 @@ struct LoginPage { | @@ -97,20 +97,16 @@ struct LoginPage { | ||
| 97 | .margin({ top: 78 }) | 97 | .margin({ top: 78 }) |
| 98 | .align(Alignment.Center) | 98 | .align(Alignment.Center) |
| 99 | 99 | ||
| 100 | - if (this.checkCodePage) { | ||
| 101 | - LoginInputComponent({ | ||
| 102 | - phoneContent: $phoneContent, | ||
| 103 | - codeContent: $codeContent, | ||
| 104 | - isSubmit: $isSubmit, | ||
| 105 | - isCodeSend: $isCodeSend, | ||
| 106 | - codeStateSuccess:$codeStateSuccess, | ||
| 107 | - protocolState:this.protocolState, | ||
| 108 | - isNeedProtocol:true | ||
| 109 | - }) | ||
| 110 | - } else { | ||
| 111 | - this.addPassword() | ||
| 112 | - } | ||
| 113 | - | 100 | + LoginInputComponent({ |
| 101 | + phoneContent: $phoneContent, | ||
| 102 | + codeContent: $codeContent, | ||
| 103 | + isSubmit: $isSubmit, | ||
| 104 | + isCodeSend: $isCodeSend, | ||
| 105 | + codeStateSuccess:$codeStateSuccess, | ||
| 106 | + protocolState:this.protocolState, | ||
| 107 | + isNeedProtocol:true | ||
| 108 | + }).visibility(this.checkCodePage ? Visibility.Visible : Visibility.None) | ||
| 109 | + this.addPassword() | ||
| 114 | 110 | ||
| 115 | Row() { | 111 | Row() { |
| 116 | Image(this.protocolState ? $r('app.media.login_checkbox_select') : $r('app.media.login_checkbox_unselected')) | 112 | Image(this.protocolState ? $r('app.media.login_checkbox_select') : $r('app.media.login_checkbox_unselected')) |
| @@ -239,11 +235,7 @@ struct LoginPage { | @@ -239,11 +235,7 @@ struct LoginPage { | ||
| 239 | }) | 235 | }) |
| 240 | 236 | ||
| 241 | RelativeContainer() { | 237 | RelativeContainer() { |
| 242 | - // if (this.passwordSwitch) { | ||
| 243 | this.addPasswordInputLayout() | 238 | this.addPasswordInputLayout() |
| 244 | - // } else { | ||
| 245 | - // this.addPasswordInputLayout() | ||
| 246 | - // } | ||
| 247 | 239 | ||
| 248 | Image(this.passwordSwitch ? $r('app.media.login_password_off') : $r('app.media.login_password_on')) | 240 | Image(this.passwordSwitch ? $r('app.media.login_password_off') : $r('app.media.login_password_on')) |
| 249 | .onClick(() => { | 241 | .onClick(() => { |
| @@ -262,6 +254,7 @@ struct LoginPage { | @@ -262,6 +254,7 @@ struct LoginPage { | ||
| 262 | .height(48) | 254 | .height(48) |
| 263 | .width('100%') | 255 | .width('100%') |
| 264 | }.padding({ left: 25, right: 25 }).width('100%').margin({ top: 36 }) | 256 | }.padding({ left: 25, right: 25 }).width('100%').margin({ top: 36 }) |
| 257 | + .visibility(this.checkCodePage ? Visibility.None : Visibility.Visible) | ||
| 265 | 258 | ||
| 266 | } | 259 | } |
| 267 | 260 |
-
Please register or login to post a comment