pages-donate-donate.cc6c41bf.js 9.3 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-donate-donate"],{"1c7d":function(t,e,a){var i=a("24fb");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/* 页面左右间距 */\n/* 文字尺寸 */\n/*文字颜色*/\n/* 边框颜色 */\n/*颜色*/\n/* 图片加载中颜色 */\n/* 行为相关颜色 */\n/* 功能栏字体大小 */\n/*功能栏左侧小图标*/.donate-wrapper[data-v-6e18a30f]{padding-top:%?25?%}.top-select[data-v-6e18a30f]{font-size:%?30?%;font-family:PingFang SC;font-weight:500;color:#333;height:%?63?%;line-height:%?63?%;padding:0 %?20?% 0 %?19?%;margin-bottom:%?20?%}.top-select .select[data-v-6e18a30f]{padding-left:%?40?%;background:#fff;border-radius:%?5?%;font-size:%?26?%;font-family:PingFang SC;font-weight:500;color:#999;line-height:%?63?%;position:relative}.top-select .select[data-v-6e18a30f]::after{content:"";width:0;height:0;border-left:%?10?% solid transparent;border-right:%?10?% solid transparent;border-top:%?10?% solid grey;position:absolute;right:%?30?%;bottom:%?26?%}.top-select .area[data-v-6e18a30f]{width:%?355?%;height:%?63?%;margin:0 %?10?% 0 %?24?%}.top-select .status[data-v-6e18a30f]{width:%?204?%;height:%?63?%}.top-select .action[data-v-6e18a30f]{color:#000}.item-wrapper[data-v-6e18a30f]{padding:0 %?20?%}.item-wrapper .item[data-v-6e18a30f]{width:%?710?%;height:%?280?%;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:%?8?%;padding:%?40?% %?20?%;margin-bottom:%?20?%}.item-wrapper .item .item-left[data-v-6e18a30f]{width:%?190?%;height:%?200?%;border-radius:%?10?%}.item-wrapper .item .item-left uni-image[data-v-6e18a30f]{width:%?190?%;height:%?200?%;border-radius:%?10?%}.item-wrapper .item .item-right[data-v-6e18a30f]{padding-left:%?22?%;position:relative}.item-wrapper .item .item-right .item-title[data-v-6e18a30f]{width:%?316?%;font-size:%?30?%;font-family:PingFang SC;font-weight:500;color:#333;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;line-height:1;padding-bottom:%?14?%}.item-wrapper .item .item-right .item-content[data-v-6e18a30f]{width:%?416?%;font-size:%?22?%;font-family:PingFang SC;font-weight:400;color:#999;line-height:1.5}.item-wrapper .item .item-right .item-status[data-v-6e18a30f]{font-size:%?24?%;font-family:PingFang SC;font-weight:500;color:#666;line-height:1.5;position:absolute;left:%?22?%;bottom:0}.item-wrapper .item .item-right .item-status uni-text[data-v-6e18a30f]{color:#e80000;font-weight:700}.item-wrapper .item .item-right .item-btn[data-v-6e18a30f]{width:%?160?%;height:%?60?%;background:#f2f2f2;border-radius:30px;font-size:%?28?%;font-family:PingFang SC;font-weight:500;color:#999;line-height:%?60?%;text-align:center;position:absolute;right:%?-42?%;bottom:%?-9?%}.item-wrapper .item .item-right .btn-active[data-v-6e18a30f]{background:#fa7e67;color:#fff;-webkit-box-shadow:0 2px 20px 0 rgba(250,126,103,.5);box-shadow:0 2px 20px 0 rgba(250,126,103,.5)}',""]),t.exports=e},"3cea":function(t,e,a){"use strict";var i=a("4ea4");Object.defineProperty(e,"__esModule",{value:!0}),e.computedOrderkey=r,e.createOrderkey=o,e.balance=s,e.orderPay=l,e.getProjectList=c,e.getProjectInfo=u,e.createProject=d,e.getLogistics=f,e.getAllArea=p,e.getDonationInfo=g,e.getMyorder=h,e.createUser=v,e.getAllOrder=m,e.getUserList=w;var n=i(a("db25"));function r(t){return(0,n.default)({url:"/api/order/computed/"+t.orderkey,method:"post",data:t})}function o(t,e){return(0,n.default)({url:"/api/donate/create",method:"post",data:t})}function s(t){return(0,n.default)({url:"/api/user/balance",method:"get",data:t})}function l(t){return(0,n.default)({url:"/api/order/pay",method:"post",data:t})}function c(t){return(0,n.default)({url:"/api/project/list",method:"get",data:t})}function u(t){return(0,n.default)({url:"/api/project/info",method:"get",data:t})}function d(t){return(0,n.default)({url:"/api/project/order_create",method:"post",data:t})}function f(t){return(0,n.default)({url:"/api/project/logistics",method:"get",data:t})}function p(t){return(0,n.default)({url:"/api/project/area",method:"get",data:t})}function g(t){return(0,n.default)({url:"/api/project/Donation_info",method:"get",data:t})}function h(t){return(0,n.default)({url:"/api/project/myorder",method:"post",data:t})}function v(t){return(0,n.default)({url:"/api/project/create_user",method:"post",data:t})}function m(t){return(0,n.default)({url:"/api/project/all_order",method:"post",data:t})}function w(t){return(0,n.default)({url:"/api/project/user_list",method:"get",data:t})}},5419:function(t,e,a){"use strict";a.r(e);var i=a("f9a3"),n=a.n(i);for(var r in i)"default"!==r&&function(t){a.d(e,t,(function(){return i[t]}))}(r);e["default"]=n.a},"57cd":function(t,e,a){var i=a("1c7d");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=a("4f06").default;n("74cb40ce",i,!0,{sourceMap:!1,shadowMode:!1})},"5be3":function(t,e,a){"use strict";var i=a("57cd"),n=a.n(i);n.a},"806d":function(t,e,a){"use strict";a.r(e);var i=a("a5db"),n=a("5419");for(var r in n)"default"!==r&&function(t){a.d(e,t,(function(){return n[t]}))}(r);a("5be3");var o,s=a("f0c5"),l=Object(s["a"])(n["default"],i["b"],i["c"],!1,null,"6e18a30f",null,!1,i["a"],o);e["default"]=l.exports},a5db:function(t,e,a){"use strict";var i;a.d(e,"b",(function(){return n})),a.d(e,"c",(function(){return r})),a.d(e,"a",(function(){return i}));var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("v-uni-view",{staticClass:"donate-wrapper"},[a("v-uni-view",{staticClass:"top-select flex",staticStyle:{position:"relative","z-index":"99"}},[a("v-uni-view",{},[t._v("选择地区")]),a("v-uni-picker",{attrs:{range:t.areas,"range-key":"name"},on:{change:function(e){arguments[0]=e=t.$handleEvent(e),t.bindAreaChange.apply(void 0,arguments)}}},[a("v-uni-view",{staticClass:"area select",class:{action:t.area}},[t._v(t._s(t.area||"点击选择地区"))])],1),a("v-uni-picker",{attrs:{range:t.statuss},on:{change:function(e){arguments[0]=e=t.$handleEvent(e),t.bindStatusChange.apply(void 0,arguments)}}},[a("v-uni-view",{staticClass:"status select",class:{action:t.status}},[t._v(t._s(t.status))])],1)],1),a("v-uni-scroll-view",{staticClass:"item-wrapper",style:{height:t.height},attrs:{"scroll-y":"true"}},[0===t.showList.length?a("empty"):t._e(),t._l(t.showList,(function(e){return a("v-uni-view",{staticClass:"item flex",on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.join(e.id)}}},[a("v-uni-view",{staticClass:"item-left"},[a("v-uni-image",{attrs:{src:e.img,mode:""}})],1),a("v-uni-view",{staticClass:"item-right"},[a("v-uni-view",{staticClass:"item-title clamp"},[t._v(t._s(e.title))]),a("v-uni-view",{staticClass:"item-content clamp2"},[t._v(t._s(e.info))]),a("v-uni-view",{staticClass:"item-status"},[t._v("捐赠进度"),a("v-uni-text",[t._v(t._s(e.project_progress)+"%")])],1),a("v-uni-view",{staticClass:"item-btn",class:{"btn-active":1==e.status}},[t._v(t._s(2==e.status?"已结束":0==e.status?"未开始":"我要捐赠"))])],1)],1)}))],2)],1)},r=[]},f9a3:function(t,e,a){"use strict";var i=a("4ea4");a("4de4"),a("d81d"),a("ac1f"),a("5319"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=i(a("5f4c")),r=a("3cea"),o={components:{empty:n.default},data:function(){return{areas:[],area:"",select_area:0,area_id:0,statuss:["全部","进行中","已结束"],status:"全部",select_status:0,list:[],height:0}},onReady:function(t){var e=this;uni.getSystemInfo({success:function(t){var a=uni.createSelectorQuery();a.select(".item-wrapper").boundingClientRect(),a.exec((function(a){console.log(a,"ddddddddddddd"),e.height=t.windowHeight-a[0].top+"px",console.log("打印页面的剩余高度",e.height)}))},fail:function(t){}})},computed:{showList:function(){var t=this;return 0===t.list.length?[]:0===t.select_area?0===t.select_status?t.list:1===t.select_status?t.list.filter((function(t){return 1===t.status})):t.list.filter((function(t){return 2===t.status})):0===t.select_status?t.list.filter((function(e){return e.project_area===t.select_area})):1===t.select_status?t.list.filter((function(e){return e.project_area==t.select_area&&1===e.status})):t.list.filter((function(e){return console.log(e.project_area,t.select_area),e.project_area==t.select_area&&2===e.status}))}},onLoad:function(){console.log("****************************************"),this.loadDate(),this.getAllArea()},methods:{bindAreaChange:function(t){console.log(t.target),this.area=this.areas[t.target.value].name,this.select_area=this.areas[t.target.value].id},bindStatusChange:function(t){console.log(t.target),this.status=this.statuss[t.target.value],"已结束"==this.status?this.select_status=2:"全部"==this.status?this.select_status=0:(this.select_status=1,console.log(this.select_status,"this.select_status+++++++++++++"))},join:function(t){console.log(t),uni.navigateTo({url:"/pages/donate/donateDetail?id="+t}),console.log("dddddddddd")},loadDate:function(){var t=this;(0,r.getProjectList)({page:1,status:-2,limit:1e4}).then((function(e){var a=e.data;a.list.map((function(e){(0,r.getProjectInfo)({id:e.id}).then((function(a){var i=JSON.parse(a.msg);return e.project_progress=i.project_progress,e.info=e.info.replace(/<img [^>]*src=['"]([^'"]+)[^>]*>/g,"").replace(/<[^>]+>/g,""),console.log(e),t.list.push(e),e}))})),console.log(t.list,"5555555")}))},getAllArea:function(){var t=this;(0,r.getAllArea)().then((function(e){var a=e.data;console.log(a,"6666666666"),t.areas=a}))},isShow:function(){console.log()}}};e.default=o}}]);