1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-157bba72"],{"14d9":function(t,e,r){"use strict";var n=r("23e7"),o=r("7b0b"),i=r("07fa"),a=r("3a34"),s=r("3511"),l=r("d039"),c=l((function(){return 4294967297!==[].push.call({length:4294967296},1)})),u=function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(t){return t instanceof TypeError}},d=c||!u();n({target:"Array",proto:!0,arity:1,forced:d},{push:function(t){var e=o(this),r=i(e),n=arguments.length;s(r+n);for(var l=0;l<n;l++)e[r]=arguments[l],r++;return a(e,r),r}})},3511:function(t,e,r){"use strict";var n=TypeError,o=9007199254740991;t.exports=function(t){if(t>o)throw n("Maximum allowed index exceeded");return t}},"3a34":function(t,e,r){"use strict";var n=r("83ab"),o=r("e8b5"),i=TypeError,a=Object.getOwnPropertyDescriptor,s=n&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(t){return t instanceof TypeError}}();t.exports=s?function(t,e){if(o(t)&&!a(t,"length").writable)throw new i("Cannot set read only .length");return t.length=e}:function(t,e){return t.length=e}},"48a9":function(t,e,r){"use strict";r.r(e);var n=function(){var t=this,e=t._self._c;return e("div",{staticClass:"pt-28 p-4"},[e("div",{staticClass:"text-center"},[e("van-image",{attrs:{width:"6rem",height:"6rem",src:this.$settings.logo}}),e("p",{staticClass:"mt-5 mb-12 text-2xl"},[t._v("志远选材报价")])],1),e("van-form",{on:{submit:t.onSubmit}},[e("van-field",{attrs:{clearable:"",label:"手机号",placeholder:"请输入手机号",type:"tel",rules:[{required:!0}]},model:{value:t.loginForm.phone,callback:function(e){t.$set(t.loginForm,"phone",e)},expression:"loginForm.phone"}}),e("van-field",{attrs:{clearable:"",type:"password",label:"密码",placeholder:"请输入密码",rules:[{required:!0}]},model:{value:t.loginForm.password,callback:function(e){t.$set(t.loginForm,"password",e)},expression:"loginForm.password"}}),e("div",{staticClass:"mt-8"},[e("van-button",{attrs:{loading:t.loginLoading,block:"",type:"info","loading-text":"加载中...","native-type":"submit"}},[t._v("登录")])],1)],1)],1)},o=[],i=(r("14d9"),r("13d5"),r("b64b"),r("d3b7"),{data:function(){return{loginLoading:!1,sendLoading:!1,loginForm:{phone:"",code:""}}},watch:{$route:{handler:function(t){var e=t.query;console.log(t.query),e&&(this.redirect=e.redirect,this.otherQuery=this.getOtherQuery(e))},immediate:!0}},methods:{onSubmit:function(){var t=this;this.loginLoading=!0,this.$store.dispatch("user/login",this.loginForm).then((function(){t.$router.push({path:t.redirect||"/",query:t.otherQuery}),t.loginLoading=!1})).catch((function(){t.loginLoading=!1}))},getOtherQuery:function(t){return Object.keys(t).reduce((function(e,r){return"redirect"!==r&&(e[r]=t[r]),e}),{})}}}),a=i,s=r("2877"),l=Object(s["a"])(a,n,o,!1,null,null,null);e["default"]=l.exports}}]);
|