parameters: (self)
return_statement: return div
docstring: Return code confirmation form.
docstring_summary: Return code confirmation form.
docstring_tokens: Return code confirmation form .
function: def get_code_confirmation_content(self):
          '''Return code confirmation form.'''
  
          web = WebContainer.get_web()
          login_name = web.get_form_value('login')
          hidden = HiddenWdg('login', login_name)
  
          div = DivWdg()
          div.add_style("margin: 0px 0px")
  
          div.add(hidden)
  
          # hidden element in the form to pass message that this was not
          # actually a typical submitted form, but rather the result
          # of a login page
          div.add( HiddenWdg("is_from_login", "yes") )
          div.add_style("font-size: 10px")
          div.add_class("reset-container")
  
          div.add("<div class='code-msg-container'>A code was sent to <span class='msg-user'>%s</span>'s email. Please enter the code to reset your password:</div>" % login_name)
  
          code_container = DivWdg()
          div.add(code_container)
          code_container.add_class("sign-in-input")
          code_container.add("<div class='label'>Code</div>")
  
          code_wdg = TextWdg("code")
          code_container.add(code_wdg)
  
          bottom_container = DivWdg()
          div.add(bottom_container)
          bottom_container.add_class("bottom-container")
  
          resend_container = DivWdg()
          bottom_container.add(resend_container)
  
          next_button = DivWdg('Next')
          bottom_container.add(next_button)
          next_button.add_class('sign-in-btn hand')
          next_button.add_attr('title', 'Next')
          next_button.add_event("onclick", "document.form.elements['reset_password'].value='true'; document.form.submit()")
  
          hidden = HiddenWdg('reset_password')
          div.add(hidden)
  
          msg = web.get_form_value(BaseSignInWdg.RESET_MSG_LABEL)
          if msg:
              err_msg_container = DivWdg()
              div.add(err_msg_container)
              err_msg_container.add_class("msg-container")
  
              err_msg_container.add("<i class='fa fa-exclamation-circle'></i><span>%s</span>" % msg)
  
  
              resend_container.add_class("forgot-password-container")
              hidden = HiddenWdg('resend_code')
              resend_container.add(hidden)
  
              access_msg = "Resend email"
              js = '''document.form.elements['resend_code'].value='true'; document.form.submit()'''
              link = HtmlElement.js_href(js, data=access_msg)
              link.add_color('color','color', 60)
              resend_container.add(link)
  
  
          div.add(self.get_content_styles())
  
          return div
function_tokens: def get_code_confirmation_content ( self ) : web = WebContainer . get_web ( ) login_name = web . get_form_value ( 'login' ) hidden = HiddenWdg ( 'login' , login_name ) div = DivWdg ( ) div . add_style ( "margin: 0px 0px" ) div . add ( hidden ) # hidden element in the form to pass message that this was not # actually a typical submitted form, but rather the result # of a login page div . add ( HiddenWdg ( "is_from_login" , "yes" ) ) div . add_style ( "font-size: 10px" ) div . add_class ( "reset-container" ) div . add ( "<div class='code-msg-container'>A code was sent to <span class='msg-user'>%s</span>'s email. Please enter the code to reset your password:</div>" % login_name ) code_container = DivWdg ( ) div . add ( code_container ) code_container . add_class ( "sign-in-input" ) code_container . add ( "<div class='label'>Code</div>" ) code_wdg = TextWdg ( "code" ) code_container . add ( code_wdg ) bottom_container = DivWdg ( ) div . add ( bottom_container ) bottom_container . add_class ( "bottom-container" ) resend_container = DivWdg ( ) bottom_container . add ( resend_container ) next_button = DivWdg ( 'Next' ) bottom_container . add ( next_button ) next_button . add_class ( 'sign-in-btn hand' ) next_button . add_attr ( 'title' , 'Next' ) next_button . add_event ( "onclick" , "document.form.elements['reset_password'].value='true'; document.form.submit()" ) hidden = HiddenWdg ( 'reset_password' ) div . add ( hidden ) msg = web . get_form_value ( BaseSignInWdg . RESET_MSG_LABEL ) if msg : err_msg_container = DivWdg ( ) div . add ( err_msg_container ) err_msg_container . add_class ( "msg-container" ) err_msg_container . add ( "<i class='fa fa-exclamation-circle'></i><span>%s</span>" % msg ) resend_container . add_class ( "forgot-password-container" ) hidden = HiddenWdg ( 'resend_code' ) resend_container . add ( hidden ) access_msg = "Resend email" js = '''document.form.elements['resend_code'].value='true'; document.form.submit()''' link = HtmlElement . js_href ( js , data = access_msg ) link . add_color ( 'color' , 'color' , 60 ) resend_container . add ( link ) div . add ( self . get_content_styles ( ) ) return div