1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-member-pointscart-Cart"],{"06ae":function(t,e,i){"use strict";i("7a82"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,i("a9e3");var a=i("0b9f"),r=i("26cb"),n={data:function(){return{isSelected:!0,deleteGoods:[]}},computed:(0,r.mapState)({}),props:{totalPrice:{},totalAmount:{},cartId:{},isCheckedAll:{type:Boolean,default:!1},issShowTabbar:{type:Number,default:0},isStatus:{type:Boolean,default:!0}},watch:{isCheckedAll:function(t){this.isSelected=!t},isStatus:function(t){this.isSelected=t}},methods:{selectedAll:function(t){var e=t.detail.value;this.isSelected=e.length>0,uni.$emit("cart-bottom-status",{isCheckAll:this.isSelected})},deleteSelected:function(){uni.$emit("update-cart-list",{isdelete:!0})},checkout:function(){this.isCheckedAll||0==this.totalAmount||uni.navigateTo({url:"/pages/member/pointsbuy/step1?"+(0,a.urlencode)({cart_id:this.cartId})})}}};e.default=n},"0728":function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是uni-app内置的常用样式变量\r\n *\r\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.ui-cart-footer[data-v-4a55f352]{position:relative;display:flex;justify-content:space-between;align-content:center;align-items:center;height:2.8rem;padding-bottom:constant(safe-area-inset-bottom);\r\n /*兼容 IOS<11.2*/padding-bottom:env(safe-area-inset-bottom);\r\n /*兼容 IOS>11.2*/box-sizing:initial;background:#fff;padding-left:.6rem;bottom:0;position:fixed;width:-webkit-fill-available;box-shadow:0 4px 4px #f7f7f7;margin-bottom:1px}.ui-cart-footer .list-checkbox[data-v-4a55f352]{display:flex;align-items:center;flex-shrink:0;position:relative;margin-right:.25rem;height:2.8rem;line-height:2.8rem}.ui-cart-footer .list-checkbox .label[data-v-4a55f352]{padding:0;position:absolute;top:50%;margin-top:-.5rem;left:0;width:1rem;height:1rem;display:inline-block;border-radius:50%;border:1px solid #333;box-sizing:border-box}.ui-cart-footer .list-checkbox .label .iconfont[data-v-4a55f352]{display:none;line-height:1rem;text-align:center}.ui-cart-footer .list-checkbox .label.checked[data-v-4a55f352]{border-color:#fb2630;background-color:#fb2630}.ui-cart-footer .list-checkbox .label.checked .iconfont[data-v-4a55f352]{display:block;color:#fff}.ui-cart-footer .list-checkbox .checkbox[data-v-4a55f352]{position:relative;width:1rem;height:1rem;margin:0;z-index:-999;background-color:#fff;opacity:0}.ui-cart-footer .list-checkbox .i[data-v-4a55f352]{padding-left:.6rem;font-style:normal;font-size:.7rem}.ui-cart-footer .list-checkbox .i.total-price .span[data-v-4a55f352]{color:#fb2630}.ui-cart-footer .span.cart-footer-btn[data-v-4a55f352]{width:7.5rem;height:2.8rem;display:inline-block;font-size:.7rem;color:#fff;line-height:2.8rem;text-align:center;cursor:pointer;font-weight:400}.ui-cart-footer .checkout[data-v-4a55f352]{background:#fb2630}.ui-cart-footer .disable[data-v-4a55f352]{background:#c3c3c3}.ui-cart-footer .remove[data-v-4a55f352]{background:#f23030}.has-bottom[data-v-4a55f352]{bottom:2.5rem}',""]),t.exports=e},"0784":function(t,e,i){"use strict";i.r(e);var a=i("b74b"),r=i.n(a);for(var n in a)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return a[t]}))}(n);e["default"]=r.a},"0868":function(t,e,i){"use strict";i("7a82");var a=i("4ea4").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=a(i("5530")),n=i("26cb"),s=i("de79"),o={name:"MemberBase",data:function(){return{page:"",cartNumber:0}},props:{show:{type:Boolean,default:!0}},computed:(0,r.default)((0,r.default)({},(0,n.mapState)({user:function(t){return t.member.info},isOnline:function(t){return t.member.isOnline}})),{},{getCarCount:function(){return this.cartNumber>0&&this.cartNumber<100?this.cartNumber:this.cartNumber>=100?"99+":void 0}}),mounted:function(){var t=getCurrentPages(),e=t[t.length-1];this.page={route:e.route,options:e.options},this.user||uni.navigateTo({url:"/pages/home/memberlogin/Login?clear=1"}),this.getCartCount()},methods:{getCartCount:function(){var t=this;this.isOnline&&(0,s.cartQuantity)().then((function(e){e&&(t.cartNumber=e.result.cart_count)}))}}};e.default=o},"1adb":function(t,e,i){"use strict";i.r(e);var a=i("06ae"),r=i.n(a);for(var n in a)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return a[t]}))}(n);e["default"]=r.a},2440:function(t,e,i){"use strict";i.r(e);var a=i("39d6"),r=i("1adb");for(var n in r)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return r[t]}))}(n);i("4fa3");var s=i("f0c5"),o=Object(s["a"])(r["default"],a["b"],a["c"],!1,null,"4a55f352",null,!1,a["a"],void 0);e["default"]=o.exports},"265e":function(t,e,i){"use strict";i("7a82"),Object.defineProperty(e,"__esModule",{value:!0}),e.cartUpdate=e.cartQuantity=e.cartGet=e.cartDelete=e.cartAdd=e.buyStep2=e.buyStep1=void 0;var a=i("887c");e.cartGet=function(){return(0,a.requestApi)("/Pointcart/cart_list","POST",{},"member")};e.cartDelete=function(t){return(0,a.requestApi)("/Pointcart/cart_del","POST",{pcart_id:t},"member")};e.cartUpdate=function(t,e){return(0,a.requestApi)("/Pointcart/cart_edit_quantity","POST",{pcart_id:t,quantity:e},"member")};e.cartAdd=function(t,e){return(0,a.requestApi)("/Pointcart/add","POST",{pgid:t,quantity:e},"member")};e.cartQuantity=function(){return(0,a.requestApi)("/Pointcart/cart_count","POST",{},"member")};e.buyStep1=function(t,e){return(0,a.requestApi)("/Pointcart/step1","POST",{cart_id:t,ifcart:e},"member")};e.buyStep2=function(t,e,i,r){return(0,a.requestApi)("/Pointcart/step2","POST",{cart_id:t,ifcart:e,address_options:i,pcart_message:r},"member")}},"2e13":function(t,e,i){var a=i("0728");a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var r=i("4f06").default;r("53d006b5",a,!0,{sourceMap:!1,shadowMode:!1})},"2e91":function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是uni-app内置的常用样式变量\r\n *\r\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.empty-cart[data-v-7a6fa926]{padding-top:6.2rem;text-align:center}.empty-cart .img[data-v-7a6fa926]{width:3.7rem;height:3.7rem}.empty-cart .p[data-v-7a6fa926]{font-size:.8rem;color:#333;line-height:1.1rem;padding:1.3rem 0 2rem 0}.empty-cart .span[data-v-7a6fa926]{font-size:.8rem;color:#fff;height:2.2rem;background:#fb2630;border-radius:.15rem;line-height:2.2rem;display:inline-block;width:10rem}',""]),t.exports=e},"39d6":function(t,e,i){"use strict";i.d(e,"b",(function(){return a})),i.d(e,"c",(function(){return r})),i.d(e,"a",(function(){}));var a=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-view",{staticClass:"div ui-cart-footer",class:{"has-bottom":t.issShowTabbar}},[i("v-uni-checkbox-group",{staticClass:"div list-checkbox",on:{change:function(e){arguments[0]=e=t.$handleEvent(e),t.selectedAll.apply(void 0,arguments)}}},[i("v-uni-checkbox",{staticClass:"checkbox",attrs:{id:"checkbox-all",value:"1",checked:t.isSelected}}),i("v-uni-label",{staticClass:"label",class:{checked:t.isSelected},attrs:{for:"checkbox-all"}},[i("v-uni-text",{staticClass:"span iconfont"},[t._v("")])],1),t.isCheckedAll?i("v-uni-text",{staticClass:"i"},[t._v("全选")]):t._e(),t.isCheckedAll?t._e():i("v-uni-text",{staticClass:"i total-price"},[t._v("合计"),i("v-uni-text",{staticClass:"span"},[t._v(t._s(t.totalPrice))])],1)],1),t.isCheckedAll?i("v-uni-text",{staticClass:"span cart-footer-btn remove",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.deleteSelected()}}},[t._v("删除")]):t._e(),t.isCheckedAll?t._e():i("v-uni-text",{staticClass:"span cart-footer-btn checkout",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.checkout.apply(void 0,arguments)}}},[t._v("结算("+t._s(t.totalAmount)+")")])],1)},r=[]},"40dd":function(t,e,i){"use strict";i.r(e);var a=i("9bca"),r=i("0784");for(var n in r)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return r[t]}))}(n);i("5d6f");var s=i("f0c5"),o=Object(s["a"])(r["default"],a["b"],a["c"],!1,null,"2639d324",null,!1,a["a"],void 0);e["default"]=o.exports},"4f4c":function(t,e,i){var a=i("2e91");a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var r=i("4f06").default;r("01edeb7a",a,!0,{sourceMap:!1,shadowMode:!1})},"4fa3":function(t,e,i){"use strict";var a=i("2e13"),r=i.n(a);r.a},"5d6f":function(t,e,i){"use strict";var a=i("9528"),r=i.n(a);r.a},6445:function(t,e,i){"use strict";i.r(e);var a=i("9df1"),r=i("766d");for(var n in r)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return r[t]}))}(n);i("90e0");var s=i("f0c5"),o=Object(s["a"])(r["default"],a["b"],a["c"],!1,null,"7a6fa926",null,!1,a["a"],void 0);e["default"]=o.exports},6533:function(t,e,i){"use strict";i.d(e,"b",(function(){return r})),i.d(e,"c",(function(){return n})),i.d(e,"a",(function(){return a}));var a={uniNavBar:i("7bfb").default},r=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-view",{staticClass:"div common-header-wrap"},[i("v-uni-view",{style:"height:"+t.navHeight+"px"}),i("v-uni-view",{staticClass:"common-header-holder"}),i("v-uni-view",{staticClass:"common-header-fixed"},[i("title-header"),i("uni-nav-bar",{staticClass:"common-header",attrs:{title:"购物车","left-icon":"back"},on:{clickLeft:function(e){arguments[0]=e=t.$handleEvent(e),t.goBack()}}},[t.isFinish||t.isEmpty?t._e():i("v-uni-view",{staticClass:"div common-btn btn",attrs:{slot:"right"},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.changeFinishStatus()}},slot:"right"},[t._v("编辑")]),t.isFinish?i("v-uni-view",{staticClass:"div common-btn btn",attrs:{slot:"right"},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.changeFinishStatus()}},slot:"right"},[t._v("完成")]):t._e()],1)],1)],1)},n=[]},"69f5":function(t,e,i){"use strict";i.r(e);var a=i("0868"),r=i.n(a);for(var n in a)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return a[t]}))}(n);e["default"]=r.a},"766d":function(t,e,i){"use strict";i.r(e);var a=i("7d94"),r=i.n(a);for(var n in a)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return a[t]}))}(n);e["default"]=r.a},"7b4a":function(t,e,i){"use strict";i.r(e);var a=i("8034"),r=i("69f5");for(var n in r)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return r[t]}))}(n);i("dacb");var s=i("f0c5"),o=Object(s["a"])(r["default"],a["b"],a["c"],!1,null,"3e6c03f6",null,!1,a["a"],void 0);e["default"]=o.exports},"7d94":function(t,e,i){"use strict";i("7a82");var a=i("4ea4").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=a(i("5530")),n=i("0b9f"),s=a(i("7b4a")),o=a(i("e438")),c=a(i("40dd")),d=a(i("2440")),l=i("26cb"),u={data:function(){return{totalPrice:0,totalAmount:0,cartId:"",type:0,isFinish:!1,isStatus:!0,isshowpromos:!0,target:"",isEmpty:!1}},computed:(0,r.default)({fontSize:function(){return(0,n.getFontSize)()}},(0,l.mapState)({isOnline:function(t){return t.member.isOnline}})),created:function(){var t=this;this.isSignin(),uni.$on("change-list-selected",(function(e){t.isEmpty||(t.isFinish=e.isFinish,e.isFinish?(t.isshowpromos=!1,t.$refs.list.addChecked(!1)):(t.isshowpromos=!0,t.$refs.list.addChecked(!0)),t.$refs.list.renderCart())})),uni.$on("update-cart-list",(function(e){e.isdelete&&t.$refs.list.deleteSelected()})),uni.$on("get-promos-data",(function(t){})),uni.$on("calcu-cart-data",(function(e){t.totalPrice=e.totalPrice,t.totalAmount=e.totalAmount,t.cartId=e.cartId})),uni.$on("cart-bottom-status",(function(e){e.isCheckAll&&!t.isFinish?t.isshowpromos=!0:t.isshowpromos=!1,t.$refs.list.addChecked(e.isCheckAll),t.$refs.list.renderCart()})),uni.$on("change-footer-status",(function(e){t.isStatus=e})),uni.$on("list-is-empty",(function(e){e.length>0?t.isEmpty=!1:t.isEmpty=!0}))},mounted:function(){},beforeDestroy:function(){uni.$off("change-list-selected"),uni.$off("update-cart-list"),uni.$off("get-promos-data"),uni.$off("calcu-cart-data"),uni.$off("cart-bottom-status"),uni.$off("change-footer-status"),uni.$off("list-is-empty")},components:{MemberBase:s.default,"v-cart-header":o.default,"v-cart-list":c.default,"v-cart-footer":d.default},methods:{isSignin:function(){this.isOnline?this.isEmpty=!1:this.isEmpty=!0},goHome:function(){uni.navigateTo({url:"/pages/home/pointsgoods/Index"})},goSingin:function(){uni.navigateTo({url:"/pages/home/memberlogin/Login"})}}};e.default=u},8034:function(t,e,i){"use strict";i.d(e,"b",(function(){return a})),i.d(e,"c",(function(){return r})),i.d(e,"a",(function(){}));var a=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("v-uni-view",{staticClass:"div member-base"},[a("v-uni-view",{staticClass:"status-holder"}),a("v-uni-view",{staticClass:"content"},[t._t("default")],2),t.show?a("v-uni-view",{staticClass:"div common-footer-wrap"},[a("v-uni-view",{staticClass:"common-footer"},[a("v-uni-view",{staticClass:"item-wrap",class:{active:"pages/home/index/Index"==t.page.route}},[a("v-uni-navigator",{staticClass:"item",attrs:{url:"/pages/home/index/Index","open-type":"reLaunch"}},["pages/home/index/Index"==t.page.route?a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("0207")}}):a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("241a")}}),a("v-uni-text",{staticClass:"span text"},[t._v("首页")])],1)],1),a("v-uni-view",{staticClass:"item-wrap",class:{active:"pages/home/goodsclass/Goodsclass"==t.page.route}},[a("v-uni-navigator",{staticClass:"item",attrs:{url:"/pages/home/goodsclass/Goodsclass"}},["pages/home/goodsclass/Goodsclass"==t.page.route?a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("79bf")}}):a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("d86e")}}),a("v-uni-text",{staticClass:"span text"},[t._v("分类")])],1)],1),a("v-uni-view",{staticClass:"item-wrap",class:{active:"pages/home/search/Search"==t.page.route}},[a("v-uni-navigator",{staticClass:"item",attrs:{url:"/pages/home/search/Search"}},["pages/home/search/Search"==t.page.route?a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("492b")}}):a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("1702")}}),a("v-uni-text",{staticClass:"span text"},[t._v("搜索")])],1)],1),a("v-uni-view",{staticClass:"item-wrap",class:{active:"pages/member/cart/Cart"==t.page.route}},[a("v-uni-navigator",{staticClass:"item",attrs:{url:"/pages/member/cart/Cart"}},["pages/member/cart/Cart"==t.page.route?a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("62a8")}}):a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("8559")}}),a("v-uni-text",{staticClass:"span text"},[t._v("购物车")]),t.cartNumber>0?a("v-uni-text",{staticClass:"span icon"},[t._v(t._s(t.getCarCount))]):t._e()],1)],1),a("v-uni-view",{staticClass:"item-wrap",class:{active:"pages/member/index/Index"==t.page.route}},[a("v-uni-navigator",{staticClass:"item",attrs:{url:"/pages/member/index/Index","open-type":"reLaunch"}},["pages/member/index/Index"==t.page.route?a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("857e")}}):a("v-uni-image",{staticClass:"img image",attrs:{mode:"aspectFit",src:i("e31d")}}),a("v-uni-text",{staticClass:"span text"},[t._v("我的")])],1)],1)],1)],1):t._e()],1)},r=[]},"8a0c":function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是uni-app内置的常用样式变量\r\n *\r\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.status-holder[data-v-3e6c03f6]{background-color:#fff}.member-base[data-v-3e6c03f6]{display:flex;flex-direction:column}.content[data-v-3e6c03f6]{flex:1}.item-wrap[data-v-3e6c03f6]{position:relative}.image[data-v-3e6c03f6]{width:1rem;height:1rem;display:block;margin-left:auto;margin-right:auto;margin-top:.2rem;margin-bottom:.2rem}.icon[data-v-3e6c03f6]{position:absolute;right:.8rem;top:.2rem;font-size:.5rem;line-height:.7rem;width:.9rem;height:.7rem;background:#ef3338;border-radius:1rem;text-align:center;color:#fff}',""]),t.exports=e},"90e0":function(t,e,i){"use strict";var a=i("4f4c"),r=i.n(a);r.a},9528:function(t,e,i){var a=i("a77c4");a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var r=i("4f06").default;r("1028d992",a,!0,{sourceMap:!1,shadowMode:!1})},"979e":function(t,e,i){var a=i("dece");a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var r=i("4f06").default;r("7b770100",a,!0,{sourceMap:!1,shadowMode:!1})},"9bca":function(t,e,i){"use strict";i.d(e,"b",(function(){return a})),i.d(e,"c",(function(){return r})),i.d(e,"a",(function(){}));var a=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-view",{staticClass:"div cart-list-wrapper",style:"padding-top:"+t.navHeight+"px"},[i("v-uni-view",{staticClass:"div cart-list"},t._l(t.cartList,(function(e,a){return i("v-uni-checkbox-group",{key:a,staticClass:"div list",on:{change:function(e){arguments[0]=e=t.$handleEvent(e),t.changeSingleStatu.apply(void 0,arguments)}}},[i("v-uni-view",{staticClass:"div list-checkbox"},[i("v-uni-checkbox",{staticClass:"checkbox",attrs:{id:"goods"+a,value:e.pgoods_id,checked:e.checked,disabled:!t.isCheckedAll&&0==e.pgoods_storage}}),i("v-uni-label",{staticClass:"label",class:{checked:e.checked},attrs:{for:"goods"+a}},[i("v-uni-text",{staticClass:"span iconfont"},[t._v("")])],1)],1),i("v-uni-view",{staticClass:"div list-item",on:{click:function(i){arguments[0]=i=t.$handleEvent(i),t.goDetail(e.pgoods_id)}}},[i("v-uni-view",{staticClass:"div item"},[i("v-uni-view",{staticClass:"div ui-image"},[i("v-uni-image",{staticClass:"img",attrs:{mode:"aspectFit",src:e.pgoods_image}}),0==e.pgoods_storage?i("v-uni-text",{staticClass:"span stock-info"},[t._v("已售罄")]):t._e(),e.pgoods_storage>0&&e.pgoods_storage<=10?i("v-uni-text",{staticClass:"span stock-info"},[t._v("仅剩"+t._s(e.pgoods_storage)+"件")]):t._e()],1),i("v-uni-view",{staticClass:"div list-info"},[i("v-uni-view",{staticClass:"div product-header"},[i("v-uni-text",{staticClass:"h3 product-title",class:{"disabled-list":0==e.pgoods_storage}},[t._v(t._s(e.pgoods_name))])],1),i("v-uni-text",{staticClass:"h3 property-info"}),i("v-uni-view",{staticClass:"div info-price"},[i("v-uni-view",{staticClass:"p",class:{"disabled-list":0==e.pgoods_storage}},[t._v(t._s(e.pgoods_points)+"积分")]),i("v-uni-view",{staticClass:"div ui-number"},[i("v-uni-view",{staticClass:"div reduce ui-common",class:{"reduce-opacity":e.pgoods_choosenum<=1},on:{click:function(i){i.stopPropagation(),arguments[0]=i=t.$handleEvent(i),t.reduceNumber(e.pcart_id,e.pgoods_choosenum,a)}}},[t._v("-")]),i("v-uni-input",{staticClass:"number",attrs:{type:"number",min:"1",value:"1",readonly:"true"},model:{value:e.pgoods_choosenum,callback:function(i){t.$set(e,"pgoods_choosenum",i)},expression:"item.pgoods_choosenum"}}),i("v-uni-view",{staticClass:"div add ui-common",on:{click:function(i){i.stopPropagation(),arguments[0]=i=t.$handleEvent(i),t.addNumber(e.pcart_id,e.pgoods_choosenum,a)}}},[t._v("+")])],1)],1)],1)],1)],1)],1)})),1)],1)},r=[]},"9df1":function(t,e,i){"use strict";i.d(e,"b",(function(){return r})),i.d(e,"c",(function(){return n})),i.d(e,"a",(function(){return a}));var a={pageMeta:i("6d42").default},r=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-view",[i("page-meta",{attrs:{"root-font-size":t.fontSize+"px"}}),i("member-base",{attrs:{show:!1}},[i("v-uni-view",{staticClass:"div ui-cart-wrapper"},[i("v-cart-header",{ref:"header",attrs:{issShowTabbar:t.type,isEmpty:t.isEmpty}}),t.isEmpty?t._e():i("v-uni-view",{staticClass:"div"},[i("v-cart-list",{ref:"list",attrs:{issShowTabbar:t.type,isCheckedAll:t.isFinish}}),i("v-cart-footer",{attrs:{issShowTabbar:t.type,isCheckedAll:t.isFinish,isStatus:t.isStatus,totalPrice:t.totalPrice,totalAmount:t.totalAmount,cartId:t.cartId}})],1),t.isEmpty?i("v-uni-view",{staticClass:"div empty-cart"},[t.isOnline?i("v-uni-view",{staticClass:"p"},[t._v("您的购物车还是空的")]):t._e(),t.isOnline?t._e():i("v-uni-view",{staticClass:"p"},[t._v("登录后即可查看购物车中的商品")]),t.isOnline?i("v-uni-text",{staticClass:"span",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.goHome()}}},[t._v("随便逛逛")]):t._e(),t.isOnline?t._e():i("v-uni-text",{staticClass:"span",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.goSingin()}}},[t._v("去登录")])],1):t._e()],1)],1)],1)},n=[]},a77c4:function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是uni-app内置的常用样式变量\r\n *\r\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.cart-list-wrapper[data-v-2639d324]{overflow-y:auto;position:fixed;width:100%;bottom:2.8rem;padding-bottom:constant(safe-area-inset-bottom);\r\n /*兼容 IOS<11.2*/padding-bottom:env(safe-area-inset-bottom);\r\n /*兼容 IOS>11.2*/top:2rem;margin-bottom:.5rem}.cart-list-wrapper .cart-list[data-v-2639d324]{margin-bottom:.5rem;background:#fff}.cart-list-wrapper .store-info[data-v-2639d324]{background:#fff;border-bottom:1px solid #e8eaed;display:flex;padding-left:.6rem;align-content:center;align-items:center}.cart-list-wrapper .store-info .store-name[data-v-2639d324]{font-size:.8rem;line-height:2rem;flex:1}.cart-list-wrapper .list-checkbox[data-v-2639d324]{width:1rem;height:1rem;flex-basis:1rem;flex-shrink:0;position:relative;margin-right:.25rem}.cart-list-wrapper .list-checkbox .label[data-v-2639d324]{padding:0;position:absolute;left:0;top:0;width:1rem;height:1rem;display:inline-block;border-radius:50%;border:1px solid #333;box-sizing:border-box}.cart-list-wrapper .list-checkbox .label .iconfont[data-v-2639d324]{display:none;line-height:1rem;text-align:center}.cart-list-wrapper .list-checkbox .label.checked[data-v-2639d324]{border-color:#fb2630;background-color:#fb2630}.cart-list-wrapper .list-checkbox .label.checked .iconfont[data-v-2639d324]{display:block;color:#fff}.cart-list-wrapper .list-checkbox .checkbox[data-v-2639d324]{position:relative;width:1rem;margin:0;opacity:0;background-color:#fff}.cart-list-wrapper .list[data-v-2639d324]{background-color:#fff;padding:.6rem;display:flex;align-content:center;align-items:center}.cart-list-wrapper .list .list-item[data-v-2639d324]{display:flex;width:100%;flex-direction:column}.cart-list-wrapper .list .list-item .div.item[data-v-2639d324]{display:flex;width:100%}.cart-list-wrapper .list .list-item .div.item .div.ui-image[data-v-2639d324]{flex-shrink:0;width:4.5rem;height:4.5rem;flex-basis:4.5rem;position:relative}.cart-list-wrapper .list .list-item .div.item .div.ui-image .img[data-v-2639d324]{width:100%;height:100%;border-radius:.4rem}.cart-list-wrapper .list .list-item .div.item .div.ui-image .span.promos[data-v-2639d324]{position:absolute;width:1.8rem;height:1rem;color:#fff;font-size:.5rem;top:0;background-size:cover;font-weight:100;line-height:1rem;text-align:left;padding-left:.25rem}.cart-list-wrapper .list .list-item .div.item .div.ui-image .span.stock-info[data-v-2639d324]{position:absolute;height:1rem;background:#f3f4f5;line-height:1rem;text-align:center;font-size:.7rem;color:#fb2630;width:100%;bottom:0;left:0}.cart-list-wrapper .list .list-item .div.item .div.list-info[data-v-2639d324]{margin-left:.5rem;width:100%;display:flex;flex-direction:column;align-content:center;justify-content:space-between}.cart-list-wrapper .list .list-item .div.item .div.list-info .product-header[data-v-2639d324]{display:flex;align-items:center}.cart-list-wrapper .list .list-item .div.item .div.list-info .product-header .promos-icon[data-v-2639d324]{width:.8rem;height:.8rem;margin-right:.2rem}.cart-list-wrapper .list .list-item .div.item .div.list-info .product-header .product-title[data-v-2639d324]{font-size:.7rem;line-height:1rem;height:2rem;padding:0;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}.cart-list-wrapper .list .list-item .div.item .div.list-info .product-header .product-title.disabled-list[data-v-2639d324]{color:#a4aab3}.cart-list-wrapper .list .list-item .div.item .div.list-info .h3[data-v-2639d324]{font-size:.7rem;color:#4e545d;padding:0;margin:0;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}.cart-list-wrapper .list .list-item .div.item .div.list-info .h3.disabled-list[data-v-2639d324]{color:#a4aab3}.cart-list-wrapper .list .list-item .div.item .div.list-info .h3.property-info[data-v-2639d324]{font-size:.6rem;color:#7c7f88}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.info-price[data-v-2639d324]{width:100%;display:flex;justify-content:space-between;align-content:flex-end;align-items:flex-end}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.info-price .p[data-v-2639d324]{font-size:.85rem;color:#fb2630;padding:0;margin:0;display:inline-block}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.info-price .p.disabled-list[data-v-2639d324]{color:#a4aab3}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.ui-number[data-v-2639d324]{height:1.2rem;display:flex;border-radius:.15rem 0 0 .15rem}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.ui-number uni-input[data-v-2639d324],\r\n.cart-list-wrapper .list .list-item .div.item .div.list-info .div.ui-number .div[data-v-2639d324]{height:1.2rem;text-align:center;color:#404245;display:inline-block;padding:0;margin:0;border:0;outline-offset:0}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.ui-number .ui-common[data-v-2639d324]{line-height:1.2rem;width:1.3rem;height:1.2rem;border:1px solid #c7c7cd;cursor:pointer}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.ui-number .reduce[data-v-2639d324]{border-right:0}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.ui-number .reduce-opacity[data-v-2639d324]{opacity:.4}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.ui-number .add[data-v-2639d324]{border-left:0}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.ui-number .number[data-v-2639d324]{width:1.3rem;border:1px solid #c7c7cd;border-radius:0;border-image-width:0;box-shadow:0;vertical-align:bottom}.cart-list-wrapper .list .list-item .div.item .div.list-info .div.ui-number .number[data-v-2639d324]:focus{outline:none}.cart-list-wrapper .list .list-item .p.list-promotion-info[data-v-2639d324]{margin-top:.6rem;padding:.4rem 0;line-height:auto;font-size:.5rem;color:#000;background:#f8f8f8;width:100%}.cart-list-wrapper .list .list-item .p.list-promotion-info .span[data-v-2639d324]{border:1px solid #fb2630;padding:1px .2rem;border-radius:.1rem;font-size:.5rem;color:#fb2630;margin:0 .5rem;text-align:center}.has-bottom[data-v-2639d324]{bottom:4.7rem}',""]),t.exports=e},a9d0:function(t,e,i){"use strict";i.r(e);var a=i("ae07"),r=i.n(a);for(var n in a)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return a[t]}))}(n);e["default"]=r.a},ae07:function(t,e,i){"use strict";i("7a82");var a=i("4ea4").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,i("a9e3");a(i("cce0")),i("26cb");var r={mounted:function(){},data:function(){return{navHeight:0,isFinish:!1}},props:{issShowTabbar:{type:Number,default:0},isEmpty:{type:Boolean,default:!1}},computed:{},methods:{goBack:function(){uni.navigateBack({delta:1})},changeFinishStatus:function(){this.isFinish=!this.isFinish;var t={isFinish:this.isFinish};uni.$emit("change-list-selected",t)}}};e.default=r},b74b:function(t,e,i){"use strict";i("7a82");var a=i("4ea4").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,i("e25e"),i("14d9"),i("d3b7"),i("d401"),i("25f0"),i("c975");var r=a(i("5530")),n=i("0b9f"),s=i("26cb"),o=i("265e"),c={props:{isCheckedAll:{type:Boolean,default:!1}},data:function(){return{navHeight:0,cartList:[],indicator:{spinnerType:"fading-circle"},totalPrice:0,cartId:"",totalAmount:0,promosIds:[]}},created:function(){this.getCartList(!0)},mounted:function(){},methods:(0,r.default)((0,r.default)({},(0,s.mapMutations)({getAmount:"calculationAmount",getPrice:"calculationPrice",setCartNumber:"setCartNumber",saveSelectedCartGoods:"saveSelectedCartGoods"})),{},{getCartList:function(t){var e=this;(0,o.cartGet)().then((function(i){i&&i.result.cart_array.length>0?(e.cartList=Object.assign([],i.result.cart_array),e.addChecked(t),e.renderCart()):(e.cartList=[],e.getAmount(0),e.getPrice(0)),uni.$emit("list-is-empty",e.cartList)}))},addChecked:function(t){var e=this.cartList;for(var i in e)0!=e[i].pgoods_storage||this.isCheckedAll?e[i].checked=t:e[i].checked=!1;this.cartList=Object.assign([],e)},renderCart:function(){var t=this.cartList;this.promosIds=[];var e=[],i=0,a=0;for(var r in t)t[r].checked&&(i+=parseInt(t[r].pgoods_choosenum),a+=parseInt(t[r].pgoods_choosenum)*parseInt(t[r].pgoods_points),e.push(t[r].pcart_id+"|"+t[r].pgoods_choosenum));this.cartId=e.toString(),this.totalPrice=a,this.totalAmount=i,uni.$emit("calcu-cart-data",{totalPrice:this.totalPrice,totalAmount:this.totalAmount,cartId:this.cartId})},deleteSelected:function(){var t=this,e=this.cartList,i=[];for(var a in this.promosIds=[],e)e[a].checked&&i.push(e[a].pcart_id);i.length>0?(i=i.toString(),uni.showLoading({title:"加载中"}),(0,o.cartDelete)(i).then((function(e){e&&(t.getCartList(!1),uni.hideLoading())}))):uni.showToast({icon:"none",title:"当前没有可删除的商品"})},changeSingleStatu:function(t){var e=t.detail.value,i=this.cartList;for(var a in i)e.indexOf(i[a].pgoods_id)>-1?(i[a].checked=!0,1,k++):i[a].checked=!1;uni.$emit("change-footer-status",!1),this.isCheckedAll||this.renderCart(),this.cartList=Object.assign([],i)},reduceNumber:function(t,e,i){e>1?(e--,this.updateCartQuantity(t,e,i)):uni.showToast({icon:"none",title:{message:"受不了了, 宝贝不能再少了"}})},addNumber:function(t,e,i,a){e++,this.updateCartQuantity(t,e,i,a)},updateCartQuantity:function(t,e,i){var a=this;uni.showLoading({title:"加载中"}),(0,o.cartUpdate)(t,e).then((function(t){t&&(uni.hideLoading(),a.cartList[i].pgoods_choosenum=e,a.renderCart())}),(function(t){uni.showToast({icon:"none",title:t.message}),uni.hideLoading()}))},getCartNumber:function(){var t=this;(0,o.cartQuantity)().then((function(e){e&&t.setCartNumber(e.quantity)}))},goDetail:function(t){uni.navigateTo({url:"/pages/home/pointsgoods/Detail?"+(0,n.urlencode)({pgoods_id:t})})}})};e.default=c},bd94:function(t,e,i){"use strict";var a=i("979e"),r=i.n(a);r.a},dacb:function(t,e,i){"use strict";var a=i("f6c0"),r=i.n(a);r.a},dece:function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是uni-app内置的常用样式变量\r\n *\r\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.cart-header-wrapper[data-v-3ab577a0]{position:fixed;width:-webkit-fill-available}.cart-header-wrapper .span[data-v-3ab577a0]{position:absolute;font-size:.75rem;color:#4e545d;display:inline-block;height:2.2rem;line-height:2.2rem;top:0;right:.75rem}.btn[data-v-3ab577a0]{background:#000;color:#fff;box-shadow:0 2px 4px #d2d2d2}',""]),t.exports=e},e438:function(t,e,i){"use strict";i.r(e);var a=i("6533"),r=i("a9d0");for(var n in r)["default"].indexOf(n)<0&&function(t){i.d(e,t,(function(){return r[t]}))}(n);i("bd94");var s=i("f0c5"),o=Object(s["a"])(r["default"],a["b"],a["c"],!1,null,"3ab577a0",null,!1,a["a"],void 0);e["default"]=o.exports},f6c0:function(t,e,i){var a=i("8a0c");a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var r=i("4f06").default;r("11f8896b",a,!0,{sourceMap:!1,shadowMode:!1})}}]);
|