Changeset View
Changeset View
Standalone View
Standalone View
src/view/phui/PHUIObjectBoxView.php
<?php | <?php | ||||
final class PHUIObjectBoxView extends AphrontView { | final class PHUIObjectBoxView extends AphrontView { | ||||
private $headerText; | private $headerText; | ||||
private $formError = null; | private $formError = null; | ||||
private $form; | private $form; | ||||
private $validationException; | private $validationException; | ||||
private $header; | private $header; | ||||
private $flush; | private $flush; | ||||
private $id; | |||||
private $tabs = array(); | private $tabs = array(); | ||||
private $propertyLists = array(); | private $propertyLists = array(); | ||||
public function addPropertyList( | public function addPropertyList( | ||||
PHUIPropertyListView $property_list, | PHUIPropertyListView $property_list, | ||||
$tab = null) { | $tab = null) { | ||||
▲ Show 20 Lines • Show All 49 Lines • ▼ Show 20 Lines | public function setFormError($error) { | ||||
return $this; | return $this; | ||||
} | } | ||||
public function setForm($form) { | public function setForm($form) { | ||||
$this->form = $form; | $this->form = $form; | ||||
return $this; | return $this; | ||||
} | } | ||||
public function setID($id) { | |||||
$this->id = $id; | |||||
return $this; | |||||
} | |||||
public function setHeader(PHUIHeaderView $header) { | public function setHeader(PHUIHeaderView $header) { | ||||
$this->header = $header; | $this->header = $header; | ||||
return $this; | return $this; | ||||
} | } | ||||
public function setFlush($flush) { | public function setFlush($flush) { | ||||
$this->flush = $flush; | $this->flush = $flush; | ||||
return $this; | return $this; | ||||
▲ Show 20 Lines • Show All 107 Lines • ▼ Show 20 Lines | $content = id(new PHUIBoxView()) | ||||
$exception_errors, | $exception_errors, | ||||
$this->form, | $this->form, | ||||
$tabs, | $tabs, | ||||
$tab_lists, | $tab_lists, | ||||
$property_lists, | $property_lists, | ||||
$this->renderChildren(), | $this->renderChildren(), | ||||
)) | )) | ||||
->setBorder(true) | ->setBorder(true) | ||||
->setID($this->id) | |||||
->addMargin(PHUI::MARGIN_LARGE_TOP) | ->addMargin(PHUI::MARGIN_LARGE_TOP) | ||||
->addMargin(PHUI::MARGIN_LARGE_LEFT) | ->addMargin(PHUI::MARGIN_LARGE_LEFT) | ||||
->addMargin(PHUI::MARGIN_LARGE_RIGHT) | ->addMargin(PHUI::MARGIN_LARGE_RIGHT) | ||||
->addClass('phui-object-box'); | ->addClass('phui-object-box'); | ||||
if ($this->tabs) { | if ($this->tabs) { | ||||
$content->addSigil('phui-object-box'); | $content->addSigil('phui-object-box'); | ||||
$content->setMetadata( | $content->setMetadata( | ||||
Show All 12 Lines |