|
@@ -1,121 +1,45 @@
|
|
|
<template>
|
|
|
- <view>
|
|
|
- <!-- <view class="map_container">
|
|
|
- <map class="map" ref="map" :longitude="longitude" :latitude="latitude" scale="14" show-location="true"
|
|
|
- :markers="markers" @click="markertap"></map>
|
|
|
- </view>
|
|
|
- <view class="mapText">
|
|
|
- {{address}}
|
|
|
- </view> -->
|
|
|
- <view class="search-box" @click="openChooseLocation">
|
|
|
+ <view class="content">
|
|
|
+ <view style="height: 190px;background-color: bisque;"></view>
|
|
|
+ <!-- leftTitle:标题 icon:左边图标 @click:点击事件 -->
|
|
|
+ <cc-wxMenuBtn leftTitle="我的报名" icon="../../static/image/add.png" @click="goFunctionClick(0)"></cc-wxMenuBtn>
|
|
|
+ <cc-wxMenuBtn leftTitle="我的交易" icon="../../static/image/add.png" @click="goFunctionClick(1)"></cc-wxMenuBtn>
|
|
|
+ <cc-wxMenuBtn leftTitle="我的兑换" icon="../../static/image/add.png" @click="goFunctionClick(1)"></cc-wxMenuBtn>
|
|
|
+ <cc-wxMenuBtn leftTitle="我的资料" icon="../../static/image/add.png" @click="goFunctionClick(3)"></cc-wxMenuBtn>
|
|
|
|
|
|
- qqqqq1
|
|
|
-
|
|
|
- </view>
|
|
|
</view>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
- import {
|
|
|
- onPullDownRefresh,
|
|
|
- onReachBottom
|
|
|
- } from "@dcloudio/uni-app"
|
|
|
-
|
|
|
- import amapFile from "@/libs/amap-wx.130.js";
|
|
|
- import config from "../../config.js";
|
|
|
-
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
- myAmapFunT: '',
|
|
|
- startPoint: {
|
|
|
- latitude: 43.834931,
|
|
|
- longitude: 125.289036
|
|
|
- }
|
|
|
+
|
|
|
}
|
|
|
|
|
|
},
|
|
|
computed: {},
|
|
|
onLoad: function(options) {
|
|
|
- this.myAmapFunT = new amapFile.AMapWX({
|
|
|
- key: config.gaodeKey
|
|
|
- })
|
|
|
- setTimeout(function() {
|
|
|
- console.log('start pulldown');
|
|
|
- }, 1000);
|
|
|
- uni.startPullDownRefresh();
|
|
|
- },
|
|
|
- onPullDownRefresh() {
|
|
|
- console.log('refresh');
|
|
|
- setTimeout(function() {
|
|
|
- console.log('stop pulldown');
|
|
|
- uni.stopPullDownRefresh();
|
|
|
- }, 1000);
|
|
|
+
|
|
|
},
|
|
|
methods: {
|
|
|
- openChooseLocation(opt) {
|
|
|
- let that = this
|
|
|
- uni.chooseLocation({
|
|
|
- latitude: opt?.latitude || that.startPoint.latitude,
|
|
|
- longitude: opt?.longitude || that.startPoint.longitude,
|
|
|
- success: function(res) {
|
|
|
- console.log(res)
|
|
|
- console.log('位置名称:' + res.name);
|
|
|
- console.log('详细地址:' + res.address);
|
|
|
- console.log('纬度:' + res.latitude);
|
|
|
- console.log('经度:' + res.longitude);
|
|
|
- if (!res.name) {
|
|
|
- return uni.showToast({
|
|
|
- title: '请重新选择位置',
|
|
|
- icon: 'none'
|
|
|
- });
|
|
|
- }
|
|
|
-
|
|
|
- },
|
|
|
- fail: function(info) { //失败回调
|
|
|
- console.log('调取失败')
|
|
|
- console.log(info)
|
|
|
- },
|
|
|
+ goFunctionClick(flag) {
|
|
|
|
|
|
+ console.log("点击的功能菜单 = " + flag);
|
|
|
+ uni.showModal({
|
|
|
+ title: '温馨提示',
|
|
|
+ content: '我点击的是第' + (flag + 1) + '个功能菜单'
|
|
|
})
|
|
|
- },
|
|
|
+ }
|
|
|
|
|
|
}
|
|
|
}
|
|
|
</script>
|
|
|
<style scoped>
|
|
|
- .map_container {
|
|
|
- position: absolute;
|
|
|
- top: 20px;
|
|
|
- bottom: 0;
|
|
|
- left: 0;
|
|
|
- right: 0;
|
|
|
- }
|
|
|
-
|
|
|
- .map {
|
|
|
- width: 100%;
|
|
|
- height: 100%;
|
|
|
- }
|
|
|
-
|
|
|
- .mapText {
|
|
|
- position: absolute;
|
|
|
- left: 0;
|
|
|
- right: 0;
|
|
|
- top: 0px;
|
|
|
- height: 20px;
|
|
|
- background: #fff;
|
|
|
- padding: 0 15px;
|
|
|
- }
|
|
|
-
|
|
|
- text {
|
|
|
- margin: 5px 0;
|
|
|
- display: block;
|
|
|
- font-size: 12px;
|
|
|
- }
|
|
|
+ .content {
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
|
|
|
- .h1 {
|
|
|
- margin: 15px 0;
|
|
|
- font-size: 15px;
|
|
|
}
|
|
|
</style>
|