onChange()

in packages/form-render/src/widgets/fields/upload/index.tsx [34:45]


    onChange(info: any) {
      if (info.file.status === 'done') {
        message.success(`${info.file.name} ${t('upload_success')}`);
        const path = get(schema, 'props.path', '');
        const url = path
          ? get(info.file.response, path)
          : info.file.response.url;
        onChange(url);
      } else if (info.file.status === 'error') {
        message.error(`${info.file.name} ${t('upload_fail')}`);
      }
    },