refactor: Repeated boilerplate code between upload to database forms (#16756)

* abstract boilerplate code into class and rename csv to file

* add db migration

* fix some stuff

* more renaming of csv to file

* rename in translations

* update down revision

* update down revision

* bump chart version

* switch to alter column name approach in db migration

* fix db migration for MySQL

* db migration conflict
This commit is contained in:
Shiva Raisinghani
2021-10-25 03:53:06 -07:00
committed by GitHub
parent 4f1d202430
commit ef3afbde82
53 changed files with 205 additions and 251 deletions

View File

@@ -104,7 +104,7 @@ class DatabaseRestApi(BaseSupersetModelRestApi):
"cache_timeout",
"expose_in_sqllab",
"allow_run_async",
"allow_csv_upload",
"allow_file_upload",
"configuration_method",
"allow_ctas",
"allow_cvas",
@@ -121,7 +121,7 @@ class DatabaseRestApi(BaseSupersetModelRestApi):
"sqlalchemy_uri",
]
list_columns = [
"allow_csv_upload",
"allow_file_upload",
"allow_ctas",
"allow_cvas",
"allow_dml",
@@ -148,7 +148,7 @@ class DatabaseRestApi(BaseSupersetModelRestApi):
"cache_timeout",
"expose_in_sqllab",
"allow_run_async",
"allow_csv_upload",
"allow_file_upload",
"allow_ctas",
"allow_cvas",
"allow_dml",
@@ -164,7 +164,7 @@ class DatabaseRestApi(BaseSupersetModelRestApi):
list_select_columns = list_columns + ["extra", "sqlalchemy_uri", "password"]
order_columns = [
"allow_csv_upload",
"allow_file_upload",
"allow_dml",
"allow_run_async",
"changed_on",