ENHANCEMENT: using CSS3 to do number label in dialog box (SSO-8)

This commit is contained in:
Julian Seidenberg 2011-09-30 12:48:34 +13:00
parent 28e63efd5e
commit a7527eef9c

View File

@ -1034,14 +1034,22 @@ JS;
);
$pageTypes[$type->getField('ClassName')] = $html;
}
$labelTriangle = '<span class="label-triangle"></span>';
$fields = new FieldSet(
// new HiddenField("ParentID", false, ($this->parentRecord) ? $this->parentRecord->ID : null),
// TODO Should be part of the form attribute, but not possible in current form API
$hintsField = new LiteralField('Hints', sprintf('<span class="hints" data-hints="%s"></span>', $this->SiteTreeHints())),
$label1 = new LabelField("1", _t('CMSMain.1', '1').$labelTriangle),
$parentField = new TreeDropdownField("ParentID", _t('CMSMain.AddFormParentLabel', 'Parent page'), 'SiteTree'),
$label2 = new LabelField("1", _t('CMSMain.2', '2').$labelTriangle),
new OptionsetField("PageType", _t('CMSMain.PageType', 'Page type'), $pageTypes, 'Page')
);
$label1->addExtraClass("numeric-label");
$label1->setAllowHTML(true);
$label2->addExtraClass("numeric-label");
$label2->setAllowHTML(true);
$parentField->setValue(($record) ? $record->ID : null);
$actions = new FieldSet(