1 | <?php |
||
3 | class DMSDocumentAddExistingField extends CompositeField |
||
4 | { |
||
5 | public $useFieldContext = true; |
||
6 | |||
7 | public function __construct($name, $title = null) |
||
22 | |||
23 | /** |
||
24 | * Force a record to be used as "Parent" for uploaded Files (eg a Page with a has_one to File) |
||
25 | * @param DataObject $record |
||
26 | */ |
||
27 | public function setRecord($record) |
||
32 | /** |
||
33 | * Get the record to use as "Parent" for uploaded Files (eg a Page with a has_one to File) If none is set, it |
||
34 | * will use Form->getRecord() or Form->Controller()->data() |
||
35 | * @return DataObject |
||
36 | */ |
||
37 | public function getRecord() |
||
49 | |||
50 | public function FieldHolder($properties = array()) |
||
54 | |||
55 | public function Field($properties = array()) |
||
63 | |||
64 | /** |
||
65 | * Sets or unsets the use of the "field" class in the template. The "field" class adds Javascript behaviour |
||
66 | * that causes unwelcome hiding side-effects when this Field is used within the link editor pop-up |
||
67 | * |
||
68 | * @return $this |
||
69 | */ |
||
70 | public function setUseFieldClass($use = false) |
||
75 | } |
||
76 |
Since your code implements the magic setter
_set
, this function will be called for any write access on an undefined variable. You can add the@property
annotation to your class or interface to document the existence of this variable.Since the property has write access only, you can use the @property-write annotation instead.
Of course, you may also just have mistyped another name, in which case you should fix the error.
See also the PhpDoc documentation for @property.