|
|
@@ -748,8 +748,12 @@ const setValue = (field, value) => {
|
|
|
if (!fieldMapValue) {
|
|
|
console.error("没有找到字段编号:" + field)
|
|
|
}
|
|
|
- if (fieldMapValue.type == "MULTI") {
|
|
|
- formData[field] =JSON.parse(value) ;
|
|
|
+ if (value && fieldMapValue.type == "MULTI" && typeof value == 'string') {
|
|
|
+ formData[field] = JSON.parse(value);
|
|
|
+ } else if (value && (fieldMapValue.type == "INTEGER" || fieldMapValue.type == "DECIMAL") && typeof value != 'string') {
|
|
|
+ formData[field] = value.toString();
|
|
|
+ } else if (value && fieldMapValue.type == "DATETIME" && typeof value != 'string') {
|
|
|
+ formData[field] = value.toString();
|
|
|
} else {
|
|
|
formData[field] = value;
|
|
|
}
|