Commit c3b6b208 authored by XieZhiXiong's avatar XieZhiXiong

chore: 修改 省市区组件 默认值

parent efd208e5
......@@ -28,7 +28,7 @@ export type ElementType = {
*/
fieldLength?: number,
/**
* 是否可为空0-不能为空1-可以为空
* 是否可为空 0-不能为空 1-可以为空
*/
fieldEmpty?: number,
/**
......@@ -187,13 +187,16 @@ const getFieldType = (field: ElementType, editable: boolean = true) => {
'x-component-props': {
disabled: isDisabled,
},
// 这里判断 省级 是否有值,没值给 undefined
// 后台没值是返回 {provinceCode: '', cityCode: '', districtCode: ''}
default: field.fieldValue ? field.fieldValue.provinceCode ? field.fieldValue : undefined : undefined,
};
break;
}
default:
break;
}
return Object.assign({}, description, common);
return Object.assign({}, common, description);
};
/**
......
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