You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1 line
8.6 KiB

5 months ago
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["user/pages/choose-technician"],{"26da":function(t,e,n){"use strict";(function(t){var i=n("47a9");Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var a=i(n("7eb4")),r=i(n("34cf")),c=i(n("7ca3")),o=i(n("ee10")),s=n("8f59");function u(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function l(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?u(Object(n),!0).forEach((function(e){(0,c.default)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}var d={components:{technicianListItem:function(){n.e("components/technician-list-item").then(function(){return resolve(n("a0e3"))}.bind(null,n)).catch(n.oe)},technicianListPopup:function(){n.e("components/technician-list-popup").then(function(){return resolve(n("ba2d"))}.bind(null,n)).catch(n.oe)}},data:function(){return{isLoad:!1,options:{},param:{page:1,ser_id:0,coach_name:""},list:{data:[]},loading:!0,lockTap:!1,pageLen:1}},computed:(0,s.mapState)({primaryColor:function(t){return t.config.configInfo.primaryColor},subColor:function(t){return t.config.configInfo.subColor},configInfo:function(t){return t.config.configInfo},cityId:function(t){return t.technician.cityId},cityIndex:function(t){return t.technician.cityIndex},cityList:function(t){return t.technician.cityList},loginType:function(t){return t.user.loginType},userInfo:function(t){return t.user.userInfo},location:function(t){return t.user.location}}),onLoad:function(t){var e=this;return(0,o.default)(a.default.mark((function n(){return a.default.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return e.options=t,e.$util.showLoading(),n.next=4,e.initIndex();case 4:e.isLoad=!0;case 5:case"end":return n.stop()}}),n)})))()},onPullDownRefresh:function(){t.showNavigationBarLoading(),this.initRefresh(),t.stopPullDownRefresh()},onReachBottom:function(){this.list.current_page>=this.list.last_page||this.loading||(this.param.page=this.param.page+1,this.loading=!0,this.getList())},methods:l(l(l({},(0,s.mapActions)(["getCityList"])),(0,s.mapMutations)(["updateUserItem","updateTechnicianItem"])),{},{initIndex:function(){var t=arguments,e=this;return(0,o.default)(a.default.mark((function n(){return a.default.wrap((function(n){while(1)switch(n.prev=n.next){case 0:t.length>0&&void 0!==t[0]&&t[0],e.pageLen=getCurrentPages().length,e.getList(0==e.cityList.length);case 3:case"end":return n.stop()}}),n)})))()},initRefresh:function(){this.param.page=1,this.initIndex(!0)},pickerChange:function(t,e){var n=t.target.value;this.updateTechnicianItem({key:"cityIndex",val:n}),this.updateTechnicianItem({key:"cityId",val:this.cityList[n].id}),this.param.page=1,this.getList()},toOpenLocation:function(){this.$util.checkAuth({type:"userLocation"})},toSearch:function(t){this.param.page=1,this.param.coach_name=t,this.getList()},toChooseLocation:function(e){var n=this;return(0,o.default)(a.default.mark((function e(){var i,c,o,s,u,l,d,f,p,h,g,v,m,y,b,_,x,w;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,n.$util.checkAuth({type:"userLocation"});case 2:return i=n.location,c=i.lat,void 0===c?"":c,o=i.lng,void 0===o?"":o,s={},e.next=7,t.chooseLocation(s);case 7:if(u=e.sent,l=(0,r.default)(u,2),d=l[1],f=d.address,p=void 0===f?"":f,h=d.longitude,g=d.latitude,v=d.province,m=void 0===v?"":v,y=d.city,b=void 0===y?"":y,_=d.district,x=void 0===_?"":_,h){e.next=22;break}return e.abrupt("return");case 22:return w={lng:h,lat:g,address:p,province:m,city:b,district:x},n.updateUserItem({key:"location",val:w}),n.param.page=1,e.next=27,n.getList(!0,1);case 27:case"end":return e.stop()}}),e)})))()},getList:function(){var t=arguments,e=this;return(0,o.default)(a.default.mark((function n(){var i,r,c,o,s,u,l,d,