"use strict";(self["webpackChunkbaozhida_chain_verify_online"]=self["webpackChunkbaozhida_chain_verify_online"]||[]).push([[292],{6292:function(e,t,i){i.r(t),i.d(t,{default:function(){return v}});var s=function(){var e=this,t=e._self._c;return t("div",{staticClass:"login"},[t("div",{staticClass:"loginMai"},[t("div",{staticClass:"loginPir"},[t("div",{staticClass:"loginPir-t"}),t("div",{staticClass:"loginPir-c"},[t("div",{staticClass:"loginPir-cLR"},[e._m(0),t("div",{staticClass:"loginPir-c-R"},[t("div",{staticClass:"loginPir-c-R1"},[e._v(" 账号登录/Login ")]),t("div",{staticClass:"loginPir-c-R2"},[t("div",{staticStyle:{"margin-bottom":"15px"}},[t("el-input",{attrs:{placeholder:"请输入内容"},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.login.apply(null,arguments)}},model:{value:e.Info.bzd_username,callback:function(t){e.$set(e.Info,"bzd_username",t)},expression:"Info.bzd_username"}})],1),t("div",{staticStyle:{"margin-bottom":"15px"}},[t("el-input",{attrs:{placeholder:"请输入密码","show-password":""},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.login.apply(null,arguments)}},model:{value:e.Info.bzd_password,callback:function(t){e.$set(e.Info,"bzd_password",t)},expression:"Info.bzd_password"}})],1),t("div",{staticStyle:{"margin-bottom":"15px"}},[t("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择"},model:{value:e.Info.value,callback:function(t){e.$set(e.Info,"value",t)},expression:"Info.value"}},e._l(e.options,(function(e){return t("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1)],1),t("div",{staticStyle:{"margin-top":"40px"}},[t("el-button",{staticStyle:{width:"100%"},attrs:{type:"primary"},on:{click:e.login}},[e._v("登录")])],1)])])])]),t("div",{staticClass:"loginPir-b"})])])])},n=[function(){var e=this,t=e._self._c;return t("div",{staticClass:"loginPir-c-L"},[t("h1",[e._v("冷链验证报告线上")]),t("div",{staticClass:"loginPir-c-L"},[e._v(" 验证报告管理、校准证书管理 ")])])}],a=i(4784);const o={UserLogin:"/Login_verification",AdminLogin:"/Login_Admin_verification"};function r(e){return(0,a.o)({url:o.UserLogin,method:"post",data:e})}function l(e){return(0,a.o)({url:o.AdminLogin,method:"post",data:e})}var d={data(){return{Info:{bzd_username:"",bzd_password:"",value:"2"},options:[{value:"1",label:"管理员登录"},{value:"2",label:"用户登录"}]}},methods:{login(){""!==this.Info.bzd_username?""!==this.Info.bzd_username?1==this.Info.value?this.GetadminLgApi():this.GetuserLgApi():this.$message.error("请输入登录密码"):this.$message.error("请输入登录账号")},GetuserLgApi(){var e={bzd_username:this.Info.bzd_username,bzd_password:this.$md5(this.Info.bzd_password)};r(e).then((e=>{200==e.data.Code&&(this.$store.commit("setuserInfo",{username:this.Info.bzd_username,password:this.Info.bzd_password,value:this.Info.value,token:e.data.Data}),this.$router.replace("/home"))}))},GetadminLgApi(){var e={bzd_username:this.Info.bzd_username,bzd_password:this.$md5(this.Info.bzd_password)};l(e).then((e=>{200==e.data.Code&&(this.$store.commit("setuserInfo",{username:this.Info.bzd_username,password:this.Info.bzd_password,value:this.Info.value,token:e.data.Data}),this.$router.replace("/home"))}))}}},u=d,c=i(1001),p=(0,c.Z)(u,s,n,!1,null,null,null),v=p.exports}}]);
//# sourceMappingURL=292.8779fb13.js.map