Commit Graph

2166 Commits

Author SHA1 Message Date
Ingo Schommer
93dd7600df ENHANCEMENT Renamed tab "Meta-data" to "Metadata" for better readability (see #3142)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66654 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:38 +13:00
Ingo Schommer
29c2757841 ENHANCEMENT Fixed default level in HeaderField - was duplicating defaults already present in two other places (see r66639)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66646 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:38 +13:00
Sam Minnee
be6e67a20f DataObject::relObject() throws an exception rather than an error so that it can be caught
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66645 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:38 +13:00
Sean Harvey
7874d09771 MINOR Removed redundant code
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66640 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:38 +13:00
Sam Minnee
5f189c42da Set default level for HeaderField
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66639 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:38 +13:00
Sean Harvey
0d450e6c3a BUGFIX Fixed flaw logic checking for $member variable, since it's always set the alternative for choosing Member::currentUser() would never work.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66638 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
a2d5a9ac75 MINOR Code formatting of !isset($member) on SiteTree->canAddChildren() for consistency with other can*() methods
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66637 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
8089d7b14c MINOR Renamed to correct updateCMSActions() in php comment
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66636 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
640c50149d BUGFIX Fixed SiteTree->getCMSActions() so it returns a FieldSet, instead of a DataObjectSet. This makes it consistent with DataObject->getCMSActions() as well as SiteTree->getCMSFields()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66635 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
4713842790 BUGFIX Fixed SiteTree->getCMSActions() not extending properly because it was passing an array to the extend() 2nd argument, which expected a FieldSet object
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66632 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
8b57dc223d MINOR Moved File::find() to the top of the class for consistency with other classes
MINOR Added phpDoc comments for File::find()
MINOR Removed unused private static $dataobject_select in File

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66631 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
ed3ac6924f MINOR Code formatting cleanup in File->getAbsoluteSize()
MINOR phpDoc comments for File->getAbsoluteSize()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66630 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
53cef6b435 BUGFIX Fixed incorrect class name in user_error message for deprecated function HTTP::sendFileToBrowser()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66629 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
087cba096e MINOR Code formatting cleanup on CheckboxSetField->Field()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66628 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
ca2c814cd9 ENHANCEMENT Allow CheckboxSetField to use extra classes as other FormField classes do. Also dded test for this behaviour in CheckboxSetFieldTest.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66625 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
4950fdf0cb MINOR Added tests for checking extra class was added to DropdownField
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66624 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
0af4fb3673 MINOR Added tests for checking extra class was added to FormField subclasses (TextField, EmailField and OptionsetField)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66623 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sean Harvey
0e62bb5f7d ENHANCEMENT Sort test class list by alphabetical order so it's easier to read
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66622 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:37 +13:00
Sam Minnee
1d89795fda ENHANCEMENT: Added experimental support using (relname)Query methods to pass complex relations (those defined by methods) into searchfilter
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66583 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Sam Minnee
b877ddb546 Added support to DataObject::relObject() for looking at $casting to get information about the relation - good for dynamic relations
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66582 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Ingo Schommer
916df369d8 BUGFIX Consistenly returning cloned instances for all FormField classes when calling performReadonlyTransformation() or performDisabledTransformation(). Making sure that these instances are actually flagged as readyonly/disabled. Addd unit tests to dynamically instanciate most FormField classes to check for this behaviour. Originally, this bugfix was necessary to avoid changed FormField state when recursively calling replaceField() on FieldSet->dataFields() in Translatable->updateCMSFields()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66505 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Sean Harvey
3431e9815b BUGFIX Removed hacky code setting fields in the SearchForm constructor
BUGFIX Removed SearchForm->FormMethod() and used $this->setFormMethod() in SearchForm constructor instead which is a nicer solution instead of overloading a Form method

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66431 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Will Rossiter
07e9aaa547 MINOR: added setter function to write_js_on_body() so I can override the settings
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66426 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Normann Lou
92e7071412 APICHANG: if a DataObject has getCMSActions, its model admin should be able to add them.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66392 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Sam Minnee
9d1be81b41 Merge pre-2.3-oct08 into 2.3 (via trunk)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66353 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Sam Minnee
2606f99fb4 ENHANCEMENT: Added comments in rendered templates to indicate the source .ss files, on dev sites only:
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66343 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Ingo Schommer
77575e69b7 BUGFIX Hiding "change password" fields by default in admin/myprofile, they shouldn't validate the input by default. Replaced with a link to toggle those fields (#3106)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66334 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Ingo Schommer
4cc3ace3b8 ENHANCEMENT Added ConfirmedPasswordField->setShowOnClickTitle()
MINOR Documentation for ConfirmedPasswordField

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66333 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Ingo Schommer
03277b5349 BUGFIX Include jquery_improvements.js whenever jquery.js is required, so jQuery.noConflict() is set. This is required to ensure $() behaves in the prototypey way (alias for document.getElementByID()) rather than jQuery style (document.getElementsBySelector())
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66332 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Ingo Schommer
e772a4c1d4 ENHANCEMENT Respecting SiteTree->canView() settings in results (see #3052). This causes wrong counts, bugreport in #3120
ENHANCEMENT Added $data parameter to SearchForm->getResults() to remove dependency on $_REQUEST for better testability
ENHANCEMENT Added SearchForm->numPerPage - this shouldn't need to be passed around methods on every call, its instance specific
ENHANCEMENT Added SearchFormTest
MINOR Documentation for SearchForm


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66322 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Sean Harvey
5e3726ff43 ENHANCEMENT Added more known file extensions (tiff, js, html, css, ico) to File->getFileType()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66320 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:36 +13:00
Sean Harvey
55dbe2bf52 BUGFIX Check if $member variable isn't empty before looking for first name in MemberLoginForm
MINOR Coding conventions, inconsistent use of tabs and spaces

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66318 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:35 +13:00
Sean Harvey
e50b7369b7 BUGFIX Fixed call to incorrect case of function name, Member::currentUser() should be used
MINOR Code conventions (spaces should be between operator characters)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66317 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:35 +13:00
Ingo Schommer
a9bc9c6845 BUGFIX Fixed ForeignKey->scaffoldFormField() usage of model class instead of relation class to generate dropdown list
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66313 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:35 +13:00
Ingo Schommer
3a220c9e38 ENHANCEMENT Added support for $relationCallbacks on the importer class (in addition to methods on the model class)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66312 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:35 +13:00
Sean Harvey
76f15e47bf MINOR Removed old references from workflow in SiteTree and VirtualPage (AssignedToID and RequestedByID were old properites of a workflow page type)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66311 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:35 +13:00
Sean Harvey
29899c4396 BUGFIX Fixed HasManyComplexTableField, and subclass fields HasOneComplexTableField and ManyManyComplexTableField saving bug because javascript wasn't being included properly
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66306 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:35 +13:00
Sam Minnee
f15cfaccf4 BUGFIX: Fixed recursion bug with FieldSet::fieldPosition
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66305 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:35 +13:00
Sam Minnee
10c6c394b8 Fixed bug in test makefile
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66304 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:35 +13:00
Ingo Schommer
647c25ca14 MINOR Added isset($_SERVER['HTTP_HOST']) checks to Director->isDev() and Director->isTest() - these environment variables are not available in CLI mode, and show up as PHP notices in a default cli-script/sake execution
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66302 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:35 +13:00
Sam Minnee
e4bcce061c Build database before testing, for RestfulService test, etc
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66296 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00
Sean Harvey
c20e69d563 MINOR Code formatting in FormField
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66270 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00
Sam Minnee
b40dbbb2f0 BUGFIX: Merged from trunk; fix DataObject::hasDatabaseFields()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66269 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00
Sam Minnee
0eac163b11 API CHANGE: Deprecated Controller::PastVisitor(), it generates a lot of unused cookies
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66268 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00
Sam Minnee
03c88ba020 Return an HTTPResponse consistently from controllers
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66267 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00
Sam Minnee
6d5db643ab API CHANGE: Improve encapsulation of cookies in Director::test()
BUGFIX: Fix test/cookie conflict in ErrorPage rendering

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66266 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00
Sam Minnee
4f84e92dbf Fixed RequirementsTest
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66265 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00
Sam Minnee
adb03a1d88 BUGFIX: Removed unnecessary and bug-causing Behaviour.apply() call.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66251 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00
Andrew O'Neil
d76611f380 #2771: Fix SQLQuery::filtersOnID() (wakeless)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66225 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00
Andrew O'Neil
4c81b8c3a5 BUGFIX #2714 - Cookie::set doesn't operate correctly with expiryDays 0 (wakeless)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.3@66196 467b73ca-7a2a-4603-9d3b-597d59a354a9
2011-02-02 14:26:34 +13:00