mirror of
https://github.com/silverstripe/silverstripe-translatable
synced 2024-10-22 11:05:59 +02:00
Fixed 3.x deprecations, updated dep from 3.1 to 3.2
This commit is contained in:
parent
94945a49cd
commit
05b4b84f19
@ -6,12 +6,7 @@ php:
|
|||||||
- 5.4
|
- 5.4
|
||||||
|
|
||||||
env:
|
env:
|
||||||
- DB=MYSQL CORE_RELEASE=3.1
|
- DB=MYSQL CORE_RELEASE=3
|
||||||
|
|
||||||
matrix:
|
|
||||||
include:
|
|
||||||
- php: 5.4
|
|
||||||
env: DB=MYSQL CORE_RELEASE=3
|
|
||||||
|
|
||||||
before_script:
|
before_script:
|
||||||
- pear -q install --onlyreqdeps pear/PHP_CodeSniffer
|
- pear -q install --onlyreqdeps pear/PHP_CodeSniffer
|
||||||
|
@ -5,7 +5,6 @@
|
|||||||
## Introduction ##
|
## Introduction ##
|
||||||
|
|
||||||
Allows translation of DataObject and SiteTree records into multiple languages.
|
Allows translation of DataObject and SiteTree records into multiple languages.
|
||||||
Note: This module was originally part of the SilverStripe CMS 2.x codebase.
|
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
@ -13,7 +12,7 @@ Note: This module was originally part of the SilverStripe CMS 2.x codebase.
|
|||||||
|
|
||||||
## Requirements ##
|
## Requirements ##
|
||||||
|
|
||||||
* SilverStripe Framework 3.1+ and CMS 3.1+
|
* SilverStripe Framework 3.2+ and CMS 3.2+
|
||||||
|
|
||||||
## Maintainers ##
|
## Maintainers ##
|
||||||
|
|
||||||
|
@ -561,10 +561,10 @@ class Translatable extends DataExtension implements PermissionProvider {
|
|||||||
if($this->owner && $this->translatableFields === null) {
|
if($this->owner && $this->translatableFields === null) {
|
||||||
$this->translatableFields = array_merge(
|
$this->translatableFields = array_merge(
|
||||||
array_keys($this->owner->db()),
|
array_keys($this->owner->db()),
|
||||||
array_keys($this->owner->has_many()),
|
array_keys($this->owner->hasMany()),
|
||||||
array_keys($this->owner->many_many())
|
array_keys($this->owner->manyMany())
|
||||||
);
|
);
|
||||||
foreach (array_keys($this->owner->has_one()) as $fieldname) {
|
foreach (array_keys($this->owner->hasOne()) as $fieldname) {
|
||||||
$this->translatableFields[] = $fieldname.'ID';
|
$this->translatableFields[] = $fieldname.'ID';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -15,8 +15,8 @@
|
|||||||
"require":
|
"require":
|
||||||
{
|
{
|
||||||
"php": ">=5.3.2",
|
"php": ">=5.3.2",
|
||||||
"silverstripe/framework": "~3.1",
|
"silverstripe/framework": "~3.2",
|
||||||
"silverstripe/cms": "~3.1"
|
"silverstripe/cms": "~3.2"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"silverstripe/postgresql": "*",
|
"silverstripe/postgresql": "*",
|
||||||
|
Loading…
Reference in New Issue
Block a user