Hi all,
I noticed that the module uses american date format for date input. Is it possible to change the input format to the system "short date format"??
Where to change format in code?

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

vistree created an issue. See original summary.

Eric_A’s picture

Version: 7.x-1.8 » 7.x-1.x-dev
Status: Active » Needs review
Related issues: +#2680567: Miscellaneous features and minor bug fixes
FileSize
2.4 KB

I extracted 2.x code by mairi out of the monster patch in #2680567: Miscellaneous features and minor bug fixes and backported it to 7.x-1.x.
It introduces a workbench_scheduler_date_format variable that can be set with drush or devel and controlled with a feature. No UI in this patch.

Eric_A’s picture

FileSize
2.79 KB

Added an implementation of hook_uninstall().

partdigital’s picture

Hi Eric_A, thanks for your help on this. I grabbed your patch and took it one step further. Instead of using a variable I used the internal Drupal date format 'short'. This also accounts for locale. In a later commit we can add a settings page where admins can change the date format to 'medium', 'long' or any other custom date format.

I also replaced 'Y-m-d H:i:s' with the DATE_FORMAT_DATETIME constant.

Note: This is for version 7.x-2.x

partdigital’s picture

Version: 7.x-1.x-dev » 7.x-2.x-dev
mairi’s picture

Thanks so much @Eric_A @partdigital - this community really is awesome :) I have finally managed to come back to this & I need to take the latest 7.x-2.x-dev & apply the patches I had started splitting down. I'll try this one in place of what I have for date format, and will review #2717419-5 as well. I'll create issues for the remaining parts. Sorry it's taken so long!

mairi’s picture

@Eric_A @partdigital I have applied the patch from #4 locally and it is looking good. +1 for not needing the additional variable setting and -1 to me for not thinking the Drupal date format 'short' in the original patch :)

  • Eric_A authored 11b3522 on 7.x-2.x
    Issue #2693387 by Eric_A, partdigital, vistree, mairi: Input date
    
partdigital’s picture

Status: Needs review » Fixed

This has been rolled into the latest dev release. Thanks for your help everyone!

Status: Fixed » Closed (fixed)

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