{"action":"created","issue":{"url":"https://api.github.com/repos/spatie/laravel-medialibrary/issues/68","labels_url":"https://api.github.com/repos/spatie/laravel-medialibrary/issues/68/labels{/name}","comments_url":"https://api.github.com/repos/spatie/laravel-medialibrary/issues/68/comments","events_url":"https://api.github.com/repos/spatie/laravel-medialibrary/issues/68/events","html_url":"https://github.com/spatie/laravel-medialibrary/issues/68","id":109649009,"number":68,"title":"Ability to upload temporary images","user":{"login":"a-komarev","id":1849174,"avatar_url":"https://avatars.githubusercontent.com/u/1849174?v=3","gravatar_id":"","url":"https://api.github.com/users/a-komarev","html_url":"https://github.com/a-komarev","followers_url":"https://api.github.com/users/a-komarev/followers","following_url":"https://api.github.com/users/a-komarev/following{/other_user}","gists_url":"https://api.github.com/users/a-komarev/gists{/gist_id}","starred_url":"https://api.github.com/users/a-komarev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/a-komarev/subscriptions","organizations_url":"https://api.github.com/users/a-komarev/orgs","repos_url":"https://api.github.com/users/a-komarev/repos","events_url":"https://api.github.com/users/a-komarev/events{/privacy}","received_events_url":"https://api.github.com/users/a-komarev/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-10-03T22:23:05Z","updated_at":"2015-10-05T22:09:42Z","closed_at":"2015-10-04T08:50:06Z","body":"Proposal for a new feature. Use case:\r\n\r\n1. User coming to website as guest and proceeding to registration.\r\n2. On registration he uploading his photo. Then he reloading page or if it's multi-step form - changing step.\r\n3. Because image could be attached only after successful model creation there could be an option to store upload temporary in `temp` folder.\r\n4. Place name of temp file in session.\r\n5. After registration have an ability to retrieve temporary filename, persist it and attach to model.\r\n"},"comment":{"url":"https://api.github.com/repos/spatie/laravel-medialibrary/issues/comments/145684161","html_url":"https://github.com/spatie/laravel-medialibrary/issues/68#issuecomment-145684161","issue_url":"https://api.github.com/repos/spatie/laravel-medialibrary/issues/68","id":145684161,"user":{"login":"a-komarev","id":1849174,"avatar_url":"https://avatars.githubusercontent.com/u/1849174?v=3","gravatar_id":"","url":"https://api.github.com/users/a-komarev","html_url":"https://github.com/a-komarev","followers_url":"https://api.github.com/users/a-komarev/followers","following_url":"https://api.github.com/users/a-komarev/following{/other_user}","gists_url":"https://api.github.com/users/a-komarev/gists{/gist_id}","starred_url":"https://api.github.com/users/a-komarev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/a-komarev/subscriptions","organizations_url":"https://api.github.com/users/a-komarev/orgs","repos_url":"https://api.github.com/users/a-komarev/repos","events_url":"https://api.github.com/users/a-komarev/events{/privacy}","received_events_url":"https://api.github.com/users/a-komarev/received_events","type":"User","site_admin":false},"created_at":"2015-10-05T22:09:42Z","updated_at":"2015-10-05T22:09:42Z","body":"So, in this case there is only way to add an hidden model which will hold all temporary records then. Because media could be uploaded before model is created.\r\n\r\nI know that's not a great behaviour, but customer want exactly this flow. Media uploaded > Model created."}}