scms.namespace("m.auth");scms.container.createDialog("scms.m.auth.login",{msg:null,show:function(msg)
{this.msg=msg;this.display();},getConfig:function()
{return{constraintoviewport:true,fixedcenter:true}},getHtml:function()
{var html='<div class="hd">Anmeldung</div>'
+'<div class="bd">'
+'<fieldset class="dataset">'
+'<p><label for="'+this.getFieldId("username")+'">Benutzername:</label>'
+'<input type="text" id="'+this.getFieldId("username")+'" value="" /></p>'
+'<p><label for="'+this.getFieldId("password")+'">Passwort:</label>'
+'<input type="password" id="'+this.getFieldId("password")+'" /></p>'
+'<p class="text error" style="margin-top: 17px;" id="'+this.getFieldId("message")+'"></p>'
+'</fieldset>'
+'</div>';return html;},load:function()
{var inst=this;scms.shortcut.add("enter",function(){inst.save();});var dlg=this.getDialog();dlg.moveTo(null,100);this.getFieldElement("username").focus();var msg=this.getFieldElement("message");if(!this.msg){YAHOO.util.Dom.setStyle(msg,"display","none");}else{msg.innerHTML=this.msg;}},getButtons:function()
{var inst=this;return[{text:"Passwort vergessen",handler:function(){window.location.href=SLink.simple("auth","lostpassword");return false;}},{text:"Anmelden",handler:function(){inst.save();return false;}}];},save:function()
{this.startLoading();document.getElementById("use2rn5ame").value=this.getFieldElement("username").value;document.getElementById("pas2sw5ord").value=this.getFieldElement("password").value;document.getElementById("login-form").submit();},cancel:function()
{window.location.href="/";}});
