incredibleMachines / 30PP

Player and Uploader App for 30 Park Place
0 stars 0 forks source link

File Library: "Delete" button #39

Closed itsjennkaye closed 10 years ago

itsjennkaye commented 10 years ago

Doesn't work. Also, what happens if I delete an asset that is associated with a scene? Need to have some visible error on both the Events page and Events detail page.

itsjennkaye commented 10 years ago

Sorry -- when I try to delete one of my assets out of the File Library, I click the "delete" button and then get an error that says: "Cannot POST /files//delete"

Secondarily asking about when I CAN successfully delete an asset, what happens to the scenes that are currently using that asset? The asset will then go missing. screen shot 2014-02-19 at 5 42 42 pm

piuggi commented 10 years ago

The problem here is that the route is malformed. the slug is not being added to each form in the submission area. without the file slug the item cannot be referenced, additionally there is no // extension in our router so the request fails.

On Wednesday, February 19, 2014 at 5:44 PM, itsjennkaye wrote:

Sorry -- when I try to delete one of my assets out of the File Library, I click the "delete" button and then get an error that says: "Cannot POST /files//delete" Secondarily asking about when I CAN successfully delete an asset, what happens to the scenes that are currently using that asset? The asset will then go missing.

— Reply to this email directly or view it on GitHub (https://github.com/incredibleMachines/30PP/issues/39#issuecomment-35559374).

itsjennkaye commented 10 years ago

Ok cool so you know what the problem is.

Any thoughts on my other question? Or table for now.

piuggi commented 10 years ago

Files and assets are completely different in our architecture. We will have to surface better deleting strategies when we remove files and thus update assets. if you delete a file the asset would just fail to load providing a null. We'll need to surface that on the events/single.ejs

piuggi commented 10 years ago

Implemented as of commit: https://github.com/incredibleMachines/30PP/commit/30197f192e1f9b08ec99c5fd6023d32db7d1146e