Commit Graph

2417 Commits

Author SHA1 Message Date
Ingo Schommer
8ca264b0b0 MINOR Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75875 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-01 05:07:41 +00:00
Sean Harvey
9b75cb1987 Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75845 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-01 03:49:34 +00:00
Ingo Schommer
4965352bc3 BUGFIX Limiting all SQL queries going through Translatable->augmentSQL() to the Locale of the current object (if set), otherwise falling back to default locale. This fixes lots of problems with the Versioned extension in combination with Translatable, for example showing and comparing versions in the CMS sidebar (see #3886)
BUGFIX Removing the appended querying for NULL or empty Locale values in Translatable->augmentSQL() - this should no longer be necessary as we set default locales to all records through Translatable->requireDefaultRecords()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75826 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-01 03:18:40 +00:00
Sean Harvey
fdeacb4d07 Reverted r69557
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75825 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-01 03:18:05 +00:00
Sean Harvey
35c8666c4a Merged in r75816
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75819 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-05-01 03:06:20 +00:00
Ingo Schommer
b5bd96b07b ENHANCEMENT Running TestRunner tests suites alphabetically through natcasesort() instead of using the (relatively arbitrary) class ordering from ClassInfo::getSubclassesFor()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75793 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-30 23:52:55 +00:00
Ingo Schommer
7e41cc2b8e BUGFIX Fixed ErrorPage::get_filepath_for_errorcode() to work with locale values instead of short language subtags
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75791 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-30 23:51:55 +00:00
Ingo Schommer
d0761a3e78 BUGFIX Fixed some wrongly duplicated locale values in i18n::$common_languages and i18n::$common_locales
BUGFIX Unified locale values between i18n::$all_locales and $common_locales - the common locales should be a subset of all locales, without any additional ones as this might cause side-effects with LanguageDropdownField (see #3958)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75782 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-30 22:56:56 +00:00
Sean Harvey
964c67e98b MINOR Fixed undefined index error on ComplexTableField
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75781 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-30 22:48:21 +00:00
Ingo Schommer
c28c90b708 MINOR Re-added Translatable->extendWithSuffix()
BUGFIX Fixed DBLocaleTest

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75745 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-30 08:39:49 +00:00
Ingo Schommer
c1c920cca0 ENHANCEMENT Added DBLocale class for Translatable extension
API CHANGE Deprecated Translatable::get_langs_by_id() - use getTranslations()
MINOR Removed Translatable::is_default_locale() - no deprecation necessary, was recently added
MINOR Removed commented out methods in Translatable: augmentNumChildrenCountQuery(), augmentAllChildrenIncludingDeleted() and augmentStageChildren()
MINOR Removed fieldsInExtraTables() and extendWithSuffix()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75742 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-30 07:37:09 +00:00
Ingo Schommer
f2efb12bdd MINOR Updated Translatable and i18n documentation
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75707 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-30 02:51:17 +00:00
Sean Harvey
8471d1fc87 MINOR Updated titles for alt and title attribute value fields
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75697 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-30 01:29:29 +00:00
Sean Harvey
30481b5199 ENHANCEMENT Added a new "TitleText" field to ImageForm allowing a user to select which title attribute should appear on their images inserted into the content
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75690 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-30 00:15:41 +00:00
Ingo Schommer
9306b8b065 ENHANCEMENT Adapted MigrateTranslatableTask to new Locale datamodel and fixed some inconsistencies with translation groups, duplicate records etc
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75678 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-29 23:21:48 +00:00
Ingo Schommer
332e231529 ENHANCEMENT Added Versioned support to Translatable::getTranslation() and getTranslations()
ENHANCEMENT Marking 2.1-style "_lang" tables obsolete in Translatable::requireDefaultRecords()
ENHANCEMENT Added override flag to Translatable::addTranslationGroups()
MINOR Disabled Translatable->TranslationMasterID - not implemented yet

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75677 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-29 23:18:17 +00:00
Ingo Schommer
3d0c4a1615 BUGFIX Fixed i18n::get_locale_from_lang() to return original parameter if it detects a fully qualified locale that shouldn't be converted
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75675 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-29 23:15:38 +00:00
Sean Harvey
a39822712b Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75659 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-29 07:28:53 +00:00
Sean Harvey
cd1417a029 BUGFIX Added missing HtmlEditorField.js file from branches/2.3 that wasn't copied over during the last merge effort
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75619 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-29 02:52:18 +00:00
Sean Harvey
4615fd74b3 Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75591 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-29 01:21:38 +00:00
Sean Harvey
a5e82ddff1 Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75590 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-29 01:20:24 +00:00
Sean Harvey
13b358a8dd Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75582 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-29 00:07:39 +00:00
Sean Harvey
56fbe55a47 Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75580 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-28 23:55:53 +00:00
Sean Harvey
76b5adc979 Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75579 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-28 23:52:15 +00:00
Sean Harvey
ec9765d9f2 Merged from branches/2.3
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75572 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-28 23:40:35 +00:00
Ingo Schommer
908ef4c1b7 ENHANCEMENT Auto-update locale values in Translatable->requireDefaultRecords() with default language when Translatable is first enabled
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75421 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-28 03:12:57 +00:00
Ingo Schommer
c07f20b9a7 MINOR Partially merged r66168 from branches/2.3 - the last merge was ignoring SiteTreeDecorator.php file which was necessary for the new googlesitemaps module compatiblity
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75380 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-28 01:40:24 +00:00
Ingo Schommer
405a7905e2 ENHANCEMENT Added nl_NL javascript translations for sapphire, see #3896 - thanks Mad_Clog
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75351 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-28 00:10:11 +00:00
Ingo Schommer
a8028df67e ENHANCEMENT Added Translatable->MetaTags() to automatically insert <link rel="alternate" hreflang="...> tags into the page template
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75349 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-28 00:08:14 +00:00
Ingo Schommer
99c1fe9f93 BUGFIX Allowing translated homepages in RootUrlController
BUGFIX Limiting RootURLController to just trigger Translatable if no DomainForHomepage value is found
BUGFIX Using $locale parameter in Translatable::get_homepage_urlsegment_by_locale()
BUGFIX Updated enabling mechanism in Translatable->alternateGetByUrl()
MINOR Removed HTTP_HOST setting in TranslatableTest, wasn't necessary
API CHANGE Deprecated Translatable::get_homepage_urlsegment_by_language(), use get_homepage_urlsegment_by_locale()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75328 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 23:08:39 +00:00
Geoff Munn
eb86cc1b07 Re-enabled searchable fields
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75297 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 21:38:46 +00:00
Geoff Munn
f326047536 basic templates
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75295 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 21:37:35 +00:00
Geoff Munn
3022c7a908 Removed Database Abstraction TODO notice
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75291 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 21:35:20 +00:00
Ingo Schommer
ca24365c6f BUGFIX Fixed Translatable->onBeforeWrite() to change ClassNames on all translations when the "master page" (default language) changes its class to avoid inconsistencies with saving translations (see #3487)
BUGFIX Correctly showing the available languages dropdown in Translatable->getCMSFields()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75249 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 05:57:11 +00:00
Ingo Schommer
e55f3126fa BUGFIX Changed DataObject->newClassInstance() to only force changes if a differing classname was set. Setting ClassName property on new instance to trigger change detection (required for Translatable->onBeforeWrite())
BUGFIX Only force DataObject->forceChange() on fields which aren't already marked as changed

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75248 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 05:55:25 +00:00
Ingo Schommer
f5d578ff8c BUGFIX Setting Classname and RecordClassname properties on internal $record map when constructing a DataObject without passing $record into it. This ensures that getChangedFields() works on ClassName as well, which is required for Translatable->onBeforeWrite()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75156 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 01:36:15 +00:00
Ingo Schommer
bc14dd3b80 MINOR Fixed case of SQL commands in Database class
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75155 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 01:34:23 +00:00
Sam Minnee
b165bde578 BUGFIX #3919: Fix DataObject::dbObject() for decorated fields
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75150 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 00:44:10 +00:00
Sam Minnee
8fcdcfa2eb BUGFIX: Don't load SapphireTest unnecessarily, as this is a slow operation
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75147 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-27 00:19:16 +00:00
Ingo Schommer
bac89fd2c5 BUGFIX Setting the correct ParentID for children with existing parents in Translatable->createTranslation() - see #3861
BUGFIX Fixed Locale duplication detection for queries in Translatable->augmentSQL()

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75027 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-23 04:41:49 +00:00
Sean Harvey
16293cf1d4 ENHANCEMENT DataObjectSet::groupBy() now supports use of a method name to group objects
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74996 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-23 02:37:44 +00:00
Ingo Schommer
235ce958b8 BUGFIX Fixed TranslatableSearchFormTest->setUp() method
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74942 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-22 03:24:50 +00:00
Ingo Schommer
228b976ce1 ENHANCEMENT Adding SapphireTest::set_up_once() and SapphireTest::tear_down_once() for better test performance with state that just needs to be initialized once per test case (not per test method). Added new SapphireTestSuite to support this through PHPUnit.
ENHANCEMENT Using set_up_once() in TranslatableTest and TranslatableSearchFormTest for better test run performance

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74941 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-22 03:22:09 +00:00
Sean Harvey
515f7b1587 ENHANCEMENT Allow calling Format() on a Time DB field type to specify the formatting type
MINOR Code formatting fixes for Date and Time classes
MINOR Added phpDoc comments to methods



git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74786 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-20 22:32:13 +00:00
Normann Lou
9a5928438a ENHANCEMENT: Member::getTitle() return more flexible title in case of Surname or/and FirstName missing.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74665 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-17 06:00:32 +00:00
Normann Lou
eb0b76840c BUGFIX: RequestHandler::checkAccessAction() breaks when $this->class is null, this happens when you delete a DataObject from ResultForm (list view) in DataAdmin. We use safer call get_class($this) instead.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74633 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-16 22:41:14 +00:00
Mark Rickerby
1bd388ee92 fixing alteration message to output plaintext if executed via cli
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74337 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-11 05:00:41 +00:00
Sean Harvey
2199a581e1 BUGFIX SSViewer::getTemplateContent() now gracefully continues to operate if the file name can't be found to get unparsed content from.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74294 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-08 23:36:05 +00:00
Mark Rickerby
0881728d79 trying to see why my commits are coming up under sam's name
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74091 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-06 00:00:42 +00:00
Sam Minnee
b34b284929 fixing bug in TaskRunner which caused broken links in the task listing
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@74089 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-04-05 23:53:25 +00:00