Commit Graph

3163 Commits

Author SHA1 Message Date
Ingo Schommer
fd0c8ad4c0 Convert::upperCamelToLowerCamel()
Used to expose lowercase web service object keys in SS4,
without requiring an explicit field mapping for these.

The first use case is exposing File data:
[ID => 99, FileName => 'test'] becomes {"id": 99, "fileName": "test"} in JSON.
2016-06-23 12:27:54 +12:00
Hamish Friedlander
51d53f4b50 Merge pull request #5646 from open-sausages/pulls/4.0/config-table-name
API Allow table_name to be declared / introduce DataObjectSchema
2016-06-14 15:06:38 +12:00
Daniel Hensby
9e3f76832b
Merge branch '3' 2016-06-13 13:41:20 +01:00
Damian Mooyman
5e8ae41d47 API Refactor dataobject schema management into separate service
API Allow table_name to be configured via Config
2016-06-08 13:22:56 +12:00
Damian Mooyman
19a27d22a3 Cleanup PHP and PHPDoc
Remove some deprecated code
Deprecate some code
2016-06-08 10:00:21 +12:00
Loz Calver
0ad64387c7
Refactor duplicate code in Object 2016-06-07 16:17:58 +01:00
Loz Calver
429ce55756
FIX: ViewableData::setFailover() didn't remove cached methods 2016-06-07 16:17:49 +01:00
Sam Minnee
65eb0bde6a API: Look for templates of namespaced classes in subfolders.
This change will mean that SilverStripe\Control\Controller will look for its
template in templates/SilverStripe/Control/Controller.ss.

In order to preserve some backwards campatibility, non-namespaced classes
can have the templates stored in any template subfolder, but once you
add a namespace to a class, the namespaced path expression will need to
be a subfolder of <module>/templates or themes/<theme>/templates.

