(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/set/userinfo"],{"256b":function(t,e,n){"use strict";n.r(e);var o=n("b014"),r=n("9c9a");for(var c in r)"default"!==c&&function(t){n.d(e,t,(function(){return r[t]}))}(c);n("6ebc");var u,a=n("f0c5"),i=Object(a["a"])(r["default"],o["b"],o["c"],!1,null,null,null,!1,o["a"],u);e["default"]=i.exports},"6ebc":function(t,e,n){"use strict";var o=n("bfb4"),r=n.n(o);r.a},"9c9a":function(t,e,n){"use strict";n.r(e);var o=n("b16b"),r=n.n(o);for(var c in o)"default"!==c&&function(t){n.d(e,t,(function(){return o[t]}))}(c);e["default"]=r.a},b014:function(t,e,n){"use strict";var o;n.d(e,"b",(function(){return r})),n.d(e,"c",(function(){return c})),n.d(e,"a",(function(){return o}));var r=function(){var t=this,e=t.$createElement;t._self._c},c=[]},b16b:function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var o=n("26cb"),r=n("ef8a"),c=n("1d0e");function u(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,o)}return n}function a(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?u(Object(n),!0).forEach((function(e){i(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var f={data:function(){return{}},onLoad:function(){console.log(this.userInfo)},computed:a({},(0,o.mapState)("user",["userInfo"])),methods:a(a({},(0,o.mapMutations)("user",["logout"])),{},{imgsub:function(){var t=this;console.log("上传头像"),(0,r.uploads)({filename:""}).then((function(e){console.log("data",e),t.userInfo.avatar=e[0].url}))},confirm:function(){var e=this;(0,c.userEdit)({avatar:this.userInfo.avatar,nickname:this.userInfo.nickname}).then((function(n){e.$api.msg("修改成功"),setTimeout((function(){t.switchTab({url:"/pages/user/user"})}),1e3),console.log(n)})).catch((function(t){console.log(t)}))},toLogout:function(){var e=this;t.showModal({content:"确定要退出登录么",success:function(n){n.confirm&&((0,c.logout)({}).then((function(e){t.navigateBack()})).catch((function(t){console.log(t)})),e.logout())}})}})};e.default=f}).call(this,n("543d")["default"])},b56a:function(t,e,n){"use strict";(function(t){n("e27b");o(n("66fd"));var e=o(n("256b"));function o(t){return t&&t.__esModule?t:{default:t}}wx.__webpack_require_UNI_MP_PLUGIN__=n,t(e.default)}).call(this,n("543d")["createPage"])},bfb4:function(t,e,n){}},[["b56a","common/runtime","common/vendor"]]]);