Commit dc011b5b authored by 田翔's avatar 田翔

fix: 坐标获取地址修复

parent ab875fa9
{
"name": "panda-xform",
"version": "5.0.3",
"description": "5.0.3 设备选择映射字段支持清空,缩略图优化",
"version": "5.0.4",
"description": "5.0.4 坐标获取地址修复",
"keywords": [
"panda-xform"
],
......
......@@ -63,7 +63,7 @@ const textWidgets = [
title: '文本',
type: 'string',
widget: 'TextInput',
placeholder: '请输入内容',
placeholder: '',
},
setting: {
widget: {
......@@ -248,7 +248,7 @@ const textWidgets = [
title: '多行文本',
type: 'string',
widget: 'TextArea',
placeholder: '请输入内容'
placeholder: ''
},
setting: {
widget: {
......@@ -368,7 +368,7 @@ const textWidgets = [
type: 'string',
widget: 'NumberInput',
presetValue: '0',
placeholder: '请输入内容',
placeholder: '',
},
setting: {
widget: {
......@@ -716,7 +716,7 @@ const textWidgets = [
title: '地址',
type: 'string',
widget: 'SearchLocation',
placeholder: '请输入地址',
placeholder: '',
},
setting: {
widget: {
......@@ -829,7 +829,7 @@ const selectWidgets = [
placeholder: {
title: '提示语',
type: 'string',
default: '点击下拉选择内容',
default: '',
},
description: {
title: '字段说明',
......@@ -1315,7 +1315,7 @@ const selectWidgets = [
name: '关联选择',
type: 'string',
widget: 'RelevanceSelect',
placeholder: '请选择内容',
placeholder: '',
},
setting: {
widget: {
......@@ -1401,7 +1401,7 @@ const selectWidgets = [
name: '级联选择',
type: 'string',
widget: 'CascadeSelector',
placeholder: '点击下拉选择内容',
placeholder: '',
},
setting: {
widget: {
......@@ -1504,7 +1504,7 @@ const businessWidgets = [
title: '人员选择',
type: 'string',
widget: 'PersonSelector',
placeholder: '点击选择人员',
placeholder: '',
},
setting: {
widget: {
......@@ -1625,7 +1625,7 @@ const businessWidgets = [
title: '部门选择',
type: 'string',
widget: 'DeptSelector',
placeholder: '点击选择部门',
placeholder: '',
},
setting: {
widget: {
......@@ -1721,7 +1721,7 @@ const businessWidgets = [
title: '台账选择',
type: 'string',
widget: 'AccountSelector',
placeholder: '点击输入框弹出选择框',
placeholder: '',
},
setting: {
widget: {
......@@ -1839,7 +1839,7 @@ const dateWidgets = [
title: '日期选择',
type: 'string',
widget: 'DateTime',
placeholder: '请选择日期',
placeholder: '',
},
setting: {
widget: {
......@@ -1939,7 +1939,7 @@ const dateWidgets = [
title: '时间选择',
type: 'string',
widget: 'Time',
placeholder: '请选择时间',
placeholder: '',
},
setting: {
widget: {
......@@ -2160,7 +2160,7 @@ const mapWidgets = [
title: '地图坐标',
type: 'string',
widget: 'Coordinate',
placeholder: '请选择地图坐标',
placeholder: '',
},
setting: {
widget: {
......@@ -2259,7 +2259,7 @@ const mapWidgets = [
title: '设备选择',
type: 'string',
widget: 'Device',
placeholder: '请选择设备',
placeholder: '',
},
setting: {
widget: {
......@@ -2353,7 +2353,7 @@ const mapWidgets = [
title: '路径控件',
type: 'string',
widget: 'DrawPath',
placeholder: '绘制地图路径',
placeholder: '',
},
setting: {
widget: {
......@@ -2440,7 +2440,7 @@ const mapWidgets = [
title: '区域控件',
type: 'string',
widget: 'DrawArea',
placeholder: '绘制地图区域',
placeholder: '',
},
setting: {
widget: {
......
......@@ -171,7 +171,9 @@ const Coordinate = (props) => {
const getAddress = async (presetValue) => {
if (presetValue) {
const { code, data } = await getLocation(presetValue)
let coordinate = presetValue.split(',')
let LngLat = mercatorToLngLat(coordinate[0], coordinate[1])
const { code, data } = await getLocation(LngLat.join(','))
if (Array.isArray(data) && data.length) {
const { pname, adname, name, address } = data[0]
setText(`${pname}/${adname}/${name}`)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment