Commit Graph

156 Commits

Author SHA1 Message Date
Sean Harvey
87a8af00c5 BUGFIX Fixed array to string conversion error in Date::setValue() (from r82749)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@89718 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-21 02:30:07 +00:00
Andrew Short
55408946a6 MINOR: Parse HTMLText and HTMLVarchar values with ShortcodeParser before inserting into a template.
From: Andrew Short <andrewjshort@gmail.com>

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@88475 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-11 00:06:59 +00:00
Andrew Short
365b4784a9 FEATURE: Refactored ViewableData. The main changes are:
* Values are not always casted before being rendered into a template.
	* Casting information can by dynamically provided by $casting_properties, rather than being hardcoded to $casting and $db.
	* Removed unneeded ViewableData_Iterator - ArrayIterator is instead used.
	* Removed ViewableData_ObjectCustomised - now just uses ViewableData_Customised.
ENHANCEMENT: Added template and value methods to database fields.
MINOR: Added ViewableDataTest and extended DataObjectTest.

From: Andrew Short <andrewjshort@gmail.com>

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@88474 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-11 00:06:58 +00:00
Geoff Munn
ddfc0613ad MINOR CHANGE: numeric datatypes changed to support array types
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87895 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-01 21:03:52 +00:00
Geoff Munn
acba65eaaa API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87568 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:02:35 +00:00
Geoff Munn
c2cb8dd4b9 API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87567 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:02:28 +00:00
Geoff Munn
05014765e6 API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87566 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:01:59 +00:00
Geoff Munn
dd31eb1754 API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87565 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:01:51 +00:00
Geoff Munn
e0334112f9 API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87564 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:01:41 +00:00
Geoff Munn
fa4be08785 API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87563 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:01:30 +00:00
Geoff Munn
d07871c372 API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87562 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:01:15 +00:00
Geoff Munn
c1e32fb3db API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87561 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:01:06 +00:00
Geoff Munn
9cb252d976 API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87560 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:00:56 +00:00
Geoff Munn
acbff3b95a API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87559 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:00:45 +00:00
Geoff Munn
8cd96982c9 API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87558 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:00:36 +00:00
Geoff Munn
772c1136d4 API CHANGE: array data type now supported
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@87557 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-29 22:00:27 +00:00
Sean Harvey
2fdb548594 Merged Text::ContextSummary() changes from branches/2.3 - r82035 and r82036
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@86669 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-18 02:53:46 +00:00
Sean Harvey
a1d20b8ae9 BUGFIX #3228 Fixed undefined offset error in Text::BigSummary() if trying to summarise text that is smaller than the requested word limit
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@85076 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-08-24 06:16:56 +00:00
Normann Lou
5c68bb3bde BUGFIX: an time field input between 12:00pm to 12:59pm can't save back to database or always save as 00:00:00.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@84086 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-08-10 03:56:59 +00:00
Ingo Schommer
26d7985877 MINOR Documentation in DBLocale
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@83968 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-08-06 21:24:15 +00:00
Will Rossiter
1b4eed87ec BUGFIX: Allow percentage fields to store 100%. Merged From 2.2 r83164
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@83179 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-07-29 23:58:27 +00:00
Normann Lou
ce9a4b158d FEATURE: plug in Postful mailling function to Process, making faking process for testing the postful mail functions. The two faking processes is implemented in two functions LotTicketedBased::fakepopulate() and ISSOrderDecorator::fakepopulatepayment().
FEATURE: customise OrderAdmin by ISSOrderAdmin.
ENHANCEMENT: refactoring Preview feature for PostfulMail.
ENHANCEMENT: add hasAmount to Menoy Class

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@82629 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-07-24 03:16:20 +00:00
Sam Minnee
a738dc2027 BUGFIX: returns duplicated number of the same sentences (from r78773, r78778)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@81472 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-07-09 06:14:04 +00:00
Sam Minnee
f41e2b474c ENHANCEMENT: Improved performance of admin/assets area.
BUGFIX: Fixed bug in 'sake interactive' error handling.
BUGFIX: Fixed bugs with MSSQL and Windows support.
API CHANGE: Added FormAction::setButtonContent()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@80782 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-07-01 22:27:18 +00:00
Sam Minnee
ef82fe2859 MINOR #3776: Fixed documentation
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@80222 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-06-27 07:42:31 +00:00
Sam Minnee
c52f67aae5 MINOR ajshort: Replaced usage of the deprecated split() function with preg_split().
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@79568 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-06-18 09:34:17 +00:00
Ingo Schommer
6fa83caae6 ENHANCEMENT Making SSDatetime mockable through SSDatetime::set_mock_now()
ENHANCEMENT SSDatetime::now()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@79503 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-06-18 00:10:02 +00:00
Sean Harvey
6c754d29e9 Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@79438 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-06-17 11:36:49 +00:00
Ingo Schommer
e1e9295fb5 MINOR Simplified definition on Money::$composite_db - the ORM doesn't handle array-style definitions currently, which means DataObject::custom_database_fields() etc. will fail
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@78234 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-06-02 03:41:26 +00:00
Ingo Schommer
7bef503953 MINOR Documentation for CompositeDBField
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77895 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-27 00:32:37 +00:00
Ingo Schommer
dfa44c055c API CHANGE Changing DataObject::$changed to private visiblity. Please use getChangedFields() and isChanged()
ENHANCEMENT Added DataObject->isChanged() to detect if a field has been changed in this object instance
MINOR Changing call to CompositeDBField->compositeDatabaseFields() in DataObject->hasOwnDatabaseField()
BUGFIX Unsettig "Version" property in DataObject->getChangedField() to allow versioned to write a new version after a call to forceChange()
BUGFIX Introduced $markChanged in Money class
BUGFIX Casting Money->__toString() return value as string
MINOR Changing Member class to use new DataObject->isChanged() API
BUGFIX Using new $markChanged API for CompositeDBFields in DBField::create()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77893 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-27 00:09:23 +00:00
Ingo Schommer
c7768d8820 API CHANGE Added interface methods to CompositeDBField
MINOR Documented CompositeDBField

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77892 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-27 00:05:10 +00:00
Ingo Schommer
2a58703ecf BUGFIX Money->setValue() was not working when loading $value and $record parameters, and only $record had a
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77790 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-26 01:08:27 +00:00
Ingo Schommer
b478c8be34 FEATURE Added MoneyField as a form field to edit Money values
ENHANCEMENT Using MoneyField in Money->scaffoldFormField()
BUGFIX Fixed Money->setValue() to respect $value parameter over $record to avoid wrongly updated values from stale $record values instead of new $value

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77772 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-25 22:21:02 +00:00
Ingo Schommer
4d55f1e5d7 BUGFIX Fixed Money->Nice() to provide symbol and currency shortname based on Money->getCurrency()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77754 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-25 06:03:06 +00:00
Sean Harvey
ee072565ec API CHANGE Removed @deprecated method Text::LimitWordCountPlainText(): Please use Text::LimitWordCount() instead
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77635 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-22 04:54:51 +00:00
Ingo Schommer
a2a507f73c BUGFIX Fixed Money->writeToManipulation() to correctly overwrite with NULL values
ENHANCEMENT Added Money->NiceWithName()
ENHANCEMENT Changed Money->NiceWithShortname() to use Zend_Currency options
BUGFIX Setting isChanged flag on Money individual setters
MINOR Added Money->__toString()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77548 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-21 04:46:58 +00:00
Sean Harvey
ed39a9e369 API CHANGE Removed @deprecated 2.3 method Varchar::Attr() on Varchar: Please use Varchar::ATT_val() instead
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77380 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-20 06:25:15 +00:00
Ingo Schommer
7a18cd8bec BUGFIX Fixed quoting in Money
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77132 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-19 01:58:29 +00:00
Sean Harvey
5322ecc692 ENHANCEMENT SSDatetime->setValue() can now set a timestamp, consistently working the same as Date does
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77120 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-19 00:35:15 +00:00
Geoff Munn
a4cf64f105 Formatting fixed
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77099 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-18 21:24:33 +00:00
Geoff Munn
b0a56e7d37 Enum values now include table name
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@77098 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-18 21:24:02 +00:00
Ingo Schommer
84089a1b7d BUGFIX Increased decimal precision of Money->Amount database column to support currencies with a greater precision than 2 digits.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@76743 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-13 22:21:17 +00:00
Ingo Schommer
4085b3e654 BUGFIX Added Money->addToQuery() to work around changes in the ORM which require database columns to be explcitly selected
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@76664 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-12 05:29:59 +00:00
Sam Minnee
29afa282b9 BUGFIX: Added default values for Money's component fields, to work with more picky databases.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@76368 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-07 05:58:10 +00:00
Normann Lou
b50d564a5c BUGFIX: pass-in the params in right order when constructing of Zend_Currency in Money Constructor. Add NiceWithShortname function.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@76299 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-06 23:32:57 +00:00
Sean Harvey
b20b6e0f95 Merged from 2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@76269 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-06 06:36:16 +00:00
Normann Lou
7a4320f339 ENHANCEMENT: set the DBField name to its scaffoldFormField id, so that we could get if from other places.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@76257 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-06 05:50:18 +00:00
Normann Lou
d9ea21c68e MINOR: delete debug info
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@76145 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-06 01:07:03 +00:00
Ingo Schommer
5e8e47ef77 FEATURE Added Money class for managing monetary amounts with currencies through the Money design pattern. Uses the CompositeDBField interface to contain multiple database columns in a single DBField
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@76100 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-05 08:10:51 +00:00