diff --git a/components/InputAndSwiper/InputAndSwiper.vue b/components/InputAndSwiper/InputAndSwiper.vue index 6697869..77316e2 100644 --- a/components/InputAndSwiper/InputAndSwiper.vue +++ b/components/InputAndSwiper/InputAndSwiper.vue @@ -31,62 +31,86 @@ "https://alifei01.cfp.cn/creative/vcg/800/new/VCG41175510742.jpg" ] } - }, - position: { - type: String, - default () { - return '定位' - } } }, data() { return { - + position: '' }; }, options: { styleIsolation: 'shared', // 解除样式隔离 }, created() { - // this.getLocation() + console.log('createsd'); + this.open() }, methods: { - getLocation() { - uni.getLocation({ + getLocation1() { + var that = this + let qqmapsdk = new QQMapWX({ + key: 'ZRKBZ-Q7FWL-GVZPK-MCRBU-4XFB5-ATBDB' + }); + uni.getFuzzyLocation({ type: 'wgs84', - // geocode: true, // 返回城市信息 - // enableHighAccuracy: false, // 开启高精度模式 - success: function(res) { - let qqmapsdk = new QQMapWX({ - key: 'ZRKBZ-Q7FWL-GVZPK-MCRBU-4XFB5-ATBDB' - }); + success(res) { + console.log('res.latitude', res.latitude); + console.log('res.longitude', res.longitude); qqmapsdk.reverseGeocoder({ location: { latitude: res.latitude, longitude: res.longitude }, success: (re) => { - console.log(re.result.ad_info.city, '成都市=='); - console.log(re.result.ad_info.district, '武侯区=='); + console.log("解析地址成功", re); + console.log(re.result.ad_info.city,); + console.log(re.result.ad_info.district, ); + let city=re.result.ad_info.city + let district=re.result.ad_info.district + that.position = city.slice(0,2) + district.slice(0,2) }, fail: (re) => { console.log(re, '失败信息'); } }) - } + }, + fail(err) { + console.log("获取经纬度失败", err); + }, }); }, //提示用户开启定位服务 open() { - // uni.authorize({ - // scope: 'scope.userLocation', - // success: function() { - // console.log('授权成功'); - // }, - // fail: function() { - // console.log('授权失败'); - // } - // }) + var that = this + uni.authorize({ + scope: 'scope.userFuzzyLocation', + success: function() { + console.log('授权成功'); + that.getLocation1() + }, + fail: function() { + console.log('授权失败'); + uni.showModal({ + content: '检测到您没打开获取信息功能权限,是否去设置打开?', + confirmText: "确认", + cancelText: '取消', + success: (res) => { + if (res.confirm) { + uni.openSetting({ + success: (res) => { + console.log(res); + that.getLocation1(); + } + }) + } else { + console.log('取消'); + return false; + } + } + }) + return false; + } + }) // wx.getSetting({ // success: (res) => { // if (res.authSetting['scope.userLocation'] === false) { diff --git a/manifest.json b/manifest.json index 942d70f..a87efa3 100644 --- a/manifest.json +++ b/manifest.json @@ -59,9 +59,12 @@ // 获取当前的地理位置、速度 配置 "scope.userLocation": { "desc": "你的位置信息将用于小程序位置接口的效果展示" + }, + "scope.userFuzzyLocation": { + "desc": "你的位置信息将用于小程序位置的效果展示" } - } - + }, + "requiredPrivateInfos": ["choosePoi", "chooseAddress", "getFuzzyLocation"] }, "mp-alipay": { "usingComponents": true diff --git a/pages.json b/pages.json index 40348e8..80023ad 100644 --- a/pages.json +++ b/pages.json @@ -97,17 +97,16 @@ } } - - ,{ - "path" : "pages/Partnerships/Partnerships", - "style" : - { - "navigationBarTitleText": "成功合伙人", - "enablePullDownRefresh": false - } - - } - ], + + , { + "path": "pages/Partnerships/Partnerships", + "style": { + "navigationBarTitleText": "成功合伙人", + "enablePullDownRefresh": false + } + + } + ], "tabBar": { "color": "#CCCCCC", "borderStyle": "white", @@ -146,6 +145,11 @@ "navigationBarBackgroundColor": "#F8F8F8", "backgroundColor": "#F8F8F8" }, + "permission": { + "scope.userFuzzyLocation": { + "desc": "你的位置信息将用于小程序位置的效果展示" + } + }, "uniIdRouter": {}, "condition": { //模式配置,仅开发期间生效 "current": 0, //当前激活的模式(list 的索引项) diff --git a/pages/Partnerships/Partnerships.vue b/pages/Partnerships/Partnerships.vue index f76af10..db3f125 100644 --- a/pages/Partnerships/Partnerships.vue +++ b/pages/Partnerships/Partnerships.vue @@ -1,19 +1,27 @@ @@ -28,7 +36,7 @@ submit(){ console.log('提交'); }, - confirmCheckWay(){ + confirmCheckWay(e){ } @@ -37,5 +45,32 @@ diff --git a/pages/index/HomeMainContent/HomeNavCard.vue b/pages/index/HomeMainContent/HomeNavCard.vue index c180164..3270311 100644 --- a/pages/index/HomeMainContent/HomeNavCard.vue +++ b/pages/index/HomeMainContent/HomeNavCard.vue @@ -1,6 +1,6 @@ @@ -45,11 +45,19 @@ } ], shopList: { + shopid: 1, imageUrl: 'https://alifei01.cfp.cn/creative/vcg/800/new/VCG41175510742.jpg', title: '琴行铺面转让', promotionNum: 23, - price: 5000, - date: '2023-11-02' + price: 6000, + date: '2023-11-02', + pos: '锦江区', + exactPos: '锦江区-汇源南路366号', + sqr: 100, + zrfText: "转让费:20万", + category: '餐饮美食', + uname: "张先生", + phoneNum: 13348946108, } } }, @@ -119,8 +127,8 @@ position: absolute; z-index: 1; bottom: 60rpx; - left: 10%; - transform: translateX(-10%); + left: 50%; + transform: translateX(-50%); .list-border { margin: 0; diff --git a/pages/publish/publishAddress/publishAddress.vue b/pages/publish/publishAddress/publishAddress.vue index 9f51b6c..0ec5235 100644 --- a/pages/publish/publishAddress/publishAddress.vue +++ b/pages/publish/publishAddress/publishAddress.vue @@ -1,6 +1,45 @@ @@ -8,7 +47,9 @@ export default { data() { return { - + show1:false, + show2:false, + show3:false, } }, methods: { @@ -17,6 +58,39 @@ } - + \ No newline at end of file diff --git a/pages/publish/publishInvestment/publishInvestment.vue b/pages/publish/publishInvestment/publishInvestment.vue index bed6bea..0ec5235 100644 --- a/pages/publish/publishInvestment/publishInvestment.vue +++ b/pages/publish/publishInvestment/publishInvestment.vue @@ -1,6 +1,45 @@ @@ -8,7 +47,9 @@ export default { data() { return { - + show1:false, + show2:false, + show3:false, } }, methods: { @@ -17,6 +58,39 @@ } - + \ No newline at end of file diff --git a/pages/publish/publishRent/publishRent.vue b/pages/publish/publishRent/publishRent.vue index 812f1cb..0ec5235 100644 --- a/pages/publish/publishRent/publishRent.vue +++ b/pages/publish/publishRent/publishRent.vue @@ -1,6 +1,45 @@ @@ -8,7 +47,9 @@ export default { data() { return { - + show1:false, + show2:false, + show3:false, } }, methods: { @@ -17,6 +58,39 @@ } - + \ No newline at end of file diff --git a/pages/publish/publishTransfer/publishTransfer.vue b/pages/publish/publishTransfer/publishTransfer.vue index c9760cf..af2165a 100644 --- a/pages/publish/publishTransfer/publishTransfer.vue +++ b/pages/publish/publishTransfer/publishTransfer.vue @@ -9,20 +9,19 @@ - - 111111 - - + + 123 + - 123 + 123 - 123 + 123 @@ -40,9 +39,7 @@ 发布 - - - + @@ -61,8 +58,6 @@ title:'' }, columns:[ - ['中国', '美国'], - ['深圳', '厦门', '上海', '拉萨'] ], show1:false, show2:false, @@ -89,9 +84,10 @@ margin-right: 20px; } .input-class{ - font-size: 30rpx; + font-size: 40rpx; font-weight:1px; border-style: none + } .upload{ display: flex; @@ -107,4 +103,14 @@ .bug-figure{ height: 100rpx; } + .checkbox1{ + display: flex; + justify-content: space-between; + } + .checktext{ + margin-top: 5rpx; + font-size: 40rpx; + font-weight:1px; + color: #A0A0A0; + } diff --git a/pages/published/published.vue b/pages/published/published.vue index e55981b..cc57dd1 100644 --- a/pages/published/published.vue +++ b/pages/published/published.vue @@ -1,5 +1,5 @@