(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pagesCard/mine/index"],{"08b0":function(t,e,n){"use strict";var a=n("8858"),i=n.n(a);i.a},"75ac":function(t,e,n){"use strict";(function(t,e){var a=n("47a9");n("aa6c");a(n("3240"));var i=a(n("990b"));t.__webpack_require_UNI_MP_PLUGIN__=n,e(i.default)}).call(this,n("3223")["default"],n("df3c")["createPage"])},8858:function(t,e,n){},"990b":function(t,e,n){"use strict";n.r(e);var a=n("f883"),i=n("ea20");for(var r in i)["default"].indexOf(r)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(r);n("08b0");var o=n("828b"),s=Object(o["a"])(i["default"],a["b"],a["c"],!1,null,null,null,!1,a["a"],void 0);e["default"]=s.exports},e8d7:function(t,e,n){"use strict";(function(t){var a=n("47a9");Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=a(n("7ca3")),r=n("8f59");function o(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}var s={components:{cardItem:function(){n.e("pagesCard/component/card/index").then(function(){return resolve(n("f812"))}.bind(null,n)).catch(n.oe)}},data:function(){return{loadEnd:!1,titleBarHeight:0,cardStatistics:{},cardList:[],defaultCard:{},shareData:{}}},computed:function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?o(Object(n),!0).forEach((function(e){(0,i.default)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({},(0,r.mapState)({themeColor:function(t){return t.app.themeColor},shareImage:function(t){return t.app.shareImage},shareTitle:function(t){return t.app.shareTitle}})),mounted:function(){var e=t.getSystemInfoSync().statusBarHeight,n=t.getMenuButtonBoundingClientRect();this.titleBarHeight=e+2*(n.top-e)+n.height},onLoad:function(){var e=this;t.showLoading({title:"加载中"}),this.getCardStatistics(),this.getDefaultCard(),this.getCardList((function(){t.hideLoading(),e.loadEnd=!0}))},onShow:function(){this.loadEnd&&(this.getCardStatistics(),this.getDefaultCard(),this.getCardList())},onPullDownRefresh:function(){this.getCardStatistics(),this.getDefaultCard(),this.getCardList((function(){t.stopPullDownRefresh()}))},onShareAppMessage:function(t){return"button"==t.from?{title:this.shareData.share_title,path:"/pagesCard/card/details?id="+this.shareData.id,imageUrl:this.shareData.image}:"menu"==t.from?{title:this.shareTitle,imageUrl:this.shareImage}:void 0},onShareTimeline:function(){return{title:this.shareTitle,imageUrl:this.shareImage}},methods:{getCardStatistics:function(){var e=this;this.$util.request("card.statistics").then((function(n){1==n.code?e.cardStatistics=n.data:t.showToast({title:n.msg,icon:"none"})})).catch((function(t){console.error("获取名片统计 ",t)}))},getCardList:function(e){var n=this;this.$util.request("card.list").then((function(a){e&&e(),1==a.code?n.cardList=a.data:t.showToast({title:a.msg,icon:"none"})})).catch((function(t){e&&e(),console.error("获取名片列表 ",t)}))},getDefaultCard:function(){var e=this;this.$util.request("card.getDefault").then((function(n){1==n.code?e.defaultCard=n.data:t.showToast({title:n.msg,icon:"none"})})).catch((function(t){console.error("获取默认名片 ",t)}))},handleAdd:function(){this.$util.toPage({mode:1,path:"/pagesCard/mine/edit"})},setShareData:function(t){this.shareData=t},resetCardList:function(){this.getDefaultCard(),this.getCardList()},setShareTips:function(){t.showToast({icon:"none",title:"请先设置默认名片后操作"})},toCardManage:function(){this.$util.toPage({mode:1,path:"/pagesCard/mine/manage"})}}};e.default=s}).call(this,n("df3c")["default"])},ea20:function(t,e,n){"use strict";n.r(e);var a=n("e8d7"),i=n.n(a);for(var r in a)["default"].indexOf(r)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(r);e["default"]=i.a},f883:function(t,e,n){"use strict";n.d(e,"b",(function(){return a})),n.d(e,"c",(function(){return i})),n.d(e,"a",(function(){}));var a=function(){var t=this.$createElement,e=(this._self._c,this.loadEnd?this.cardList.length:null);this.$mp.data=Object.assign({},{$root:{g0:e}})},i=[]}},[["75ac","common/runtime","common/vendor"]]]);