Skip to content
This repository has been archived by the owner on Dec 13, 2022. It is now read-only.

Add URL input option #87

Merged
merged 34 commits into from
Jun 25, 2020
Merged

Add URL input option #87

merged 34 commits into from
Jun 25, 2020

Conversation

aguilerapy
Copy link
Contributor

#42

@aguilerapy aguilerapy self-assigned this May 5, 2020
@aguilerapy aguilerapy requested a review from romifz May 7, 2020 19:58
Copy link
Contributor

@romifz romifz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey Andrés, I think this looks good. However, there is a lot of code duplication. Most of it was probably already present, but I think it would be good if we can start correcting this. Can you please try to:

  • Use template snippets for common pieces, like the upload/URL selection.
  • Parametrize existing javascript methods instead of copying and editing.

default/static/js/url_uploader.js Outdated Show resolved Hide resolved
default/templates/default/base-uploader.html Outdated Show resolved Hide resolved
default/templates/default/base-uploader.html Outdated Show resolved Hide resolved
default/templates/default/combine-packages.html Outdated Show resolved Hide resolved
default/templates/default/to-json.html Outdated Show resolved Hide resolved
default/views.py Outdated Show resolved Hide resolved
default/static/js/url_uploader.js Outdated Show resolved Hide resolved
tests/test_upload_url.py Outdated Show resolved Hide resolved
tests/test_upload_url.py Outdated Show resolved Hide resolved
default/templates/default/to-spreadsheet.html Show resolved Hide resolved
@aguilerapy aguilerapy requested a review from romifz May 23, 2020 01:24
Copy link
Contributor

@romifz romifz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Andrés,

I've added more comments. Besides them I have one more request: is it possible to verify the format of the file after downloading them to the server? As we do for the files that are uploaded from the client.

I've got also had these issues: when displaying the page below, no option is selected. Please make that the "Upload files" option is selected by default.

screenshot-127 0 0 1_8000-2020 05 25-22_40_03

Also, the footer hides the "Start" button after selecting the "Upload files" option:

screenshot-127 0 0 1_8000-2020 05 25-22_40_42

I believe that, since all files are sequentially downloaded in the server side, it would be nice if we have some kind of visual feedback on how many files are processed and how many are left, instead of the "Processing" modal.

locale/es/LC_MESSAGES/django.po Outdated Show resolved Hide resolved
default/static/js/uploader.js Outdated Show resolved Hide resolved
default/templates/default/base-uploader.html Outdated Show resolved Hide resolved
locale/es/LC_MESSAGES/django.po Outdated Show resolved Hide resolved
locale/es/LC_MESSAGES/django.po Outdated Show resolved Hide resolved
locale/es/LC_MESSAGES/django.po Outdated Show resolved Hide resolved
locale/es/LC_MESSAGES/django.po Outdated Show resolved Hide resolved
default/views.py Outdated Show resolved Hide resolved
@aguilerapy
Copy link
Contributor Author

Is it possible to verify the format of the file after downloading them to the server?

Done.

Please make that the "Upload files" option is selected by default.

Done.

Also, the footer hides the "Start" button after selecting the "Upload files" option:

Done here.

It would be nice if we have some kind of visual feedback on how many files are processed and how many are left, instead of the "Processing" modal.

Done.

Copy link
Contributor

@romifz romifz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Andrés,

I reviewed the code and it seems ok to me. There is a lot of repetition still, but we can continue working to remove this gradually.

When testing I've found two issues:

  • I provided the URLs for a release package and a record package together in the Combine Packages feature. When submitting there is no visual feedback that says something went wrong, although there are errors in the server console. The resulting file is a package with the release package only.

  • When reloading the Combine Packages page I still see one of the URLs I selected before in the single input box that is visible. I'm not sure if this is because of my browser (firefox) but it would be nice to ensure this field is blank when reloading the page.

@aguilerapy aguilerapy mentioned this pull request Jun 18, 2020
3 tasks
@aguilerapy aguilerapy requested a review from romifz June 19, 2020 20:06
@romifz
Copy link
Contributor

romifz commented Jun 25, 2020

@jpmckinney would you like to review this before merging?

@jpmckinney jpmckinney merged commit a5363c0 into master Jun 25, 2020
@jpmckinney jpmckinney deleted the 42-in_out_options_2 branch June 25, 2020 00:19
@jpmckinney
Copy link
Member

I haven't reviewed – looks like you did a thorough review!

I did "Squash and merge" since there were a lot of commits addressing the same issues, which made history a bit unclear.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants