Commit c750767e authored by 田翔's avatar 田翔

fix: 点击官网可以选择

parent ae5505b3
{
"name": "panda-xform",
"version": "5.6.1",
"description": "5.6.1 台账选择器问题修复",
"version": "5.6.2",
"description": "5.6.2 点击官网可以选择",
"keywords": [
"panda-xform"
],
......
......@@ -41,7 +41,7 @@ const Device = (props) => {
})
}
clickref.current = new ClickQuery({
layersInfo,
layerInfos: layersInfo,
view: view.current,
offsetX: -150,
offsetY: -310,
......@@ -154,10 +154,20 @@ const Device = (props) => {
if (isObject(values)) {
for (let key in values) {
if (key === 'GIS编码' && gisInfo.gisCode) {
addons.setValue(`${v}.${key}`, gisInfo.gisCode)
const schema = addons.getSchemaByPath(`${v}.${key}`);
if (['FileUpload', 'TextInput'].includes(schema.widget)) {
addons.setSchemaByPath(`${v}.${key}`, { ...schema, otherValue: gisInfo.gisCode });
} else {
addons.setValueByPath(`${v}.${key}`, gisInfo.gisCode)
}
}
if (key === 'GIS图层' && gisInfo.layerName) {
addons.setValue(`${v}.${key}`, gisInfo.layerName)
const schema = addons.getSchemaByPath(`${v}.${key}`);
if (['FileUpload', 'TextInput'].includes(schema.widget)) {
addons.setSchemaByPath(`${v}.${key}`, { ...schema, otherValue: gisInfo.layerName });
} else {
addons.setValueByPath(`${v}.${key}`, gisInfo.layerName)
}
}
}
}
......
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