pages-order-choisestore.e644f17e.js 7.2 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-order-choisestore"],{"0c4c":function(t,e,o){"use strict";o.r(e);var a=o("c37f"),i=o.n(a);for(var n in a)"default"!==n&&function(t){o.d(e,t,(function(){return a[t]}))}(n);e["default"]=i.a},2731:function(t,e,o){"use strict";var a=o("84ea"),i=o.n(a);i.a},"2bfa":function(t,e,o){"use strict";o.r(e);var a=o("8305"),i=o("0c4c");for(var n in i)"default"!==n&&function(t){o.d(e,t,(function(){return i[t]}))}(n);o("2731");var r,s=o("f0c5"),l=Object(s["a"])(i["default"],a["b"],a["c"],!1,null,"40226178",null,!1,a["a"],r);e["default"]=l.exports},"46ab":function(t,e,o){"use strict";var a=o("4ea4");Object.defineProperty(e,"__esModule",{value:!0}),e.groom4=n,e.groom1=r,e.groom3=s,e.loadIndexs=l,e.getIndexData=d,e.getStoreList=u,e.getPointList=c;var i=a(o("bc58"));function n(t){return(0,i.default)({url:"/api/groom/list/4",method:"get",data:t})}function r(t){return(0,i.default)({url:"/api/groom/list/1",method:"get",data:t})}function s(t){return(0,i.default)({url:"/api/groom/list/3",method:"get",data:t})}function l(t){return(0,i.default)({url:"/api/index",method:"get",data:t})}function d(t){return(0,i.default)({url:"/api/common/home",method:"get",data:t})}function u(t){return(0,i.default)({url:"/api/store_list",method:"get",data:t})}function c(t,e){return(0,i.default)({url:"/api/point_list/"+e,method:"get",data:t})}},8305:function(t,e,o){"use strict";o.d(e,"b",(function(){return i})),o.d(e,"c",(function(){return n})),o.d(e,"a",(function(){return a}));var a={uniLoadMore:o("488d").default},i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("v-uni-view",{staticClass:"stores-wrapper"},[o("v-uni-scroll-view",{style:{height:t.maxheight+"px"},attrs:{"scroll-y":"true"},on:{scrolltolower:function(e){arguments[0]=e=t.$handleEvent(e),t.loadDate.apply(void 0,arguments)}}},[!0===t.loaded&&0===t.list.length?o("empty"):t._e(),t._l(t.list,(function(e){return o("v-uni-view",{staticClass:"store",on:{click:function(o){arguments[0]=o=t.$handleEvent(o),t.sele(e)}}},[o("v-uni-view",{staticClass:"store-logo"},[1==t.type?o("v-uni-image",{attrs:{src:e.image,mode:""}}):t._e(),o("v-uni-text",{staticClass:"store-name clamp"},[t._v(t._s(e.name))])],1),o("v-uni-view",{staticClass:"store-addr store-base"},[t._v("地区:"),o("v-uni-text",[t._v(t._s(e.detailed_address))])],1),o("v-uni-view",{staticClass:"store-addr store-base"},[t._v("电话:"),o("v-uni-text",[t._v(t._s(e.phone))])],1),o("v-uni-view",{staticClass:"store-addr store-base"},[t._v("距离:"),o("v-uni-text",[t._v(t._s(t.space(e.latitude,e.longitude)))])],1),o("v-uni-view",{staticClass:"store-lv "},[t._v(t._s(1==t.type?"门店":"自提点"))])],1)})),o("uni-load-more",{attrs:{status:t.loadingType}})],2)],1)},n=[]},"84ea":function(t,e,o){var a=o("d695");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var i=o("4f06").default;i("445ac302",a,!0,{sourceMap:!1,shadowMode:!1})},c37f:function(t,e,o){"use strict";var a=o("4ea4");o("99af"),o("d81d"),o("b680"),o("ac1f"),o("1276"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=a(o("5530")),n=o("46ab"),r=o("2f62"),s=a(o("2cfa")),l=a(o("488d")),d={components:{empty:s.default,uniLoadMore:l.default},data:function(){return{list:[],page:1,limit:10,loadingType:"more",loaded:!1,maxheight:0,type:0,store_id:0}},onLoad:function(t){this.type=t.type,2==this.type&&(this.store_id=t.id,uni.setNavigationBarTitle({title:"选择自提点"})),this.loadDate()},onReady:function(){var t=this;uni.createSelectorQuery().select(".stores-wrapper").fields({size:!0},(function(e){console.log(e),console.log(Math.floor(e.width/750*300)),t.maxheight=e.height-Math.floor(e.width/750*570),console.log(t.maxheight)})).exec()},methods:(0,i.default)((0,i.default)({},(0,r.mapMutations)("user",["setUserInfo","setOrderInfo","setStoreInfo"])),{},{space:function(t,e){var o=uni.getStorageSync("latlon");console.log(o);var a=o.split(","),i=a[0],n=a[1];console.log(t,e,i,n,"位置信息");var r=t*Math.PI/180,s=i*Math.PI/180,l=r-s,d=e*Math.PI/180-n*Math.PI/180,u=2*Math.asin(Math.sqrt(Math.pow(Math.sin(l/2),2)+Math.cos(r)*Math.cos(s)*Math.pow(Math.sin(d/2),2)));return u*=6378.137,u=Math.round(1e4*u)/1e4,u>1?u.toFixed(2)+"km":1e3*u+"m"},loadDate:function(){var t=this;"loading"!==this.loadingType&&(this.loadingType="loading",1==this.type?(uni.showLoading({title:"加载中..."}),(0,n.getStoreList)({page:this.page,limit:this.limit}).then((function(e){var o=e.data;console.log(o.list,"店面列表");var a=o.list.map((function(t){return t}));t.list=t.list.concat(a),t.page++,t.limit!=o.list.length?(t.loadingType="noMore",uni.hideLoading(),t.$set(t,"loaded",!0)):t.loadingType="more"})).catch((function(t){console.log(t)}))):(0,n.getPointList)({page:this.page,limit:this.limit},this.store_id).then((function(e){var o=e.data;console.log(o.list,"自提点列表");var a=o.list.map((function(t){return t}));t.list=t.list.concat(a),t.page++,t.limit!=o.list.length?(t.loadingType="noMore",uni.hideLoading(),t.$set(t,"loaded",!0)):t.loadingType="more"})).catch((function(t){console.log(t)})))},sele:function(t){this.getCurrentPages;var e=getCurrentPages(),o=e[e.length-2];1==this.type?this.setStoreInfo(t):2==this.type&&(o.$vm.checkedPoint=t),uni.navigateBack({})}})};e.default=d},d695:function(t,e,o){var a=o("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\n/* 页面左右间距 */\n/* 文字尺寸 */\n/*文字颜色*/\n/* 边框颜色 */\n/*颜色*/\n/* 图片加载中颜色 */\n/* 行为相关颜色 */\n/* 功能栏字体大小 */\n/*功能栏左侧小图标*/uni-page-body[data-v-40226178]{background-color:#f8f6f6;height:100%}.stores-wrapper[data-v-40226178]{padding-top:%?20?%;height:100%}.stores-wrapper .store[data-v-40226178]{width:%?710?%;height:%?231?%;background:#fff;-webkit-box-shadow:0 0 %?20?% %?0?% rgba(50,50,52,.06);box-shadow:0 0 %?20?% %?0?% rgba(50,50,52,.06);border-radius:%?10?%;margin:0 auto %?15?%;position:relative;padding:%?25?% 0 0 %?20?%}.stores-wrapper .store .store-logo[data-v-40226178]{height:%?65?%;font-size:%?32?%;font-weight:700;color:#333;line-height:%?65?%;margin-bottom:%?20?%;position:relative}.stores-wrapper .store .store-logo uni-image[data-v-40226178]{width:%?65?%;height:%?65?%;border-radius:50%}.stores-wrapper .store .store-logo .store-name[data-v-40226178]{max-width:%?500?%;display:inline-block;padding-left:%?12?%;position:absolute;top:0}.stores-wrapper .store .store-base[data-v-40226178]{height:%?37?%;line-height:%?37?%;font-size:%?24?%;font-weight:700;color:#333}.stores-wrapper .store .store-base uni-text[data-v-40226178]{font-weight:400}.stores-wrapper .store .store-lv[data-v-40226178]{display:inline-block;padding:0 %?10?%;height:%?40?%;background:-webkit-gradient(linear,right top,left top,from(#dcb876),to(#eecd92));background:-webkit-linear-gradient(right,#dcb876,#eecd92);background:linear-gradient(-90deg,#dcb876,#eecd92);border-radius:%?5?%;text-align:center;line-height:%?40?%;color:#fff;font-size:%?23?%;position:absolute;right:%?20?%;top:%?38?%}.stores-wrapper .store .store-can[data-v-40226178]{width:%?113?%;height:%?44?%;border:2px solid #901b21;border-radius:%?5?%;font-size:%?23?%;text-align:center;line-height:%?44?%;font-weight:500;color:#901b21;position:absolute;right:%?20?%;bottom:%?25?%}body.?%PAGE?%[data-v-40226178]{background-color:#f8f6f6}',""]),t.exports=e}}]);