webpackJsonp([44],{"6mP/":function(t,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=s("Dd8w"),n=s.n(i),c=s("Au9i"),a=(s("vAZe"),{props:{item:{type:Object},isSelected:{type:Boolean,default:!1}},computed:{iconUrl:function(){return this.isSelected?s("Hq5k"):s("nXob")},isDefault:function(){return!!this.item&&this.item.is_default},detailAddress:function(){var t="";if(this.item)for(var e=this.item.regions,s=0;s<e.length;s++){t+=e[s].name}return t+=this.item.address}},methods:{onclick:function(){this.$emit("onclick")}}}),r={render:function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"container",on:{click:t.onclick}},[s("div",{staticClass:"left-wrapper"},[s("div",{staticClass:"title-wrapper"},[s("label",{staticClass:"title"},[t._v(t._s(t.item.name))]),t._v(" "),s("label",{staticClass:"title"},[t._v(t._s(t.item.mobile))]),t._v(" "),t.isDefault?s("label",{staticClass:"default"},[t._v("默认")]):t._e()]),t._v(" "),s("label",{staticClass:"desc address-text",staticStyle:{"-webkit-box-orient":"vertical"}},[t._v(t._s(t.detailAddress))])]),t._v(" "),s("img",{staticClass:"indicator",attrs:{src:t.iconUrl}})])},staticRenderFns:[]};var l=s("VU/8")(a,r,!1,function(t){s("rvEY")},"data-v-3ceae8d2",null).exports,o=s("NYxO"),d=s("J6os"),u={components:{AddressItem:l},computed:n()({},Object(o.e)({selectedItem:function(t){return t.address.selectedItem},items:function(t){return t.address.items}})),created:function(){var t=this;d.c().then(function(e){var s=e.consignees;t.saveAddressItems(s)},function(t){Object(c.Toast)(t.errorMsg)})},methods:n()({},Object(o.d)(["selectAddressItem","saveAddressItems"]),{isSelectedItem:function(t){return!(!t||!this.selectedItem||t.id!==this.selectedItem.id)},goBack:function(){this.$router.go(-1)},goManage:function(){this.$router.push({name:"addressManage",query:{isFromCheckout:!0}})},onclick:function(t){this.selectAddressItem(t),this.goBack()}})},m={render:function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"container"},[s("mt-header",{staticClass:"header",attrs:{fixed:"",title:"收货地址"}},[s("header-item",{attrs:{slot:"left",isBack:!0},on:{onclick:t.goBack},slot:"left"}),t._v(" "),s("header-item",{attrs:{slot:"right",title:"管理"},on:{onclick:t.goManage},slot:"right"})],1),t._v(" "),s("div",{staticClass:"list"},t._l(t.items,function(e){return s("address-item",{key:e.id,attrs:{item:e,isSelected:t.isSelectedItem(e)},on:{onclick:function(s){t.onclick(e)}}})}))],1)},staticRenderFns:[]};var f=s("VU/8")(u,m,!1,function(t){s("QU1W")},"data-v-337abebe",null);e.default=f.exports},QU1W:function(t,e){},rvEY:function(t,e){}});
//# sourceMappingURL=44.5799898fe85933dc09b2.js.map