1 line
15 KiB
JavaScript
1 line
15 KiB
JavaScript
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-39f6e352"],{"0fb7b":function(t,e,i){var a=i("53b9");a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var n=i("499e").default;n("f426f946",a,!0,{sourceMap:!1,shadowMode:!1})},"53b9":function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,'.pcStyle[data-v-49deaf1c]{width:375px!important}.addr[data-v-49deaf1c]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-flow:row wrap;-ms-flex-flow:row wrap;flex-flow:row wrap;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;background:#fff;padding:.875rem}.addr .icon-local-img[data-v-49deaf1c]{width:.85rem;height:.85rem;color:#999}.addr .icon-sty[data-v-49deaf1c]{-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;text-align:left;padding:0 .625rem}.addr .fa-angle-right[data-v-49deaf1c]{line-height:1.5rem;font-size:.7rem;color:#999}.detail-box[data-v-49deaf1c]{background:#fff;padding:.6rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-top:.4rem}.detail-box img[data-v-49deaf1c]{width:5.45rem;height:5.45rem;border-radius:.2rem .2rem .2rem .2rem;margin:0}.detail-box .right-box[data-v-49deaf1c]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;margin-left:.3rem;padding:.325rem 0}.detail-box .right-box .top-name[data-v-49deaf1c]{text-align:left}.detail-box .right-box .top-name .skill-title[data-v-49deaf1c]{font-size:.9rem;font-weight:400;color:#333}.detail-box .right-box .top-name .skill-name[data-v-49deaf1c]{font-size:.8rem;font-weight:400;color:#999;margin-top:.8rem}.detail-box .right-box .price-bar[data-v-49deaf1c]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;color:#ff9c43;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center}.detail-box .right-box .price-bar .price-name[data-v-49deaf1c]{font-size:.85rem;font-weight:500;color:#ff9c43}.detail-box .right-box .price-bar .price-sty[data-v-49deaf1c]{font-size:.7rem;font-weight:400;color:#ff9c43}.anytime-pane[data-v-49deaf1c]{padding:.6rem .6rem 0 .6rem;background:#fff;margin:.6rem 0}.anytime-pane .appointment-time[data-v-49deaf1c]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;padding-bottom:.675rem;border-bottom:.025rem solid #e7e7e7}.anytime-pane .appointment-time .time-sty[data-v-49deaf1c]{font-size:.8rem;font-weight:400;color:#333}.anytime-pane .appointment-time .time-sty .star-sty[data-v-49deaf1c]{color:#f84949}.anytime-pane .appointment-time .right-op-time[data-v-49deaf1c]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center}.anytime-pane .appointment-time .right-op-time .true-time[data-v-49deaf1c]{font-size:.8rem;font-weight:400;color:#4978f8;margin-right:.45rem;line-height:1}.anytime-pane .demand-profile[data-v-49deaf1c]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center}.anytime-pane .demand-profile .time-sty[data-v-49deaf1c]{font-size:.8rem;font-weight:400;color:#333}.anytime-pane .demand-profile .time-sty .star-sty[data-v-49deaf1c]{color:#f84949}.time-pane .top-pane[data-v-49deaf1c]{margin:1.05rem .8rem .8rem .8rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center}.time-pane .top-pane .cancal[data-v-49deaf1c]{font-size:.7rem;font-weight:400;color:#999}.time-pane .top-pane .time-prop[data-v-49deaf1c]{font-size:.75rem;font-weight:700;color:#333}.time-pane .top-pane .sure[data-v-49deaf1c]{font-size:.7rem;font-weight:400;color:#999}.time-pane .choose-time[data-v-49deaf1c]{padding:0 .6rem;margin-bottom:.6rem}.time-pane .choose-time .tips[data-v-49deaf1c]{color:#000;padding:1rem;text-align:left;font-weight:700}.time-pane .choose-time .choose-time-name[data-v-49deaf1c]{padding:.65rem 0;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;border-top:.025rem solid #e7e7e7}.time-pane .choose-time .choose-time-name .time-sty[data-v-49deaf1c]{font-size:.85rem;font-weight:400;color:#333}.time-pane .choose-time .choose-time-name .time-sty-op[data-v-49deaf1c]{font-size:.8rem;font-weight:400;color:#999}.time-pane .choose-time .specific-time[data-v-49deaf1c]:after{content: ""; width:25%; height: 0; visibility: hidden}.time-pane .choose-time .specific-time[data-v-49deaf1c]{margin-bottom:.6rem;display:grid;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;grid-template-columns:1fr 1fr 1fr 1fr}.time-pane .choose-time .specific-time .specific-time-rol[data-v-49deaf1c]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin:0 .6rem .6rem 0;padding:.5rem 1.2rem;background:#fffaf1;border-radius:.85rem .85rem .85rem .85rem;font-size:.7rem;font-weight:400;color:#333;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}.time-pane .choose-time .specific-time .active-color[data-v-49deaf1c]{background:#f49f19;color:#fff}.bottom-pane[data-v-49deaf1c]{background:#fff;padding:.4rem .6rem;position:fixed;width:100%;bottom:0}.bottom-pane .text[data-v-49deaf1c]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;padding:.375rem 2.2rem}.bottom-pane .text .name[data-v-49deaf1c]{font-size:.7rem;font-weight:400;color:#999}.bottom-pane .text .price-name[data-v-49deaf1c]{font-size:.8rem;font-weight:500;color:#ff9c43;margin-left:.425rem}.bottom-pane .appointment-pane[data-v-49deaf1c]{position:relative}.bottom-pane .appointment-pane .appointment-name[data-v-49deaf1c]{background:#4978f8;color:#fff;padding:.375rem 2.2rem;border-radius:1.025rem 1.025rem 1.025rem 1.025rem;position:absolute;right:.6rem;top:-1.85rem}[data-v-49deaf1c] .van-cell__title{text-align:left}.none-act[data-v-49deaf1c]{background-color:hsla(0,0%,60%,.6)!important;color:#fff!important}',""]),t.exports=e},"980e2":function(t,e,i){"use strict";i("0fb7b")},ae82:function(t,e,i){"use strict";i.r(e);var a=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{attrs:{id:"order-bar"}},[i("c-title",{attrs:{text:"提交订单"}}),t.info?i("div",{staticClass:"addr",on:{click:function(e){t.showAddress=!0}}},[i("img",{staticClass:"icon-local-img",attrs:{src:"https://mini-app-img-1251768088.cos.ap-guangzhou.myqcloud.com/plugin/anytime_service/icon_local (1).png",alt:""}}),i("p",{directives:[{name:"show",rawName:"v-show",value:t.location_detail.username,expression:"location_detail.username"}],staticClass:"icon-sty"},[t._v(" 收件人:"+t._s(t.location_detail.username)+" "+t._s(t.location_detail.mobile)+" "),i("br"),i("span",{staticStyle:{color:"#999"}},[t._v(t._s(t.location_detail.province)+t._s(t.location_detail.city)+t._s(t.location_detail.district)+t._s(t.location_detail.street)+t._s(t.location_detail.address))])]),i("p",{directives:[{name:"show",rawName:"v-show",value:!t.location_detail.username,expression:"!location_detail.username"}],staticClass:"icon-sty"},[t._v("请点击选择地址")]),i("i",{directives:[{name:"show",rawName:"v-show",value:t.location_detail.username,expression:"location_detail.username"}],staticClass:"fa fa-angle-right"})]):t._e(),i("div",{staticClass:"detail-box"},[i("img",{attrs:{src:t.dataDetail.pic_url,alt:""}}),i("div",{staticClass:"right-box"},[i("div",{staticClass:"top-name"},[i("div",{staticClass:"skill-title"},[t._v(t._s(t.dataDetail.title))]),i("div",{staticClass:"skill-name"},[t._v(t._s(t.dataDetail.has_one_category?t.dataDetail.has_one_category.title:"")+" "+t._s(t.dataDetail.desc))])]),i("div",{staticClass:"price-bar"},[i("span",{staticClass:"price-name"},[t._v(t._s(t.dataDetail.fee))]),i("span",{staticClass:"price-sty"},[t._v("元/次")])])])]),i("div",{staticClass:"anytime-pane"},[i("div",{staticClass:"appointment-time"},[t._m(0),i("div",{staticClass:"right-op-time",on:{click:t.clickAppointment}},[""!==t.time_op?i("span",{staticClass:"true-time"},[t._v(t._s(t.time_day.split("-")[1])+"月"+t._s(t.time_day.split("-")[2])+"日("+t._s(t.time_op)+")")]):t._e(),i("van-icon",{attrs:{name:"arrow"}})],1)]),i("div",{staticClass:"demand-profile"},[t._m(1),i("van-field",{staticStyle:{width:"80%"},attrs:{placeholder:"请输入需求简介"},model:{value:t.content,callback:function(e){t.content=e},expression:"content"}})],1)]),i("div",{class:[3==this.fun.getPhoneEnv()?"pcStyle bottom-pane":"bottom-pane"]},[i("div",{staticClass:"text"},[i("span",{staticClass:"name"},[t._v("合计:")]),i("span",{staticClass:"price-name"},[t._v("¥"+t._s(t.dataDetail.fee))])]),i("div",{staticClass:"appointment-pane"},[i("span",{staticClass:"appointment-name",on:{click:t.submit}},[t._v("预约")])])]),i("van-popup",{style:{height:"100%"},attrs:{position:"bottom"},on:{"click-overlay":t.cancalTime},model:{value:t.popup_show,callback:function(e){t.popup_show=e},expression:"popup_show"}},[i("div",{staticClass:"time-pane"},[i("div",{staticClass:"top-pane"},[i("span",{staticClass:"cancal",on:{click:t.cancalTime}},[t._v("取消")]),i("span",{staticClass:"time-prop"},[t._v("预约时间")]),i("span",{staticClass:"sure",on:{click:function(e){t.popup_show=!1}}},[t._v("确认")])]),i("div",[t.popup_show?i("c-calendar",{ref:"calendar",attrs:{events:t.calendarEvents},on:{select:t.selectedDay,monthChanged:t.monthChanged}}):t._e()],1),i("div",{staticClass:"choose-time"},[t.timeList.length<=0?i("div",{staticClass:"tips"},[t._v("暂无可预约时间")]):t._e(),t.timeList.length>0?i("van-collapse",{model:{value:t.activeNames,callback:function(e){t.activeNames=e},expression:"activeNames"}},[i("van-collapse-item",{attrs:{title:"选择时间",name:1,value:t.time_op}},[i("div",{staticClass:"specific-time"},t._l(t.timeList,(function(e,a){return i("span",{key:a,class:0!==e.state?"specific-time-rol none-act":t.time_op==e.time_str?"specific-time-rol active-color":"specific-time-rol",on:{click:function(i){return t.chooseTime(e)}}},[t._v(t._s(e.time_str))])})),0)])],1):t._e()],1)])]),i("yz-address-list",{on:{confirm:t.confirmSelectAddress},model:{value:t.showAddress,callback:function(e){t.showAddress=e},expression:"showAddress"}})],1)},n=[function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("span",{staticClass:"time-sty"},[t._v("预约时间"),i("span",{staticClass:"star-sty"},[t._v("*")])])},function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("span",{staticClass:"time-sty"},[t._v("需求简介"),i("span",{staticClass:"star-sty"},[t._v("*")])])}],s=i("5530"),o=i("b85c"),c=(i("b64b"),i("99af"),i("14d9"),i("a9e3"),i("3dc5")),l=i("a234"),r={data:function(){return{location_detail:{},popup_show:!1,showCalendar:!1,calendarEvents:[],time_op:"",timeList:[],time_day:"",save_time:"",showAddress:!1,id:"",dataDetail:{},content:"",info:!1,myLocation:{},activeNames:[1]}},activated:function(){this.myLocation=JSON.parse(localStorage.getItem("myLocation")),this.id=this.$route.params.id,this.getAddress()},methods:{selectedDay:function(t){var e="".concat(t[0],"-").concat(t[1],"-").concat(t[2]);this.time_day=e,this.time_op="",this.getTimeList(new Date("".concat(t[0],"-").concat(this.filterDate(t[1]),"-").concat(t[2])).getTime()/1e3)},monthChanged:function(t){},chooseTime:function(t){0==t.state&&(this.time_op=t.time_str)},cancalTime:function(){this.popup_show=!1,this.save_time?(this.time_op=this.save_time[3],this.time_day=this.save_time[0]+"-"+this.save_time[1]+"-"+this.save_time[2]):this.time_op=""},clickAppointment:function(){this.save_time=""!==this.time_op?[this.time_day.split("-")[0],this.time_day.split("-")[1],this.time_day.split("-")[2],this.time_op]:"",this.time_day=(new Date).getFullYear()+"-"+((new Date).getMonth()+1)+"-"+(new Date).getDate(),this.time_op="",this.getTimeGroup(new Date(this.time_day).getTime()/1e3)},confirmSelectAddress:function(t){this.location_detail=t},getAddress:function(){var t=this;$http.get("member.member-address.index",{}).then((function(e){if(1===e.result){if(e.data.length>0){var i,a=Object(o["a"])(e.data);try{for(a.s();!(i=a.n()).done;){var n=i.value;1==n.isdefault&&(t.location_detail=n)}}catch(s){a.e(s)}finally{a.f()}}t.getData()}else t.$toast(e.msg)}),(function(t){}))},getData:function(){var t=this;$http.get("plugin.be-within-call.frontend.create-need.pre-ability",{aid:this.id}).then((function(e){1===e.result?(t.dataDetail=e.data,t.info=!0):(t.$toast(e.msg),t.$router.go(-1))}),(function(t){}))},getTimeList:function(t){var e=this;this.timeList=[],$http.get("plugin.be-within-call.frontend.work-time.pre-time",{aid:this.id,date:t},"loading").then((function(t){1===t.result?e.timeList=t.data.time_list:e.$toast(t.msg),e.popup_show=!0,e.showCalendar=!0}),(function(t){}))},getTimeGroup:function(t){var e=this;$http.get("plugin.be-within-call.frontend.work-time.group",{aid:this.id}).then((function(i){if(1===i.result){var a,n=Object(o["a"])(i.data);try{for(n.s();!(a=n.n()).done;){var s=a.value;e.calendarEvents.push(e.timestampToTime(s.date))}}catch(c){n.e(c)}finally{n.f()}}else e.$toast(i.msg);e.getTimeList(t)}),(function(t){}))},submit:function(){var t=this,e=new Date("".concat(this.time_day.split("-")[0],"/").concat(this.time_day.split("-")[1],"/").concat(this.time_day.split("-")[2]," ").concat(this.time_op)),i={content:this.content,longitude:this.myLocation?this.myLocation.point.lng:"",latitude:this.myLocation?this.myLocation.point.lat:"",province:this.location_detail.province,city:this.location_detail.city,district:this.location_detail.district,street:this.location_detail.street,address:this.location_detail.address,start_at:e.getTime()/1e3,finish_at:e.getTime()/1e3,realname:this.location_detail.username,mobile:this.location_detail.mobile,ability_id:this.id};$http.post("plugin.be-within-call.frontend.create-need.appointment",Object(s["a"])({},i)).then((function(e){1===e.result?t.$router.push(t.fun.getUrl("orderpay",{status:2,order_ids:e.data.order_ids})):t.$toast(e.msg)}),(function(t){}))},timestampToTime:function(t){if(!Number(t)||""==t)return"";var e=new Date(1e3*t),i=e.getFullYear()+"-",a=(e.getMonth()+1<10?"0"+(e.getMonth()+1):e.getMonth()+1)+"-",n=e.getDate()<10?"0"+e.getDate():e.getDate();return i+a+n},filterDate:function(t){var e=t.split(""),i="";return i=-1==e.indexOf("0")?t:e[1],i}},components:{cCalendar:c["a"],yzAddressList:l["default"]}},d=r,m=d,p=(i("980e2"),i("2877")),f=Object(p["a"])(m,a,n,!1,null,"49deaf1c",null);e["default"]=f.exports}}]); |