Commit Graph

28 Commits

Author SHA1 Message Date
Ingo Schommer
5c41df21d4 ENHANCEMENT Using jQuery UI datepicker in DateField and DatetimeField instead of outdated DHTML calendar.js (fixes #5397)
ENHANCEMENT Abstracted optional DateField->setConfig('showcalendar') logic to DateField_View_JQuery

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107438 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:37 +13:00
Sean Harvey
3be26a4cec ENHANCEMENT #5352 Decouple date display from i18n locales, users now have access to change their date and time formats in Member::getCMSFields() using Member_DatetimeOptionsetField field
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@107326 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:35 +13:00
Ingo Schommer
8cfe7aa11b BUGFIX Prevent DateField->performReadonlyTransformation() from segfaulting on PHP 5.2 due to broken __toString() casting (fixes #5713, thanks charden)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@106666 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:32 +13:00
Will Rossiter
56be2afbc5 BUGFIX: force dateformat to en_NZ if showcalendar is enabled as calendar is compatibile with en_NZ only
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@105225 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:27 +13:00
Ingo Schommer
577857b98c BUGFIX DateField with setConfig('dmyfields') now validates TRUE for empty values (fixes #5458)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@103450 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:19:15 +13:00
Ingo Schommer
3f7e1e6cad BUGFIX Disable javascript date validation via DateField->jsValidation() if locale is not 'en_NZ" (which is the only format it validates for).
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@100986 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:58 +13:00
Sean Harvey
54720e62e6 BUGFIX #5157 strftime() %F format parameter does not work on Windows - use %Y-%m-%d instead
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@100795 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:53 +13:00
Ingo Schommer
d3a85844f7 ENHANCEMENT Allow locale/dateformat specific reordering of day, month, year input fields in DateField
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@99361 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:38 +13:00
Ingo Schommer
c945e23c62 FEATURE New DatetimeField class (form field wrapper composed of DateField andTimeField)
FEATURE New DateField and TimeField form classes with more consistent API and easier localization
API CHANGE Date/time parsing in DateField, TimeField and DatetimeField defaults to i18n::get_locale() ('en_US') instead of using en_NZ/en_GB specific parsing. Use i18n::set_locale('en_NZ') in mysite/_config.php to revert to old behaviour.
API CHANGE $timeformat constructor parameter in TimeField needs to be in ISO date notation (not PHP's date())
API CHANGE TimeField, DateField and related subclasses use Zend_Date for date parsing, meaning they're stricer than the previously used strtotime()
API CHANGE Removed DMYCalendarDateField and CalendarDateField, use DateField with setConfig('showcalendar')
API CHANGE Removed CompositeDateField, DMYDateField, use DateField with setConfig('dmyfields')
API CHANGE Removed DropdownTimeField, use TimeField with setConfig('showdropdown')
API CHANGE Removed PopupDateTimeField, use DatetimeField
API CHANGE Changed 'date', 'month' and 'year' HTML field names to lowercase in DMYDateField
API CHANGE Removed support for ambiguous date formats in DateField, e.g. '06/03/03'. Use DateField->setConfig('dateformat', '<format>') to revert to this behaviour.
API CHANGE Removed $futureOnly flag from DateField, CalendarDateField etc., use DateField->setConfig('min') and DateField->setConfig('max')
ENHANCEMENT Using Zend_Date for DateField and TimeField, with more robust date handling, starting localization support. Set globally via i18n::set_locale(), or for a field instance through setLocale(). Note: Javascript validation is not localized yet.

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@99360 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:18:38 +13:00
Normann Lou
aa27047ed9 git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@97726 467b73ca-7a2a-4603-9d3b-597d59a354a9 2011-02-02 14:18:15 +13:00
Sean Harvey
26606fd01d BUGFIX MSSQLDatabase returns strange formatted Datetime values, removed hacks from DateField and PopupDateTimeField and put it in DataObject::__construct() so that it fixes the problem at the source
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@78963 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-06-11 07:18:10 +00:00
Sean Harvey
ee2771e99a BUGFIX Slice of extra "OO" if SQL server attempts to set value in DateField
BUGFIX Don't attempt to use JS validation on DateField is javascript handler is "none"


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@78065 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-28 04:06:14 +00:00
Ingo Schommer
a9a12e51d6 MINOR Documentation
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74012 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-02 17:17:04 +00:00
Sean Harvey
41aac525b5 ENHANCEMENT DateField validation is now enabled through DateField::$validation_enabled so that it can be optionally disabled by setting it to false
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@72753 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-03-10 02:32:42 +00:00
Andrew O'Neil
60f75c5ca4 Merged changes from 2.3 branch
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@71172 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-02-01 23:49:53 +00:00
Ingo Schommer
d26f08b481 MINOR merged branches/2.3 into trunk
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@67465 467b73ca-7a2a-4603-9d3b-597d59a354a9
2008-12-04 22:38:32 +00:00
Normann Lou
132f4ae5ca CurrencyField::jsValidation() needs to register its validateCurrency function mulitiple times with different FormID for working in a popup of ComplexTableField where FormID is changed.
In general all Form Fields should imply with this rule if a page contain mulitiple forms, but this is not under our current developing cycle, since our form fields validation is changing to use jQuery.

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@64896 467b73ca-7a2a-4603-9d3b-597d59a354a9
2008-10-30 01:02:57 +00:00
Hayden Smith
634ed7b70c Merged from branches/nzct-trunk. Use 'svn log -c <changeset> -g' for full commit message. Merge includes stability fixes and minor refactor of TableListField and ComplexTableField.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@63806 467b73ca-7a2a-4603-9d3b-597d59a354a9
2008-10-08 02:00:12 +00:00
Sam Minnee
2dcda9bd91 BUGFIX: Fixed a number of really basic problems with a number of date fields - got basic loading and saving working across them all
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@62885 467b73ca-7a2a-4603-9d3b-597d59a354a9
2008-09-23 01:44:40 +00:00
Hayden Smith
130ecfe5aa Merged [47044]: Introduces modifications to Sapphire's form handling that allows it to ignore fields marked as Disabled when saving the contents of a form's fields to a DataObject.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@60469 467b73ca-7a2a-4603-9d3b-597d59a354a9
2008-08-12 02:58:48 +00:00
Ingo Schommer
60860cc1b9 MINOR Unified @package PHPdoc (added where missing, removed duplicates)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@56212 467b73ca-7a2a-4603-9d3b-597d59a354a9
2008-06-15 13:33:53 +00:00
Sam Minnee
fea4042c3c rbarreiros: #1918 Translate newsletter and other strings
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@47832 467b73ca-7a2a-4603-9d3b-597d59a354a9
2008-01-10 03:28:13 +00:00
Sam Minnee
41a11b277e Improved API documentation
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@47799 467b73ca-7a2a-4603-9d3b-597d59a354a9
2008-01-10 00:34:18 +00:00
Sam Minnee
b1d2e3906b API Documentation updates
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@47766 467b73ca-7a2a-4603-9d3b-597d59a354a9
2008-01-09 04:18:36 +00:00
Normann Lou
26b8f7dffe switch externals to trunk.
Inform-merge: from the changeset:
r32477: Merge 2.0-inform from trunk previously
r32478: Merge 2.0-inform from trunk previously
r32481: merge 2.0infom with lastes chunk 
r32483: merge 2.0infom with lastes chunk 
r33526: Final styling of all forms and combined communication form add/alter javascript for height adjustment of First / Second block 
r33580: styling for combined form communication in myinfom pages 
r33706: styling of combined form (communication) in Email 
r33881: made compatible to $extraClass 
r33885: added defaultVal
r33887: fixed typo 
r34728: modified SmallFieldHolder?()
r34729: added "validationError"-class 
r34914: WIP3866: Factfinder: Hide "self emplyed" block 
r34964: Change current plan upto TraumaInsurance? 
r35038: disabled friggin field focus 
r35230: #1032 Fixed hash-link insertion 
r35887: conditionally setting parameters in sourceID() - to avoid empty overrides
r35892: Saving value in SQL-compatible format (YYYY-MM-DD instead of DD/MM/YYYY), with fallback for non-sql values (just passed through without conversion) 
r35928: Removed "create a" from PageType?-dropdown, sorting alphabetically, falling back to $singular_name
r35990: branched off for membertablefield
r35994: fix for membertablefield
r36024: added array-condition needed for DMYDateField 
r36083: fix bug for compositeField -> dropDatalessField
r36394: removed debug code 
r36826: change wrong indent format 
r36828: WIP 4262: Logging out of My Inform goes to blank page
r36858: Fixed error caused in r12472 while merging to Session-class
r37132: Merged partial changesets from branches/2.0-nzct, only adding childID to detailform when not in add-mode 
r40815: add an unsubscribe record when a member subscribe a newslettertype 
r41113: fix the bug described in http://support.silverstripe.com/info/ticket/31: CRM not showing search results
r43226: fixed search (partial merge from trunk) 
r43268: merged createNewPassword() from trunk, was referencing a non-existinent global function randomString()


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@45473 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-11-23 01:10:19 +00:00
Ingo Schommer
393caf4287 FEATURE made sapphire i18n-capable
FEATURE a little bit of german translation

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@43842 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-10-25 02:47:45 +00:00
Normann Lou
3bc0eaafbb implement validation to tablefield,
fixed bug on validation of datefield, emailfield, numericefield.
make CMS validation enabled.

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@40755 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-08-23 05:47:54 +00:00
Hayden Smith
4a5d9b03f8 Moved Sapphire module to open source path
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@39001 467b73ca-7a2a-4603-9d3b-597d59a354a9
2007-07-19 10:40:28 +00:00