"use strict";(self["webpackChunktest"]=self["webpackChunktest"]||[]).push([[702],{9702:function(e,t,s){s.r(t),s.d(t,{default:function(){return d}});var r=function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",[s("div",{staticClass:"login"},[s("h1",[e._v("欢迎来到后台管理系统")]),s("div",{staticClass:"inp"},[s("form",{attrs:{action:""}},[e._v(" 用户名: "),s("input",{directives:[{name:"model",rawName:"v-model",value:e.id,expression:"id"}],attrs:{type:"text",placeholder:"请输入账号"},domProps:{value:e.id},on:{input:function(t){t.target.composing||(e.id=t.target.value)}}}),s("br"),s("br"),e._v(" 密  码: "),s("input",{directives:[{name:"model",rawName:"v-model",value:e.password,expression:"password"}],attrs:{type:"password",placeholder:"请输入密码",autocomplete:"off"},domProps:{value:e.password},on:{input:function(t){t.target.composing||(e.password=t.target.value)}}}),s("br"),s("br"),s("el-button",{attrs:{type:"primary"},on:{click:e.submit}},[e._v("登录")])],1)])])])},a=[],n=s(6198),o=(s(5666),{name:"Login",data:function(){return{id:"",password:""}},methods:{submit:function(){var e=this;return(0,n.Z)(regeneratorRuntime.mark((function t(){var s,r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return s={username:e.id,password:e.password},t.next=3,e.$axios("/api/user/login/","POST",s);case 3:r=t.sent,console.log(r),0===r.code?(e.$message.success("登录成功"),window.sessionStorage.setItem("token",123),e.$router.push("/LayOut")):e.$message.error("登录失败");case 6:case"end":return t.stop()}}),t)})))()}}}),i=o,u=s(1001),c=(0,u.Z)(i,r,a,!1,null,"7d183ff8",null),d=c.exports}}]);
//# sourceMappingURL=702-legacy.js.map