Commit Graph

9591 Commits

Author SHA1 Message Date
Ingo Schommer
a71077c9e9 Merge branch 'aa_function' of git://github.com/simonwelsh/silverstripe-framework into simonwelsh-aa_function 2012-08-29 11:58:02 +02:00
Simon Welsh
78fdcc580b API DataList->leftJoin()/innerJoin() args no longer escaped
The table name in the join was being escaped, though table
names aren't escaped anywhere else. This breaks
namespaced classes, which rely on unescaped backslashes.
2012-08-29 11:54:42 +02:00
Sam Minnee
c2afca2cd8 Merge branch '3.0' 2012-08-28 16:08:57 +12:00
Sam Minnée
93cdb83ac8 Merge pull request #738 from simonwelsh/lsb-53-30
FIX Removes version checking for LSB in Object::static_lookup()
2012-08-27 21:07:29 -07:00
Sam Minnée
5b58e7951c Merge pull request #742 from silverstripe-rebelalliance/7812
BUG: open ticket 7812 correcting filter syntax on a DataObject used by f...
2012-08-27 21:05:09 -07:00
Sam Minnée
881952bf57 Merge pull request #743 from silverstripe-rebelalliance/trac/7817
FIX issue with cyclic configs when framework called sapphire
2012-08-27 21:04:49 -07:00
Hamish Friedlander
26cfd64d8e FIX issue with cyclic configs when framework called sapphire
The _config/route rules explicitly mentioned framework by module name,
so if you installed framework in the older sapphire directory youd
always end up with cyclic config requirement errors
2012-08-28 15:44:40 +12:00
Hamish Friedlander
aa0cd147bf FIX Make config DAG error message more dev friendly 2012-08-28 14:38:33 +12:00
Ingo Schommer
dc08e87bd5 BUG Take first non-empty link field for preview
Goes by priority, but allows for fields to be empty.
This is important e.g. for models which are removed just
from live, or just from draft.
Also reacts to a field rename done in CMS module (62783c75).
2012-08-27 18:22:33 +02:00
Ingo Schommer
f63893544e BUG Fix CMS layout after preview navigation (fixes #7463) 2012-08-27 16:50:37 +02:00
Ingo Schommer
5a44ea2e20 Deselect tree nodes when reacting to form load event (fixes #7401)
Multiselected nodes are only possible in batch mode,
which would never trigger a form load event.
2012-08-27 16:49:06 +02:00
Ingo Schommer
4a8236ffa7 Removed special "from"/"to" filter field CSS rules
Use global field rules instead, and fall back to new
"stacked" styling of FieldGroup (see CMS CSS)
2012-08-27 16:03:21 +02:00
Ingo Schommer
e4db3c6c05 Removed DateField special width with .hasDatepicker class
Causes field to change width after first display,
as the .hasDatepicker class is added dynamically on first field focus.
Since we don't add an icon by default, there's no difference
between an <input> field with date picker, an input field for dates,
and a simple input field. Fall back to global (or CMS specific) rules.
2012-08-27 16:02:40 +02:00
Ingo Schommer
76dd8cca0f Remove width limit on CMS panel dropdowns
No longer necessary as we've fixed the Chosen.js width
settings, which means the <select> fields can inherit
their settings and determine width automatically.
2012-08-27 15:52:01 +02:00
Ingo Schommer
88dfde8afa Removed arbitrary width restrictions on field group children
Let the fields handle their dimensions themselves
(for example the "from" and "to" date fields in the CMS pages search form)
2012-08-27 15:50:21 +02:00
Ingo Schommer
2e21574988 NEW FieldGroup_DefaultFieldHolder template
As a replacement for the FieldGroup->subfieldParam
setting available in 2.4. Usage through FieldGroup->setTemplate().
2012-08-27 15:41:56 +02:00
Ingo Schommer
1d2288b091 NEW Open external links in preview mode in new window (fixes #7652)
Rather than disabling the links altogether, which is
counter-intuitive to most users.
See https://github.com/silverstripe/sapphire/pull/638.

Also hide a duplicate $SilverStripeNavigator on the previewed
website (in case it has been manually applied to the template).
2012-08-27 14:42:10 +02:00
Ingo Schommer
a8f335360b Merge remote-tracking branch 'origin/3.0' 2012-08-27 09:25:59 +02:00
Ingo Schommer
dddc5bdf46 Removed accidental *.orig files 2012-08-27 09:06:10 +02:00
Sam Minnée
dd97da0ac2 Merge pull request #741 from silverstripe-rebelalliance/trac/7765
FIX several issues with the config system
2012-08-26 22:18:14 -07:00
Hamish Friedlander
8b6e4f5a90 Add some basic tests for ConfigManifest#relativeOrder 2012-08-27 16:42:25 +12:00
Hamish Friedlander
6009cfadc2 NEW Allow debugging of config cyclic errors
It is possible to specify before and after rules on config fragments
that conflict - A before B and B before A isnt possible to solve.

This used to just throw an error with no way to debug. Now if you
specify debug as a GET parameter and the site is not in live mode
youll get a basic dump of the remaining DAG graph
2012-08-27 16:08:10 +12:00
Hamish Friedlander
e0b8f15171 FIX Config wasnt filtering wildcards properly
When specifying a specific before rule and a wildcard after rule (or
vice versa), the config system was filtering out any fragment
from the list of fragments that matched the wildcard if it matched
_any_ componenet of the specific rule, not all of them.

Fixed, and added handling of two semi wild-card rules, where a
rule with less wildcards wins over a rule with more.

See http://open.silverstripe.org/ticket/7765 for more
2012-08-27 16:03:03 +12:00
Hamish Friedlander
c7ca47f2b1 FIX Config frag could only have one before or after rule
You should be able to specify multiple before and after rules in
a config fragment. This was intended to be a comma seperated string
but that wasnt being split properly

Now if you provide a comma seperated string it is split properly,
but you can also provide an array, which is actually cleaner
2012-08-27 16:00:54 +12:00
Kirk Mayo
3e351bc421 BUG: open ticket 7812 correcting filter syntax on a DataObject used by function updatetreenodes 2012-08-27 14:41:07 +12:00
Ingo Schommer
30b9fa5404 Merge branch '3.0' 2012-08-27 00:13:45 +02:00
Ingo Schommer
0a6a3fa936 i18n for file type descriptors (see #7798) 2012-08-27 00:02:52 +02:00
Ingo Schommer
8dccb7f7d7 i18n for GridField pagination footer (see #7798) 2012-08-26 23:58:31 +02:00
Ingo Schommer
2fab657fce i18n for CMS section titles (see #7798) 2012-08-26 23:58:31 +02:00
Ingo Schommer
3b592122fd i18n for "select an anchor" string (see #7798) 2012-08-26 23:58:31 +02:00
Sean Harvey
674b52b4f7 Merge pull request #734 from silverstripe-rebelalliance/trac/7799
API Reverse config extra statics control flow
2012-08-26 14:24:05 -07:00
Ingo Schommer
0aa28943ff Updated translations 2012-08-23 23:34:42 +02:00
Ingo Schommer
6997be6658 Merge remote-tracking branch 'origin/translation-staging'
Conflicts:
	lang/de.yml
	lang/mi_NZ.yml
	lang/nl.yml
	lang/ru.yml
2012-08-23 23:33:02 +02:00
TeamCity
1b0212b9dc MINOR Updated translations 2012-08-24 03:04:39 +12:00
TeamCity
931da41e03 MINOR Updated translations 2012-08-24 02:19:42 +12:00
TeamCity
ee3ca61a05 MINOR Updated translations 2012-08-24 00:05:32 +12:00
TeamCity
094bd2f930 MINOR Updated translations 2012-08-23 23:16:19 +12:00
Simon Welsh
e159a68f89 FIX Removes version checking for LSB in Object::static_lookup()
Late static binding was added in PHP 5.3, not 5.4. As such, the check for 5.4
and then fallback to Reflection isn't needed.
2012-08-23 17:51:29 +12:00
Sam Minnée
8560ccede5 Merge pull request #737 from simonwelsh/dotest-fix
FIX Use array_intersect() with expected values so that the order matches
2012-08-22 22:49:27 -07:00
Simon Welsh
cd61b61a84 FIX Use array_intersect() with expected values so that the order matches.
The values in $values aren't returned in any order, so this test can randomly fail. This
changes the check from expected = $values to $values \cap expected = $value. PHP's array_intersect
maintains the keys of the first array, so order is preserved. The intersect also guarentees that the
only accepted values are the expected ones.
2012-08-23 17:36:59 +12:00
Simon Welsh
f1db583fb4 NEW Allow arguments to be passed to allowed_action checkers
This allows arguments to be passed along in an $allowed_actions deceleration of
the form 'action' => '->method' in the same way that arguments can be passed to
extension constructors when adding them using $extensions or
Object::add_extension.

I.e. 'action' => '->checkerMethod(false, 7, 2, "yesterday") would call the
checkerMethod method with the boolean false the numbers 7 and 2 and  the string
"yesterday" as its arguments.
2012-08-23 17:05:12 +12:00
Sam Minnee
f1c021ff22 Merge branch '3.0' 2012-08-23 12:56:17 +12:00
Sam Minnee
87685eefdd BUGFIX: Fix Versioned's stage_unique mode on PostgreSQL. 2012-08-23 12:56:06 +12:00
Sam Minnee
824afffd2e Merge branch '3.0' 2012-08-23 12:39:41 +12:00
Sam Minnee
ed0341e82f BUGFIX: Ensure that subtracting a sorted DataList works. 2012-08-23 12:38:54 +12:00
Sam Minnee
296ee1fa0f BUGFIX: Add double quotes to index columns for more reliable DB-schema management. 2012-08-23 12:38:44 +12:00
Sam Minnee
dd302a68a7 BUGFIX: Ensure that all_versions are sorted explicitly for better cross-db behaviour. 2012-08-23 12:38:37 +12:00
Sam Minnee
f6334dd017 Added default sort to test data for better cross-db performance. 2012-08-23 12:38:33 +12:00
Sean Harvey
5c6707df89 Merge pull request #735 from oddnoc/scheme-relative-requirements
Allow scheme-relative URLs in requirements
2012-08-22 16:56:18 -07:00
Fred Condo
3e0782267c Allow scheme-relative URLs in requirements
The Requirements class currently treats only absolute URLs as URLs, and
tries to interpret anything else as a filesystem path. This prevents
using scheme-relative URLs for requirements.

Example:
<% require javascript(//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js) %>

This forces the unfortunate choice of not using a CDN for common
scripts, always using an https absolute URL, or accepting that some
browsers will throw a security warning when viewing the site in https.

This change allows scheme-relative URLs & updates RequirementsTest.
2012-08-22 16:49:55 -07:00