1 <?php
2
3 4 5 6 7
8 class RecipientExportField extends FormField {
9
10 function __construct( $name, $title, $memberGroup, $memberClass = 'Member', $form = null ) {
11 $this->memberGroup = $memberGroup;
12 $this->memberClass = $memberClass;
13 parent::__construct( $name, $title, null, $form );
14 }
15
16 function Field() {
17 $link = Director::absoluteBaseURL() . 'admin/newsletter/exportrecipients/' . $this->typeID;
18 return "<div class=\"utility\"><span class=\"item\"><a href=\"{$link}\">"._t('RecipientExportField.EXPORTRECIPIENTS')."</a></span></div>";
19 }
20
21 function setTypeID( $id ) {
22 $this->typeID = $id;
23 }
24
25 function setController( $controller ) {
26 $this->controller = $controller;
27 }
28
29 function TypeID() {
30 return $this->typeID;
31 }
32 }
33
[Raise a SilverStripe Framework issue/bug](https://github.com/silverstripe/silverstripe-framework/issues/new)
- [Raise a SilverStripe CMS issue/bug](https://github.com/silverstripe/silverstripe-cms/issues/new)
- Please use the
Silverstripe Forums to ask development related questions.
-