Commit Graph

2820 Commits

Author SHA1 Message Date
Hamish Friedlander
d355cd5baf ENHANCEMENT: Add config layer - the Config access class itself, and the ConfigManfiest builder which parses in the yaml config files 2012-03-09 18:13:56 +13:00
Sam Minnee
adbcf61c56 MINOR: Minor fixes after new SS_List interfaces cleanup 2012-03-09 17:50:32 +13:00
Sam Minnee
a55e06f6b5 API CHANGE: Introduce SS_Limitable class for adding to SS_Lists that have limit capability.
API CHANGE: Deprecated SS_List::getRange() in favour of SS_Limitable::limit().
API CHANGE: Introduce SS_Limitable::limit($limit, $offset = 0) as the only modern way of specifying limits; deprecate all others.
2012-03-09 17:07:40 +13:00
Hamish Friedlander
407913f2cf MINOR: Add workaround for hitting XDebugs fairly conservative nesting level limit 2012-03-06 09:31:56 +13:00
Hamish Friedlander
927dbbe717 API-CHANGE: Global template variables can now be called directly using SSViewer_DataPresenter instead of needing to inherit off ViewableData 2012-03-06 09:11:46 +13:00
Dominik Beerbohm
7927fffc0a AP(RE)CHANGE Exclude files with the underscore prefix from manifest. 2012-03-03 15:10:09 +01:00
AngryPHPNerd
2457c4f0bc BUGFIX: Eescape / in RegExp. 2012-02-28 00:44:27 +01:00
AngryPHPNerd
0e2cbb0b88 Replace ereg with preg_* 2012-02-27 22:14:02 +01:00
Simon Welsh
7658e902fc BUGFIX Convert::html2raw() not correctly stripping script and style tags 2012-02-15 07:55:52 +13:00
Fred Condo
d370423825 Clean up trailing ?> per coding standard
All sapphire but the lang directory
2012-02-12 12:40:16 -08:00
Simon Welsh
741f104749 FEATURE Allow setting of constant CUSTOM_INCLUDE_PATH in _ss_enivronment.php which is prepended to the include path 2012-02-11 14:33:55 +13:00
Sam Minnée
2c770a6f8f Merge pull request #146 from simonwelsh/namespace-manifest
BUGFIX Namespaced classes were always having their namespace prepended t...
2012-01-06 15:58:46 -08:00
Ingo Schommer
4056b94f75 BUGFIX Improved ClassInfo::ancestry() performance through in-memory caching and removal of unnecessary is_object() check - get_class() will complain if its not passed an object already) 2012-01-02 16:49:33 +01:00
Simon Welsh
dd546a9888 BUGFIX Merge request arrays recursively 2011-12-23 17:48:49 +13:00
Simon Welsh
27a51ed7ed BUGFIX Namespaced classes were always having their namespace prepended to their base class 2011-12-23 10:24:42 +13:00
Ingo Schommer
05d19d9a82 Revert "MINOR Use json_decode() instead of the Services_JSON class if the function exists." - it breaks assumptions around Convert::json2array() only converting the *first* level of an object structure into an array, which in turn fails CMSMainTest and LeftAndMainTest (as well as some UI functionality relying on it). In order to introduce this change we have to fix these issues in a backwards compatible manner.
This reverts commit 3a006b77ae.
2011-12-18 20:17:41 +01:00
Hamish Friedlander
be9286fbc4 Merge pull request #132 from simonwelsh/namespace-manifest 2011-12-17 15:40:06 +13:00
Sam Minnée
fdb8665a43 Merge pull request #133 from simonwelsh/54_fixes
MINOR Change error reporting level to explicitly exclude values rather t...
2011-12-16 18:04:42 -08:00
Simon Welsh
10b09420be MINOR Change error reporting level to explicitly exclude values rather than using XOR. 2011-12-17 14:40:58 +13:00
Simon Welsh
da2ac79205 BUGFIX Check for the correct type for $data['namespace'] 2011-12-17 14:32:14 +13:00
Simon Welsh
3e6a91a07f ENHANCEMENT Allow ClassManifest to handle classes with namespaces, or that extend classes in namspaces or that implement interfaces in namespaces. 2011-12-17 14:03:53 +13:00
Sam Minnée
dd495fb8bf Merge pull request #130 from sminnee/master
Fixed tests for PHPUnit 3.6
2011-12-16 15:19:47 -08:00
Sam Minnee
70d40cf4df BUGFIX: Removed use of base "Exception" class in order to avoid failures on PHPUnit 3.6. 2011-12-17 11:51:40 +13:00
simonwelsh
3a006b77ae MINOR Use json_decode() instead of the Services_JSON class if the function exists. 2011-12-10 08:57:45 +13:00
Ingo Schommer
755663a00a BUGFIX Set default mbstring encoding in Core.php instead of main.php and cli-script.php so phpunit binary test runs behave consistently (same as running through TestRunner+cli-script.php). Fixes URLSegmentFilterTest 2011-12-04 13:32:03 +01:00
Ingo Schommer
9b27a4c1be ENHANCEMENT More flexible URL filtering through new URLSegmentFilter API. Support for multibyte URL segments through URLPathFilter::$default_allow_multibyte. Abstraction from Convert::raw2url() (and SiteTree->generateURLSegment()) 2011-11-29 11:04:08 +01:00
Sam Minnee
da64123116 MINOR: Removed use of deprecated ClassInfo::is_subclass_of 2011-10-29 17:34:32 +13:00
Sam Minnee
e5afa25522 MINOR: Use Deprecation class to indicate deprecated methods in core. 2011-10-29 17:34:31 +13:00
Sam Minnée
d88b39f292 Merge pull request #81 from stojg/release/object-create
MINOR Object::create should not call a constructor if there aren't one.
2011-10-28 16:34:58 -07:00
Simon Welsh
5ad5dfc7ed Changes error reporting level to explicitly exclude E_DREPRECATED and E_STRICT, rather than xor. 2011-10-29 10:28:18 +13:00
Stig Lindqvist
e38dd08ea5 MINOR: Fix docblocks to reference SS_List instead of (now deprecated) DataObjectSet where appropriate 2011-10-28 15:58:55 +13:00
Stig Lindqvist
3a11bb2f66 MINOR Do not call a constructor if there aren't one.
This will fix a lot of unittests failing.
2011-10-27 18:13:41 +02:00
Fred Condo
9bd499617b Spelling correction
Found and fixed all misspellings of "[Hh]ierarchy"
2011-10-18 15:32:52 -07:00
Ingo Schommer
670eec95cb MINOR Documentation 2011-10-07 22:57:23 +02:00
Ingo Schommer
3a5b3af7c6 BUGFIX Fixed tag stacking in Diff.php thirdparty lib (AIR-71) 2011-10-07 14:12:52 +02:00
Ingo Schommer
03db2894db ENHANCEMENT Optional HTML escaping in Diff::compareHTML() (tested implicitly in DataDifferencerTest for sapphire) (AIR-56) 2011-10-07 14:12:52 +02:00
Ingo Schommer
72d5423ac5 MINOR Removed debug code from Diff.php 2011-10-07 14:12:52 +02:00
Ingo Schommer
d6f4b24066 MINOR Allowing array-based values in Diff->getHTMLChunks() by imploding on comma (AIR-39) 2011-10-07 14:12:51 +02:00
Sam Minnee
0601384cda BUGFIX: Reapply decorator statics if it has been removed and re-added. (merged from r100706) 2011-10-07 14:12:50 +02:00
Ingo Schommer
715638333e API CHANGE Obeying existing memory_limit settings in increase_memory_limmit_to(). Introduced set_increase_memory_limit_max() and set_increase_time_limit_max() 2011-10-07 14:12:48 +02:00
Will Rossiter
1732a17114 Merged new-orm into datagrid 2011-09-26 16:47:54 +13:00
Ingo Schommer
ce8e72cf0e MINOR Removing executable flag from all files (thanks miiihi) 2011-09-18 22:04:02 +02:00
Sam Minnee
878b348a0f Merge branch 'master' into new-orm
Conflicts:
	docs/en/reference/built-in-page-controls.md
	model/SQLQuery.php
