I use Date CCK module date field and I want to group views table values by year + month. But now Views provide only prapared formats (long, sort...). So i suggest to create a way to choose custom date format.

I make a custom 'long' format in '...admin/settings/date-time' but in views this format did not changed. It seems that Views use its own format. So it could use drupal formats or we could custom date in Views. Thanks.

Comments

merlinofchaos’s picture

Project: Views (for Drupal 7) » Date
Version: 6.x-2.3 » 6.x-2.x-dev
Component: node data » Miscellaneous

If you only read one of these submission guidelines, read this one. (Then please read the rest) If your problem deals exclusively with fields or filters provided by another module (CCK, Image, VotingAPI are common) please post the issue under the queue for that module first; all modules are responsible for telling Views about their own fields. It's possible Views IS at fault, but the module maintainers are the best people to make that determination, and they can kick the issue into the Views queue with an explanation of what's wrong if that is the case.

szy’s picture

Component: Date API » Miscellaneous
Category: support » feature
Issue tags: -views

@mindix, it works, checked yesterday.

1. make a format at /admin/settings/date-time/formats/add,

2. name it at the end of /admin/settings/date-time/formats,

3. connect your name with your new format at the same page,

That's what you have done, right? Then:

4. run cron, clear temporary data or Views cache - I don't know what exactly
cointans that part of data, or just wait for Drupal to do it,

5. configure your date field - your custom formats will do appear there - use it!

Works now?

Szy.

szy’s picture

Component: Miscellaneous » Date API
Category: feature » support
Issue tags: +views, +date
mindaugasd’s picture

Component: Miscellaneous » Date API
Category: feature » support
Issue tags: +views

I didn't understand how to make a new formats. /admin/settings/date-time/formats/add and /admin/settings/date-time/formats pages looks the same. I did not find any fields to make or name formats. All I could do is change existing formats, but not to create a new one.

And the formats I can change (it is Short, Medium and Long) looks totaly different from the formats in views, regardless their are under the same name. Thanks.

mindix.

szy’s picture

@mindix, maybe you have older Date's version installed?

Unfortunately, I don't know which version (or a submodule?) brings 'add date
format' option.

Szy.

karens’s picture

Status: Active » Fixed

You will only see those options on the latest -dev version of Date. I'm going to be releasing a new version this weekend and they will be in that. You will have lots of flexibility in formats once you are using the right version of the code.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

gregaltuna’s picture

THANK YOU! Was trying to figure out how to make this happen on a view with From/To dates and it wouldn't let me do a custom "Format:". You rock!