Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The label "Date value" is always showing up under the real label as soon as I expose any kind of date filter in views. Please look at the attached image.
I have been looking around for this bug but I really can't find anything so I will report it.
Comments
Comment #1
nagiek CreditAttribution: nagiek commentedHi, I would like to see this fixed too. Problem is that
date_parts_form()
indate_views_filter_handler_simple.inc
sets a title without checking for an existing label. You can include the following code at the start of the function to override if you want. I'm no good at making patches, but if someone wants to create one..?I honestly think the best solution is to just have one label, not two.
Comment #2
nagiek CreditAttribution: nagiek commentedComment #3
whop CreditAttribution: whop commentedme too :D
thanks
Comment #4
Mangostaniko CreditAttribution: Mangostaniko commentedThis is just what i need – thank you – , but (i'm quite new to Drupal) where exactly do i put this code?
Comment #5
nagiek CreditAttribution: nagiek commentedIn the
date_parts_form()
function, found indate_views_filter_handler_simple.inc
. This is in the date -> date_views -> includes folder. Usually .inc files are kept in that folder, if not in the main directory.Comment #6
Mangostaniko CreditAttribution: Mangostaniko commentedThank you!
Anyway, I found a different solution to make the label disappear:
EDIT: Soorry! It seems i just changed the title of this page... Unfortunately I don't remember what it was like..
Comment #7
jesss CreditAttribution: jesss commentedFixing the title....
Comment #8
KarenS CreditAttribution: KarenS commentedI think the labels are necessary when you use the between or not between operators, otherwise you have nothing that tells you one is the start and the other the end date. But we could get rid of the extra label for the other operators.
Comment #9
nagiek CreditAttribution: nagiek commentedYeah that's the best idea.
It's funny, I just made a view that exposed both start and end dates, and was thinking "OK, this doesn't make sense any more". So two labels only when two dates exposed.