(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-79033610"],{"02f8":function(t,n,e){},"3bb0":function(t,n,e){t.exports=e.p+"static/img/oauth_loading.7a48dd1b.gif"},"51c1":function(t,n,e){"use strict";e.r(n);var o=function(){var t=this,n=t.$createElement;t._self._c;return t._m(0)},i=[function(){var t=this,n=t.$createElement,o=t._self._c||n;return o("div",{staticClass:"content"},[o("div",{staticClass:"loading-ico"},[o("img",{attrs:{src:e("3bb0")}})]),o("div",{staticClass:"loading-txt"},[t._v("正在获取第三方授权...")])])}],a=e("ed08"),r=e("751a"),c=e("d722"),s={name:"OauthWeixin",data:function(){return{code:""}},created:function(){this.init()},methods:{doLogin:function(t){var n=this;r["a"].post(c["a"].oauth_weixin_login,t).then((function(t){200===parseInt(t.code)?(Object(a["f"])("LoginErrorNumByCode",0),Object(a["f"])("LoginErrorNumByPwd",0),n.$store.commit("clearCountDownFun"),n.$store.commit("setLoginState",{whether:!0,utype:t.data.utype,token:t.data.token,mobile:t.data.mobile,userIminfo:t.data.user_iminfo}),1===t.data.utype?n.$router.push("/company"):n.$router.push("/personal")):n.$message.error(t.message)})).catch((function(){}))},getUserinfo:function(t){var n=this,e={code:t};r["a"].post(c["a"].oauth_weixin_getuserinfo,e).then((function(t){n.doLogin(t.data)})).catch((function(){}))},init:function(){var t=this.$route.params.code;if(void 0!==t)return this.getUserinfo(t),!1}}},u=s,d=(e("dc2d"),e("2877")),f=Object(d["a"])(u,o,i,!1,null,"107eb796",null);n["default"]=f.exports},dc2d:function(t,n,e){"use strict";var o=e("02f8"),i=e.n(o);i.a}}]);