Commit c0cbdeba authored by 田翔's avatar 田翔

fix: 代码修复

parent 907ab05b
{ {
"name": "panda-xform", "name": "panda-xform",
"version": "5.4.6", "version": "5.4.7",
"description": "5.4.6 关联表单配置统一", "description": "5.4.7 本人信息bug修复",
"keywords": [ "keywords": [
"panda-xform" "panda-xform"
], ],
......
...@@ -75,7 +75,7 @@ const XRender = (props, ref) => { ...@@ -75,7 +75,7 @@ const XRender = (props, ref) => {
} }
childObj[s] = { childObj[s] = {
...child[s], ...child[s],
presetValue: disabledField ? (value || '') : (value || child[s].presetValue), presetValue: value || child[s].presetValue,
textDefalut: child[s].presetValue, textDefalut: child[s].presetValue,
disabled: disabledField, disabled: disabledField,
required, required,
......
...@@ -64,21 +64,25 @@ const TextInput = (props) => { ...@@ -64,21 +64,25 @@ const TextInput = (props) => {
useEffect(() => { useEffect(() => {
let valueNext = presetValue let valueNext = presetValue
if (preview !== 'preview') { if (preview !== 'preview') {
if (!presetValue || loaclPaths.includes(presetValue)) { if (loaclPaths.includes(presetValue)) {
if (textDefalut === '【本人姓名】') { if (disabled) {
if (isStoreID) { valueNext = ''
valueNext = userInfo.OID + '' } else {
} else { if (textDefalut === '【本人姓名】') {
valueNext = userInfo.fullName if (isStoreID) {
} valueNext = userInfo.OID + ''
} else if (textDefalut === '【本人部门】') { } else {
if (isStoreID) { valueNext = userInfo.fullName
valueNext = userInfo.depart.OID + '' }
} else { } else if (textDefalut === '【本人部门】') {
valueNext = userInfo.depart.name if (isStoreID) {
valueNext = userInfo.depart.OID + ''
} else {
valueNext = userInfo.depart.name
}
} else if (textDefalut === '【本人电话】') {
valueNext = userInfo.Phone
} }
} else if (textDefalut === '【本人电话】') {
valueNext = userInfo.Phone
} }
} }
} }
......
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