"use strict";(self["webpackChunktest"]=self["webpackChunktest"]||[]).push([[33],{2033:function(e,t,s){s.r(t),s.d(t,{default:function(){return d}});var a=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)])])])},r=[],o={name:"Login",data(){return{id:"",password:""}},methods:{async submit(){const e={username:this.id,password:this.password},t=await this.$axios("/api/user/login/","POST",e);0===t.code?(this.$message.success("登录成功"),window.sessionStorage.setItem("token",123),this.$router.push("/LayOut")):this.$message.error("登录失败")}}},i=o,n=s(1001),u=(0,n.Z)(i,a,r,!1,null,"6bbe5650",null),d=u.exports}}]);
//# sourceMappingURL=33.js.map