oeplatform icon indicating copy to clipboard operation
oeplatform copied to clipboard

Improve usability upload Wizzard

Open chrwm opened this issue 3 years ago • 2 comments

The upload Wizzard on the OEP is a great feature to upload single/few tables. However, having used it recently, I want to propose some improvement suggestions regarding the workflow.

  1. Introduce option to upload one vs many tables (from csv) (after each table and finished metadata -> create table)
  2. Switch the workflow order and make "Upload csv" the first step
  3. Then transfer the table headers from the csv-file automatically to the next step "Create Table" to avoid manual copy&paste of table headers
  4. Set the checkbox "nullable" by default to True
  5. ? Open question: Is it possible to auto. set the datatype for each column based on the CSV value?

Additional: Function to save the current progress when creating one or multible tables locally. (Without creating the table on Database)

chrwm avatar Apr 05 '22 12:04 chrwm

This is an excellent idea. Having to define a table first without any helper tools is a show-stopper for most users.

What do we have to do to make this happen?

pajot avatar May 23 '22 12:05 pajot

We would have to extend the JavaScript application that lives in the django app dataedit. @wingechr has implemented this, I just had a quick look and it seems like we can adapt from this function. Since the wizzard already reads the csv headers automatically, we could either do:

  • option 1: We need to add new functionality that calls the OEP API and creates the table with all the columns, gets the correct datatype and mapps the csv fields to the database table model. And maybe some other things.
  • option 2: We use the table and column name from the csv input and pass them to the Wizzard usign the state . What do you think about this @wingechr ?

Alternatively, we could pass the csv column names to the wizzard (django) view and create the columns via the view (using python and sqlalchemy) in the backend and other preprocessing steps if needed.

jh-RLI avatar May 23 '22 17:05 jh-RLI