1 |
- webpackJsonp([113],{"kw0/":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});n("dKK0");var a=n("balU"),o=n("7+uW");n("PJh5");o.a.use(a.a);var i={name:"employee_edit",data:function(){return{submit_loading:!1,userinfo:this.$userInfo(),account_info:this.$store.getters.account_info}},created:function(){var t=this;this.$nextTick(function(){t.$refs.nickname_input.focus()})},methods:{employee_update:function(){var t=this;if(""==t.userinfo.nickname)return t.$toast("姓名不能为空!"),!1;t.submit_loading=!0,t.$toast.loading({mask:!0,message:"正在处理"}),this.$axios("post","/api/pro/account/edit",{name:t.account_info.name,img_url:t.account_info.img_url}).then(function(e){if(t.submit_loading=!1,1==e.data.code){if(t.$toast(e.data.msg),window.plus?plus.storage.removeItem("account_info"):localStorage.removeItem("account_info"),window.plus)for(var n=plus.webview.all(),a=0;a<n.length;a++)n[a].evalJS('window.VueObj.$store.dispatch("get_account_info").then(function(res){window.VueObj.$forceUpdate();});');else t.$store.dispatch("get_account_info");t.$toast.clear(),setTimeout(function(){t.$route_back()},500)}else t.$toast(e.data.msg)}).catch(function(e){t.$toast(e)})}}},c={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("van-nav-bar",{attrs:{"right-text":"保存",title:"修改资料","left-text":"返回","left-arrow":""},on:{"click-left":t.$route_back,"click-right":t.employee_update}}),t._v(" "),n("div",{staticClass:"body_com",staticStyle:{"background-color":"#f1f1f1"}},[n("scroller",[n("van-cell-group",[n("van-field",{ref:"nickname_input",attrs:{required:"",label:"姓名",placeholder:"输入您的姓名",maxlength:"15"},model:{value:t.account_info.name,callback:function(e){t.$set(t.account_info,"name",e)},expression:"account_info.name"}})],1)],1)],1)],1)},staticRenderFns:[]};var s=n("VU/8")(i,c,!1,function(t){n("n2nm")},"data-v-575de610",null);e.default=s.exports},n2nm:function(t,e){}});
|