Browse Source

添加appId,在获取用户坐标失败问题修改

master
mk 7 months ago
parent
commit
b922fa4e54
  1. 5
      app.json
  2. 20
      project.config.json
  3. 11
      subpages/heart/pages/clockIn/clockIn.js

5
app.json

@ -107,5 +107,8 @@
"desc": "志愿者小程序将获取您的位置信息"
}
},
"sitemapLocation": "sitemap.json"
"sitemapLocation": "sitemap.json",
"requiredPrivateInfos": [
"getLocation"
]
}

20
project.config.json

@ -1,9 +1,5 @@
{
"description": "项目配置文件",
"packOptions": {
"ignore": [],
"include": []
},
"setting": {
"urlCheck": false,
"es6": true,
@ -23,8 +19,6 @@
"uploadWithSourceMap": true,
"compileHotReLoad": false,
"useMultiFrameRuntime": true,
"useApiHook": true,
"useApiHostProcess": true,
"babelSetting": {
"ignore": [],
"disablePlugins": [],
@ -37,12 +31,10 @@
"userConfirmedBundleSwitch": false,
"packNpmManually": false,
"packNpmRelationList": [],
"minifyWXSS": true
"minifyWXSS": true,
"ignoreUploadUnusedFiles": true
},
"compileType": "miniprogram",
"libVersion": "3.2.2",
"appid": "wxc4fe0ea629aaa309",
"projectname": "e锦水-志愿者端",
"cloudfunctionTemplateRoot": "",
"simulatorType": "wechat",
"simulatorPluginLibVersion": {},
@ -73,5 +65,11 @@
"editorSetting": {
"tabIndent": "auto",
"tabSize": 4
}
},
"libVersion": "3.7.4",
"packOptions": {
"ignore": [],
"include": []
},
"appid": "wxc4fe0ea629aaa309"
}

11
subpages/heart/pages/clockIn/clockIn.js

@ -114,6 +114,7 @@ Page({
latitude,
longitude
}) {
console.log(latitude,longitude,'逆地址解析经纬度');
var that = this;
that.data.qqmapsdk.reverseGeocoder({
location: {
@ -122,10 +123,18 @@ Page({
},
success: (res) => {
wx.hideLoading();
if (res.message === "query ok") {
if (res.message === "Success") {
that.setData({
operationAddress: res.result.address
})
}else{
wx.showToast({
title: '定位信息有误,请检查权限',
icon:'none'
})
that.setData({
ldata: true
})
}
}
})

Loading…
Cancel
Save