This commit is contained in:
RickCole 2020-11-18 16:42:28 +08:00 committed by GitHub
parent 0dedee2338
commit d90bfbcf6c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 3 deletions

View File

@ -148,7 +148,7 @@ import './renderers/Icon';
import './renderers/Carousel';
import Scoped, {ScopedContext} from './Scoped';
import {FormItem} from './renderers/Form/Item';
import {FormItem, registerFormItem} from './renderers/Form/Item';
// 兼容旧版本用法
import './compat';
@ -170,7 +170,7 @@ import {
validateObject
} from './utils/validations';
import {normalizeOptions} from './components/Select';
import {OptionsControl} from './renderers/Form/Options';
import {OptionsControl, registerOptionsControl} from './renderers/Form/Options';
import {
classnames,
@ -209,6 +209,8 @@ export {
getRendererByName,
registerRenderer,
unRegisterRenderer,
registerFormItem,
registerOptionsControl,
resolveRenderer,
filterSchema,
filterDate,

View File

@ -177,7 +177,7 @@ function responseAdaptor(ret: fetcherResult) {
status: data.status,
msg: data.msg,
msgTimeout: data.msgTimeout,
data: data.data ? data.data : data // 兼容直接返回数据的情况
data: !data.data && !data.hasOwnProperty('status') ? data : data.data // 兼容直接返回数据的情况
};
if (payload.status == 422) {