Skip to content

Infer table schema when a suitable file is selected #77

@amercader

Description

@amercader

As discussed in #65, When a user selects a suitable file, fire a background HTTP request to the action created in #76 to get an inferred table schema.

  • Re-use or adapt code from Schema editor integration #25 that listen to changes in the Upload button,
  • Check if the extension is one of the ones supported.
  • If so read the whole file or a sample if it's bigger than X and use the ckan JS client to call the action with this data and the format
  • If we get a response and there are no errors, we store the result in the schema_json field (let's get this down first and we'll render the editor component later)
  • If there are errors display them

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions