Assets Fieldtype "Browse" function not working
Describe the bug
Whenever I try to select content from the "Browse" button using the Assets Fieldtype, it always is slow to load and then freezes at the end of the loading process. I can only upload files directly on the field to use it.
To reproduce
Steps to reproduce the behaviour:
- Download the Spin-up-Statamic CMS and run it in local dev.
- Once it is started up, create a Blueprint or edit one and add an Assets Field from Create Field.
- Set the Max and Min files to at least one and set the container of the Assets Field to "Assets".
- Go into Pages and make sure the Blueprint with the Asset Field you set is selected.
- Click the "Browse" button in the Assets Field, select a file, and open up the console on your browser.
- See error messages "GET http://localhost:8050/cp/assets-fieldtype?assets[]=assets::testimages%2Ftestimage3-1688939123.png 404 (Not Found)" and "Uncaught (in promise) Error: Request failed with status code 404 at createError (app-3beb22f3.js:377:184785) at settle (app-3beb22f3.js:377:185061) at XMLHttpRequest.ue (app-3beb22f3.js:378:2002)".
Expected behaviour
The files load in from the "Browse" function on the Assets Fieldtype and display in the Fieldtype as a selected file.
Screenshot
Versions
- Statamic version: 4.9.2
hmmmm... probably something with how the asset routing works that I'm not understanding fully.
Does the request http://localhost:8050/cp/assets-fieldtype?assets%5B%5D=assets::testimages%2Ftestimage3-1688939123.png look correct to you in terms of what you'd expect to see?
I don't see an assets-fieldtype directory in my cp directory for this spin-up-statmic. I can see the photos saved in the Statamic folders being located in the statamic directory in the glide/containers directory and in that directory being saved in the assets directory within it. So statamic/glide/assets.