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.
pingAnQiYeWeb/public/modules/route_rjta0o.js

1 line
59 KiB

/**/_jsload2 && _jsload2('route', 'var li={web:"http://api.map.baidu.com/direction?",android:"bdapp://map/direction?",ios:"baidumap://map/direction?"};function mi(a){this.city=a.city;this.sw=a.start;this.Bv=a.end;this.Vr=a.eu;this.moreResultsUrl=a.url;this.taxiFare=a.bP||p;this.fV=a.VO||ge;this.kS=a.DL||ge}x.extend(mi.prototype,{vj:v("sw"),lh:v("Bv"),uY:v("fV"),RX:v("kS"),Wx:function(){return this.Vr.length},rf:function(a){if(this.Vr[a])return this.Vr[a]}});function ni(a){mi.call(this,a);this.policy=a.$c}x.ua(ni,mi,"DrivingRouteResult"); function oi(a){mi.call(this,a)}x.ua(oi,mi,"WalkingRouteResult");function pi(a){mi.call(this,a);this.policy=a.$c}x.ua(pi,mi,"TransitRouteResult");var qi=mi.prototype;U(qi,{getStart:qi.vj,getEnd:qi.lh,getStartStatus:qi.uY,getEndStatus:qi.RX,getNumPlans:qi.Wx,getPlan:qi.rf});function ri(a){this.lk=a.PF.slice(0);this.dg=a.od||0;this.pr=a.duration||0;this.UR=a.gX||[]}x.extend(ri.prototype,{nh:function(a){if(this.lk[a])return this.lk[a]},zt:function(){return this.lk.length},Ue:function(a){return a===q?this.dg:si(this.dg)},ut:function(a){return a===q?this.pr:ti(this.pr,"nav")},PX:v("UR")});var ui=ri.prototype;U(ui,{getNumRoutes:ui.zt,getRoute:ui.nh,getDistance:ui.Ue,getDuration:ui.ut,getDragPois:ui.PX});function vi(a){ri.call(this,a);this.Xi=a.rZ;this.sl=a.description;this.pr=a.duration||0}x.ua(vi,ri,"TransitRoutePlan"); x.extend(vi.prototype,{Vx:function(){return this.Xi.length},rE:function(a){if(this.Xi[a])return this.Xi[a]},kh:function(a){return a===q?Q.mO(this.sl):this.sl},ut:function(a){return a===q?this.pr:ti(this.pr,"bustime")},aY:function(){for(var a="",b=this.Xi.length-1,c=0;c<b;c++)this.Xi[c]&&this.Xi[c].title&&(a+=this.TL(this.Xi[c].title)+" \\u2192 ");return a+=this.TL(this.Xi[b].title)},TL:function(a){return a.substring(0,a.indexOf("("))},GY:function(){for(var a=0,b=this.lk.length,c=0;c<b;c++)a+=this.lk[c].Ue(q); return si(a)}});var wi=vi.prototype;U(wi,{getNumLines:wi.Vx,getLine:wi.rE,getNumRoutes:wi.zt,getRoute:wi.nh,getDistance:wi.Ue,getDuration:wi.ut,getDescription:wi.kh});function xi(a){this.qs=a.Gj&&a.Gj.slice(0)||[];this.dg=a.od||0;this.$j=a.index||0;this.Xr=a.ha.slice(0);this.IB=a.yF||0;this.MU=a.Yy;0===this.dg&&2<this.Xr.length&&(this.Xr.length=2)}x.extend(xi.prototype,{Xx:function(){return this.qs.length},kM:function(a){if(this.qs[a])return this.qs[a]},Ue:function(a){return a===q?this.dg:si(this.dg)},pE:v("$j"),yp:v("Zi"),ve:v("Xr"),zp:v("MU"),lY:v("IB")});var yi=xi.prototype; U(yi,{getNumSteps:yi.Xx,getStep:yi.kM,getDistance:yi.Ue,getIndex:yi.pE,getPolyline:yi.yp,getPath:yi.ve,getRouteType:yi.zp});function zi(a){this.title=a.title;this.uid=a.uid;this.type=a.type;this.aj=a.h0.slice(0);this.Xr=a.ha.slice(0);this.dg=a.od||0;this.WT=a.JZ||0;this.Dd=a.status||{}}x.extend(zi.prototype,{gY:v("WT"),oE:function(){return this.aj[0]},nE:function(){return this.aj[1]},ve:v("Xr"),yp:v("Zi"),Ue:function(a){return a===q?this.dg:si(this.dg)},Ap:v("title")});var Ai=zi.prototype;U(Ai,{getNumViaStops:Ai.gY,getGetOnStop:Ai.oE,getGetOffStop:Ai.nE,getPath:Ai.ve,getPolyline:Ai.yp,getDistance:Ai.Ue,getTitle:Ai.Ap});function Bi(a){this.Yh=a.point;this.$j=a.index;this.sl=a.description;this.dg=a.od||0;this.JU=a.k5||0;this.IB=a.yF||0}x.extend(Bi.prototype,{ia:v("Yh"),pE:v("$j"),kh:function(a){return a===q?Q.mO(this.sl):this.sl},Ue:function(a){return a===q?this.dg:si(this.dg)},X3:v("JU"),lY:v("IB")});var Ci=Bi.prototype;U(Ci,{getPosition:Ci.ia,getIndex:Ci.pE,getDescription:Ci.kh,getDistance:Ci.Ue});x.extend(Ae.prototype,{va:function(a){window.RouteAddrInst=this;var b={},a=this.cc=this.VZ(this.cc,a);if(a.result){var c=this.fe=a.content.tpList.length+1,d=a.content,e=[],f=[],g=["sel_n","sel_n1","sel_y","sel_x","sel_x1"],i=[-1,-1],j=[],f=[];this.Hu=[a.current_city.code,a.current_city.code];tempCode=a.current_city.code;for(var l=0;l<c+1;l++){var m=p;e.push([]);j.push("");f.push("");0==l?a.result.start_city&&(this.Hu[0]=a.result.start_city.code||a.result.start_city[0].code,tempCode=this.Hu[0]):a.result.end_city&& (this.Hu[l]=a.result.end_city.code||a.result.end_city[l-1].code,tempCode=this.Hu[l]);m=this.qi(l);if(0<a.result.count[l]&&1!=a.result.city_list[l]){13!=a.result.type&&24!=a.result.type&&(f[l]=\'<a href="javascript:void(0)" ></a>\');e[l].push(\'<div id="RADiv_ResItem\'+l+\'" class="sel_body_body_div sel_body_resitem">\');var n=[0,9];10>m.length&&(n[1]=m.length-1);e[l].push(this.qN(l,n));10<a.result.count[l]&&(e[l].push(\'<div id="RADiv_PAGE\'+l+\'" style="height:20px;" class="sel_body_body_page"></div>\'),this.lP[l]= Math.ceil(a.result.count[l]/10),this.Js[l]=1);e[l].push("</div>");1==a.result.prio_flag[l]?(i[l]=2,this.Ma[l].n=m[0].name,this.Ma[l].c=tempCode,this.Ma[l].u=m[0].uid,n=T.tb(Q.kb(m[0].geo,o).point),this.Ma[l].x=n.lng,this.Ma[l].y=n.lat,this.Ma[l].t=m[0].poiType,this.zg=n=this.oK(this.k.ja.map,n,m[0].name,l),this.iF.push(n.point),j[l]=m[0].name):i[l]=0}}for(var s,u,l=0;l<i.length;l++)if(m=i[l],3==m&&!s)this.jj=l,u&&(i[u-1]=1),s=l+1;else if(s){if(0==m||3==m)i[l]=m+1}else 0==m&&!u?(this.jj=l,u=l+1):u&& 0==m&&(i[l]=1);b.startPointClass=g[i[0]];this.pz=a.result.s_query?a.result.s_query:a.result.s_wd;b.startPoint=""==j[0]?this.pz:j[0];b.startBody=e[0].join("");b.endPointClass=g[i[c]];this.Gx=a.result.e_query?"string"==typeof a.result.e_query?a.result.e_query:a.result.e_query[c-1]:"string"==typeof a.result.e_wd?a.result.e_wd:a.result.e_wd[c-1];b.endPoint=""==j[c]?this.Gx:j[c];b.endBody=e[c].join("");b.startButton=f[0];b.endIndex=c;b.endButton=f[c];this.nP=[];s=[""];for(l=0;l<d.tpList.length;l++)u=l+ 1,c=j[u],""==c&&(c=a.result.d3[l]),this.nP.push(c),s.push([\'<div id="RouteAddress_DIV\'+u+\'" class="\'+g[i[u]]+\'">\',\' <div class="sel_body">\',\' <div class="sel_body_top" onclick="RouteAddrInst.showLst(\'+u+\')">\',\' <div class="sel_body_title">\\n <div class="sel_body_sign"></div>\',\' <div class="sel_body_name">\\u9014\\u7ecf\\u70b9\'+u+\'\\uff1a<b id="B_PointName\'+u+\'">\'+c+"</b></div>"," </div>",\' <div id="RD_TOP_BUT\'+u+\'" class="sel_body_button">\'+f[u]+"</div>"," </div>",\' <div class="sel_body_body" id="RADIV_BODY\'+ u+\'">\'+e[u].join("")+"</div>"," </div>\\n</div>"].join("\\n"));b.tpList=s.join("");return this.s0(b)}},BC:function(){var a;x.$("RouteAddress_DIV0")&&(a=x.$("RouteAddress_DIV0").getElementsByTagName("tr"),this.vO(a));x.$("RouteAddress_DIV1")&&(a=x.$("RouteAddress_DIV1").getElementsByTagName("tr"),this.vO(a));var b=this;this.Bb&&this.Bb.addEventListener("open",function(){var a=x.$("selInfoWndBtn");x.M(a,"click",function(){var c=a.getAttribute("data-uid").split("_");b.itmSelect(c[0],c[1])});x.M(a,"mouseover", function(){b._selBtnOver(a)});x.M(a,"mousedown",function(){b._selBtnDown(a)});x.M(a,"mouseout",function(){b._selBtnOut(a)})});var c,d;x.$("RouteAddress_DIV0")&&(c=x.$("RouteAddress_DIV0").firstChild.firstChild,x.M(c,"click",function(){var a=c.getAttribute("data-uid");b.showLst(a)}));x.$("RouteAddress_DIV1")&&(d=x.$("RouteAddress_DIV1").firstChild.firstChild,x.M(d,"click",function(){var a=d.getAttribute("data-uid");b.showLst(a)}))},vO:function(a){var b=this;this.Fb(a,function(a,d){x.M(d,"mouseover", function(a){var c=d.getAttribute("data-uid").split("_");n2=parseInt(c[1],10);ih=parseInt(c[2],10);b._lstMouseOver(this,0,c[0],ih-n2,a)});x.M(d,"mouseout",function(a){var c=d.getAttribute("data-uid").split("_");n2=parseInt(c[1],10);ih=parseInt(c[2],10);b._lstMouseOut(this,0,c[0],ih-n2,a)});x.M(d,"click",function(a){var c=d.getAttribute("data-uid").split("_"),e=parseInt(c[0],10);n2=parseInt(c[1],10);ih=parseInt(c[2],10);b.select(e,ih,a)});var e=d.childNodes[2].getElementsByTagName("div")[0];x.M(e,"click", function(){var a=e.getAttribute("data-uid").split("_");b.itmSelect(a[0],a[1])});x.M(e,"onmouseover",function(){b._selBtnOver(e)});x.M(e,"onmouseout",function(){b._selBtnOut(e)});x.M(e,"onmousedown",function(){b._selBtnDown(e)})})},VZ:function(a,b){a.content||(a.content={start:[],end:[]});a.content.tpList=[];if(19==a.result.type){this.WZ(a,b);var c=a.content,d=[],e=c.length;a.content={start:[],end:[]};if(2<e)for(var f=1;f<e-1;f++)d.push(c[f]);a.content.end=c[e-1];a.content.tpList=d;a.content.start= c[0]}return a},WZ:function(a,b){var c={},d,e=0,f=0,g=[],i,j=a.result;d=[];c.city_list=[];c.count=[];c.current_null=[];c.e_query=[];c.e_wd=[];c.end_city=[];c.wd2=[];c.prio_flag=[];c.sug_index=[];c.total=[];c.s_wd="";c.s_query="";this.ax=[];j.e_wd||(j.e_wd=[],j.e_query=[]);d=this.cO(b.start);i=d.type;c.s_wd=1==i?d.wb:j.s_wd;c.s_query=1==i?d.wb:j.s_query;1==i&&(this.Ma[e].o=c.s_wd,this.Ma[e].x=d.point.split(",")[0],this.Ma[e].y=d.point.split(",")[1]);this.ax.push(2==i);c.total.push(1==i?1:j.total[f]); c.count.push(1==i?1:j.count[f]);c.current_null.push(1==i?0:j.current_null[f]);c.prio_flag.push(1==i?1:j.prio_flag[f]);c.sug_index.push(1==i?"":j.sug_index[f]);g.push(1==i?[{name:d.wb,geo:"1|"+d.point+";"+d.point+"|"+d.point+";"}]:a.content[f]);c.city_list.push(1==i?0:j.city_list[f]);c.wd2.push(1==i?"":j.wd2[f]);2==i&&f++;e++;d=decodeURIComponent(b.end).split("to:");for(var l=0,m;m=d[l];l++){m=this.cO(m);i=m.type;2==i&&m.uid&&m.point&&(i=1);this.ax.push(2==i);var n=2==i?m.wb:0==f?j.s_wd:j.e_wd[f-1]; c.e_wd.push(n);c.e_query.push(n);c.end_city.push(1==i?a.current_city:0==f?j.start_city:j.end_city[f-1]);1==i&&(this.Ma[e].o=c.s_wd,this.Ma[e].x=m.point.split(",")[0],this.Ma[e].y=m.point.split(",")[1]);m.zj&&(this.aZ(e-1,{Ty:c.e_wd[e-1],As:c.wd2[e],point:1==i?Q.gM(m.point):p,uid:m.uid}),this.Ju.push({Ty:c.e_wd[e-1],As:c.wd2[e],point:1==i?Q.gM(m.point):p,uid:m.uid}));c.total.push(1==i?1:j.total[f]);c.count.push(1==i?1:j.count[f]);c.current_null.push(1==i?0:j.current_null[f]);c.prio_flag.push(1==i? 1:j.prio_flag[f]);c.sug_index.push(1==i?"":j.sug_index[f]);g.push(1==i?[{name:m.wb,geo:"1|"+m.point+";"+m.point+"|"+m.point+";"}]:a.content[f]);c.city_list.push(1==i?0:j.city_list[f]);c.wd2.push(1==i?"":j.wd2[f]);2==i&&f++;e++}x.extend(a.result,c);a.content=g},aZ:function(a,b){var c=x.extend({},b);if(this.Iu.length>a)this.Iu[a]=b;else if(this.Iu.length==a)this.Iu.push(b);else return;this.Iu[a]=c},cO:function(a){a=decodeURIComponent(a);a=a.split("$$");return{type:a[0],uid:a[1],point:a[2],wb:a[3],k4:a[4], t4:a[5],l3:a[6],zj:a[7]}},qi:function(a){return 0==a?this.cc.content.start:a==this.fe?this.cc.content.end:this.cc.content.tpList[a-1]},qN:function(a,b,c){this.li=-1;var c=c?c:this.qi(a),d=[];d.push(\'<div id="RA_ResItem_\'+a+\'"><table border="0" cellspacing="0" cellpadding="0" style="width:100%">\');for(var e=b[0];e<=b[1];e++){d.push(\'<tr onmouseover="RouteAddrInst._lstMouseOver(this, 0,\'+a+", "+(e-b[0])+\', event)" onmouseout="RouteAddrInst._lstMouseOut(this, 0,\'+a+", "+(e-b[0])+\', event)" onclick="RouteAddrInst.select(\'+ a+","+e+\', event)" filter = "item" data-uid="\'+a+"_"+b[0]+"_"+e+\'" ><th><div title="\\u5728\\u56fe\\u4e0a\\u663e\\u793a\\u8be5\\u70b9" class="icon iconbg" id="no_\'+a+"_"+(e-b[0]+1)+\'"></div></th>\');var f=0==a?"\\u9009\\u4e3a\\u8d77\\u70b9":a==this.fe?"\\u9009\\u4e3a\\u7ec8\\u70b9":"\\u9009\\u4e3a\\u9014\\u7ecf\\u70b9";d.push(\'<td style="word-break:break-all;padding-right:24px">\');d.push(\'<a href="javascript:void(0)">\'+c[e].name+"</a>");c[e].addr&&""!=c[e].addr&&(d.push("<div>"),0==c[e].poiType?d.push(\'<span style="color:#999">\\u5730\\u5740: \'+ c[e].addr+"</span>"):1==c[e].poiType?d.push(\'<span style="color:#999">\\u9014\\u7ecf\\u516c\\u4ea4\\u8f66\\uff1a</span>\'+c[e].addr.split(";").join("; ")):3==c[e].poiType&&d.push(\'<span style="color:#999">\\u9014\\u7ecf\\u5730\\u94c1\\uff1a</span>\'+c[e].addr.split(";").join("; ")),d.push("</div>"));d.push("</td>");d.push(\'<td style="vertical-align:middle;width:106px"><div tid="selBtn_\'+a+"_"+e+\'" class="selBtn" onclick="RouteAddrInst.itmSelect(\'+a+","+e+\');return false;" onmouseover="RouteAddrInst._selBtnOver(this)" onmouseout="RouteAddrInst._selBtnOut(this)" onmousedown="RouteAddrInst._selBtnDown(this)" data-uid = "\'+ a+"_"+e+\'" >\'+f+"</div>");d.push(\'<a data-uid="\'+c[e].uid+\'" href="javascript:void(0);" class="list_street_view_poi" style="visibility:hidden"><img src="/static/images/transparent.gif" ></a>\');d.push("</td>");d.push("</tr>")}d.push("</table></div>");return d.join("")},oK:function(a,b,c,d,e){0==d?a=X.So(a,b,c,Di):d==this.fe?a=X.So(a,b,c,Ei):(c=this.Ju[d-1],c.point=b,e&&(c.uid=e),a=X.tK(a,b,d-1));return a},s0:function(a){var b=[];b.push(\'<div class="RouteAddressOuterBkg">\');b.push(\'<div class="RouteAddressTip"><span>\\u8bf7\\u9009\\u62e9\\u51c6\\u786e\\u7684\\u8d77\\u70b9\\u3001\\u9014\\u7ecf\\u70b9\\u6216\\u7ec8\\u70b9</span></div>\'); b.push(\'<div class="RouteAddressInnerBkg">\');b.push(\'<div id="pos5" style="display:none"></div>\');b.push(\'<div id="RouteAddress_DIV0" class="\'+a.startPointClass+\'"> \');b.push(\'<div class="sel_body">\');b.push(\'<div class="sel_body_top" data-uid="0" onclick="RouteAddrInst.showLst(0)" >\');b.push(\'<div class="sel_body_title">\');b.push(\'<div class="sel_body_sign"></div>\');b.push(\'<div class="sel_body_name">\\u8d77\\u70b9\\uff1a<b id="B_PointName0">\'+a.startPoint+"</b></div>");b.push("</div>");b.push(\'<div id="RD_TOP_BUT0" class="sel_body_button">\'+ a.startButton+"</div>");b.push("</div>");b.push(\'<div class="sel_body_body" id="RADIV_BODY0">\'+a.startBody+"</div>");b.push("</div>");b.push("</div>");b.push(a.tpList);b.push(\'<div id="RouteAddress_DIV\'+a.endIndex+\'" class="\'+a.endPointClass+\'">\');b.push(\'<div class="sel_body">\');b.push(\'<div class="sel_body_top" data-uid=\'+a.endIndex+\' onclick="RouteAddrInst.showLst(\'+this.fe+\')" >\');b.push(\'<div class="sel_body_title">\');b.push(\'<div class="sel_body_sign"></div>\');b.push(\'<div class="sel_body_name">\\u7ec8\\u70b9\\uff1a<b id="B_PointName\'+ a.endIndex+\'">\'+a.endPoint+"</b></div>");b.push("</div>");b.push(\'<div id="RD_TOP_BUT\'+a.endIndex+\'" class="sel_body_button">\'+a.endButton+"</div>");b.push("</div>");b.push(\'<div class="sel_body_body" id="RADIV_BODY\'+a.endIndex+\'">\'+a.endBody+"</div>");b.push("</div>");b.push("</div>");b.push(\'<div id="pos6" style="display:none"></div>\');b.push("</div>");b.push("</div>");return b.join("")},showLst:function(a){this.jj=a;var b=this.cc.content.tpList.length+1,c=this.qi(a);if(!c||!(1==c.length&&c[0].JE&& 1==c[0].JE)){var d=this.Js,e=x.$("RouteAddress_DIV"+a).className;if(!("sel_n"==e||"sel_x"==e||this.ax&&!this.ax[a])){if("sel_n1"==e||"sel_y"==e||"sel_x1"==e){for(var f=0;f<=b;f++){var g=x.$("RouteAddress_DIV"+f);ka.Ec("B_PointName"+f).innerHTML=this.NX(f);"sel_x"==g.className?g.className="sel_x1":"sel_n"==g.className&&(g.className="sel_n1")}this.NC();this.zg&&(this.map.Ub(this.zg),this.zg=p);"sel_y"==e&&(this.Ma[a]={o:"",Fd:0,In:0,x:0,y:0,qa:-1},this.dq[a]=0);0>=this.cc.result.count[a]?x.$("RouteAddress_DIV"+ a).className="sel_x":(x.$("RouteAddress_DIV"+a).className="sel_n",1!=this.cc.result.city_list[a]&&(b=10*(d[a]-1)+9,c.length<b+1&&(b=c.length-1),this.Uo(a,[10*(d[a]-1),b])))}this.li=-1}}},WB:function(a,b){var c;x.$("RA_ResItem_"+a)&&(c=x.$("RA_ResItem_"+a).childNodes[0]);if(c&&(c=c.rows[b]))c.style.backgroundColor="#F4F4F4",c.getElementsByTagName("td")[1].childNodes[0].style.visibility="visible",c.getElementsByTagName("th")[0].childNodes[0].style.backgroundPosition=24*-b+"px -32px";this.Uf.length> b&&(this.Uf[b].Vb(new nd(I.HG,I.QP,{offset:I.PP,imageOffset:new M(-I.NP*b,-I.OP),infoWindowOffset:I.GG})),this.JJ(this.Uf[b],o,o))},_lstMouseOver:function(a,b,c,d){a=this.k.ja.map;this.li!=d&&(a.Wc(),this.WB(c,d))},_lstMouseOut:function(a,b,c,d){this.li!=d&&this.Cw(c,d)},Cw:function(a,b){var c=p;x.$("RA_ResItem_"+a)&&(c=x.$("RA_ResItem_"+a).childNodes[0]);c&&(c=c.rows[b],c.style.backgroundColor="#ffffff",c.getElementsByTagName("td")[1].childNodes[0].style.visibility="",c.getElementsByTagName("th")[0].childNodes[0].style.backgroundPosition= 24*-b+"px -64px");this.Uf.length>b&&(this.Uf[b].Vb(new nd(I.HG,I.KG,{offset:I.p1,imageOffset:new M(-I.JG*b,-I.IG),infoWindowOffset:I.o1})),this.JJ(this.Uf[b],q))},JJ:function(a,b,c){a&&a.Ei&&(b&&!a.HI&&a.Yc&&a.Yc.style?(a.HI=o,c?a.Ei(o,1000100):a.Ei(o)):!b&&(a.Yc&&a.Yc.style)&&(delete a.HI,a.Ei(q)))},select:function(a,b,c){if(2<arguments.length&&(c=c||window.c3,"selBtn"==(c.srcElement||c.target).className))return;var d=this.qi(a);this.map.Wc();d&&(this.cq[0]!=this.cq[1]&&this.zg&&this.map&&this.map.Dh(this.ln), this.bV(d,a,b),-1!=this.li&&this.Cw(a,this.li),this.li=b%10,this.WB(a,this.li))},NC:function(){var a=this;(function c(){0!==a.Uf.length&&(a.map.Ub(a.Uf.shift()),c())})();(function d(){0!==a.ln.length&&(a.ln.shift(),d())})()},itmSelect:function(a,b){var c=this.map,d=this.qi(a);this.Ma[a].n=d[b].name;this.Ma[a].c=this.cq[a];this.Ma[a].u=d[b].uid;var e=T.tb(Q.kb(d[b].geo_base64||d[b].geo,o).point);this.Ma[a].x=e.lng;this.Ma[a].y=e.lat;this.Ma[a].t=d[b].poiType;x.$("B_PointName"+a)&&(x.$("B_PointName"+ a).innerHTML=d[b].name);this.zg=this.oK(c,e,d[b].name,a);0!=a&&a!=this.fe&&(this.Ju[a-1].Ty=d[b].name);this.NC();if(this.cZ())this.zg&&(c.Ub(this.zg),this.zg=p),this.submit();else{x.$("RouteAddress_DIV"+a)&&(x.$("RouteAddress_DIV"+a).className="sel_y");for(c=0;1<=this.fe;){c=(a+1)%(this.fe+1);x.$("RouteAddress_DIV"+c)&&x.$("RouteAddress_DIV"+c);break}if(0==this.dq[c]){x.$("RouteAddress_DIV"+c)&&(x.$("RouteAddress_DIV"+c).className="sel_n");var d=this.Js[c],e=10*(d-1)+9,f=this.qi(c);f.length<e+1&& (e=f.length-1);this.Uo(c,[10*(d-1),e]);this.select(c,0)}else 2==this.dq[c]?x.$("RouteAddress_DIV"+c)&&(x.$("RouteAddress_DIV"+c).className="sel_n"):x.$("RouteAddress_DIV"+c)&&(x.$("RouteAddress_DIV"+c).className="sel_x");this.jj=c}},submit:function(){var a=this.map,b=this.Ma[0].c,c=this.Ma[this.fe].c;if(b==c)var d=b;var e={},f=new N("onpoiselected");if(13==this.cc.result.type||23==this.cc.result.type||24==this.cc.result.type)23==this.cc.result.type&&b!=c?(e.c=d||this.cc.current_city.code,e.sc=b,e.ec= c,e.sn="1$$$$"+this.Ma[0].x+","+this.Ma[0].y+"$$"+this.Ma[0].n+"$$$$$$",e.en="1$$$$"+this.Ma[1].x+","+this.Ma[1].y+"$$"+this.Ma[1].o+"$$$$$$"):(e.c=d||this.cc.current_city.code,e.sc=b,e.ec=c,e.sn="1$$"+this.Ma[0].u+"$$"+this.Ma[0].x+","+this.Ma[0].y+"$$"+this.Ma[0].n+"$$$$$$",e.en="1$$"+this.Ma[1].u+"$$"+this.Ma[1].x+","+this.Ma[1].y+"$$"+this.Ma[1].n+"$$$$$$");else{for(var g=d="",i=this.fe,j=0,l=this.Ju.length;j<l;j++)d+=this.by(this.Ju[j]),g+=this.Ma[j+1].c+"+to:";e.sc=b;e.ec=g+c;e.sn="1$$$$"+this.Ma[0].x+ ","+this.Ma[0].y+"$$"+this.Ma[0].n+"$$$$$$";e.en=d+"1$$$$"+this.Ma[i].x+","+this.Ma[i].y+"$$"+this.Ma[i].n+"$$$$$$"}e.sq=this.pz;e.eq=this.Gx;f.paramInfo=e;f.sType=this.Zy;a.dispatchEvent(f)},by:function(a,b){var c=2,d="",e="",f="",g="0",i="";if(a.point||a.jO)c=1,e=a.point?a.point.lng+","+a.point.lat:a.jO.lng+","+a.jO.lat,a.uid&&(c=2,d=a.uid);a.Ty&&(f=a.Ty);a.As&&(g="1",i=a.As);isNaN(b)||(c=b);return c+"$$"+d+"$$"+e+"$$"+f+"$$"+g+"$$"+i+"$$$$1$$+to:"},cZ:function(){for(var a=0;a<=this.fe;a++)if(""== this.Ma[a].n&&!this.Ma[a].x&&!this.Ma[a].y||this.Ma[a].n==k)return q;return o},_selBtnOver:function(a){a.style.backgroundPosition="-100px -81px"},_selBtnOut:function(a){a.style.backgroundPosition="-21px -81px"},_selBtnDown:function(a){a.style.backgroundPosition="-220px -81px";a.style.fontWeight="bold"},ra:function(){var a=this,b=this.fe;this.KO(this.cc);a.GO();for(var c=0;c<=b;c++)x.$("RADiv_PAGE"+c)&&(pg0=new se("RADiv_PAGE"+c,function(b){var c=a.jj,d=[10*(b-1),10*b-1];a.iu[c]<d[1]+1&&(d[1]=a.iu[c]- 1);x.K.remove=function(a){var a=x.$(a),b=a.parentNode;b&&b.removeChild(a)};x.$("RA_ResItem_"+c)&&(x.K.remove(x.$("RA_ResItem_"+c)),ka.K.my(x.$("RADiv_ResItem"+c),"AFTERBEGIN",a.qN(c,d)));a.Uo(c,d,o);x.$("RADiv_ResItem"+c).scrollTop=0;a.Js[c]=b},{Wf:5,Md:a.lP[c],page:a.Js[d]}));var d=[0,9],c=this.jj,e=ka.Ec("RouteAddress_DIV"+c),f=this.qi(c);"sel_n"==e.className?this.cc.content&&(this.cc.result.city_list&&1!=this.cc.result.city_list[c]&&f&&0<f.length)&&(f.length<d[1]+1&&(d[1]=f.length-1),a.Uo(c,d), a.select(c,0)):this.zg&&"sel_x"==e.className&&this.map.Dh(this.iF);for(var d=0;d<=b;d++)"sel_y"==x.$("RouteAddress_DIV"+d).className&&(c=this.qi(d),0<c.length&&(c[0].JE&&1==c[0].JE)&&(ka.d5(ka.Ec("RD_TOP_BUT"+d),"sel_body_button"),x.$("RD_TOP_BUT"+d).innerHTML=""))},LP:function(){var a=this.fe;this.KO(this.cc);this.GO();for(var b=0;b<=a;b++){var c=this.jj,d=[0,9];this.iu[c]<d[1]+1&&(d[1]=this.iu[c]-1);this.Uo(c,d,o)}a=[0,9];b=this.jj;ka.Ec("RouteAddress_DIV"+b);c=this.qi(b);1==b?this.cc.content&& (this.cc.result.city_list&&1!=this.cc.result.city_list[b]&&c&&0<c.length)&&(c.length<a[1]+1&&(a[1]=c.length-1),this.Uo(b,a)):this.zg&&0==b&&this.map&&this.map.Dh(this.iF);this.select(b,0)},KO:function(a){var b=this.map;if(a.OW&&!(a.result.i5&1)&&(29==a.result.type||13==a.result.type)){var a=a.OW,c=["country","province","city","area"],c=a.type!=p?modelConfig.wg[c[a.type]]:k,a=a.Jd!=p?a=Q.kb(a.Jd,o).point:k;b.oX?(c&&b.Jg(c),a&&b.Xf(a)):(b.oX=o,b.Gd(a||b.wc(),c||b.ga()))}},GO:function(){this.cq=this.Hu; for(var a=0;a<=this.fe;a++)0<this.cc.result.count[a]?0==this.cc.result.city_list[a]?(this.dq[a]=1==this.cc.result.prio_flag[a]?1:0,this.iu[a]=this.cc.result.count[a]):this.dq[a]=2:this.dq[a]=3},Uo:function(a,b){var c=this,d=this.qi(a),e=c.map;c.NC();if(d){for(var f=b[0];f<=b[1];f++){var g=Q.kb(d[f].geo_base64||d[f].geo,o);c.Uf.push(X.FV(g.ha[0],f-b[0],d[f].name,e));c.ln.push(g.ha[0])}d=c.ln;c.zg&&c.cq[0]==c.cq[1]&&d.push(c.zg.point);if(this.map.oa()==Ra){var g=Vd[Ra].K2[e.Sb][1],i=getPointsBounds(d), j=e.Dt(i).zoom;g.Mt(i)?(15>=j&&(j=15),e.Gd(d[0],j)):e&&e.Dh(d)}else e&&e.Dh(d);11==c.ln.length&&c.ln.pop();for(var l=this.Uf,f=b[0];f<=b[1];f++)(function(){var d=f;l[f-b[0]]&&(l[f-b[0]].addEventListener("click",function(){c.select(a,d)}),l[f-b[0]].addEventListener("mouseover",function(){var b=d%10;c.li!=b&&c.WB(a,b)}),l[f-b[0]].addEventListener("mouseout",function(){var b=d%10;c.li!=b&&c.Cw(a,b)}))})()}},bV:function(a,b,c){var d=this,e=a[c],a="<span class=\'iw_poi_title\' title=\'"+e.name+"\'>"+e.name+ "</span>",f=[],g="";e.addr&&""!=e.addr&&(0==e.poiType?g="\\u5730\\u5740: "+e.addr:1==e.poiType?g="\\u9014\\u7ecf\\u516c\\u4ea4\\u8f66\\uff1a"+e.addr.split(";").join("; "):3==e.poiType&&(g="\\u9014\\u7ecf\\u5730\\u94c1\\uff1a"+e.addr.split(";").join("; ")));f.push("<div style=\'padding:11px 11px 6px 11px;line-height:20px;word-break:break-all\'>"+g+"</div>");f.push("<div style=\'line-height:180%;margin-bottom:10px;\'>");e="\\u9009\\u4e3a\\u9014\\u7ecf\\u70b9";0==b&&(e="\\u9009\\u4e3a\\u8d77\\u70b9");b==this.fe&&(e="\\u9009\\u4e3a\\u7ec8\\u70b9"); f.push("<div style=\'text-align:center;\'><div id=\'selInfoWndBtn\' class=\'selInfoWndBtn\' data-uid = \'"+b+"_"+c+"\' />"+e+"</div>");f.push("</div>");this.Bb?(this.Bb.Dc(a),this.Bb.ad(f.join(""))):(this.Bb=new td(f.join(""),{title:a,height:0,width:280,margin:[0,0,0,0]}),this.Bb.addEventListener("open",function(){var a=x.$("selInfoWndBtn");x.M(a,"click",function(){var b=a.getAttribute("data-uid").split("_");d.itmSelect(b[0],b[1])});x.M(a,"mouseover",function(){d._selBtnOver(a)});x.M(a,"mousedown",function(){d._selBtnDown(a)}); x.M(a,"mouseout",function(){d._selBtnOut(a)})}),this.Bb.addEventListener("close",function(){d.Cw(b,i)}));var i=c%10;this.Uf&&this.Uf[i]&&this.Uf[i].Mb(this.Bb)},NX:function(a){a==k&&(a=this.jj);return 0==a?this.pz:a==this.fe?this.Gx:this.nP[a-1]},Fb:function(a,b){for(var c=0,d=a.length;c<d;c++)b(c,a[c])}});ue.aI=function(a,b,c){var d="";0===c&&(d+=";border-top:1px solid #e4e6e7");var e="nav-ed";0===c&&(e="nav-st");c=["<div style=\'"+d+"\'><div style=\'cursor:pointer;padding:8px 0 8px 10px;line-height:15px\'"];c.push("onclick=\'"+b+"\'>");c.push("<span class=\'navtrans-navlist-icon "+e+"\'></span>");c.push("<div style=\'overflow:hidden;line-height:20px;\'>"+a);c.push("</div></div></div>");return c.join("")}; ue.$H=function(a,b,c){return\'<h1 style="margin:0;border-top:1px solid #e4e6e7;\'+(c?"border-bottom:1px solid #e4e6e7;padding:10px 0 10px 7px;":"padding:10px 0 9px 7px;")+"font:bold 16px "+I.fontFamily+\'"> \'+b+"\\u524d\\u5f80 "+a+" \\u7684\\u8def\\u7ebf</h1>"}; x.extend(ue.prototype,{search:function(a,b){return!a||!b?(this.Qe(),this.sb(5),this.Ra(Y.Tc),q):o},Qe:function(){delete this.ka;delete this.fa;delete this.Ha;delete this.Wq;delete this.Vl;var a=this.k.ja;this.sb();a.Ia&&(a.Ia.innerHTML="");a.map&&a.map.Wc();this.Sj();this.lb=-1},bf:function(a,b){var c,b=b||{};"string"===typeof a?c=[2,"","",a,0,""]:a instanceof O||a instanceof K?(c=T.tb(a),c=[1,"",c.lng+","+c.lat,b.T5||"",0,""]):(c=T.tb(a.point),c=[1,""+a.uid,c.lng+","+c.lat,a.title,0,""]);return c.join("$$")+ "$$"},Qh:function(a,b){var c;"string"===typeof a?c=a:(c=a instanceof O||a instanceof K?a:a.point,c=c.lat+","+c.lng);"string"!==typeof a&&(b&&""!==b&&"string"===typeof b)&&(c="name:"+b+"|latlng:"+c);return c},by:function(a){return this.bf(a)+"$$1$$"},a2:function(){var a;"string"===typeof dest?a=dest:(a=dest instanceof O||dest instanceof K?dest:dest.point,a=a.lat+","+a.lng);return a}});var Di=0,Ei=1; function si(a){"string"===typeof a&&(a=parseFloat(a));a=!a||0>a?"0\\u7c73":10>=a?"10\\u7c73":1E3>a?10*Math.round(a/10)+"\\u7c73":(a/1E3).toFixed(1)+"\\u516c\\u91cc";"1000\\u7c73"===a&&(a="1.0\\u516c\\u91cc");return a} function ti(a,b){if(!a||isNaN(a))return"";var c="",d=Math.ceil(a/60);if("bustime"===b)var e=d%10,f=parseInt(d/10,10),d=0!==e?5<e?10*++f:f?10*f:5:d;e=parseInt(d/1440,10);d%=1440;f=parseInt(d/60,10);d%=60;1<=e&&(c+=e+"\\u5929");1<=f&&(c+=f+"\\u5c0f\\u65f6");if(1<=d&&(!b||!("nav"===b&&1<=e)))c+=d+"\\u5206\\u949f";return c}U(rg,{clearResults:rg.Qe});x.extend(ve.prototype,{Td:function(){for(var a=0,b=this.Pa.length;a<b;a++){var c=this.Pa[a];this[c.method].apply(this,c.arguments)}delete this.Pa;var d=this;this.k.ja.map&&this.k.ja.map.addEventListener("onpoiselected",function(a){d.FF(a)})},gB:function(a,b){function c(a){var a=a.split("$$"),b=a[0],c=p;/[0-2]/.test(b)&&7===a.length&&(c=a[+b+1]);return c}var d=this;this.Pg(this.Ad,function(e){e={qt:d.xd,c:e,sn:a,g3:b,sy:d.k.$c||0,ext:1};4===e.sy&&(e.f="[0,2,4,7,5,8,9,10,11]");var f=c(a),g=c(b);de.eb(function(a, b){d.Lf(a,b)},e,{start:f,end:g})})},search:function(a,b){if(ue.prototype.search.call(this,a,b)===o){var c=this;this.Pg(this.Ad,function(d){d||(this.sb(5),this.Ra(Y.Tc));var e;"object"===typeof a&&"string"===typeof b||"string"===typeof a&&"object"===typeof b?"string"===typeof a?e={qt:"bse",c:d,isSingle:o,wd:a,en:c.bf(b),sy:c.k.$c||0,ex:1}:"string"===typeof b&&(e={qt:"bse",c:d,isSingle:o,wd:b,sn:c.bf(a),sy:c.k.$c||0,ex:1}):e={qt:c.xd,c:d,sn:c.bf(a),en:c.bf(b),sy:c.k.$c||0,ex:1};4===e.sy&&(e.f="[0,2,4,7,5,8,9,10,11]"); de.eb(function(a,b){c.Lf(a,b)},e,{start:a,end:b,ZH:"search"})})}},FF:function(a){if(a.sType===this.xd){a=a.paramInfo;a.qt=this.xd;var b=this;a.sy=b.k.$c||0;var c={start:a.sq,end:a.eq,ZH:"preciseSearch"};this.k.fd&&(c.qO=B.Rp+"mobile/webapp/interface/wiseBus/",c.ft=o);de.eb(function(a){b.Lf(a,c)},a,c)}},Lf:function(a,b){var c=this.k.ja.map;this.Qe();this.Ha=a;var d=a.result;this.fa=b;if(0!==d.error||d.type!==this.bv||!a.content)23===d.type&&this.k.ja.map?(c=new Ae(a,{ja:this.k.ja,Zy:this.xd}),d=H("div", {style:"font:12px "+I.fontFamily+";background:#fff"}),d.innerHTML=c.va(),this.k.ja.Ia?(this.k.ja.Ia.appendChild(d),c.ra()):c.LP(),c.BC()):(this.ka=new pi({city:a.current_city.name,eu:[],$c:d.sy,VO:k,DL:k}),this.sb(3),this.Ra(Y.Tc,this.ka));else if(this.k.fd&&"search"===b.ZH){var e=new N("onpoiselected"),f={};f.qt=this.xd;f.sy=this.k.$c||0;f.sq=b.start;f.eq=b.end;f.sn=d.sn?d.sn:this.bf(d.start.wd);f.en=d.en?d.en:this.bf(d.end.wd);f.c=d.c;e.paramInfo=f;e.sType=this.xd;c.dispatchEvent(e)}else this.Sl(), this.Tl(),this._selectPlan(0)},eT:function(a,b){var c=ge;0===b&&(c=0<a?2:1);return c},Sl:function(){var a=this.Ha.result,b=this.Ha.content,c=this.Ha.current_city,d={},e={};if("object"===typeof this.fa.start&&!(this.fa.start instanceof O||this.fa.start instanceof K))x.extend(d,this.fa.start);else{d.title=a.start.wd||"\\u8d77\\u70b9";d.uid=a.start.uid;d.url=Y.Rh(d.uid,c.code);if(this.k.fd){var f=a.start.pt.split(",");d.point=T.ub(new K(parseFloat(f[0]),parseFloat(f[1])))}else d.point=Q.kb(a.start.pt, o).point;d.city=c.name}"object"===typeof this.fa.end&&!(this.fa.end instanceof O||this.fa.end instanceof K)?x.extend(e,this.fa.end):(e.title=a.end.wd||"\\u7ec8\\u70b9",e.uid=a.end.uid,e.url=Y.Rh(e.uid,c.code),this.k.fd?(f=a.end.pt.split(","),e.point=T.ub(new K(parseFloat(f[0]),parseFloat(f[1])))):e.point=Q.kb(a.end.pt,o).point,e.city=c.name);var f=[],g=0;this.Wq=[];for(var i=0;i<b.length&&!(g>this.k.Pk-1);i++)for(var j=0,l=b[i]&&b[i].stops&&b[i].stops.length;j<l&&!(g>this.k.Pk-1);j++){this.Wq[g]=[]; for(var m=b[i].stops[j],n=b[i].lines[j],s=0,u=0,w=n.length;u<w;u++)"object"===typeof n[u]&&s++;for(var s=n[s+1],u=[],w=[],y=0,D="<table class=\'trans-plan-content\'>",C=0;C<m.length-1&&n[C].geo;C++){var F=m[C].getOn,F={title:F.name,uid:F.uid,url:Y.Rh(F.uid,c.code),city:c.name,point:Q.kb(F.geo,o).point},A=m[C+1].getOff,A={title:A.name,uid:A.uid,url:Y.Rh(A.uid,c.code),city:c.name,point:Q.kb(A.geo,o).point},z=[];if(0===C)0<m[C].walk.distance&&m[C].walk.geo&&(z=Q.kb(m[C].walk.geo,o).ha.concat(F.point)); else if(0<m[C].walk.distance&&m[C].walk.geo)var z=Q.kb(m[C].getOff.geo,o).point,E=Q.kb(m[C].getOn.geo,o).point,z=[z].concat(Q.kb(m[C].walk.geo,o).ha).concat(E);w.push(new xi({od:m[C].walk.distance,ha:z.slice(0),Yy:ee,index:C,yF:i}));y+=m[C].walk.distance;C===m.length-2&&(0<m[C+1].walk.distance&&m[C+1].walk.geo&&(z=[A.point].concat(Q.kb(m[C+1].walk.geo,o).ha)),w.push(new xi({od:m[C+1].walk.distance,ha:z.slice(0),Yy:ee,index:C+1,yF:i})),y+=m[C+1].walk.distance);z=Q.kb(n[C].geo,o);E=[];if(this.k.fd&& n[C].link_color&&0<n[C].link_color.length)for(var G=0,P=0,S=n[C].link_color,aa=S.length;G<aa;G++){var ba=S[G],ia=ba.status,Sa=z.ha.slice(P,P+ba.geo_cnt+1);E.push({ha:Sa,status:ia});P+=ba.geo_cnt}u.push(new zi({title:n[C].name,uid:n[C].uid,od:n[C].distance,ha:z.ha,status:E,h0:[F,A],type:this.RS(n[C].type),JZ:n[C].station_num}));E=z.$a;z=E.xe();E=E.pf();z=[z,E];this.Wq[g].push(z[0],z[1]);y+=n[C].distance;m[C].walk.distance&&(D+="<tr><td><span class=\'navtrans-bus-icon walk\'><span class=\'bmap-link\'></span></span><div class=\'navtrans-bus-desc\'>\\u6b65\\u884c\\u7ea6"+ si(m[C].walk.distance)+"\\uff0c\\u5230\\u8fbe<span class=\'navtrans-busstation\'>"+F.title+"</span></div></td></tr>");D+="<tr><td><span class=\'navtrans-bus-icon bus\'><span class=\'bmap-link\'></span></span><div class=\'navtrans-bus-desc\'>\\u4e58\\u5750<span class=\'navtrans-busstation\'>"+this.ZU(n[C].name)+"</span>\\uff0c\\u7ecf\\u8fc7"+n[C].station_num+"\\u7ad9\\uff0c\\u5230\\u8fbe<span class=\'navtrans-busstation\'>"+A.title+"</span></div></td></tr>";C<m.length-2?D+="":m[C+1].walk.distance&&(D+="<tr><td><span class=\'navtrans-bus-icon walk\'></span><div class=\'navtrans-bus-desc\'>\\u6b65\\u884c\\u7ea6"+ si(m[C+1].walk.distance)+"\\uff0c\\u5230\\u8fbe<span class=\'navtrans-busstation\'>"+m[C+1].getOn.name+"</span></div></td></tr>")}D+="</table>";if(0===y)break;f.push(new vi({PF:w,od:y,duration:s,rZ:u,description:D}));g++}b=B.jc+"direction?"+Jb({region:c.name,origin:this.Qh(this.fa.start,this.fa.start.title?this.fa.start.title:this.fa.start),destination:this.Qh(this.fa.end,this.fa.end.title?this.fa.end.title:this.fa.end)})+"&output=html&mode=transit&src=baidu_map_jsapi";this.ka=new pi({city:c.name,eu:f, start:d,end:e,url:b,$c:a.sy});this.sb(0);this.Ra(Y.Tc,this.ka)},AU:function(a){var b=this.k.ja.map,c=[],d=this;if(b){var e=this.ka.rf(a);if(e){var f=this.ka.vj(),g=this.ka.lh(),i=X.So(b,f.point,f.title,Di);f.marker=i;i.addEventListener("click",function(){d._select(0)});this.wa.push(i);i=X.So(b,g.point,g.title,Ei);g.marker=i;this.wa.push(i);i.addEventListener("click",function(){d._selectLast()});this.Wq[a].push(f.point,g.point);for(var j=0,i=e.Vx();j<i;j++){var l=e.rE(j),m=X.To(b,l.ve()),n=[];if(this.k.fd&& 0<l.Dd.length){for(var s=0,u=l.Dd.length;s<u;s++){var w=l.Dd[s];w.status&&(w=X.qK(b,w.ha,w.status),n.push(w),this.wa.push(w))}l.h2=n}l.Zi=m;this.wa.push(m);m=l.oE();c.push(m);var y=X.sK(b,m.point,l.type,m.title);m.marker=y;this.wa.push(y);m=l.nE();c.push(m);var D=X.sK(b,m.point,l.type,m.title);m.marker=D;(function(){var a=j;y.addEventListener("click",function(){d._select(2*(a+1)-1)});D.addEventListener("click",function(){d._select(2*(a+1))})})();this.wa.push(D);l=e.nh(j);0<l.Ue(q)&&(m=X.fm(b,l.ve(), l.zp()),l.Zi=m,this.wa.push(m))}l=e.nh(j);m=X.fm(b,l.ve(),l.zp());l.Zi=m;this.wa.push(m);d=this;this.k.ja.bh&&b.Dh(this.Wq[a],{margins:[30,30,30,30]});this.Ra(Y.Xu,e.Xi,e.lk);this.Ra(Y.zq,[f,g],c)}}},Tl:function(){if(this.k.ja.Ia&&this.k.ja.Ia.appendChild&&this.ka&&0<this.ka.Wx()){for(var a=H("div",{style:"font:12px "+I.fontFamily+";background:#fff"}),b=ue.$H(this.ka.lh().title,"\\u4e58\\u516c\\u5171\\u4ea4\\u901a\\u5de5\\u5177"),c=this.bI(this.ka.vj().title,\'Instance("\'+this.ba+\'")["_select"](0)\',0),d= this.bI(this.ka.lh().title,\'Instance("\'+this.ba+\'")["_selectLast"]()\',1),e=["<table style=\'font:12px "+I.fontFamily+";border-collapse:collapse;width:100%;\' cellpadding=\'0\' cellspacing=\'0\' border=\'0\'>"],f=0,g=this.ka.Wx();f<g;f++){var i=this.ka.rf(f),j=i.Ue().replace(/(\\d+(?:.\\d+)?)/,"$1 "),l=i.ut().replace(/(\\d+)/,"$1 "),m=i.GY();bg="";var n="<p style=\'margin:0px 0px 5px 0px;font-size:14px;color: #36c;\'>"+i.aY()+"</p>",j="<p style=\'margin:5px 0px;font-size:12px;\'>"+j+" &nbsp;|&nbsp; "+l+" &nbsp;|&nbsp; \\u6b65\\u884c"+ m+"</p>";e.push("<tr class=\'tranroute-plan-list\' style=\\"cursor:pointer"+bg+\'" onclick=\\\'Instance("\'+this.ba+\'")._selectPlan(\'+f+")\'>");e.push("<td style=\'vertical-align:top;line-height:18px\' ><div style=\'margin:3px 0px;border:1px solid #e4e6e7;\'><div class=\'trans-title\' style=\'padding: 5px 10px;\'>"+n+j+"</div><div class=\'trans_plan_desc\' style=\'padding:0px 8px;margin:0px;display:none;position:relative;\'>"+c+i.kh()+d+"</div></div></td>");e.push("</tr>")}e.push("</table>");c="<div style=\'border-bottom:1px solid #ccc;margin-bottom:10px;color:#7777cc;background:#e5ecf9;overflow:hidden;padding:2px;text-align:right\'>"; this.ka.moreResultsUrl&&(c+="<a style=\'color:#7777cc\' href=\'"+this.ka.moreResultsUrl+"\' target=\'_blank\'>\\u5230\\u767e\\u5ea6\\u5730\\u56fe\\u67e5\\u770b&#187;</a>");a.innerHTML=b+e.join("")+(c+"&nbsp;</div>");this.k.ja.Ia.appendChild(a);this.Ra(Y.Yu,a)}},_select:function(a,b){var c=this.k.ja.map;if(c){var b=b||window.event,d=this.ka.rf(this.lb);if(d){var e=this,f=2*d.Vx();if(0===a||a===f+1){var g=0===a?this.ka.vj():this.ka.lh(),i=X.qx({content:"<b>"+g.title+"</b>",total:f,ux:a,Hy:function(a){e._select(a)}}); i.addEventListener("open",function(){e.Ra(Y.Tn,g,X.vt(c))});var j=0===a?0:1,e=this;c.B.Dm?ef.Ip(i,c.getCurrentCity().code,{panoInstance:c.P,lngLat:g.point,titleTip:g.title,type:"busline",beforeDomId:"trans_nav"},function(){e.wa[j].Mb(i)}):e.wa[j].Mb(i)}else{var d=d.rE(Math.floor((a+1)/2)-1),l,m=d.Ap();1===a%2?(l=d.oE(),d=m+"<b>"+l.title+"\\u7ad9\\u4e0a\\u8f66</b>"):(l=d.nE(),d=m+"<b>"+l.title+"\\u7ad9\\u4e0b\\u8f66</b>");i=X.qx({content:d,total:f,ux:a,Hy:function(a){e._select(a)}});i.addEventListener("open", function(){e.Ra(Y.Tn,l,X.vt(c))});e=this;c.B.Dm?ef.Ip(i,c.getCurrentCity().code,{panoInstance:c.P,lngLat:l.point,titleTip:l.title,type:"busline",beforeDomId:"trans_nav"},function(){l.marker.Mb(i)}):l.marker.Mb(i)}oa(b)}}},_selectLast:function(a){a=a||window.event;if(this.ka&&-1<this.lb){var b=this.ka.rf(this.lb);if(!b)return;this._select(2*b.Vx()+1)}oa(a)},_selectPlan:function(a){if(this.ka||this.k2.rf(a)){this.ka.rf(a);var b=this.k.ja.map;b&&(b.Wc(),this.Sj(),this.AU(a));if(this.k.ja.Ia){var c=this.k.ja.Ia.getElementsByTagName("table")[0]; if(!c)return;for(var b=x.getElementsByClassName(c,"tranroute-plan-list"),c=x.getElementsByClassName(c,"trans_plan_desc"),d=0;d<c.length;d++)d!==a&&(c[d].style.display="none");for(c=0;c<b.length;c++)x.Tb(b[c],"expand");c=x.getElementsByClassName(b[a],"trans_plan_desc")[0];"none"===c.style.display?(c.style.display="block",x.Ta(b[a],"expand")):c.style.display="none"}this.lb=a}},Sj:function(){for(var a=0;a<this.wa.length;a++)this.wa[a]&&this.wa[a].EB&&(this.wa[a].EB.remove(),this.wa[a].EB=p),this.wa[a]&& this.wa[a].remove(),this.wa[a]=p;this.wa.length=0},RS:function(a){return ve.cQ[a]},bI:function(a,b,c){var d="";0===c&&(d+="padding-top:5px;");var e="nav-ed";0===c&&(e="nav-st");c=["<div style=\'"+d+"\'><div style=\'cursor:pointer;padding:2px 0 2px 0px;line-height:15px\'"];c.push("onclick=\'"+b+"\'>");c.push("<span class=\'navtrans-navlist-icon "+e+"\'></span>");c.push("<div style=\'overflow:hidden;line-height:20px;\'>"+a);c.push("</div></div></div>");return c.join("")}});we=ve.prototype;U(we,{_internalSearch:we.gB});xe.fQ=20;xe.$P=50;xe.ZP=10; x.extend(xe.prototype,{QE:function(){this.aa={Yp:[],Jb:[],Ii:[],fh:[],ne:p,sd:p,tD:q,bx:p,$o:p,RM:q,tx:p,uD:1,sD:1,LK:"\\u8d77\\u70b9",KK:"\\u7ec8\\u70b9",Ey:q,Qs:[]}},Td:function(){this.QE();for(var a=0,b=this.Pa.length;a<b;a++){var c=this.Pa[a];this[c.method].apply(this,c.arguments)}delete this.Pa;var d=this;this.k.ja.map&&this.k.ja.map.addEventListener("onpoiselected",function(a){d.FF(a)})},search:function(a,b,c){this.aa.RM=q;var c=c||{},d=c.waypoints;"[object Array]"==Object.prototype.toString.call(d)||(d= []);this.JP=d;if(ue.prototype.search.call(this,a,b)===o){var e=this;this.Pg(this.Ad,function(f){var f=f||1,g;if(("object"===typeof a&&"string"===typeof b||"string"===typeof a&&"object"===typeof b)&&0===d.length&&!e.k.fd)"string"===typeof a?g={qt:"nse",c:f,isSingle:o,wd:a,en:e.bf(b),sy:e.k.$c||0}:"string"===typeof b&&(g={qt:"nse",c:f,isSingle:o,wd:b,sn:e.bf(a),sy:e.k.$c||0}),this.xd=e.k.fd?e.xd:"nse",f={start:a,end:b,ft:e.k.fd};else{var i=e.bf(a);en="";if(0<d.length){for(var j=0;j<d.length;j++)en+= e.by(d[j])+"+to:";en+=e.bf(b)}else en=e.bf(b);g={qt:e.xd,c:f,sn:i,en:en,sy:e.k.$c||0};f={start:i,end:en,ft:e.k.fd}}0<d.length&&(f.vP=o);c.startCity&&(g.sc=c.startCity);if(c.endCity){i="";if(0<d.length){for(j=0;j<d.length;j++)i+=c.endCity+"+to:";i+=c.endCity}else i=c.endCity;g.ec=i}e.k.fd&&(g.route_traffic=1,g.version=4,g.mrs=0<e.JP.length?0:1);de.eb(function(a,b){e.Lf(a,b)},g,f)})}},zA:function(a,b){var c=this;c.aa.RM=o;c.Pg(c.Ad,function(d){for(var d=d||1,e=T.tb(c.aa.Jb[0]),e="1$$$$"+e.lng+","+e.lat+ "$$$$",f=c.aa.uD||d,g="",i="",j=1,l=c.aa.Jb.length;j<l;j++){var m=c.aa.Jb[j];j===l-1?(g+=c.bf(m),i+=c.aa.sD||d):(g=m.zj?g+(c.by(m)+"+to:"):g+(c.bf(m)+"+to:"),i+="0 +to:")}d={qt:c.xd,c:d,drag:1,sc:f,ec:i,sn:e,en:g,sy:c.k.$c||0};c.k.fd&&(d.route_traffic=1,d.version=4,d.mrs=0);e={start:a,end:b,ft:c.k.fd};x.extend(e,{vP:o});de.eb(function(a,b){c.Lf(a,b)},d,e)})},FF:function(a){var b=this;if(a.sType===this.xd){a=a.paramInfo;a.qt=this.xd;var b=this,c={start:a.sq,end:a.eq,ft:b.k.fd};a.sy=b.k.$c||0;b.k.fd&& (a.route_traffic=1,a.version=4,a.mrs=0<b.JP.length?0:1);de.eb(function(a){b.Lf(a,c)},a,c)}},Lf:function(a,b){this.Qe();this.Ha=a;var c=a.result;this.fa=b;if(0!==c.error||c.type!==this.bv)if(23===c.type||19===c.type){var c=new Ae(a,{ja:this.k.ja,Zy:this.xd}),d=H("div",{style:"font:12px "+I.fontFamily+";background:#fff"});d.innerHTML=c.va(b);this.k.ja.Ia?(this.k.ja.Ia.appendChild(d),c.ra()):c.LP()}else this.ka=this.wv({city:a.current_city.name,eu:[],$c:c.sy,VO:k,DL:k}),this.sb(3),this.Ra(Y.Tc,this.ka); else this.k.fd?this.uU():this.Sl(),this.zU(),this.Tl()},eT:function(a,b){var c=ge;0===b&&(c=0<a?2:1);return c},hC:function(){this.aa.sd&&this.aa.sd.nD();for(var a=0,b=this.aa.fh.length;a<b;a++){var c=this.aa.fh[a];c instanceof W&&c.nD()}},uU:function(){var a=this.Ha.result,b=this.Ha.content,c=this.Ha.current_city,d=a.waypoints,e=b.taxis&&b.taxis[0]&&b.taxis[0].total_price||0,f=[],g=[],i=0,j=0,l=b.routes[0].legs,m=b.steps,n=b.stepts,s=[],u=[];this.Vl=[];var w=this.aa.Ii.slice(0);this.aa.Ii.length= 0;var y={},D={},C=[],b=[],F=[],A=[];if("object"===typeof this.fa.start&&!(this.fa.start instanceof O||this.fa.start instanceof K))x.extend(y,this.fa.start);else{y.title=a.start.wd||"\\u8d77\\u70b9";y.uid=a.start.uid;y.url=Y.Rh(y.uid,a.start_city.code);var z=a.start.pt.split(",");y.point=T.ub(new K(parseFloat(z[0]),parseFloat(z[1])));y.city=a.start_city.cname}this.aa.uD=a.start_city.code;if("object"===typeof this.fa.end&&!(this.fa.end instanceof O||this.fa.end instanceof K))x.extend(D,this.fa.end);else{var E, z=a.end[a.end.length-1];E=a.end_city[a.end_city.length-1];this.aa.sD=E.code;D.title=z.wd||"\\u7ec8\\u70b9";D.uid=z.uid;"null"===D.uid&&(D.uid="");D.url=Y.Rh(z.uid,E.code);z=z.pt.split(",");D.point=T.ub(new K(parseFloat(z[0]),parseFloat(z[1])));D.city=E.cname}E=z=0;for(var G=l.length;E<G;E++){var P=l[E],i=i+P.distance,j=j+P.duration;f.push(P.distance);g.push(P.duration);for(var S=[],aa=[],ba=[],ia=[],P=P.stepis,Sa=0,Wa=P.length;Sa<Wa;Sa++){for(var Ga=P[Sa],vc=Ga.s,Ga=Ga.n,Ge=m.slice(vc,Ga+vc),If=n.slice(vc, Ga+vc),pd=0;pd<Ga;pd++){for(var Rb=Ge[pd],wc=If[pd],He=wc.end,Ie=wc.status,Wc=Q.kb(Rb.path,o).ha,qd=0,Je=[],rd=0,Jf=He.length;rd<Jf;rd++){var Ke=He[rd];Je[rd]=Wc.slice(qd,qd+Ke+1);qd+=Ke}this.Vl[z]=Wc;aa=aa.concat(Wc);ba.push(Wc);ia.push(Ie);Rb.Py=Wc;Rb.I5=wc;Rb.wG=Ie;Rb.F0=Je;z++}S=S.concat(Ge);u=u.concat(n.slice(vc,Ga+vc+1))}s.push(S);F.push(ba);A.push(ia);b.push(aa)}l=[];E=0;for(g=b.length;E<g;E++)m=new xi({Gj:s[E],od:f[E],index:E,ha:F[E],wG:A[E],Yy:this.cv}),l.push(m);E=new ri({PF:l,od:i,duration:j}); f="";i={};F=p;F=j="string";s=this.k.ja.map;if(this.fa.start instanceof O||this.fa.start instanceof K)j="point";if(this.fa.end instanceof O||this.fa.end instanceof K)F="point";"point"===j&&"string"===F||"string"===j&&"point"===F?(F="nse",s.Kd(),x.extend(i,{region:c.name,zoom:s.ga()}),"string"===j?(i.origin=this.fa.start,i.destination=this.Qh(this.fa.end,this.fa.end.title?this.fa.end.title:this.fa.end)):(i.destination=this.fa.end,i.origin=this.Qh(this.fa.start,this.fa.start.title?this.fa.start.title: this.fa.start))):(F=ie,i.region=c.name,i.origin_region=a.start_city.cname,i.destination_region=a.end_city[0].cname,i.origin=this.Qh(this.fa.start,this.fa.start.title?this.fa.start.title:this.fa.start),i.destination=this.Qh(this.fa.end,this.fa.end.title?this.fa.end.title:this.fa.end));F!==p&&(f=B.jc+"direction?"+Jb(i)+"&output=html&mode=driving&src=baidu_map_jsapi");this.ka=this.wv({city:c.name,eu:[E],start:y,end:D,url:f,$c:a.sy,bP:e});this.aa.Jb.length=0;this.aa.Yp.length=0;c=1;for(E=0;E<d.length;E++)e= d[E],f=(e.pt?e.pt:a.end[E].pt).split(","),f=T.ub(new K(parseFloat(f[0]),parseFloat(f[1]))),f.zj=e.if_wp?e.if_wp:a.end[E].pt,C.push(f),this.aa.Ii.push({title:e.wd?e.wd:w[E]&&w[E].title?w[E].title:"\\u672a\\u77e5\\u8def\\u6bb5",curNo:c,point:f}),c++;this.aa.Jb.push(y.point);E=0;for(g=C.length;E<g;E++)this.aa.Jb.push(C[E]);this.aa.Jb.push(D.point);E=0;for(g=b.length;E<g;E++)a=b[E],a.$k=E,a.oj=E+1,this.aa.Yp.push(a);this.sb(0);this.Ra(Y.Tc,this.ka)},Sl:function(){var a=this.Ha.result,b=this.Ha.content,c= this.Ha.current_city,d=b.kps,e=b.rss,f=a.waypoints,g={},i={};"object"===typeof this.fa.start&&!(this.fa.start instanceof O||this.fa.start instanceof K)?x.extend(g,this.fa.start):(g.title=a.start.wd||"\\u8d77\\u70b9",g.uid=a.start.uid,g.url=Y.Rh(g.uid,a.start_city.code),g.point=Q.kb(a.start.pt,o).point,g.city=a.start_city.cname);this.aa.uD=a.start_city.code;if("object"===typeof this.fa.end&&!(this.fa.end instanceof O||this.fa.end instanceof K))x.extend(i,this.fa.end);else{var j,l;j=a.end[a.end.length- 1];l=a.end_city[a.end_city.length-1];this.aa.sD=l.code;i.title=j.wd||"\\u7ec8\\u70b9";i.uid=j.uid;"null"===i.uid&&(i.uid="");i.url=Y.Rh(j.uid,l.code);i.point=Q.kb(j.pt,o).point;i.city=l.cname}var m=[],n=[],s=[],u=0,w=[];this.Vl=[];l=[];j=[];var y=[],D=0;this.aa.Ii.length=0;for(var C=1,F=0,A=d.length-1;F<A;F++){var z=d[F],E=d[F+1],G=e[F],P=e[F-1]||{},S=e[F+1],aa=Q.kb(z.pt,o).point,ba=Q.kb(G.g,o);ba&&(y=y.concat(ba.ha));u+=S.d;3===z.rt?(1===f[C-1].if_wp&&(aa.zj=1),l.push(aa),j.push(y.slice(0)),y=[],m.push(n.slice(0)), n=[],s.push(u),u=0,this.aa.Ii.push({title:P.n||S.n||"\\u672a\\u77e5\\u8def\\u6bb5",curNo:C,point:aa}),C++):(n.push(new Bi({point:aa,index:n.length,description:this.JS(z,G,S,F,A,P,E),od:S.d})),ba&&(this.Vl[D]=1<F?[w[w.length-1]].concat(ba.ha):ba.ha,w=w.concat(ba.ha)),D++)}0<y.length&&j.push(y);0<n.length&&m.push(n);0<u&&s.push(u);d=[];F=0;for(A=j.length;F<A;F++)e=new xi({Gj:m[F],od:s[F],index:F,ha:j[F],Yy:this.cv}),d.push(e);F=b.time;this.xd===je&&(F=Math.round(b.dis/1.35));b=new ri({PF:d,od:b.dis,duration:F, gX:this.aa.Ii});F="";A={};f=p;f=d="string";e=this.k.ja.map;if(this.fa.start instanceof O||this.fa.start instanceof K)d="point";if(this.fa.end instanceof O||this.fa.end instanceof K)f="point";"point"===d&&"string"===f||"string"===d&&"point"===f?(f="nse",e.Kd(),x.extend(A,{region:c.name,zoom:e.ga()}),"string"===d?(A.origin=this.fa.start,A.destination=this.Qh(this.fa.end,this.fa.end.title?this.fa.end.title:this.fa.end)):(A.destination=this.fa.end,A.origin=this.Qh(this.fa.start,this.fa.start.title?this.fa.start.title: this.fa.start))):(f=ie,A.region=c.name,A.origin_region=a.start_city.cname,A.destination_region=a.end_city[0].cname,A.origin=this.Qh(this.fa.start,this.fa.start.title?this.fa.start.title:this.fa.start),A.destination=this.Qh(this.fa.end,this.fa.end.title?this.fa.end.title:this.fa.end));f!==p&&(F=B.jc+"direction?"+Jb(A)+"&output=html&mode=driving&src=baidu_map_jsapi");this.ka=this.wv({city:c.name,eu:[b],start:g,end:i,url:F,$c:a.sy,bP:this.gT()});this.aa.Jb.length=0;this.aa.Yp.length=0;this.aa.Jb.push(g.point); F=0;for(A=l.length;F<A;F++)this.aa.Jb.push(l[F]);this.aa.Jb.push(i.point);F=0;for(A=j.length;F<A;F++)a=j[F],a.$k=F,a.oj=F+1,this.aa.Yp.push(a);this.sb(0);this.Ra(Y.Tc,this.ka)},dI:function(){for(var a=0,b=this.ka.rf(0),c=0,d=b.zt();c<d;c++)var e=b.nh(c),a=a+e.Xx();return a},xr:function(a){for(var b=0,c=this.ka.rf(0),d=0,e=c.zt();d<e;d++)for(var f=c.nh(d),g=0,i=f.Xx();g<i;g++){var j=f.kM(g);if(b===a)return j;b++}},JS:function(a,b,c,d,e,f,g){var i="",i=parseInt(b.d,10),j=b.poi;j&&(i-=j.pd);var i=si(i), f=this.TA(f.t,f.n),j=this.TA(b.t,b.n),l=this.TA(b.t,c.n),m=this.jI(a.dw)||"",m=a.dr?m+"<span>"+a.dr+"</span>\\uff0c":"";3===g.rt&&(m+="\\u5230\\u8fbe<span>"+this.SA(g.rt)+"</span>\\uff0c");c=j===l?"":this.cT(c.t,c.n)+"<span>"+l+"</span>";g=this.vI(a.ett||a.extt||a.tt);i=g+"<div class=\'navtrans-navlist-content\'>"+((""!==j&&f===j?"\\u7ee7\\u7eed":"")+this.dT(b.t,b.n))+j+this.SA(a.rt)+i+"\\uff0c"+this.$S(b)+this.hT(a)+m;0===d?i=g+"<div class=\'navtrans-navlist-content\'>\\u4ece\\u8d77\\u70b9\\u5411"+this.Hv(a.ett|| a.extt||a.tt)+"\\u51fa\\u53d1</div>":0<d&&d<e-1?((a=this.Hv(a.ett||a.extt||a.tt))||(a=this.Hv(1)),i=i+a+c+"</div>"):i+="\\u5230\\u8fbe\\u7ec8\\u70b9</div>";return i},yT:function(a,b,c){if(b&&c&&0<c.length)for(var d=0,e=c.length;d<e;d++){var f=a.Cc(c[d]);if(X.OX(b,f)<=xe.fQ)return o}return q},zU:function(){this.k.ja.map&&this.ka&&(this.EU(),this.BU())},BU:function(){for(var a=this.k.ja.map,b=this.ka.rf(0),c=b.nh(0),d=this.ka.vj(),e=this.ka.lh(),f=this,g=this.aa.Jb.length,i=[],j=[],l,m=0,n=this.aa.Yp.length;m< n;m++){var s=this.aa.Yp[m];l=X.fm(a,s,c.zp());b.lk[m].Zi=l;l.$k=s.$k;l.oj=s.oj;s=l.Kd();i.push(s.xe());i.push(s.pf());this.BA&&g<xe.ZP+2&&(l.addEventListener("mousemove",function(b){f.aa.Ey?f.aa.sd&&f.aa.sd.U():(f.aa.tx=this,f.aa.sd?f.yT(a,b.pixel,f.aa.Jb)?f.aa.sd.U():(f.aa.sd.show(),f.aa.sd.ta(b.point),f.aa.ne.ad("\\u62d6\\u52a8\\u4ee5\\u66f4\\u6539\\u8def\\u7ebf"),f.aa.ne.show(),f.aa.sd.zn(f.aa.ne)):(f.aa.sd=X.nK(a,b.point),f.aa.sd.Gb(),f.aa.sd.addEventListener("dragging",function(){f.vJ(this,a,f.aa.tx.$k, f.aa.tx.oj)}),f.aa.sd.addEventListener("dragend",function(){var a=f.aa.bx,b=a.name,c=f.aa.tx.oj;a.zj=p;f.aa.Jb.splice(c,0,a);f.aa.Ii.splice(c,0,{title:b?b:"\\u672a\\u77e5\\u8def\\u6bb5",curNo:c,point:a});this.ta(a);f.hC();f.zA(d,e)}),f.aa.ne||(f.aa.ne=X.bL()),a.Ka(f.aa.sd)))}),l.addEventListener("mouseout",function(){f.aa.sd&&f.aa.sd.U()}));f.aa.fh.push(l);if(this.k.fd){c=b.nh(m);l=0;for(s=c.qs.length;l<s;l++)for(var u=c.qs[l],w=u.F0,u=u.wG,y=0,D=w.length;y<D;y++){if(u[y])var C=X.qK(a,w[y],u[y]);j.push(C); f.aa.fh.push(C)}c.t2=j}}this.k.ja.bh&&a.Dh(i,{margins:[30,30,30,30]});this.Ra(Y.Xu,b.lk)},EU:function(){var a=this.k.ja.map;this.ka.rf(0);for(var b=this.ka.vj(),c=this.ka.lh(),d=this,e=0,f=0,g=this.aa.Jb.length;f<g;f++){var i=this.aa.Jb[f];if(0===f)i=X.So(a,i,b.title,Di),b.marker=i,i.addEventListener("click",function(){d._select(0)}),this.wa.push(i);else if(f===this.aa.Jb.length-1)i=X.So(a,i,c.title,Ei),c.marker=i,i.addEventListener("click",function(){d._select(d.dI()+1)}),this.wa.push(i);else{i.zj? (i=X.tK(a,i,e),e++,i.zj=1):i=X.nK(a,i);this.aa.Ii[f-1].bn=i;var j=new cd;j.Rw(new fd("\\u5220\\u9664\\u8be5\\u70b9",function(a,b,c){d._delVia(c.vx)},{width:60}));i.Qo(j);d.aa.Qs.push(j)}i.vx=f;this.BA&&(i.Gb(),i.addEventListener("mouseover",function(){d.aa.Ey=o;d.aa.ne?(d.aa.ne.ad("\\u62d6\\u52a8\\u4ee5\\u66f4\\u6539\\u8def\\u7ebf"),d.aa.ne.show()):d.aa.ne=X.bL();this.zn(d.aa.ne)}),i.addEventListener("mouseout",function(){this.qE()&&this.qE().U();d.aa.Ey=q}),i.addEventListener("dragging",function(){d.vJ(this, a)}),i.addEventListener("dragend",function(){var a=d.aa.bx,e=this.vx;this.zj&&(a.zj=1);d.aa.Jb[e]=a;this.ta(a);var a=d.aa.Jb[0],f=d.aa.Jb[d.aa.Jb.length-1];0===e&&(b.point=a,b.title=d.aa.LK);e===d.aa.Jb.length-1&&(c.point=f,c.title=d.aa.KK);d.hC();d.zA(b,c)}));d.aa.fh.push(i)}e=[b];e=e.concat(this.aa.Ii);e=e.concat([c]);this.Ra(Y.zq,e)},vJ:function(a,b,c,d){var e=this;if(e.aa.tD!==o){e.aa.tD=o;setTimeout(function(){e.aa.tD=q},xe.$P);var f;f=T.tb(a.ia());var g=b.ga(),i=a.vx,j=e.k.$c;if("undefiend"!== typeof c&&"undefined"!==typeof d){var l=e.aa.Jb[c],l=T.tb(l),i=e.aa.Jb[d],i=T.tb(i);f={qt:"drag",pt:f.lng+","+f.lat,sn:l.lng+","+l.lat,en:i.lng+","+i.lat,r:5E3,st:1,et:1,sy:j,l:g}}else 0===i?(i=e.aa.Jb[i+1],i=T.tb(i),f={qt:"drag",pt:f.lng+","+f.lat,sn:"",en:i.lng+","+i.lat,r:5E3,st:1,et:1,sy:j,l:g}):i===this.aa.Jb.length-1?(l=e.aa.Jb[i-1],l=T.tb(l),f={qt:"drag",pt:f.lng+","+f.lat,sn:l.lng+","+l.lat,en:"",r:5E3,st:1,et:1,sy:j,l:g}):(l=e.aa.Jb[i-1],l=T.tb(l),i=e.aa.Jb[i+1],i=T.tb(i),f={qt:"drag",pt:f.lng+ ","+f.lat,sn:l.lng+","+l.lat,en:i.lng+","+i.lat,r:5E3,st:1,et:1,sy:j,l:g});de.eb(function(a,b){e.HU(a,b)},f,{NW:a,map:b,$k:c,oj:d})}},HU:function(a,b){if(a&&a.content){this.aa.bx=Q.kb(a.content.dragpt,o).point;var c,d=b.map,e=b.$k,f=b.oj,g=b.NW.vx;"undefiend"!==typeof e&&"undefined"!==typeof f?c=Q.$N(a.content.geo).ha:0===g?(c=Q.kb(a.content.geo,o).ha,this.aa.LK=a.content.name?a.content.name:"\\u8d77\\u70b9"):g===this.aa.Jb.length-1?(c=Q.kb(a.content.geo,o).ha,this.aa.KK=a.content.name?a.content.name: "\\u7ec8\\u70b9"):c=Q.$N(a.content.geo).ha;c&&(this.rR(g,d,e,f),this.aa.$o?this.aa.$o.me(c):(e=this.ka.rf(0).nh(0),this.aa.$o=X.fm(d,c,e.zp())));c=a.content.name?a.content.name:"\\u672a\\u77e5\\u8def\\u6bb5";this.aa.bx.name=c;d="("+si(a.content.dis)+")";this.aa.ne&&this.aa.ne.show();this.aa.ne&&this.aa.ne.ad(c+d)}},rR:function(a,b,c,d){for(var e=0,f=this.aa.fh.length;e<f;e++){var g=this.aa.fh[e];if(g instanceof Dd)if("undefiend"!==typeof c&&"undefined"!==typeof d){if(g.$k===c&&g.oj===d){b.Ub(g);break}}else(g.$k=== a||g.oj===a)&&b.Ub(g)}this.eg&&this.eg.U()},_select:function(a){var b=this.lb,c=this.k.ja;if(c.Ia){var d=c.Ia.getElementsByTagName("table"),d=d[d.length-1].getElementsByTagName("tr");0<=b-1&&d[b-1]&&(d[b-1].style.background="");0<=a-1&&d[a-1]&&(d[a-1].style.background="#f0f0f0")}var e=c.map;if(e){var b=this.ka.rf(0).nh(0),d=this.dI(),f=this;e.Wc();if(0===a||a===d+1){var g=0===a?this.ka.vj():this.ka.lh(),i=X.qx({content:"<b>"+g.title+"</b>",total:d,ux:a,Hy:function(a){f._select(a)},MY:1===c.Ht?q:o}); i.addEventListener("open",function(){f.Ra(Y.Tn,g,X.vt(e))});i.addEventListener("close",function(){if(f.k.ja.Ia){var a=c.Ia.getElementsByTagName("table");if(a=a[a.length-1])a=a.getElementsByTagName("tr"),0<=f.lb-1&&a[f.lb-1]&&(a[f.lb-1].style.background="")}f.lb=-1});var j=0===a?0:1,f=this;e.B.Dm?ef.Ip(i,e.getCurrentCity().code,{panoInstance:e.P,lngLat:g.point,titleTip:g.title,type:"busline",beforeDomId:"trans_nav"},function(){f.wa[j].Mb(i)}):f.wa[j].Mb(i);this.eg&&this.eg.U()}else{var l=c.Ht;if(1=== l){var m=this.xr(a-1),i=X.qx({content:m.kh()?m.kh(q):m.instructions,total:d,ux:a,Hy:function(a){f._select(a)}});i.addEventListener("open",function(){f.Ra(Y.Tn,m,X.vt(e))});i.addEventListener("close",function(){if(f.k.ja.Ia){var a=c.Ia.getElementsByTagName("table");if(a=a[a.length-1])a=a.getElementsByTagName("tr"),0<=f.lb-1&&a[f.lb-1]&&(a[f.lb-1].style.background="")}f.lb=-1});var n=m.ia?m.ia():m.Py[m.Py.length-1],f=this;e.B.Dm?ef.Ip(i,e.getCurrentCity().code,{panoInstance:e.P,lngLat:n,titleTip:m.kh? m.kh(q):m.instructions,type:"driving",beforeDomId:"trans_nav"},function(){e.Mb(i,n)}):e.Mb(i,n)}else if(2===l)if(1===a&&!this.k.fd)m=this.xr(0),e.Xf(m.ia?m.ia():m.Py[m.Py.length-1]),c.bh&&e.Oc(17),this.eg&&this.eg.U();else if(this.Vl[a-1]&&(this.eg?(this.eg.me(this.Vl[a-1]),this.eg.show()):this.eg=X.fm(e,this.Vl[a-1],b.zp()+2),c.bh))b=e.Dt(this.eg.Kd()),17<b.zoom&&(b.zoom=17),e.Dh(b)}}this.lb=a},_toggle:function(){var a=this.k.ja;if(a.Ia){var b=x.getElementsByClassName(a.Ia,"navtrans-res");b&&0<b.length&& (b=b[0],b.style.display=b&&"none"===b.style.display?"":"none");if((a=x.getElementsByClassName(a.Ia,"navtrans-view"))&&0<a.length)a=a[0],x.K.w0(a)}},Sj:function(){var a=this.k.ja.map;if(a){for(var b=0,c=this.wa.length;b<c;b++)a.Ub(this.wa[b]),this.wa[b]=p;this.wa.length=0;a.Ub(this.eg);this.eg=p;if(this.aa){this.aa.sd&&(a.Ub(this.aa.sd),this.aa.sd=p);this.aa.ne&&(a.Ub(this.aa.ne),this.aa.ne=p);b=0;for(c=this.aa.fh.length;b<c;b++)a.Ub(this.aa.fh[b]),this.aa.fh[b]=p;this.aa.fh.length=0;this.aa.$o&&(a.Ub(this.aa.$o), this.aa.$o=p);b=0;for(c=this.aa.Qs.length;b<c;b++)a.aq(this.aa.Qs[b]),this.aa.Qs[b]=p;this.aa.Qs.length=0;this.aa.Ey=q}}},_delVia:function(a){if(this.ka){var b=this.ka.vj(),c=this.ka.lh();this.aa.Jb.splice(a,1);this.hC();this.zA(b,c)}},Tl:function(){if(this.k.ja.Ia&&this.k.ja.Ia.appendChild&&this.ka&&0<this.ka.Wx()){var a=this.ka.rf(0),b=H("div",{style:"font:12px "+I.fontFamily+";background:#fff"}),c=this.aa.Ii,d=c.length,e=[],f=this.xd===ie,f=ue.$H(this.ka.lh().title,f?"\\u9a7e\\u8f66":"\\u6b65\\u884c", 0<d);if(0<d){e.push("<table style=\'width:100%;margin-left:4px;font:12px "+I.fontFamily+";border-collapse:collapse\' cellpadding=\'0\' cellspacing=\'0\' border=\'0\'>");for(var g=0;g<d;g++)e.push("<tr>"),0===g&&(1===d?e.push(\'<td style="padding:2px 5px;line-height:20px">\\u9014\\u7ecf\\u70b9</td>\'):e.push(\'<td valign="top" rowspan="\'+d+\'" style="padding:2px 5px;line-height:18px">\\u9014\\u7ecf\\u70b9</td>\')),e.push(\'<td style="padding:2px 5px;line-height:20px">\'+c[g].title+"</td>"),e.push(\'<td style="padding:2px 10px;line-height:20px;cursor:pointer;color:#0000ff" onclick=\\\'Instance("\'+ this.ba+\'")._delVia(\'+c[g].curNo+")\'>\\u5220\\u9664</td>"),e.push("</tr>");e.push("</table>")}for(var c=ue.aI(this.ka.vj().title,\'Instance("\'+this.ba+\'")._select(0)\',0),d=["<table class=\'navtrans-table\' style=\'width:100%;font:12px "+I.fontFamily+";border-collapse:collapse\' cellpadding=\'0\' cellspacing=\'0\' border=\'0\'>"],i=0,j=0,l=a.zt();j<l;j++)for(var m=a.nh(j),g=0,m=m.Xx();g<m;g++){var n="";this.lb===i+1&&(n=";background:#f0f0f0");d.push(\'<tr style="cursor:pointer\'+n+\'" onclick=\\\'Instance("\'+this.ba+ \'")._select(\'+(i+1)+")\'>");d.push("<td style=\'border-bottom:1px solid #E4E6E7;padding:10px;line-height:20px;\' >"+(this.xr(i).kh?this.xr(i).kh():this.xr(i).instructions)+"</td>");d.push("</tr>");i++}d.push("</table>");g=ue.aI(this.ka.lh().title,\'Instance("\'+this.ba+\'")._select(\'+(i+1)+")",1);a="<div class=\'navtrans-view expand\' style=\'position:relative;color:#7777cc;background:#e5ecf9;height:53px;overflow:hidden;text-align:right\' onclick=\'Instance(\\""+this.ba+"\\")._toggle()\'><span class=\'suggest-plan\'>\\u63a8\\u8350</span><div class=\'suggest-plan-des\'>"+ a.Ue().replace(/(\\d+(?:.\\d+)?)/,"$1 ")+"&nbsp;&nbsp;|&nbsp;&nbsp;"+a.ut().replace(/(\\d+)/,"$1 ")+"</div>";this.ka.moreResultsUrl&&(a+="<a style=\'color:#7777cc;position:absolute;top:5px;right:20px;\' href=\'"+this.ka.moreResultsUrl+"\' target=\'_blank\'>\\u5230\\u767e\\u5ea6\\u5730\\u56fe\\u67e5\\u770b&#187;</a>");b.innerHTML=f+(a+"&nbsp;<span class=\'navtrans-arrow\'></span></div>")+("<div class=\'navtrans-res\'>"+e.join("")+c+d.join("")+g+"</div>");this.k.ja.Ia.appendChild(b);this.Ra(Y.Yu,b)}},TA:function(a,b){if(""=== b||!b)if(9===a||12===a||1===a||16===a)b=xe.qQ[a];return b},$S:function(a){var b="",c=a.poi;c&&(b=this.sI(c.ps)||"",b=(this.tI(c.pw)||"")+b+"<b>"+c.pn+"</b>"+(c.pd<(13===a.qa||4===a.qa?1E3:50)?"":"\\u7ea6"+si(c.pd)+"\\u540e")+(""===b?"":"\\uff0c"));return b},hT:function(a){var b=a.iw;return!a.ic?"":(this.oI(b)||"")+"<b>"+a.ic+"</b>"+(this.pI(b)||"")},dT:function(a,b){var c="\\u6cbf";if(0===a||!b&&1!==a&&16!==a&&9!==a&&12!==a)c="";return c},cT:function(a,b){var c="\\u8fdb\\u5165";if(!b&&(9===a||12===a))c= "\\u4e0a";else if(0===a||!b&&1!==a&&16!==a)c="";return c},gT:function(){if(this.Ha&&this.Ha.content&&this.Ha.content.taxi){var a=this.Ha.content.taxi,b={distance:a.dis,remark:a.remark};if(a.detail[0]){var c=a.detail[0];b.day={initialFare:parseFloat(c.startPrice),unitFare:parseFloat(c.kmPrice),totalFare:parseFloat(c.totalPrice)}}a.detail[1]&&(a=a.detail[1],b.night={initialFare:parseFloat(a.startPrice),unitFare:parseFloat(a.kmPrice),totalFare:parseFloat(a.totalPrice)});return b}return p}});ye.Sz=" \\u76f4\\u884c \\u53f3\\u524d\\u65b9\\u8f6c\\u5f2f \\u53f3\\u8f6c \\u53f3\\u540e\\u65b9\\u8f6c\\u5f2f \\u8c03\\u5934 \\u5de6\\u540e\\u65b9\\u8f6c\\u5f2f \\u5de6\\u8f6c \\u5de6\\u524d\\u65b9\\u8f6c\\u5f2f \\u9760\\u5de6 \\u76f4\\u884c \\u9760\\u53f3 \\u6b63\\u5317\\u65b9\\u5411 \\u4e1c\\u5317\\u65b9\\u5411 \\u6b63\\u4e1c\\u65b9\\u5411 \\u4e1c\\u5357\\u65b9\\u5411 \\u6b63\\u5357\\u65b9\\u5411 \\u897f\\u5357\\u65b9\\u5411 \\u6b63\\u897f\\u65b9\\u5411 \\u897f\\u5317\\u65b9\\u5411".split(" "); ye.Qz=["","\\u4ece\\u8d77\\u70b9\\u51fa\\u53d1","\\u5230\\u8fbe\\u76ee\\u7684\\u5730","\\u9014\\u7ecf\\u70b9","\\u884c\\u9a76"];ye.Jq="s-1 s-1 s-2 s-3 s-4 s-5 s-6 s-7 s-8 s-9 s-1 s-10 ".split(" ");ye.Kz=["\\u5728","\\u4ece","\\u4ece"];ye.Lz=["","","\\u79bb\\u5f00"];ye.Pz=["\\u8fc7","\\u5728"];ye.Oz=["\\u5de6\\u4fa7\\u7684","\\u53f3\\u4fa7\\u7684",""];ye.Fz=["","\\u671d"]; x.extend(ye.prototype,{wv:function(a){return new ni(a)},Hv:function(a){return ye.Sz[a]},vI:function(a){return\'<span class="navtrans-navlist-icon \'+(ye.Jq[a]?ye.Jq[a]:"")+\'"></span>\'},SA:function(a){return ye.Qz[a]},oI:function(a){return ye.Kz[a]},pI:function(a){return ye.Lz[a]},tI:function(a){return ye.Pz[a]},sI:function(a){return ye.Oz[a]},jI:function(a){return ye.Fz[a]}});ze.Sz=" \\u76f4\\u8d70 \\u5411\\u53f3\\u524d\\u65b9\\u8f6c \\u53f3\\u8f6c \\u5411\\u53f3\\u540e\\u65b9\\u8f6c \\u5411\\u540e\\u8f6c \\u5411\\u5de6\\u540e\\u65b9\\u8f6c \\u5de6\\u8f6c \\u5411\\u5de6\\u524d\\u65b9\\u8f6c \\u5de6\\u8f6c\\u7a7f\\u8fc7\\u9a6c\\u8def\\u5e76\\u7ee7\\u7eed\\u5411\\u524d \\u53f3\\u8f6c\\u7a7f\\u8fc7\\u9a6c\\u8def\\u5e76\\u7ee7\\u7eed\\u5411\\u524d \\u5de6\\u8f6c\\u7a7f\\u8fc7\\u9a6c\\u8def\\u5e76\\u5f80\\u56de\\u8d70 \\u53f3\\u8f6c\\u7a7f\\u8fc7\\u9a6c\\u8def\\u5e76\\u5f80\\u56de\\u8d70 \\u6b63\\u5317\\u65b9\\u5411 \\u4e1c\\u5317\\u65b9\\u5411 \\u6b63\\u4e1c\\u65b9\\u5411 \\u4e1c\\u5357\\u65b9\\u5411 \\u6b63\\u5357\\u65b9\\u5411 \\u897f\\u5357\\u65b9\\u5411 \\u6b63\\u897f\\u65b9\\u5411 \\u897f\\u5317\\u65b9\\u5411 ".split(" "); ze.Jq="s-1 s-1 s-2 s-3 s-4 s-5 s-6 s-7 s-8 s-7 s-3 s-7 s-3 ".split(" ");ze.Qz=["","\\u4ece\\u8d77\\u70b9\\u51fa\\u53d1","\\u5230\\u8fbe\\u76ee\\u7684\\u5730","\\u9014\\u7ecf\\u70b9","\\u8d70"];ze.Kz=["\\u5728","\\u4ece","\\u4ece"];ze.Lz=["","","\\u79bb\\u5f00"];ze.Pz=["\\u8fc7","\\u5728"];ze.Oz=["\\u5de6\\u4fa7\\u7684","\\u53f3\\u4fa7\\u7684",""];ze.Fz=["","\\u671d"]; x.extend(ze.prototype,{wv:function(a){delete a.url;return new oi(a)},Hv:function(a){return ze.Sz[a]},vI:function(a){return\'<span class="navtrans-navlist-icon \'+(ze.Jq[a]?ze.Jq[a]:"")+\'"></span>\'},SA:function(a){return ze.Qz[a]},oI:function(a){return ze.Kz[a]},pI:function(a){return ze.Lz[a]},tI:function(a){return ze.Pz[a]},sI:function(a){return ze.Oz[a]},jI:function(a){return ze.Fz[a]}});x.extend(De.prototype,{Td:function(a,b,c){this.uM("web",this.qM(a,b,c))},wO:function(a,b,c){this.uM("web",this.qM(a,b,c))},IO:function(a,b){var c=this.vh,d="";a&&a.cN&&a.name?(d=a.cN,d="latlng:"+d.lat+","+d.lng,d+="|name:"+a.name):d=(d=a.cN)?d.lat+","+d.lng:a.name?a.name:"";c[b]=d},qM:function(a,b,c){this.IO(a,"origin");this.IO(b,"destination");var c=this.vh=x.object.extend(this.vh,c),a=[],d="";if("undefined"===typeof c.origin||""===c.origin)c.origin="";var b={destination:q,mode:q},e;for(e in c)d= e+"="+c[e],a.push(d),"undefined"!==typeof b[e]&&(b[e]=o);this.mode=c.mode;b.mode===q&&(this.mode="driving",a.push("mode=driving"),b.mode=o);e=o;for(var f in b)e=e&&b[f];return e?a.join("&"):q},uM:function(a,b,c){b&&(b=li[a]+b+"&src=baidu|jsapi",Ta(7E3,{mode:this.mode}),"web"===a&&(b+="&output=html"),location.href=b,c&&c())}}); ');