Commit faef3152 authored by 田翔's avatar 田翔

fix: BUG修复

parent a8065391
{ {
"name": "panda-xform", "name": "panda-xform",
"version": "5.9.11", "version": "5.9.12",
"description": "5.9.11 关联表单增加前端显示字段余SQL过滤配置", "description": "5.9.12 BUG修复",
"keywords": [ "keywords": [
"panda-xform" "panda-xform"
], ],
......
...@@ -2407,15 +2407,15 @@ const advancedWidgets = [ ...@@ -2407,15 +2407,15 @@ const advancedWidgets = [
dependencies: ['accountName', '$id'], dependencies: ['accountName', '$id'],
description: '默认获取前端台账字段', description: '默认获取前端台账字段',
}, },
sql: { // sql: {
title: 'SQL过滤', // title: 'SQL过滤',
name: 'SQL过滤', // name: 'SQL过滤',
type: 'string', // type: 'string',
widget: 'SqlFilter', // widget: 'SqlFilter',
props: { // props: {
placeholder: '示例:部门="XX部门"' // placeholder: '示例:部门="XX部门"'
} // }
}, // },
hiddenCondition: { hiddenCondition: {
title: '隐藏条件', title: '隐藏条件',
type: 'string', type: 'string',
......
...@@ -41,7 +41,16 @@ const RelationForm = (props) => { ...@@ -41,7 +41,16 @@ const RelationForm = (props) => {
sql, sql,
fieldList, fieldList,
} = schema } = schema
const initParams = { user: userID, accountName: otherSource?.accountName, sortFields: '录入时间', direction: 'desc', total: 0, pageIndex: 1, pageSize: 100 } const initParams = {
user: userID,
accountName: otherSource?.accountName,
condition: otherSource?.sql ? window.btoa(encodeURIComponent(otherSource?.sql)) : '',
sortFields: '录入时间',
direction: 'desc',
total: 0,
pageIndex: 1,
pageSize: 100
}
const [config, setConfig] = useState({ accountFieids: [], webShowFieldGroup: '', fieldGroup: '', formJson: {} }) const [config, setConfig] = useState({ accountFieids: [], webShowFieldGroup: '', fieldGroup: '', formJson: {} })
const [dataSource, setDataSource] = useState([]) const [dataSource, setDataSource] = useState([])
const [visible, setVisible] = useState(false) const [visible, setVisible] = useState(false)
......
...@@ -81,6 +81,16 @@ const OtherSource = (props) => { ...@@ -81,6 +81,16 @@ const OtherSource = (props) => {
} }
</Select> </Select>
</Form.Item> </Form.Item>
<Form.Item
label={'SQL过滤'}
name={'sql'}
>
<Input.TextArea
style={{ width: '100%' }}
rows={3}
placeholder='示例:部门="XX部门"'
/>
</Form.Item>
<Space align="baseline"> <Space align="baseline">
<div style={{ width: '60px' }}>字段映射:</div> <div style={{ width: '60px' }}>字段映射:</div>
<Form.List name="field" label='字段映射'> <Form.List name="field" label='字段映射'>
......
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