-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Labels
Description
New place models which include rich text image content currently require two round-trips to the server to save: one trip to create the place model and attachment models in the first place, and a second to update any embedded images with the S3 bucket urls returned from the first save. It would be better if we didn't need this double round trip.
To accomplish this, let's build out our Attachment model to support a type property. The type property will signal to the client the intended use of the attachment. Currently there are two use cases:
- cover image (images that appear at the very top of place detail views, right below the title)
- rich text embedded images (images that are embedded inside a rich text field)
The client will make use of attachments based on the value of the type field, correctly placing cover images at the top and embedded images at the appropriate point in a rich text field.