getgrav / getgrav/grav-plugin-admin
Check/display new or existing files/medias in page
- Dominant language
- PHP
- Stars
- 377
- Forks
- 225
- Avg merge
- 11h 51m
- Merged PRs (30d)
- 4
Description
Hello everybody
Am working with the grav-plugin-admin web interface
but some time am using the "folder way" to edit / add contents
and so for images / medias !
For example I can drag-n-drop file directly into ```pages/test_page/image_1.jpg```
But files I add ( in the folder/manual or admin way )
dont appears into the admin/edit page ! :cry:
The filepicker show me them, cool
... but, it would be much more easier to show the new added files
directly after/in/under the media field ("media" in blueprint)
( like when I upload some )
( but for already existing ones )

My blueprint :
```
media_files:
type: file
label: Médias
multiple: true
destination: 'self@'
random_name: false
avoid_overwriting: false
limit: 10
accept:
- image/*
```
-----
Some links I follow ( much more about filepicker / pagemediaselect )
- Filepicker form field by flaviocopes · Pull Request #750 · getgrav/grav-plugin-admin
↳ https://github.com/getgrav/grav-plugin-admin/pull/750
- Pagemediaselect should refresh when new media is uploaded · Issue #450 · getgrav/grav-plugin-admin
↳ https://github.com/getgrav/grav-plugin-admin/issues/450
- Dynamic update pagemediaselect fields when pagemedia file is uploaded · Issue #741 · getgrav/grav-plugin-admin
↳ https://github.com/getgrav/grav-plugin-admin/issues/741
-----
So my question is, for now :
How do the admin-plugin is "searching"/"scanning" for new media files ?
What it the task trigger ? Can I force this process to start ?
I follow this question :
```task.addmedia```
https://discourse.getgrav.org/t/issues-with-page-media-in-admin-task-addmedia/1311/6
Maybe using an other cron / routine task ?
Thanks
Contributor guide
Research direction
Start by tracing the filepicker and pagemediaselect behavior referenced in the issue, then review the related issues and the task.addmedia discussion. Determine how existing page media are discovered and refreshed; done means files added outside the upload flow appear beneath the media field without requiring a new upload.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, php
- Domain
- content, frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100