webpackJsonp([5],{"6Qob":function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=i("mvHQ"),n=i.n(s),o=i("5reh"),r=i("zL8q");function a(t){return t?(r.Message.warning(t),!1):(r.Message.warning("操作失败"),!1)}function l(t){return"cancel"==t?(r.Message.info(t||"cancel"),!1):t.hasOwnProperty("response")?401==t.response.status?(r.Message.error("登录过期"),!1):500==t.response.status?(r.Message.error("服务器错误500"),!1):void 0:(r.Message.error(t),!1)}var c=i("mw3O"),u={name:"login",data:function(){return{redirect:this.$route.query.redirect,token:"",form:{loginName:"damogic",password:"1",eid:"ff808081593917d90159398ec6340012"}}},computed:{imgHeight:function(){return document.body.clientHeight},imgWidth:function(){return document.body.clientWidth}},methods:{loginAnimate:function(){new LoginAnimate(loginwrap,{length:90,LineWeight:.1,clicked:!0,moveon:!0}).Run()},submitLogin:function(){var t=this;this.axios.post("/api-auth/do-login",c.stringify({loginName:this.form.loginName,password:this.form.password,eid:"ff808081593917d90159398ec6340012"})).then(function(e){if(e.data.success){(s=e.data.message)?r.Message.success(s):r.Message.success("操作成功");var i=decodeURIComponent(t.$route.query.redirect||"/index");t.$router.push({path:i})}else a(e.data.message);var s}).catch(function(t){l(t)})},getMenu:function(){var t=this;this.axios.get("/gic/get-menu").then(function(e){if(e.data.success){t.menuList=e.data.list,sessionStorage.setItem("menuList",n()(t.menuList));var i=t.$route.query.redirect||"/index";t.$router.push({path:i})}else a(e.data.errorMessage)}).catch(function(t){l(t)})}},mounted:function(){this.$store.commit(o.d,"login"),document.title=this.$store.state.title,this.loginAnimate()}},m={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"loginwrap",style:{height:t.imgHeight+"px"}},[i("div",{staticStyle:{position:"absolute",left:"0",height:"0",width:"100%"}},[i("canvas",{attrs:{id:"loginwrap",width:t.imgWidth,height:t.imgHeight}})]),t._v(" "),t._m(0),t._v(" "),i("div",{staticClass:"login_contetnt"},[i("h3",{staticClass:"login-top"},[t._v("让信息连接一切")]),t._v(" "),i("h4",{staticClass:"login-bottom"},[t._v("GIC商户后台")]),t._v(" "),i("div",{staticClass:"formlogin"},[i("el-form",{ref:"form",attrs:{model:t.form,"label-width":""}},[i("el-form-item",{attrs:{label:""}},[i("el-input",{staticClass:"forminput",attrs:{placeholder:"账号"},model:{value:t.form.loginName,callback:function(e){t.$set(t.form,"loginName",e)},expression:"form.loginName"}})],1),t._v(" "),i("el-form-item",{attrs:{label:""}},[i("el-input",{attrs:{type:"password",placeholder:"密码"},nativeOn:{keyup:function(e){if(!("button"in e)&&t._k(e.keyCode,"enter",13,e.key,"Enter"))return null;t.submitLogin("form")}},model:{value:t.form.password,callback:function(e){t.$set(t.form,"password",e)},expression:"form.password"}})],1),t._v(" "),i("el-form-item",[i("button",{staticClass:"submit",on:{click:function(e){e.preventDefault(),t.submitLogin("form")}}},[t._v("立即登录")])])],1)],1)])])},staticRenderFns:[function(){var t=this.$createElement,e=this._self._c||t;return e("div",{staticClass:"logintop"},[e("div",{staticClass:"fl loginlogo"},[e("a",{staticClass:"fr logo",attrs:{href:"#"}},[this._v("login_logo.png")])]),this._v(" "),e("a",{staticClass:"home-link fr",attrs:{href:"http://www.demogic.com/"}},[this._v("返回首页")])])}]};var f=i("VU/8")(u,m,!1,function(t){i("J8TP")},null,null);e.default=f.exports},J8TP:function(t,e){},mvHQ:function(t,e,i){t.exports={default:i("qkKv"),__esModule:!0}},qkKv:function(t,e,i){var s=i("FeBl"),n=s.JSON||(s.JSON={stringify:JSON.stringify});t.exports=function(t){return n.stringify.apply(n,arguments)}}});
//# sourceMappingURL=5.e1f32dac7e4a97a4eb1b.js.map