mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
MINOR Fixed class documentation for CompositeDBField
This commit is contained in:
parent
a9f95051bc
commit
9bd7068394
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
* Example with a combined street name and number:
|
* Example with a combined street name and number:
|
||||||
* <code>
|
* <code>
|
||||||
* class Street extends DBFields implements CompositeDBField() {
|
* class Street extends DBField implements CompositeDBField {
|
||||||
* protected $streetNumber;
|
* protected $streetNumber;
|
||||||
* protected $streetName;
|
* protected $streetName;
|
||||||
* protected $isChanged = false;
|
* protected $isChanged = false;
|
||||||
@ -42,7 +42,7 @@
|
|||||||
* }
|
* }
|
||||||
*
|
*
|
||||||
* function setValue($value, $record = null, $markChanged=true) {
|
* function setValue($value, $record = null, $markChanged=true) {
|
||||||
* if ($value instanceof Street && $value->hasValue()) {
|
* if ($value instanceof Street && $value->exists()) {
|
||||||
* $this->setStreetName($value->getStreetName(), $markChanged);
|
* $this->setStreetName($value->getStreetName(), $markChanged);
|
||||||
* $this->setStreetNumber($value->getStreetNumber(), $markChanged);
|
* $this->setStreetNumber($value->getStreetNumber(), $markChanged);
|
||||||
* if($markChanged) $this->isChanged = true;
|
* if($markChanged) $this->isChanged = true;
|
||||||
@ -85,7 +85,7 @@
|
|||||||
* return $this->isChanged;
|
* return $this->isChanged;
|
||||||
* }
|
* }
|
||||||
*
|
*
|
||||||
* function hasValue() {
|
* function exists() {
|
||||||
* return ($this->getStreetName() || $this->getStreetNumber());
|
* return ($this->getStreetName() || $this->getStreetNumber());
|
||||||
* }
|
* }
|
||||||
* }
|
* }
|
||||||
|
Loading…
Reference in New Issue
Block a user