Opened 7 years ago
Closed 7 years ago
#43820 closed enhancement (fixed)
Add "Mine" filter for attachments similarly to posts and comments
Reported by: | azaozz | Owned by: | SergeyBiryukov |
---|---|---|---|
Milestone: | 4.9.6 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Administration | Keywords: | has-patch dev-feedback commit fixed-major |
Focuses: | ui | Cc: |
Description
This will be quite useful for users that want to see, edit or export their data.
The functionality already exists. Attachments can be filtered by user name when clicking on the "Author" in the Media Library (in list-table view). To make it more accessible we would need to add a little bit of UI, perhaps another <option>
under the "Media items" drop-down.
Attachments (3)
Change History (17)
#1
@
7 years ago
- Keywords has-patch added
Hello,
43820.diff
adds "Mine" filter to list-table view.
Not sure we can add this filtering option to the grid view without creating a new js file…
Cheers,
Jb
#2
follow-up:
↓ 3
@
7 years ago
43820.diff looks good, but if we add it to the "All media items" dropdown, I would like to also see this on the grid view. The top bar UI is exactly the same, so I think it should match.
#3
in reply to:
↑ 2
@
7 years ago
Replying to desrosj:
I would like to also see this on the grid view. The top bar UI is exactly the same, so I think it should match.
Sure, but grid view is not generated the same way: it's full JS UI, and I'm wondering if we need a new file in /wp-includes/js/media/views/attachment-filters
I will look closely to this today.
#4
@
7 years ago
- Keywords dev-feedback added
Hi,
43820.2.diff
handles both table/list and grid view, but since this is a pretty complex patch (for me), I'd like to get a review on the JS/grid-view part.
cc @azaozz @desrosj
Cheers,
Jb
#5
@
7 years ago
Just updated 43820.2.diff
to remove an unnecessary comma.
I checked my code again today, and I think it looks good.
#7
follow-up:
↓ 8
@
7 years ago
- Keywords commit fixed-major added
Looks good. media-models.js and media-views.js are auto-generated files, the actual changes should go in wp-includes/js/media/views/... dir.
#8
in reply to:
↑ 7
;
follow-up:
↓ 10
@
7 years ago
Replying to azaozz:
Looks good. media-models.js and media-views.js are auto-generated files, the actual changes should go in wp-includes/js/media/views/... dir.
Thanks for the review @azaozz
Do you mean the final file is auto-generated or do I need to update my patch?
Sorry for this stupid question but I can't find any /wp-includes/js/media/views/…
dir on my local dev installation…
This ticket was mentioned in Slack in #core by desrosj. View the logs.
7 years ago
#10
in reply to:
↑ 8
;
follow-up:
↓ 11
@
7 years ago
Replying to audrasjb:
Do you mean the final file is auto-generated or do I need to update my patch?
Nah, I fixed it and committed it. Just next time when making a patch for the media library (js), it's better if you patch the appropriate file in /wp-includes/js/media/*
, not one of the auto-generated files. Then when you run grunt precommit
, media-models.js and media-views.js will be updated.
Adds Mine filter in list-table media view