2011-05-26 17:08:10 +12:00
ajshort
3f132a105b API CHANGE: Replaced DataObjectSet instances with ArrayList. 2011-05-05 20:40:24 +10:00
ajshort
04e5dae22e MINOR: Updated places that expect a DataObjectSet to accept an SS_List instance. 2011-05-02 17:14:05 +10:00
ajshort
54a5fc6a74 BUGFIX: Fixed the manifest not parsing interfaces which extended from multiple interfaces. 2011-05-02 10:37:26 +10:00
Ingo Schommer
37774d4103 ENHANCEMENT Added ClassManifest->getModules(), and removed limitation to toplevel modules in ClassManifest->handleFile() (necessary to detect new sapphire/admin/ "submodule") 2011-05-01 20:23:07 +12:00
Ingo Schommer
ea9faeccf7 API CHANGE Removed Object->cacheToFileWithArgs(), please use Object->cacheToFile() with the $arguments param 2011-05-01 20:23:07 +12:00
Sam Minnee
a15b6941a6 BUGFIX: Replaced ManifestBuilder::has_been_included() with SS_ClassLoader::hasManifest(). 2011-05-01 17:12:26 +12:00
ajshort
34e9ddfcc3 MINOR: Moved files from /core/model into /model. 2011-05-01 15:26:30 +12:00
ajshort
81c0caaddb API CHANGE: Renamed DataList::filter() and DataQuery::filter() to ::where(). 2011-05-01 15:26:30 +12:00
ajshort
8ec412e4d9 MINOR: Updated PaginatedList to be a list decorator. 2011-05-01 15:26:30 +12:00
ajshort
45a8866fab FEATURE: Added SS_ListDecorator, which is a utility class used to create decorators which wrap around a list instance, but are stll recognised as a list. 2011-05-01 15:26:29 +12:00
ajshort
3fbb29a6c5 FEATURE: Added PaginatedList, which wraps around a data list or set to provide pagination functionality. This replaces the pagination functionality baked into DataObjectSet.
API CHANGE: Removed pagination related methods from DataObjectSet and implemented them on PaginatedList.
API CHANGE: Removed DataObjectSet::parseQueryLimit(), this is now implemented as PaginatedList::setPaginationFromQuery().
API CHANGE: Deprecated DataObjectSet::TotalItems in favour of Count().
ENHANCEMENT: Added FirstLink and LastLink to PaginatedList.
MINOR: Updated documentation, and added a how-to on paginating items.
2011-05-01 15:26:29 +12:00
Sam Minnee
7efd19e7cb BUGFIX: Fixed DataList arrayaccess. 2011-05-01 15:26:28 +12:00
Sam Minnee
8db236f444 BUGFIX: Fixed DataList::relation(). 2011-05-01 15:26:28 +12:00
Sam Minnee
3a17d5c427 API CHANGE: Add removeByID(), canSortBy(), and byID() to DataList and its subclasses. 2011-05-01 15:26:01 +12:00
Sam Minnee
c615c4eb91 ENHANCEMENT: First cut of running SearchContext through DataList/DataQuery. Note that the eventual goal is probably to ditch SearchContext entirely. 2011-05-01 15:25:58 +12:00
Sam Minnee
050e0675ce ENHANCEMENT: Created HasManyList and ManyManyList objects that represent relations. API CHANGE: Relation methods no longer cache their results. API CHANGE: ComponentSet is deprecated. API CHANGE: DataObject::getManyManyComponentsQuery() no longer exists; just use the ManyManyList itself. API CHANGE: DataObject::getManyManyJoin() no longer exists; just use the ManyManyList itself. API CHANGE: DataObject::getManyManyFilter() no longer exists; just use the ManyManyList itself. 2011-05-01 15:25:45 +12:00
Sam Minnee
de1494e3a8 ENHANCEMENT: Implemented DataList as the successor of DataObjectSet. DataList doesn't execute the query until it's actually needed, allowing for a more flexible ORM.
API CHANGE: augmentSQL is now passed a DataQuery object from which query parameters can be extracted.
API CHANGE: DataObjectDecorators that manipulate the query can now define augmentDataQueryCreation().
API CHANGE: The container class argument for DataObject::get() is deprecated.
API CHANGE: DataObject::buildSQL() and DataObject::extendedSQL() are deprecated; just use DataObject::get() now.
API CHANGE: DataObject::instance_get() and DataObject::instance_get_one() are deprecated, and can no longer be overloaded.
API CHANGE: DataObject::buildDataObjectSet() is deprecated.
API CHANGE: Cant't call manual manipulation methods on DataList such as insertFirst()
2011-05-01 15:25:45 +12:00
ajshort
3a1c2df4e7 API CHANGE: Renamed DataObjectDecorator to DataExtension.
API CHANGE: Renamed LeftAndMainDecorator to LeftAndMainExtension.
MINOR: Replaced all references to decorators with extension.
2011-04-26 11:01:38 +10:00
Simon Welsh
44dabbb865 Landing pull request 3. BUGFIX: Object::__call() checking the wrong static. Fixes #6438 2011-04-25 23:11:09 +12:00
Ingo Schommer
9b29616710 API CHANGE Rearranged files in sapphire to reflect core dependencies more accurately, and have the tests/ folder mirror its folder structure 2011-03-31 09:56:21 +13:00
Julian Seidenberg
eaa6c6c49d API-CHANGE: removing protected object_to_array method (use get_object_vars instead) 2011-03-30 18:16:17 +13:00
Julian Seidenberg
5ea4615d4d ENHANCEMENT: Refactoring and documenting the ArrayData class. Deprecating the "object_to_array" method (fixes #4875, thanks tobych) 2011-03-30 18:16:17 +13:00
Julian Seidenberg
0b93a8f7cf API-CHANGE: Allowing non-standard path for session store 2011-03-30 18:16:16 +13:00
Julian Seidenberg
a204c136fe API CHANGE: JSONDataFormatter builds JSON itself, changing it to use Convert::array2json() instead (fixes #5162, thanks sharvey) 2011-03-30 18:16:12 +13:00
Julian Seidenberg
7ebe602482 BUGFIX: Enum now escapes field values (fixes #6437, thanks simon_w) 2011-03-30 18:12:35 +13:00
Julian Seidenberg
f94be66cb2 BUGFIX: HTMLText.Summary() will return nothing if there's an image at the beginning. Regex to strip out the image and unit tests (fixes #6436, thanks webbower) 2011-03-30 18:12:31 +13:00
Julian Seidenberg
341245dd4a ENHANCEMENT Allowing custom HTMLCleaner implementations via Diff:: and new TidyHTMLCleaner and PurifierHTMLCleaner classes 2011-03-30 18:02:25 +13:00
Ingo Schommer
5f59b3a3c9 MINOR Fixed paths due to file moving into sapphire/admin 2011-03-29 18:08:32 +13:00
Ingo Schommer
1225426e75 MINOR Fixed @package declarations 2011-03-29 18:07:58 +13:00
Ingo Schommer
3f3f0f6211 API CHANGE Moved SiteTree->doRollbackTo() to Versioned class 2011-03-29 18:07:58 +13:00
Ingo Schommer
502131171b BUGFIX Declaring has_many "Versions" relationship according to decorated class in Versioned->extraStatics() 2011-03-29 18:07:58 +13:00
Ingo Schommer
a9b13509d2 MINOR Removed dependency on SiteTree in various unit tests 2011-03-29 18:07:58 +13:00
Ingo Schommer
463b23baee MINOR Exception when SiteTree or File are not present in MySQLDatabase->searchEngine() 2011-03-29 18:07:57 +13:00
Ingo Schommer
357ea56c02 BUGFIX Replaced hardcoded SiteTree dependency in DataObjectSet->groupWithParents() with method parameter 2011-03-29 18:07:57 +13:00
Ingo Schommer
7e5da27443 MINOR Added comments to DataObject->can() 2011-03-29 18:07:57 +13:00
Ingo Schommer
42fa7572e7 MINOR Moved CurrentPageIdentifier from 'sapphire' to 'cms' module 2011-03-29 18:07:56 +13:00
Ingo Schommer
4adcdba226 MINOR Moved SilverStripeNavigator from 'sapphire' to 'cms' 2011-03-29 18:07:56 +13:00
Ingo Schommer
d61444e976 API CHANGE Moved Translatable class into new 'translatable' module 2011-03-29 18:07:56 +13:00
Paul Meyrick
eb221ca821 MINOR Moved Diff class from cms to sapphire module (cms/code/Diff.php) 2011-03-29 18:07:55 +13:00
Paul Meyrick
dc36725869 MINOR Using BlankPage template in SecurityTest, BasicAuthTest to remove ContentController dependency
MINOR Checking for SiteTree class existence in Security, Translatable
MINOR Checking for ContentController existence in FulltextSearchable
MINOR Removed unnecessary ContentController tests from ObjectTest
MINOR Replaced CMS specific examples in PermissionCheckboxSetFieldTest, DataObjectTest
MINOR Changed SecurityTest to make assertions against Security/login rather than relying on redirection from admin/cms
2011-03-29 18:07:55 +13:00
Ingo Schommer
204fd2c4ce MINOR Moved SiteTree, SiteTreeDecorator, SiteConfig, ErrorPage, RedirectorPage, VirtualPage (and related tests) to "cms" module 2011-03-29 18:07:55 +13:00
Ingo Schommer
5bf5b744d8 MINOR Moved ContentController, ModelAsController, NestedController, RootURLController (and related tests) to "cms" module 2011-03-29 18:07:55 +13:00
Hamish Friedlander
5ca97c7099 BUGFIX: Make SSTemplateParser work with empty templates 2011-03-25 14:07:07 +13:00
ajshort
2d4fe274a6 API CHANGE: Removed unused SSViewer::getTemplateFile() and getTemplateContent().
MINOR: Updated SSViewer::getTemplateFileByType() to use the template loader.
2011-03-24 21:31:00 +11:00
ajshort
2c22dee176 API CHANGE: Updated i18n::get_owner_module() to only search classes, since it is never used to search for templates. 2011-03-24 21:31:00 +11:00
ajshort
c34105438c FEATURE: Replaced the template manifest with SS_TemplateLoader, which finds templates from a stack of SS_TemplateManifest objects. 2011-03-24 21:30:57 +11:00
ajshort
7df8929bc0 API CHANGE: Updated Requirements::themedCSS() to take two parameters - the CSS name and a fallback module. It first looks for the CSS file inside the current theme, then falls back to the CSS file inside the module. This eliminates the need for a CSS manifest. 2011-03-24 20:14:43 +11:00
ajshort
bc0a1b7a05 MINOR: Updated various methods to use new manifest methods rather than ManifestBuilder functions or globals. 2011-03-24 20:14:43 +11:00
ajshort
184da5bbcc FEATURE: Replaced ManifestBuilder (and related bootstrap code) with a new SS_ClassLoader class which loads classes and interfaces from a stack of SS_ClassManifest instances. 2011-03-24 20:14:42 +11:00
ajshort
852920237e MINOR: Updated ClassInfo::allClasses() and ::exists() to use $_CLASS_MANIFEST rather than $_ALL_CLASSES. This means results from ClassInfo::allClasses() are now lowercase. 2011-03-24 20:14:42 +11:00
ajshort
9caf597aee MINOR: Updated DataObject::buildSQL() to use DB::getConn() to check to see if a DB connection has been intialised rather than ManifestBuilder::has_been_included(). 2011-03-24 20:14:41 +11:00
ajshort
5c972b231d API CHANGE: Moved ManifestBuilder::get_themes() to SSViewer::get_themes(). 2011-03-24 20:14:41 +11:00
ajshort
969aa0b51e MINOR: Replaced deprecated ClassInfo::is_subclass_of() calls. 2011-03-24 20:14:41 +11:00
ajshort
803e67b87d API CHANGE: Refactored ClassInfo::subclassesFor() to traverse the child tree, rather than needing to store a list of every classes descendants.
API CHANGE: Updated ClassInfo::subclassesFor() so all the array keys are consistently the same as the values.
2011-03-24 20:14:41 +11:00
ajshort
f55cc7ec67 MINOR: Refactored ClassInfo::dataClassesFor() to use existing methods rather than creating the class array itself. 2011-03-24 20:14:41 +11:00
ajshort
eba1a85ead MINOR: Refactored ClassInfo::ancestry() to use inbuilt PHP methods rather than the parent manifest. 2011-03-24 20:14:41 +11:00
ajshort
0d03348926 API CHANGE: Refactored ClassInfo::baseDataClass() to use inbuilt PHP methods, and throw an exception if the passed class is not a subclass of DataObject. 2011-03-24 20:14:38 +11:00