1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889 |
- <!--pages/jsCase/citySel/index.wxml-->
- <wxs module="utils" src="../../../utils/formatFuc.wxs" />
- <view class="head {{search&&'r_head'}}">
- <!-- 搜索框 -->
- <view class="flex-row search-box">
- <view class="city-block" bindtap="switchCity">
- <view> {{current_city}}</view>
- <image class="arrow-img {{cityShow?'arrow-up':''}}" mode="aspectFit"
- src='https://mall.zhaijieshi.cc/file/jzmall-dy/arrow-down.png'></image>
- </view>
- <view class="head_input">
- <image src="https://mall.zhaijieshi.cc/file/wx-dy/icon-search.png" class="search_icon"></image>
- <input type="text" placeholder="搜索" placeholder-class="place_holder" bindinput="getValue" value="{{search}}"
- bindfocus="mapFocus" class="input-view" confirm-type="search" bindconfirm="confSearch"></input>
- </view>
- <view class="sha_icon" catchtap="clear_input" wx:if="{{(!mapShow)}}">取消</view>
- </view>
- <view class="flex-row head_curr" wx:if="{{cityShow}}">
- <image src="https://mall.zhaijieshi.cc/file/wx-dy/address-map.png" class="h_c_icon" />
- <view>当前定位城市: {{current_city}}</view>
- </view>
- </view>
- <scroll-view wx:if="{{cityShow}}" scroll-y="true" class="sy_container" scroll-into-view="{{scrollViewId}}">
- <view class="hot_city">
- <view class="title">热门城市</view>
- <view class="flex-row flex-wrap box">
- <block wx:for="{{hot_city}}" wx:key="hot">
- <view class="name" hover-class="sel_city" hover-stay-time="150" bindtap="cityTap" data-city="{{item.name}}">
- {{item.name}}</view>
- </block>
- </view>
- </view>
- <view class="all_city">
- <view wx:for="{{city_list}}" wx:key="city_list" wx:if="{{item.data.length>0}}">
- <view class="letter_name" id="{{item.letter}}">{{item.letter}}</view>
- <view class="city">
- <block wx:for="{{item.data}}" wx:key="data" wx:for-index="index0" wx:for-item="item0">
- <view class="name flex-row" hover-class="city_hover" hover-stay-time='150' bindtap="cityTap"
- data-city="{{item0.cityName}}">{{item0.cityName}}</view>
- </block>
- </view>
- </view>
- </view>
- </scroll-view>
- <!-- 侧边选择索引 -->
- <view wx:if="{{cityShow}}">
- <view class="fixed_bar" style="height: {{barHeight}}px;" catchtouchstart="touchStart" catchtouchmove="touchMove"
- catchtouchend="touchEnd" catchtouchcancel="touchCancel">
- <view wx:for="{{city_list}}" wx:key="index" style="height: {{barHeight/22}}px;">
- <view class="bar_item flex-column j_c {{curr==index&&'bar_item_active'}}"
- style="width: {{barHeight/22*0.75}}px;height: {{barHeight/22*0.75}}px;">{{item.letter}}</view>
- </view>
- </view>
- <view wx:if="{{showLetter &&city_list[curr].letter}}" class="fixed_letter">{{city_list[curr].letter}}</view>
- </view>
- <view wx:if="{{resultShow}}" class="result_list">
- <view wx:if="{{result.length>0}}">
- <block wx:for="{{result}}" wx:key="result">
- <view class="r_item" hover-stay-time='150' hover-class="r_item_hover" bindtap="resultTap"
- data-location="{{item.location}}" data-name="{{item.name}}">
- <view>{{item.name}}</view>
- <view>{{item.district+item.address}}</view>
- </view>
- </block>
- </view>
- <view wx:else class="flex-column no_data">
- <image src="https://mall.zhaijieshi.cc/file/jzmall-dy/no-data.png" />
- <view>未搜到相关地址</view>
- <view>输入地址后请点击搜索</view>
- </view>
- </view>
- <!-- tt-if="{{mapShow}}" -->
- <map enable-rotate="{{true}}" min-scale="{{3}}" max-scale="{{19}}" id="myMap"
- enable-scroll="{{true}}" enable-overlooking="{{true}}" longitude="{{lng}}" bindtap="mapTap" show-location="{{true}}"
- latitude="{{lat}}" scale="{{15}}" bindregionchange="regionChange" enable-zoom="{{true}}" bindupdated="mapUpdated">
- </map>
- <view class="marker-name" wx:if="{{mapShow&¤tName&¤tName.length>0}}">{{currentName}}</view>
- <image src="https://mall.zhaijieshi.cc/file/jzmall-dy/icon-marker.png" class="map-icon" wx:if="{{mapShow}}"></image>
- <scroll-view class="poi-list" scroll-y="{{true}}" wx:if="{{mapShow}}">
- <view class="poi-item" wx:for="{{poiList}}" wx:key="index" bindtap="poiTap" data-poi="{{item}}">
- <view class="poi-left">
- <view class="poi-name">{{item.name}}</view>
- <view class="poi-address">{{item.address}}</view>
- </view>
- <view class="poi-right">{{utils.formatDistance(item.distance)}}米</view>
- </view>
- </scroll-view>
|