Layout and Content templates are stil supported as special template type,
Includes still functions but is a no-op. Other template subfolders should
not be used.
2016-06-07 14:36:00 +12:00
Loz Calver
6811f0969b
Improve performance of TokenisedRegularExpression 2016-05-24 10:30:10 +01:00
Daniel Hensby
65ba709271 Giving composer more responsibility over autoloading (#5572) 2016-05-24 08:40:05 +12:00
Daniel Hensby
cdb0b07345
Merge branch '3' 2016-05-20 14:20:33 +01:00
Daniel Hensby
016d39c81e
Merge branch '3.3' into 3.4 2016-05-20 12:34:10 +01:00
Daniel Hensby
4307aa36c8
Merge branch '3.2' into 3.3 2016-05-20 12:25:20 +01:00
Daniel Hensby
0c3d30e621
Merge branch '3.1' into 3.2 2016-05-20 12:24:47 +01:00
Will Rossiter
0a67052d6c Merge pull request #5564 from dhensby/pulls/3.1/manifest-optimisation
Efficiency improvement to class manifest
2016-05-20 14:32:43 +12:00
Daniel Hensby
118af06c3f
Efficiency improvement to class manifest 2016-05-19 12:47:29 +01:00
Michael van Schaik
3a277f3a5e Update ClassInfo to return arrays where expected (#5563)
These methods are expected to return an array instead of null (if $class doesnt exist);
- getValidSubClasses
- dataClassesFor
- subclassesFor
- ancestry

Fixes: #5562
Also see: https://github.com/silverstripe/silverstripe-framework/issues/5171
2016-05-19 12:28:35 +01:00
Damian Mooyman
574bc6038b Merge 3 into master
# Conflicts:
#	CONTRIBUTING.md
#	admin/css/screen.css
#	admin/css/screen.css.map
#	admin/javascript/LeftAndMain.EditForm.js
#	admin/javascript/LeftAndMain.js
#	admin/scss/_forms.scss
#	dev/Debug.php
#	docs/en/05_Contributing/01_Code.md
#	forms/DropdownField.php
#	model/DataObject.php
#	model/Versioned.php
#	model/fieldtypes/DBLocale.php
#	tests/forms/gridfield/GridFieldExportButtonTest.yml
#	tests/model/MoneyTest.php
#	tests/model/MoneyTest.yml
#	tests/model/SQLQueryTest.php
2016-05-18 18:36:10 +12:00
Damian Mooyman
303f695751 Merge 3.3 into 3
# Conflicts:
#	admin/javascript/LeftAndMain.EditForm.js
2016-05-18 17:29:30 +12:00
Damian Mooyman
dad7981332 Merge 3.2 into 3.3 2016-05-18 17:27:28 +12:00
Damian Mooyman
8dfeeb0eb6 Merge 3.1 into 3.2 2016-05-18 17:25:42 +12:00
Damian Mooyman
62bd26d11a BUG Fix suppression of display_errors in ErrorControlChain 2016-05-18 13:36:54 +12:00
Damian Mooyman
d52db0ba34 Merge 3 into master
# Conflicts:
#	.travis.yml
#	admin/css/ie7.css
#	admin/css/ie7.css.map
#	admin/css/ie8.css.map
#	admin/css/screen.css
#	admin/css/screen.css.map
#	admin/javascript/LeftAndMain.js
#	admin/scss/_style.scss
#	admin/scss/_uitheme.scss
#	control/HTTPRequest.php
#	core/Object.php
#	css/AssetUploadField.css
#	css/AssetUploadField.css.map
#	css/ConfirmedPasswordField.css.map
#	css/Form.css.map
#	css/GridField.css.map
#	css/TreeDropdownField.css.map
#	css/UploadField.css
#	css/UploadField.css.map
#	css/debug.css.map
#	dev/Debug.php
#	docs/en/00_Getting_Started/00_Server_Requirements.md
#	docs/en/02_Developer_Guides/06_Testing/00_Unit_Testing.md
#	docs/en/02_Developer_Guides/06_Testing/index.md
#	docs/en/02_Developer_Guides/14_Files/02_Images.md
#	docs/en/02_Developer_Guides/15_Customising_the_Admin_Interface/How_Tos/Extend_CMS_Interface.md
#	filesystem/File.php
#	filesystem/Folder.php
#	filesystem/GD.php
#	filesystem/Upload.php
#	forms/ToggleField.php
#	forms/Validator.php
#	javascript/lang/en_GB.js
#	javascript/lang/fr.js
#	javascript/lang/src/en.js
#	javascript/lang/src/fr.js
#	model/Image.php
#	model/UnsavedRelationList.php
#	model/Versioned.php
#	model/connect/MySQLDatabase.php
#	model/fieldtypes/DBField.php
#	model/fieldtypes/Enum.php
#	scss/AssetUploadField.scss
#	scss/UploadField.scss
#	templates/email/ChangePasswordEmail.ss
#	templates/forms/DropdownField.ss
#	tests/behat/features/bootstrap/SilverStripe/Framework/Test/Behaviour/CmsFormsContext.php
#	tests/behat/features/bootstrap/SilverStripe/Framework/Test/Behaviour/CmsUiContext.php
#	tests/forms/EnumFieldTest.php
#	tests/security/MemberTest.php
#	tests/security/MemberTest.yml
#	tests/security/SecurityTest.php
2016-04-29 17:50:55 +12:00
Daniel Hensby
8673ac15bc
MINOR Empty YAML config causes invalid argument error 2016-04-26 12:58:27 +01:00
Daniel Hensby
679185514d
Merge 3.3 into 3
Conflicts:
	admin/css/screen.css.map
2016-04-26 00:24:59 +01:00
Daniel Hensby
745faebd81
Merge 3.2 into 3.3
Conflicts:
	.travis.yml
2016-04-26 00:17:09 +01:00
Daniel Hensby
a0812f987a
Merge 3.1 into 3.2
Conflicts:
	admin/javascript/LeftAndMain.js
	control/HTTPRequest.php
	docs/en/00_Getting_Started/00_Server_Requirements.md
2016-04-26 00:09:33 +01:00
Damian Mooyman
5900893753 API Implement campaign list view 2016-04-14 12:02:59 +12:00
Patrick Nelson
0aec89d0c8 FIX for #5279 Addressing only a few PSR-2 items in one file, but primarily targeting Director::is_https() and invalid URL's. 2016-04-06 18:26:47 -07:00
Damian Mooyman
6ec2656201 BUG fix ErrorControlChain causing errors to be displayed if display_errors in php.ini is false
Fixes #5250
2016-04-01 11:04:06 +13:00
Damian Mooyman
e8a68c42ce BUG Prevent live manifest loading files from nested test directories
E.g. framework/admin/tests
2016-03-31 15:58:23 +13:00
Damian Mooyman
094745ec0f API Formally support custom ownership relations
API 'owned_by' is no longer mandatory for relations backed by normal db relations
API Extension setOwner/clearOwner is now nested
2016-03-23 14:49:34 +13:00
Sam Minnee
f5af0c85ba FIX: Don’t use SplFixedArray in PHP 7.
PHP 7 seems to suffer a segfault when using SplFixedArray. Since LRU is
deprecated anyway, I’m not too fussed about getting to the bottom of
this issue, however, if it turns out that SplFixedArray is corrected in
PHP 7.0.0 stable or a future patch release, we could update this check.
2016-03-22 18:09:38 +13:00
Sam Minnee
262f487053 MINOR: Avoid access-changing subclass in test.
Using a subclass to change the visibility of protected items didn’t
seem necessary in this case, if we add a reasonably logical getter
method.
2016-03-22 17:39:09 +13:00
Sam Minnee
12a83d70ae FIX: Removed PHP4 syntax from Diff.php
Like SimpleTest, we should probably replace this for a new library,
but for now this will help us achieve PHP7 support.
2016-03-22 17:39:08 +13:00
Simon Erkelens
debe8ba2a3 Improvement: Set the owner on an extension, before getting all the available method names.
This enhances the extensions to enable certain features like adding wrapper methods instead of having to have them on the object itself.
2016-03-21 02:36:34 +01:00
Daniel Hensby
add2ecdf8b FIX Parameter tokens now redirect to correct url if mod_rewrite is off 2016-03-18 15:56:39 +00:00
Damian Mooyman
3dada00905 Cleanup trailing whitespace 2016-03-09 10:20:31 +13:00
Ingo Schommer
f36b110db3 Merge remote-tracking branch 'origin/3.3' 2016-03-04 17:06:04 +13:00
Ingo Schommer
04e9376a5a Exclude node_modules from manifests
Believe it or not, some node modules contain PHP files,
which get included by default otherwise.

This also fixes a performance regression on ?flush,
the existence of node_modules will cause a lot of unneccesary file lookups.
2016-02-29 21:17:38 +13:00
Damian Mooyman
2b26511faa Merge branch '3.3' into 3 2016-02-27 21:20:15 +13:00
Daniel Hensby
b7b1aba3fb FIX undeclared constant issue 2016-02-27 21:01:57 +13:00
Daniel Hensby
c2a0e8945f FIX undeclared constant issue 2016-02-27 21:00:45 +13:00
Daniel Hensby
3d2fcf9087 Fixing undeclared constant issue 2016-02-26 14:45:07 +00:00
Damian Mooyman
c275c21057 API Extensible::invokeWithExtension has same method signature as Extensible::extend 2016-02-25 17:32:41 +13:00
Damian Mooyman
3b0a9f4ba2 Merge remote-tracking branch 'origin/3'
# Conflicts:
#	admin/javascript/LeftAndMain.Menu.js
#	control/HTTPRequest.php
#	css/GridField.css
#	css/GridField.css.map
#	docs/en/02_Developer_Guides/03_Forms/Field_types/01_Common_Subclasses.md
#	docs/en/02_Developer_Guides/06_Testing/00_Unit_Testing.md
#	docs/en/02_Developer_Guides/06_Testing/index.md
#	docs/en/02_Developer_Guides/14_Files/01_File_Management.md
#	docs/en/02_Developer_Guides/14_Files/02_Images.md
#	filesystem/Upload.php
#	javascript/HtmlEditorField.js
#	model/Image.php
#	model/connect/MySQLDatabase.php
#	model/fieldtypes/Enum.php
#	model/versioning/Versioned.php
#	scss/GridField.scss
2016-02-25 14:51:59 +13:00
Damian Mooyman
9fed5561f4 Merge remote-tracking branch 'origin/3.3' into 3
# Conflicts:
#	core/Constants.php
#	dev/DevelopmentAdmin.php
2016-02-24 17:39:04 +13:00
Ingo Schommer
37059eb6b3 [ss-2016-003] Hostname, IP and Protocol Spoofing through HTTP Headers 2016-02-24 11:47:16 +13:00
Ingo Schommer
faa94d51d5 [ss-2016-003] Hostname, IP and Protocol Spoofing through HTTP Headers 2016-02-24 11:33:54 +13:00
Ingo Schommer
893e49703d [ss-2016-003] Hostname, IP and Protocol Spoofing through HTTP Headers 2016-02-18 17:28:54 +13:00