Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow adding photos to an AED being added, not just to existing ones #172

Open
RicoElectrico opened this issue Nov 8, 2023 · 4 comments
Labels
enhancement New feature or request ui-photos Handling of AED photos

Comments

@RicoElectrico
Copy link

RicoElectrico commented Nov 8, 2023

Feels like an oversight 😅
However, the current API requires node ID which is not present at the upload stage. This would mean splitting the upload into 3 parts: uploading a node to the OSM API to get the ID, adding a photo to our backend and then editing the node to include the image=* tag. (the last happens on the backend).
This feels extremely flimsy.

Maybe we could just make the backend upload the AED on behalf of the user? To be stateless, ditch the changeset opening and just use 1 changeset per AED. Not optimal, but nobody will use our page to bulk load AEDs.

@Zaczero
Copy link
Member

Zaczero commented Nov 8, 2023

So backend should provide interface for automatic handling of node creation/updates (frontend sends the node diff), with an option to upload an image alongside of it. Correct?

@Zaczero
Copy link
Member

Zaczero commented Dec 25, 2023

It seems like frontend uses OSM API directly, and backend is not involved in the AED creation process at all. Perhaps this should be unified so the backend performs the creation instead? @starsep

@Zaczero Zaczero added the enhancement New feature or request label Dec 25, 2023
@starsep
Copy link
Member

starsep commented Dec 26, 2023

I agree. That will allow to create AED and upload photo at once.
Either in 1 or 2 requests.
I would prefer one which would create AED with optional photo data as parameter.
We also have to support editing existing AED - changing tags and potentially adding a photo.

@Zaczero
Copy link
Member

Zaczero commented Dec 26, 2023

Okay then. Backend will expose methods for AED creation and edits.

@danieldegroot2 danieldegroot2 added the ui-photos Handling of AED photos label Mar 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request ui-photos Handling of AED photos
Projects
None yet
Development

No branches or pull requests

4 participants