Commit Graph

1061 Commits

Author SHA1 Message Date
Daniel Hensby
f25b88b146 showqueries debugging tool now inserts parameters in place (#5885) 2016-09-15 09:15:19 +12:00
Daniel Hensby
3fd9fe3aa0
Merge branch '3.4' into 3 2016-09-07 09:22:06 +01:00
Rob Ingram
0c7264eca6 DOCS Update PHP doc on latestPublished method (#5905)
* Update doc comment on  method to be more accurate
2016-08-31 21:37:50 +01:00
Daniel Hensby
060bf6b327
Merge branch '3.3' into 3.4 2016-08-22 16:22:37 +01:00
Daniel Hensby
088d88e978
Merge branch '3.2' into 3.3 2016-08-22 16:22:02 +01:00
Loz Calver
0f3eabcf03 Merge pull request #5902 from dhensby/pulls/relation-list-cleanup
Cleanup of RelationList, HasManyList and ManyManyList
2016-08-22 14:27:29 +01:00
Daniel Hensby
4998b80445
FIX ArrayList sorting now caseinsensitive 2016-08-22 11:21:50 +01:00
Daniel Hensby
8737ddefba
Cleanup of RelationList, HasManyList and ManyManyList 2016-08-19 10:37:58 +01:00
Damian Mooyman
d88516203c Merge 3.4 into 3 2016-08-15 19:05:20 +12:00
Jonathon Menz
d4114b3dce FIX include related fields on canFilter() check
closes #5576
2016-08-11 10:26:18 -07:00
Daniel Hensby
340a48306b
Merge branch '3.4' into 3 2016-07-20 19:48:17 +01:00
Daniel Hensby
cf247534d5
Merge branch '3.3' into 3.4 2016-07-20 19:43:41 +01:00
Daniel Hensby
96b061ffff
Merge branch '3.2' into 3.3 2016-07-20 19:41:46 +01:00
madmatt
43dcde5197 FIX: Hierarchy was incorrectly unexpanding nodes that had been previously expanded 2016-07-19 11:22:36 +12:00
Daniel Hensby
4c40cf8dbb
Merge branch '3.4' into 3 2016-07-14 12:01:19 +01:00
Daniel Hensby
d766c8559b
Merge branch '3.3' into 3.4 2016-07-14 11:57:15 +01:00
Damian Mooyman
24efc7edf8 BUG Fix sorting ArrayList with sql-like syntax
Replaces #5726
2016-07-12 17:00:17 +12:00
Damian Mooyman
e810a9928c
API Add optimistic_connect to SS_Database
Fixes #4765
2016-07-12 10:19:03 +12:00
Daniel Hensby
8a21d53a07
Merge branch '3.4' into 3 2016-07-07 10:28:49 +01:00
assertchris
8b4311f020 Checking for resource before closing MySQL connection 2016-07-07 10:01:33 +12:00
Daniel Hensby
a449045b09
Merge branch '3.4' into 3 2016-07-04 23:54:27 +01:00
Daniel Hensby
c35dc508cb
Merge branch '3.3' into 3.4 2016-07-04 23:53:55 +01:00
Daniel Hensby
dfc557afd4
Merge branch '3.2' into 3.3 2016-07-04 23:43:44 +01:00
Daniel Hensby
2cdfe6cc21
FIX Use RAW for DBField template helpers 2016-07-04 14:39:56 +01:00
Daniel Hensby
b0f237bb3a
FIX Use RAW instead of Value for parsing shortcodes 2016-07-04 13:53:56 +01:00
Damian Mooyman
4dadc276b5 Merge pull request #3916 from dhensby/nfauchelle-gd-padding-improvementt
NEW Allow the paddedresize to take another hex value to specify a transparency on the padded color
2016-07-04 17:35:47 +12:00
Daniel Hensby
0d36899afa
Merge branch '3.4' into 3 2016-06-13 12:30:33 +01:00
Daniel Hensby
4e392a4d43
Merge branch '3.3' into 3.4 2016-06-13 12:30:16 +01:00
Nick
dae2295e16
NEW Allow the paddedresize to take another hex value to specify a transparency on the padded color 2016-06-05 00:05:37 +01:00
Damian Mooyman
decd7e5c57
BUG Fix getFinalisedQuery not including all queried columns
Fixes #1669
2016-05-23 08:41:58 +12:00
Daniel Hensby
be7e0db26e
Merge pull request #3835 from dnadesign/hideFromHierachy3 2016-05-19 11:52:47 +01:00
Damian Mooyman
b634b1a67d Merge pull request #5537 from IgorNadj/patch-niceformats
ENH: moving hardcoded nice date/time formats to config
2016-05-19 14:12:22 +12:00
Damian Mooyman
6035be7e57 Merge pull request #5548 from kinglozzer/4661-extrafields-casting
FIX: castingHelper failed to find many_many_extraFields data (fixes #4661)
2016-05-19 14:10:37 +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
8ed25ae482 BUG Fix DataObject::isChanged() detecting non saveable changes (#5545) 2016-05-18 09:00:04 +10:00
Loz Calver
7a81372294 FIX: castingHelper failed to find many_many_extraFields data (fixes #4661) 2016-05-17 16:04:28 +01:00
Damian Mooyman
8947bb0245 BUG Fix filtersOnId ignoring WHERE "ID" IN () (#5546) 2016-05-17 18:30:33 +12:00
John Milmine
c401d9daff new added hide_from_cms_tree and hide_from_hierarchy 2016-05-16 16:20:14 +12:00
Damian Mooyman
79d0590628 BUG Fix singleton('DBLocale') 2016-05-16 16:16:28 +12:00
Nik Rolls
9791426be6 PHPDoc improvements for Hierarchy and Versioned
- Added missing @param and @method documentation
- Fixed incorrect PHPDoc @params and @returns
- Fixed wrapping width on many docblocks
- Added and/or improved method documentation when missing or confusing
- Fixed typos as found
- Removed references to 'Page' in Versioned documentation
2016-05-16 12:08:25 +12:00
Igor Nadj
c8eda9fd5c ENH: moving hardcoded nice date/time formats to config
Old PR: #4449
2016-05-15 21:25:57 +12:00
Daniel Hensby
19a4a40d8b
Merge branch '3.3' into 3 2016-05-12 16:25:22 +01:00
Daniel Hensby
264d7e8ffe
Merge branch '3.2' into 3.3 2016-05-12 16:23:57 +01:00
Daniel Hensby
e8962b95d0
Merge branch '3.1' into 3.2 2016-05-12 16:05:54 +01:00
Daniel Hensby
3738d888e0
FIX Empty FROM clause 2016-05-12 12:38:05 +01:00
Daniel Hensby
dd554d883f
Proving bug with Deep nested many_many relations
When adding a filter to a many_many with a shared inheritance, the FROM table is removed and added as a LEFT JOIN which causes a syntax error.

This means `$dataList->filter('ManyManyRel.ID', array(1,2))` doesn't work.
2016-05-12 12:38:02 +01:00
Damian Mooyman
4f06a43986 Merge 3.3 into 3
# Conflicts:
#	admin/javascript/lang/src/cs.js
#	admin/javascript/lang/src/de.js
#	admin/javascript/lang/src/en.js
#	admin/javascript/lang/src/eo.js
#	admin/javascript/lang/src/es.js
#	admin/javascript/lang/src/fi.js
#	admin/javascript/lang/src/fr.js
#	admin/javascript/lang/src/id.js
#	admin/javascript/lang/src/id_ID.js
#	admin/javascript/lang/src/it.js
#	admin/javascript/lang/src/ja.js
#	admin/javascript/lang/src/lt.js
#	admin/javascript/lang/src/mi.js
#	admin/javascript/lang/src/nb.js
#	admin/javascript/lang/src/nl.js
#	admin/javascript/lang/src/pl.js
#	admin/javascript/lang/src/ro.js
#	admin/javascript/lang/src/ru.js
#	admin/javascript/lang/src/sk.js
#	admin/javascript/lang/src/sl.js
#	admin/javascript/lang/src/sr.js
#	admin/javascript/lang/src/sr@latin.js
#	admin/javascript/lang/src/sr_RS.js
#	admin/javascript/lang/src/sr_RS@latin.js
#	admin/javascript/lang/src/sv.js
#	admin/javascript/lang/src/zh.js
#	javascript/lang/fr.js
#	javascript/lang/src/ar.js
#	javascript/lang/src/cs.js
#	javascript/lang/src/de.js
#	javascript/lang/src/en.js
#	javascript/lang/src/eo.js
#	javascript/lang/src/es.js
#	javascript/lang/src/fi.js
#	javascript/lang/src/fr.js
#	javascript/lang/src/id.js
#	javascript/lang/src/id_ID.js
#	javascript/lang/src/it.js
#	javascript/lang/src/ja.js
#	javascript/lang/src/lt.js
#	javascript/lang/src/mi.js
#	javascript/lang/src/nb.js
#	javascript/lang/src/nl.js
#	javascript/lang/src/pl.js
#	javascript/lang/src/ru.js
#	javascript/lang/src/sk.js
#	javascript/lang/src/sl.js
#	javascript/lang/src/sr.js
#	javascript/lang/src/sr@latin.js
#	javascript/lang/src/sr_RS.js
#	javascript/lang/src/sr_RS@latin.js
#	javascript/lang/src/sv.js
#	javascript/lang/src/zh.js
#	lang/it.yml
2016-05-11 14:06:23 +12:00
Loz Calver
d1df67d308
FIX: SQLSelect count methods now cast to int (fixes #5498) 2016-05-10 12:31:45 +01:00
Daniel Hensby
457931d664
Merge branch '3.3' into 3 2016-05-04 23:32:10 +01:00
Daniel Hensby
32f0a637b4
Merge branch '3.2' into 3.3 2016-05-04 23:17:36 +01:00
Daniel Hensby
0884683c6b
Merge branch '3.1' into 3.2 2016-05-04 23:15:43 +01:00
Daniel Hensby
9fc4160425
Merge pull request #5348 from tractorcow/pulls/3/filterable-unsavedrelation 2016-05-04 10:50:46 +01:00
Damian Mooyman
da8f4a7eb6 Merge pull request #3828 from dhensby/pulls/byids-arraylist
API `byIDs` added to `ArrayList`
2016-04-26 17:52:22 +12:00
Damian Mooyman
e88a40853a Merge pull request #3772 from phptek/cms/1054
FIX: Fixes CMS errors when viewing history on "Deleted" pages.
2016-04-26 17:21:19 +12: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
Robbie Averill
ae268ae4df FIX #5363 Add .JSON option for templates 2016-04-21 17:01:05 +12:00
Damian Mooyman
43b00520fe API Remove artifact datalist overrides from UnsavedRelationList 2016-04-20 08:55:32 +12:00
Loz Calver
4353d35c0a Fix code docs for SQLSelect::count() 2016-03-27 10:23:11 +01:00
Christopher Darling
4dfe2955e3 DOCS: DataList::filter() broken examples
missing ' from 'bob'
2016-03-24 21:32:49 +00:00
Roman Schmid
25c453fe7b Fixed issue where canViewVersioned caused a DB error when Versioned was used with stages other than the default "Stage" and "Live".
Updated VersionedTest to also check an Object with a single stage in the canView test.
2016-03-22 09:42:21 +01:00
Joris Debonnet
4c741125c5 fix #5195: allow empty values in Enum 2016-03-17 22:43:26 +01:00
Damian Mooyman
6a2245474d BUG Fix FulltextsearchEnable 2016-03-07 14:47:20 +13:00
Damian Mooyman
634e86f949 API Include File.ParentID in fulltext search results
Fixes https://github.com/silverstripe-labs/silverstripe-secureassets/issues/22
2016-03-07 13:15:40 +13:00
Ryan McLaren
2079844647 BUGFIX: fixes "Uncaught ImagickException: Can not process empty Imagick object" when deleting an image 2016-03-01 12:19:23 -04: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
Damian Mooyman
5f2d3f31d7 Merge remote-tracking branch 'origin/3.2' into 3.3
# Conflicts:
#	dev/DevelopmentAdmin.php
#	docs/en/02_Developer_Guides/08_Performance/02_HTTP_Cache_Headers.md
#	lang/cs.yml
#	lang/lt.yml
2016-02-24 17:29:06 +13:00
Tyler Kidd
375bbf954e Enhancement and fix for issue #3186 2016-02-23 14:53:52 -06:00
Daniel Hensby
758c0273fa Merge pull request #4584 from Olliepop/feature-config-charset-collation 2016-02-23 15:42:09 +00:00
Oliver Shaw
ec647ed007 UPDATE: Add support for user defined charset and collation 2016-02-23 15:40:30 +00:00
Damian Mooyman
65a0981c08 BUG Correct behaviour of publish with $createNewVersion = true
Fixes #5040
Cleanup code to make behaviour more apparent
2016-02-23 10:15:49 +13:00
Jonathon Menz
d004fc8c3c Image deprecations and optimisation
Tagged generate methods for deprecation and prevented redundant creation of identical images between diferent methods
2016-02-16 09:40:18 -08:00
Daniel Pickering
9f95c76e5b Update ArrayList.php 2016-02-11 08:19:29 +13:00
Daniel Pickering
d41d601701 Ensure filterByCallback returns object of called class
This change ensures that filterByCallback returns a filtered list of the same called class, if ArrayList is extended.

The current filterByCallback always instantiates an ArrayList with the filtered results, which is probably not what you want if you extend ArrayList.


eg; currently this occurs
```
class MyArrayList extends ArrayList {
   public function sayHello() {
      return 'hi'; 
   }
}

$list = MyArrayList::create();
//populate $list here
$filtered = $list::filterByCallback($someCallback);

$filtered->sayHello();  
// -> The method 'sayHello' does not exist on 'ArrayList' 
```
2016-02-10 23:14:07 +13:00
Mark Stephens
3fcf1e2c98 BUG edge case on many many extra fields (fixes 4991)
Fixes an edge case where extraFields are not returned if
one side of a many many is added via extension (although this
may not be the only failure case). Fixes a
downstream issue with dms breaking the CMS on framework 3.2.

The bug is where a many many relationship exists on a class,
and a sub-class attempts to get the extra fields of the
relationship. The change fixes the test for exact matching of
the relationship class to the instance class, to checking if
the instance is the class or a subclass of the relationship.

The unit tests check the dms failure case, which is a more
complex failure case.
2016-02-04 12:47:07 +13:00
Silbinary Wolf
073e73a2f4 Replaced filterByCallback for 'Children' to just create a new array as function calls are exponentially expensive in PHP (the more functions that exist, the slower a function call becomes) and replaced 'array_key_exists' with op-code equivalent for speed. The best increase isn't really noticeable but we should work towards optimizing the core as much as possible. 2016-01-25 13:22:51 +00:00
Damian Mooyman
e091bb8474 Merge remote-tracking branch 'origin/3.3' into 3
# Conflicts:
#	admin/scss/_forms.scss
#	admin/scss/_style.scss
#	tests/model/VersionedTest.yml
2016-01-25 15:57:37 +13:00
Damian Mooyman
7c448bb4a2 Merge remote-tracking branch 'origin/3.2' into 3.3
# Conflicts:
#	tests/model/DataObjectLazyLoadingTest.php
#	tests/model/VersionedTest.yml
2016-01-25 14:11:37 +13:00
Damian Mooyman
d8e354d144 FIX PHPDocs on DataList::getIDList() and UnsavedRelationList::getIDList() 2016-01-25 11:09:37 +13:00
Jarkko Linnanvirta
bc9aa09b1f Remove question marks, equal signs and hashes
Those were not removed if multibyte was allowed.
2016-01-22 15:40:11 +00:00
Damian Mooyman
bf8bf5e4d5 BUG Prevent Versioned::doRollbackTo from creating incorrect versions on subclasses of Versioned DataObjects
Document correct configuration of Versioned DataObjects
Fixes #4936
2016-01-22 15:35:58 +13:00
Sam Minnee
3ee8f505b7 MINORE: Remove training whitespace.
The main benefit of this is so that authors who make use of
.editorconfig don't end up with whitespace changes in their PRs.

Spaces vs. tabs has been left alone, although that could do with a
tidy-up in SS4 after the switch to PSR-1/2.

The command used was this:

for match in '*.ss' '*.css' '*.scss' '*.html' '*.yml' '*.php' '*.js' '*.csv' '*.inc' '*.php5'; do
	find . -path ./thirdparty -not -prune -o -path ./admin/thirdparty -not -prune -o -type f -name "$match" -exec sed -E -i '' 's/[[:space:]]+$//' {} \+
	find . -path ./thirdparty -not -prune -o -path ./admin/thirdparty -not -prune -o -type f -name "$match" | xargs perl -pi -e 's/ +$//'
done
2016-01-07 10:15:54 +13:00
Damian Mooyman
ad9d293122 Merge pull request #4872 from powtac/3
Typo
2016-01-05 09:54:37 +13:00
Simon Brüchner
7ec09b5fde Typo 2015-12-23 09:32:26 +01:00
Damian Mooyman
959c84cf6f Merge pull request #4827 from SilbinaryWolf/fix-fieldLabels-abstract-class-bug
Fixed bug where inheriting an abstract class broke scaffoldFormFields / fieldLabels(true)
2015-12-22 16:42:54 +13:00
Damian Mooyman
48a30909f3 Merge remote-tracking branch 'origin/3.2' into 3
# Conflicts:
#	admin/javascript/LeftAndMain.BatchActions.js
#	css/UploadField.css
#	forms/HtmlEditorField.php
2015-12-22 14:07:52 +13:00
Damian Mooyman
880a3ef0ab Merge pull request #4793 from jonom/image-properties
FIX Image_Cached record class name
2015-12-22 10:09:05 +13:00
Ingo Schommer
0175167761 Merge pull request #4830 from open-sausages/pulls/3/fix-querystring-stage
API Disable unauthenticated get parameter access to site stage mode
2015-12-10 10:44:43 +13:00
Damian Mooyman
fa0160a874 BUG Fix regression in canViewStage 2015-12-09 14:53:21 +13:00
Damian Mooyman
6089a7c5bd API Create default security permission model for versioned data objects 2015-12-09 11:33:53 +13:00
Damian Mooyman
38e154af0a API Disable get parameter access to site stage mode
BUG Fix missing and undocumented response from Security::permissionFailure()
2015-12-07 17:39:18 +13:00
Silbinary Wolf
2d6b8a50b1 Fixed bug where inheriting an abstract class broke scaffoldFormFields / fieldLabels(true) 2015-12-05 18:53:29 +11:00
Jonathon Menz
15ae37cf03 FIX Image_Cached record class name
Sanitise properties before updating
2015-11-24 10:49:31 -08:00
Damian Mooyman
0272e443f4 BUG Prevent dev/build continually regenerating Number field type 2015-11-11 09:21:50 +13:00
Will Morgan
6d85d618b6 Merge pull request #4751 from dhensby/pulls/plural-fix
Fixing issue where words ending ay/ey/iy/oy/uy are not pluralised correctly
2015-11-06 16:55:25 +00:00
Daniel Hensby
dad3784621 Fixing issue where words ending ay/ey/iy/oy/uy are not pluralised correctly 2015-11-06 16:23:45 +00:00
Garion Herman
6a1a3bf182 Corrected TotalItems() method to use Count(). Added test coverage. (fixes #4646) 2015-11-04 00:20:45 +13:00
Damian Mooyman
c4dc10b255 Merge remote-tracking branch 'origin/3.2' into 3
Conflicts:
	forms/DropdownField.php
	tests/model/ImageTest.php
2015-11-03 13:06:39 +13:00
Patrick Nelson
293d84721e FIX for #4712: Dropping in some PHP documentation on return types for dynamically generated image methods. 2015-10-27 18:42:03 -04:00
Daniel Hensby
1974e79d71 Allow multi-line enum declarations 2015-10-15 16:23:19 +01:00