1 line
12 KiB
JavaScript
1 line
12 KiB
JavaScript
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-7d6d5bf1","chunk-2d0d83d6"],{"3e91":function(t,e,a){"use strict";a("b0c0"),a("99af");var i=a("ac0d"),r=a("eb17");e["a"]={mixins:[i["a"]],data:function(){return{listData:[],isLoadMore:!0,page:1,last_page:1}},activated:function(){var t=JSON.parse(localStorage.getItem("myLocation"));if(t&&(this.myLocation=t),this.lawyerId=this.$route.params.id,"lawyerSearch"==this.$route.name&&(this.lawyerId=this.$route.query.id),0==this.request)return!1;this.httpUrl&&this.getdata()},methods:{initdata:function(){this.page=1,this.listData=[]},getdata:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";this.initdata();var a={};this.lawyerId&&"lawyerSearch"!==this.$route.name&&(a.id=this.lawyerId),e&&(a={id:this.lawyerId,name:e}),"lawyerSearch"==this.$route.name&&("距离"!==this.text&&(a.distance_type="由近到远"==this.text?1:2,a.lng=this.myLocation.point.lng,a.lat=this.myLocation.point.lat),a.category_id=this.lawyerId),"lawyerConsult"==this.$route.name&&(a.goods_type=this.$route.params.consult_type),$http.post(this.httpUrl,a,"正在加载中...").then((function(e){var a=e.result,i=e.msg,r=e.data;a?(t.listData=r.list.data,t.last_page=r.list.last_page):t.$toast(i)}))},getMoreData:function(){var t=this;if(this.isLoadMore=!1,!(this.page>=this.last_page)){var e=this.page+1,a={page:e};"lawyerConsult"==this.$route.name&&(a.goods_type=this.$route.params.consult_type),$http.post(this.httpUrl,a,"正在加载更多数据中...").then((function(a){var i=a.result,r=a.msg,o=a.data;t.isLoadMore=!0,i?(t.page=e,t.listData=t.listData.concat(o.list.data)):t.$toast(r)}))}}},watch:{search:function(t){var e=this;this.timerId&&clearTimeout(this.timerId),this.timerId=setTimeout((function(){e.getdata(t)}),300)},lawyers:function(t){t&&t.length>0&&(this.listData=t)},immediate:!0},components:{yzBlank:r["default"]}}},"6a66":function(t,e,a){var i=a("f118");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var r=a("499e").default;r("5de2a308",i,!0,{sourceMap:!1,shadowMode:!1})},"79db":function(t,e,a){t.exports=a.p+"static/app/img/empty-image-search.ef236a93.png"},"79fa":function(t,e,a){"use strict";a("6a66")},"8d65":function(t,e,a){"use strict";a.r(e);var i=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{class:{pcStyle:3==this.fun.getPhoneEnv()},attrs:{classs:"search-list"}},[a("c-title",{attrs:{hide:!1,text:"搜索"}}),a("van-search",{attrs:{placeholder:"请输入搜索关键词"},model:{value:t.searchValue,callback:function(e){t.searchValue=e},expression:"searchValue"}}),a("van-dropdown-menu",[a("van-dropdown-item",{ref:"domain",scopedSlots:t._u([{key:"title",fn:function(){return[a("div",[t._v(t._s(t.domainName))])]},proxy:!0},{key:"default",fn:function(){return[a("div",{staticClass:"warpper"},t._l(t.categoryList,(function(e){return a("div",{key:e.id,staticClass:"category-name",class:{current:t.form.category_id==e.id},on:{click:function(a){return t.domain(e)}}},[t._v(t._s(e.title))])})),0)]},proxy:!0}])}),a("van-dropdown-item",{ref:"distance",scopedSlots:t._u([{key:"title",fn:function(){return[a("div",[t._v(t._s(t.text))])]},proxy:!0},{key:"default",fn:function(){return t._l(t.option2,(function(e){return a("div",{key:e.id},[a("div",{staticClass:"distance",class:{currentDis:t.distance==e.text},on:{click:function(a){return t.change(e)}}},[t._v(t._s(e.text))])])}))},proxy:!0}]),model:{value:t.value2,callback:function(e){t.value2=e},expression:"value2"}})],1),a("div",{staticClass:"lawyer-platform"},t._l(t.listData,(function(e,i){return a("div",{key:i,staticClass:"lawyer"},[a("img",{attrs:{src:e.avatar_image},on:{click:function(a){return t.to(e.id)}}}),a("div",{staticClass:"info"},[a("div",{staticClass:"flex between"},[a("span",{staticClass:"name"},[t._v(t._s(e.name))]),a("div",{staticClass:"title"},[a("div",{staticClass:"lawyer-title mr-1"},[t._v(t._s(e.title))])])]),a("div",{staticClass:"lawyer-detail"},[a("span",{staticClass:"life"},[t._v("职业"+t._s(e.year)+"年")]),t._l(e.category_data,(function(e,i){return a("span",{key:i,staticClass:"domain-nickName"},[t._v(t._s(e.title))])}))],2),a("div",{staticClass:"footer"},[a("div",{staticClass:"c-6b6b6b lawfirm"},[t._v(" "+t._s(e.city_name)+" | "),a("span",[t._v(t._s(e.lawyer_firm?e.lawyer_firm.name:""))])]),a("div",{staticClass:"footer-distance"},[t._v(t._s(e.distance))])])])])})),0)],1)},r=[],o=a("5530"),n=(a("e9c4"),a("d3b7"),a("b0c0"),a("3e91")),s={mixins:[n["a"]],data:function(){return{httpUrl:"plugin.lawyer-platform.frontend.controllers.lawyer.getLawyerList",lawyerId:"",searchValue:"",far:1,near:2,domainName:"领域名称",value1:0,value2:"b",option2:[{text:"由近到远",value:"由近到远"},{text:"由远到近",value:"由远到近"}],categoryList:[],text:"距离",form:{distance_type:"",name:"",lng:"",lat:"",category_id:""},distance:"",point:[],myLocation:{},listData:[],isLoadMore:!0,page:1,last_page:1}},created:function(){this.getCategory()},methods:{getSearch:function(){var t=this;this.myLocation.point&&(this.form.lng=this.myLocation.point.lng,this.form.lat=this.myLocation.point.lat),"距离"!==this.text&&(this.form.distance_type="距离"==this.text?"":"由近到远"==this.text?1:2),$http.post("plugin.lawyer-platform.frontend.controllers.lawyer.getLawyerList",Object(o["a"])({},this.form)).then((function(e){1==e.result&&(t.listData=e.data.list.data,t.page=e.data.list.current_page,t.last_page=e.data.list.last_page)}))},getCategory:function(){var t=this;$http.post("plugin.lawyer-platform.frontend.controllers.lawyer.getCategory").then((function(e){1==e.result&&(t.categoryList=e.data.category)}))},handle:function(){this.$router.push(this.fun.getUrl("lawyerPlatformApplyFor",{},{apply_for:"lawYerManagement"}))},to:function(t){this.$router.push(this.fun.getUrl("lawyerDetail",{id:t},{order_type:"lawyer"}))},domain:function(t){this.domainName==t.title?(this.domainName="领域名称",this.form.category_id=""):(this.domainName=t.title,this.form.category_id=t.id),this.$refs.domain.toggle(),this.getSearch()},change:function(t){var e=this;this.text==t.text?(this.text="距离",this.distance="",this.getSearch()):(this.text=t.text,this.distance=t.text,"{}"!==JSON.stringify(this.myLocation)?(this.form.lng=this.myLocation.point.lng,this.form.lat=this.myLocation.point.lat,this.getSearch()):this.fun.getLocation("正在定位中...").then((function(t){e.address=t.title,e.city=t.city,e.point=t.point;var a=new Promise((function(t,a){e.init(e.point),t()}));a.then((function(){e.getSearch(point)}))})).catch((function(t){}))),this.$refs["distance"].toggle()}},watch:{searchValue:function(t){var e=this;this.form.name=t,this.timerId&&clearTimeout(this.timerId),this.timerId=setTimeout((function(){e.getSearch()}),300)}}},l=s,c=(a("79fa"),a("2877")),d=Object(c["a"])(l,i,r,!1,null,"37c985e9",null);e["default"]=d.exports},ac0d:function(t,e,a){"use strict";a.d(e,"a",(function(){return o}));var i=document.documentElement,r=document.body,o={data:function(){return{}},activated:function(){window.addEventListener("scroll",this.handleScroll)},deactivated:function(){window.removeEventListener("scroll",this.handleScroll)},methods:{getScrollTop:function(){var t=0;return i&&i.scrollTop?t=i.scrollTop:r&&(t=r.scrollTop),t},getClientHeight:function(){var t=0;return t=r.clientHeight&&i.clientHeight?Math.min(r.clientHeight,i.clientHeight):Math.max(r.clientHeight,i.clientHeight),t},getScrollHeight:function(){return Math.max(r.scrollHeight,i.scrollHeight)},handleScroll:function(){this.otherScroll();var t=document.documentElement.scrollTop||document.body.scrollTop;this.btnFlag=t>60,this.getScrollTop()+this.getClientHeight()+105>this.getScrollHeight()?(this.isLoadMore&&this.getMoreData(),this.isBottom=!0):this.isBottom=!1},otherScroll:function(){}}}},f118:function(t,e,a){var i=a("24fb");e=i(!1),e.push([t.i,".name[data-v-37c985e9]{font-size:1rem}.footer-distance[data-v-37c985e9]{margin-left:3rem;font-size:.75rem}.lawyer-platform[data-v-37c985e9]{background-color:#fff;padding:.94rem}.lawyer-platform .lawyer[data-v-37c985e9]{margin-bottom:1.8rem}.life[data-v-37c985e9]{margin-right:.25rem;font-size:.75rem}[data-v-37c985e9] .van-tabs__line{background-color:#daa032}[data-v-37c985e9] .van-tab--active{color:#daa032!important}.operators[data-v-37c985e9]{background-color:#fff;height:100%;padding-bottom:5rem}.info[data-v-37c985e9]{width:100%;text-align:left;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}.contact-way[data-v-37c985e9]{color:#6b6b6b;font-size:.8rem}.title[data-v-37c985e9]{text-align:right}.lawyer-title[data-v-37c985e9]{font-size:.75rem}div.item[data-v-37c985e9]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-left:.714rem;margin-top:1.3571rem}img[data-v-37c985e9]{margin-right:.328rem}.pcStyle[data-v-37c985e9]{width:375px}.pcStyle[data-v-37c985e9] .van-dropdown-item--down{width:375px;margin:auto}.lawyer-platform .lawyer[data-v-37c985e9]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-bottom:1rem}.currentDis[data-v-37c985e9],[data-v-37c985e9] .van-dropdown-menu__title--active{color:#f5b435}.distance[data-v-37c985e9]{text-align:left;margin:1rem}.btn[data-v-37c985e9]{position:fixed;width:100vw;bottom:0;background-color:#fff;-webkit-box-shadow:0 -2px 7px 0 hsla(0,0%,83.5%,.59);box-shadow:0 -2px 7px 0 hsla(0,0%,83.5%,.59);padding:.5714rem 1.7857rem}.btn[data-v-37c985e9] .van-button--normal{width:100%;border-radius:.3571rem}.van-search__content[data-v-37c985e9]{border-radius:1rem!important}.list[data-v-37c985e9]{background-color:#fff;padding-bottom:1rem}.text-left[data-v-37c985e9]{text-align:left}.flex[data-v-37c985e9]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex}.between[data-v-37c985e9]{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between}.mr-1[data-v-37c985e9]{margin-right:1rem}.life[data-v-37c985e9]{margin-top:.94rem}.c-6b6b6b[data-v-37c985e9],.life[data-v-37c985e9]{color:#6b6b6b}.domain-nickName[data-v-37c985e9]{padding:.25rem .4rem;margin:.625rem .315rem;border:1px solid #f5b435;border-radius:2px;text-align:center;color:#f5b435;-webkit-box-sizing:border-box;box-sizing:border-box;font-size:.63rem;border-radius:.125rem}img[data-v-37c985e9]{margin:0;width:3rem;height:3rem;border-radius:100px;-o-object-fit:cover;object-fit:cover;border:1px solid #fff;margin-right:.6428rem}.item[data-v-37c985e9]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin-left:.714rem;margin-top:1.3571rem}.lawyer-title[data-v-37c985e9]{color:#daa032;font-size:.857rem}.lawyer-detail[data-v-37c985e9]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap}.lawfirm[data-v-37c985e9]{font-size:.75rem;margin-right:.3rem}#searchList[data-v-37c985e9]{background-color:#fff}.warpper[data-v-37c985e9]{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap;padding:1rem}.category-name[data-v-37c985e9],.current[data-v-37c985e9]{padding:.1rem .6rem;height:1.5714rem;border-radius:2px;border:1px solid #bdbdbd;text-align:center;margin:.2rem}.current[data-v-37c985e9]{border:1px solid #f5b435;color:#f5b435}.footer[data-v-37c985e9]{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;margin-right:1rem}.footer .footer[data-v-37c985e9]{font-size:.75rem}",""]),t.exports=e}}]); |