mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-10 08:52:39 +01:00
Move PHUIFormBoxView to PHUIObjectBoxView
Summary: I'd like to reuse this for other content areas, renaming for now. This might be weird to keep setForm, but I can fix that later if we need. Test Plan: reload a few forms in maniphest, projects, differential Reviewers: epriestley, btrahan Reviewed By: epriestley CC: Korvin, aran Differential Revision: https://secure.phabricator.com/D7120
This commit is contained in:
parent
225a38c7d3
commit
9be7a948f9
55 changed files with 119 additions and 112 deletions
|
@ -3756,7 +3756,7 @@ celerity_register_resource_map(array(
|
|||
),
|
||||
'phui-form-view-css' =>
|
||||
array(
|
||||
'uri' => '/res/5786628c/rsrc/css/phui/phui-form-view.css',
|
||||
'uri' => '/res/d87bdbeb/rsrc/css/phui/phui-form-view.css',
|
||||
'type' => 'css',
|
||||
'requires' =>
|
||||
array(
|
||||
|
@ -4162,7 +4162,7 @@ celerity_register_resource_map(array(
|
|||
), array(
|
||||
'packages' =>
|
||||
array(
|
||||
'03a782d0' =>
|
||||
'15affac5' =>
|
||||
array(
|
||||
'name' => 'core.pkg.css',
|
||||
'symbols' =>
|
||||
|
@ -4209,7 +4209,7 @@ celerity_register_resource_map(array(
|
|||
39 => 'phabricator-property-list-view-css',
|
||||
40 => 'phabricator-tag-view-css',
|
||||
),
|
||||
'uri' => '/res/pkg/03a782d0/core.pkg.css',
|
||||
'uri' => '/res/pkg/15affac5/core.pkg.css',
|
||||
'type' => 'css',
|
||||
),
|
||||
'8977e356' =>
|
||||
|
@ -4399,15 +4399,15 @@ celerity_register_resource_map(array(
|
|||
),
|
||||
'reverse' =>
|
||||
array(
|
||||
'aphront-dialog-view-css' => '03a782d0',
|
||||
'aphront-error-view-css' => '03a782d0',
|
||||
'aphront-list-filter-view-css' => '03a782d0',
|
||||
'aphront-pager-view-css' => '03a782d0',
|
||||
'aphront-panel-view-css' => '03a782d0',
|
||||
'aphront-table-view-css' => '03a782d0',
|
||||
'aphront-tokenizer-control-css' => '03a782d0',
|
||||
'aphront-tooltip-css' => '03a782d0',
|
||||
'aphront-typeahead-control-css' => '03a782d0',
|
||||
'aphront-dialog-view-css' => '15affac5',
|
||||
'aphront-error-view-css' => '15affac5',
|
||||
'aphront-list-filter-view-css' => '15affac5',
|
||||
'aphront-pager-view-css' => '15affac5',
|
||||
'aphront-panel-view-css' => '15affac5',
|
||||
'aphront-table-view-css' => '15affac5',
|
||||
'aphront-tokenizer-control-css' => '15affac5',
|
||||
'aphront-tooltip-css' => '15affac5',
|
||||
'aphront-typeahead-control-css' => '15affac5',
|
||||
'differential-changeset-view-css' => '44bfe40c',
|
||||
'differential-core-view-css' => '44bfe40c',
|
||||
'differential-inline-comment-editor' => '5e9e5c4e',
|
||||
|
@ -4421,7 +4421,7 @@ celerity_register_resource_map(array(
|
|||
'differential-table-of-contents-css' => '44bfe40c',
|
||||
'diffusion-commit-view-css' => 'c8ce2d88',
|
||||
'diffusion-icons-css' => 'c8ce2d88',
|
||||
'global-drag-and-drop-css' => '03a782d0',
|
||||
'global-drag-and-drop-css' => '15affac5',
|
||||
'inline-comment-summary-css' => '44bfe40c',
|
||||
'javelin-aphlict' => '8977e356',
|
||||
'javelin-behavior' => '9564fa17',
|
||||
|
@ -4494,54 +4494,54 @@ celerity_register_resource_map(array(
|
|||
'javelin-util' => '9564fa17',
|
||||
'javelin-vector' => '9564fa17',
|
||||
'javelin-workflow' => '9564fa17',
|
||||
'lightbox-attachment-css' => '03a782d0',
|
||||
'lightbox-attachment-css' => '15affac5',
|
||||
'maniphest-task-summary-css' => '49898640',
|
||||
'phabricator-action-list-view-css' => '03a782d0',
|
||||
'phabricator-application-launch-view-css' => '03a782d0',
|
||||
'phabricator-action-list-view-css' => '15affac5',
|
||||
'phabricator-application-launch-view-css' => '15affac5',
|
||||
'phabricator-busy' => '8977e356',
|
||||
'phabricator-content-source-view-css' => '44bfe40c',
|
||||
'phabricator-core-css' => '03a782d0',
|
||||
'phabricator-crumbs-view-css' => '03a782d0',
|
||||
'phabricator-core-css' => '15affac5',
|
||||
'phabricator-crumbs-view-css' => '15affac5',
|
||||
'phabricator-drag-and-drop-file-upload' => '5e9e5c4e',
|
||||
'phabricator-dropdown-menu' => '8977e356',
|
||||
'phabricator-file-upload' => '8977e356',
|
||||
'phabricator-filetree-view-css' => '03a782d0',
|
||||
'phabricator-flag-css' => '03a782d0',
|
||||
'phabricator-filetree-view-css' => '15affac5',
|
||||
'phabricator-flag-css' => '15affac5',
|
||||
'phabricator-hovercard' => '8977e356',
|
||||
'phabricator-jump-nav' => '03a782d0',
|
||||
'phabricator-jump-nav' => '15affac5',
|
||||
'phabricator-keyboard-shortcut' => '8977e356',
|
||||
'phabricator-keyboard-shortcut-manager' => '8977e356',
|
||||
'phabricator-main-menu-view' => '03a782d0',
|
||||
'phabricator-main-menu-view' => '15affac5',
|
||||
'phabricator-menu-item' => '8977e356',
|
||||
'phabricator-nav-view-css' => '03a782d0',
|
||||
'phabricator-nav-view-css' => '15affac5',
|
||||
'phabricator-notification' => '8977e356',
|
||||
'phabricator-notification-css' => '03a782d0',
|
||||
'phabricator-notification-menu-css' => '03a782d0',
|
||||
'phabricator-notification-css' => '15affac5',
|
||||
'phabricator-notification-menu-css' => '15affac5',
|
||||
'phabricator-object-selector-css' => '44bfe40c',
|
||||
'phabricator-phtize' => '8977e356',
|
||||
'phabricator-prefab' => '8977e356',
|
||||
'phabricator-project-tag-css' => '49898640',
|
||||
'phabricator-property-list-view-css' => '03a782d0',
|
||||
'phabricator-remarkup-css' => '03a782d0',
|
||||
'phabricator-property-list-view-css' => '15affac5',
|
||||
'phabricator-remarkup-css' => '15affac5',
|
||||
'phabricator-shaped-request' => '5e9e5c4e',
|
||||
'phabricator-side-menu-view-css' => '03a782d0',
|
||||
'phabricator-standard-page-view' => '03a782d0',
|
||||
'phabricator-tag-view-css' => '03a782d0',
|
||||
'phabricator-side-menu-view-css' => '15affac5',
|
||||
'phabricator-standard-page-view' => '15affac5',
|
||||
'phabricator-tag-view-css' => '15affac5',
|
||||
'phabricator-textareautils' => '8977e356',
|
||||
'phabricator-tooltip' => '8977e356',
|
||||
'phabricator-transaction-view-css' => '03a782d0',
|
||||
'phabricator-zindex-css' => '03a782d0',
|
||||
'phui-button-css' => '03a782d0',
|
||||
'phui-form-css' => '03a782d0',
|
||||
'phui-form-view-css' => '03a782d0',
|
||||
'phui-header-view-css' => '03a782d0',
|
||||
'phui-icon-view-css' => '03a782d0',
|
||||
'phui-object-item-list-view-css' => '03a782d0',
|
||||
'phui-spacing-css' => '03a782d0',
|
||||
'sprite-apps-large-css' => '03a782d0',
|
||||
'sprite-gradient-css' => '03a782d0',
|
||||
'sprite-icons-css' => '03a782d0',
|
||||
'sprite-menu-css' => '03a782d0',
|
||||
'syntax-highlighting-css' => '03a782d0',
|
||||
'phabricator-transaction-view-css' => '15affac5',
|
||||
'phabricator-zindex-css' => '15affac5',
|
||||
'phui-button-css' => '15affac5',
|
||||
'phui-form-css' => '15affac5',
|
||||
'phui-form-view-css' => '15affac5',
|
||||
'phui-header-view-css' => '15affac5',
|
||||
'phui-icon-view-css' => '15affac5',
|
||||
'phui-object-item-list-view-css' => '15affac5',
|
||||
'phui-spacing-css' => '15affac5',
|
||||
'sprite-apps-large-css' => '15affac5',
|
||||
'sprite-gradient-css' => '15affac5',
|
||||
'sprite-icons-css' => '15affac5',
|
||||
'sprite-menu-css' => '15affac5',
|
||||
'syntax-highlighting-css' => '15affac5',
|
||||
),
|
||||
));
|
||||
|
|
|
@ -752,7 +752,6 @@ phutil_register_library_map(array(
|
|||
'PHUIDocumentView' => 'view/phui/PHUIDocumentView.php',
|
||||
'PHUIFeedStoryExample' => 'applications/uiexample/examples/PHUIFeedStoryExample.php',
|
||||
'PHUIFeedStoryView' => 'view/phui/PHUIFeedStoryView.php',
|
||||
'PHUIFormBoxView' => 'view/form/PHUIFormBoxView.php',
|
||||
'PHUIFormDividerControl' => 'view/form/control/PHUIFormDividerControl.php',
|
||||
'PHUIFormFreeformDateControl' => 'view/form/control/PHUIFormFreeformDateControl.php',
|
||||
'PHUIFormLayoutView' => 'view/form/PHUIFormLayoutView.php',
|
||||
|
@ -765,6 +764,7 @@ phutil_register_library_map(array(
|
|||
'PHUIListItemView' => 'view/phui/PHUIListItemView.php',
|
||||
'PHUIListView' => 'view/phui/PHUIListView.php',
|
||||
'PHUIListViewTestCase' => 'view/layout/__tests__/PHUIListViewTestCase.php',
|
||||
'PHUIObjectBoxView' => 'view/phui/PHUIObjectBoxView.php',
|
||||
'PHUIObjectItemListExample' => 'applications/uiexample/examples/PHUIObjectItemListExample.php',
|
||||
'PHUIObjectItemListView' => 'view/phui/PHUIObjectItemListView.php',
|
||||
'PHUIObjectItemView' => 'view/phui/PHUIObjectItemView.php',
|
||||
|
@ -2841,7 +2841,6 @@ phutil_register_library_map(array(
|
|||
'PHUIDocumentView' => 'AphrontTagView',
|
||||
'PHUIFeedStoryExample' => 'PhabricatorUIExample',
|
||||
'PHUIFeedStoryView' => 'AphrontView',
|
||||
'PHUIFormBoxView' => 'AphrontView',
|
||||
'PHUIFormDividerControl' => 'AphrontFormControl',
|
||||
'PHUIFormFreeformDateControl' => 'AphrontFormControl',
|
||||
'PHUIFormLayoutView' => 'AphrontView',
|
||||
|
@ -2854,6 +2853,7 @@ phutil_register_library_map(array(
|
|||
'PHUIListItemView' => 'AphrontTagView',
|
||||
'PHUIListView' => 'AphrontTagView',
|
||||
'PHUIListViewTestCase' => 'PhabricatorTestCase',
|
||||
'PHUIObjectBoxView' => 'AphrontView',
|
||||
'PHUIObjectItemListExample' => 'PhabricatorUIExample',
|
||||
'PHUIObjectItemListView' => 'AphrontTagView',
|
||||
'PHUIObjectItemView' => 'AphrontTagView',
|
||||
|
|
|
@ -280,7 +280,7 @@ final class PhabricatorAuthEditController
|
|||
->setTransactions($xactions);
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
|
|
@ -81,7 +81,7 @@ final class PhabricatorAuthNewController
|
|||
->addCancelButton($this->getApplicationURI())
|
||||
->setValue(pht('Continue')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Add Authentication Provider'))
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
|
|
@ -163,7 +163,7 @@ final class PhabricatorCalendarEditStatusController
|
|||
}
|
||||
$form->appendChild($submit);
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($page_title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -110,7 +110,7 @@ final class PhabricatorConduitConsoleController
|
|||
->addCancelButton($this->getApplicationURI())
|
||||
->setValue('Call Method'));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($method->getAPIMethodName())
|
||||
->setFormError($status_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -193,7 +193,7 @@ final class PhabricatorConfigEditController
|
|||
$title = pht('Edit %s', $this->key);
|
||||
$short = pht('Edit');
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -128,7 +128,7 @@ final class PhabricatorCountdownEditController
|
|||
->addCancelButton($cancel_uri)
|
||||
->setValue($submit_label));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($page_title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -82,7 +82,7 @@ final class DifferentialDiffCreateController extends DifferentialController {
|
|||
->addCancelButton($cancel_uri)
|
||||
->setValue(pht("Create Diff")));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Create New Diff'))
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
|
|
@ -164,7 +164,7 @@ final class DifferentialRevisionEditController extends DifferentialController {
|
|||
$title = pht('Create New Differential Revision');
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -81,7 +81,7 @@ final class DiffusionCommitEditController extends DiffusionController {
|
|||
->addCancelButton('/r'.$callsign.$commit->getCommitIdentifier());
|
||||
$form->appendChild($submit);
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($page_title)
|
||||
->setForm($form);
|
||||
|
||||
|
|
|
@ -95,7 +95,7 @@ final class DiffusionRepositoryEditPolicyController
|
|||
->setValue(pht('Save Policies'))
|
||||
->addCancelButton($edit_uri));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setForm($form);
|
||||
|
||||
|
|
|
@ -76,7 +76,7 @@ final class PhabricatorFileUploadController extends PhabricatorFileController {
|
|||
$global_upload = id(new PhabricatorGlobalUploadTargetView())
|
||||
->setShowIfSupportedID($support_id);
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
|
|
@ -69,7 +69,7 @@ final class HeraldNewController extends HeraldController {
|
|||
->setValue(pht('Create Rule'))
|
||||
->addCancelButton($this->getApplicationURI()));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Create Herald Rule'))
|
||||
->setForm($form);
|
||||
|
||||
|
|
|
@ -182,7 +182,7 @@ final class HeraldRuleController extends HeraldController {
|
|||
? pht('Edit Herald Rule')
|
||||
: pht('Create Herald Rule');
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -167,7 +167,7 @@ final class LegalpadDocumentEditController extends LegalpadController {
|
|||
$form
|
||||
->appendChild($submit);
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -257,12 +257,12 @@ final class PhabricatorMacroEditController
|
|||
id(new AphrontFormSubmitControl())
|
||||
->setValue(pht('Upload File')));
|
||||
|
||||
$upload = id(new PHUIFormBoxView())
|
||||
$upload = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Upload New File'))
|
||||
->setForm($upload_form);
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -126,7 +126,7 @@ final class PhabricatorMailingListsEditController
|
|||
->setName(pht('Create Mailing List')));
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($page_title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -140,7 +140,7 @@ final class ManiphestBatchEditController extends ManiphestController {
|
|||
id(new PhabricatorCrumbView())
|
||||
->setName($title));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Batch Edit Tasks'))
|
||||
->setForm($form);
|
||||
|
||||
|
|
|
@ -526,7 +526,7 @@ final class ManiphestTaskEditController extends ManiphestController {
|
|||
->addCancelButton($cancel_uri)
|
||||
->setValue($button_name));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($header_name)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -251,7 +251,7 @@ final class PhabricatorOwnersEditController
|
|||
->addCancelButton($cancel_uri)
|
||||
->setValue(pht('Save Package')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -205,7 +205,7 @@ final class PhabricatorPasteEditController extends PhabricatorPasteController {
|
|||
|
||||
$form->appendChild($submit);
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -349,7 +349,7 @@ final class PhabricatorPeopleEditController
|
|||
$title = pht('Create New User');
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
@ -454,7 +454,7 @@ final class PhabricatorPeopleEditController
|
|||
|
||||
$title = pht('Edit Role');
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
@ -496,7 +496,7 @@ final class PhabricatorPeopleEditController
|
|||
|
||||
$title = pht('Conduit Certificate');
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setForm($form);
|
||||
|
||||
|
@ -592,7 +592,7 @@ final class PhabricatorPeopleEditController
|
|||
id(new AphrontFormSubmitControl())
|
||||
->setValue(pht('Change Username')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Change Username'))
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
@ -685,7 +685,7 @@ final class PhabricatorPeopleEditController
|
|||
id(new AphrontFormSubmitControl())
|
||||
->setValue(pht('Delete User')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Delete User'))
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
|
|
@ -80,7 +80,7 @@ final class PhabricatorPeopleProfileEditController
|
|||
->addCancelButton($profile_uri)
|
||||
->setValue(pht('Save Profile')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Edit Your Profile'))
|
||||
->setValidationException($validation_exception)
|
||||
->setForm($form);
|
||||
|
|
|
@ -260,7 +260,7 @@ final class PhabricatorPeopleProfilePictureController
|
|||
->setLabel(pht('Use Picture'))
|
||||
->setValue($buttons));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
@ -284,12 +284,12 @@ final class PhabricatorPeopleProfilePictureController
|
|||
$errors = id(new AphrontErrorView())->setErrors($errors);
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
||||
$upload_box = id(new PHUIFormBoxView())
|
||||
$upload_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Upload New Picture'))
|
||||
->setForm($upload_form);
|
||||
|
||||
|
|
|
@ -170,7 +170,7 @@ final class PhameBlogEditController
|
|||
$error_view = null;
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($page_title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -174,7 +174,7 @@ final class PhamePostEditController
|
|||
$error_view = null;
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($page_title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -117,7 +117,7 @@ final class PhamePostNewController extends PhameController {
|
|||
}
|
||||
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setForm($form);
|
||||
|
||||
|
|
|
@ -46,7 +46,7 @@ final class PhamePostPublishController extends PhameController {
|
|||
|
||||
$frame = $this->renderPreviewFrame($post);
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Preview Post'))
|
||||
->setForm($form);
|
||||
|
||||
|
|
|
@ -176,7 +176,7 @@ final class PhluxEditController extends PhluxController {
|
|||
->setHref($request->getRequestURI()));
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
|
|
@ -322,7 +322,7 @@ final class PholioMockEditController extends PholioController {
|
|||
->setError($e_images))
|
||||
->appendChild($submit);
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -43,7 +43,7 @@ final class PhabricatorXHPASTViewRunController
|
|||
id(new AphrontFormSubmitControl())
|
||||
->setValue('Parse'));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Generate XHP AST'))
|
||||
->setForm($form);
|
||||
|
||||
|
|
|
@ -226,7 +226,7 @@ final class PhrictionEditController
|
|||
->addCancelButton($cancel_uri)
|
||||
->setValue($submit_button));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Edit Document'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -94,7 +94,7 @@ final class PonderAnswerEditController extends PonderController {
|
|||
id(new PhabricatorCrumbView())
|
||||
->setName(pht('Edit Answer')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Edit Answer'))
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
|
|
@ -108,7 +108,7 @@ final class PonderQuestionEditController extends PonderController {
|
|||
->setControlID('content')
|
||||
->setPreviewURI($this->getApplicationURI('preview/'));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Ask New Question'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -113,7 +113,7 @@ final class PhabricatorProjectCreateController
|
|||
->setName(pht('Create Project'))
|
||||
->setHref($this->getApplicationURI().'create/'));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Create New Project'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -106,11 +106,11 @@ final class PhabricatorProjectMembersEditController
|
|||
id(new AphrontFormInsetView())
|
||||
->appendChild($list));
|
||||
|
||||
$box = id(new PHUIFormBoxView())
|
||||
$box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Current Members (%d)', count($handles)))
|
||||
->setForm($faux_form);
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setForm($form);
|
||||
|
||||
|
|
|
@ -219,7 +219,7 @@ final class PhabricatorProjectProfileEditController
|
|||
->addCancelButton('/project/view/'.$project->getID().'/')
|
||||
->setValue(pht('Save')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -108,7 +108,7 @@ final class ReleephProjectCreateController extends ReleephProjectController {
|
|||
->addCancelButton('/releeph/project/')
|
||||
->setValue(pht('Create')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Create New Project'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -101,7 +101,7 @@ final class PhabricatorRepositoryCreateController
|
|||
->setValue('Create Repository')
|
||||
->addCancelButton('/repository/'));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Create Repository'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -155,7 +155,7 @@ final class PhabricatorRepositoryEditController
|
|||
|
||||
$nav = $this->sideNav;
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Edit Repository'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
@ -674,7 +674,7 @@ final class PhabricatorRepositoryEditController
|
|||
id(new AphrontFormSubmitControl())
|
||||
->setValue('Save Configuration'));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Edit Repository Tracking'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -92,7 +92,7 @@ final class PhabricatorSearchEditController
|
|||
$title = pht('Save Query');
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($errors)
|
||||
->setForm($form);
|
||||
|
|
|
@ -137,7 +137,7 @@ final class PhabricatorSettingsPanelAccount
|
|||
id(new AphrontFormSubmitControl())
|
||||
->setValue(pht('Save Account Settings')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Account Settings'))
|
||||
->setForm($form);
|
||||
|
||||
|
|
|
@ -78,7 +78,7 @@ final class PhabricatorSettingsPanelConduit
|
|||
->setHeight(AphrontFormTextAreaControl::HEIGHT_SHORT)
|
||||
->setValue($user->getConduitCertificate()));
|
||||
|
||||
$cert_form = id(new PHUIFormBoxView())
|
||||
$cert_form = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Arcanist Certificate'))
|
||||
->setForm($cert_form);
|
||||
|
||||
|
@ -96,7 +96,7 @@ final class PhabricatorSettingsPanelConduit
|
|||
id(new AphrontFormSubmitControl())
|
||||
->setValue(pht('Regenerate Certificate')));
|
||||
|
||||
$regen_form = id(new PHUIFormBoxView())
|
||||
$regen_form = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Regenerate Certificate'))
|
||||
->setForm($regen_form);
|
||||
|
||||
|
|
|
@ -64,7 +64,7 @@ final class PhabricatorSettingsPanelConpherencePreferences
|
|||
->setErrors(array(pht('Your preferences have been saved.')));
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Conpherence Preferences'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -93,7 +93,7 @@ final class PhabricatorSettingsPanelDeveloperPreferences
|
|||
->setErrors(array(pht('Your preferences have been saved.')));
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Developer Settings'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -66,7 +66,7 @@ final class PhabricatorSettingsPanelDiffPreferences
|
|||
->setErrors(array(pht('Your preferences have been saved.')));
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Diff Preferences'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -145,7 +145,7 @@ EXAMPLE;
|
|||
->setErrors(array(pht('Your preferences have been saved.')));
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Display Preferences'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -216,7 +216,7 @@ final class PhabricatorSettingsPanelEmailPreferences
|
|||
id(new AphrontFormSubmitControl())
|
||||
->setValue(pht('Save Preferences')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Email Preferences'))
|
||||
->setFormError($notice)
|
||||
->setForm($form);
|
||||
|
|
|
@ -200,7 +200,7 @@ final class PhabricatorSettingsPanelHomePreferences
|
|||
->setErrors(array(pht('Your preferences have been saved.')));
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Home Page Preferences'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -159,7 +159,7 @@ final class PhabricatorSettingsPanelPassword
|
|||
id(new AphrontFormSubmitControl())
|
||||
->setValue(pht('Save')));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Delete User'))
|
||||
->setFormError($notice)
|
||||
->setForm($form);
|
||||
|
|
|
@ -58,7 +58,7 @@ final class PhabricatorSettingsPanelSearchPreferences
|
|||
->setErrors(array(pht('Your preferences have been saved.')));
|
||||
}
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText(pht('Search Preferences'))
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -231,7 +231,7 @@ final class PhabricatorSlowvoteEditController
|
|||
id(new PhabricatorCrumbView())
|
||||
->setName($title));
|
||||
|
||||
$form_box = id(new PHUIFormBoxView())
|
||||
$form_box = id(new PHUIObjectBoxView())
|
||||
->setHeaderText($title)
|
||||
->setFormError($error_view)
|
||||
->setForm($form);
|
||||
|
|
|
@ -1,11 +1,12 @@
|
|||
<?php
|
||||
|
||||
final class PHUIFormBoxView extends AphrontView {
|
||||
final class PHUIObjectBoxView extends AphrontView {
|
||||
|
||||
private $headerText;
|
||||
private $formError = null;
|
||||
private $form;
|
||||
private $validationException;
|
||||
private $content = array();
|
||||
|
||||
public function setHeaderText($text) {
|
||||
$this->headerText = $text;
|
||||
|
@ -22,6 +23,11 @@ final class PHUIFormBoxView extends AphrontView {
|
|||
return $this;
|
||||
}
|
||||
|
||||
public function addContent($content) {
|
||||
$this->content[] = $content;
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function setValidationException(
|
||||
PhabricatorApplicationTransactionValidationException $ex = null) {
|
||||
$this->validationException = $ex;
|
||||
|
@ -54,12 +60,13 @@ final class PHUIFormBoxView extends AphrontView {
|
|||
$this->formError,
|
||||
$exception_errors,
|
||||
$this->form,
|
||||
$this->content,
|
||||
))
|
||||
->setBorder(true)
|
||||
->addMargin(PHUI::MARGIN_LARGE_TOP)
|
||||
->addMargin(PHUI::MARGIN_LARGE_LEFT)
|
||||
->addMargin(PHUI::MARGIN_LARGE_RIGHT)
|
||||
->addClass('phui-form-box');
|
||||
->addClass('phui-object-box');
|
||||
|
||||
return $content;
|
||||
|
|
@ -426,17 +426,17 @@ table.aphront-form-control-checkbox-layout th {
|
|||
display: none;
|
||||
}
|
||||
|
||||
.phui-form-box .phabricator-action-header {
|
||||
.phui-object-box .phabricator-action-header {
|
||||
padding: 4px 5px 4px 12px;
|
||||
border-bottom: 1px solid {$lightblueborder};
|
||||
}
|
||||
|
||||
.phui-form-box .phabricator-action-header h3 {
|
||||
.phui-object-box .phabricator-action-header h3 {
|
||||
color: {$bluetext};
|
||||
text-shadow: 0 1px 2px #fff;
|
||||
}
|
||||
|
||||
.phui-form-box .aphront-error-view {
|
||||
.phui-object-box .aphront-error-view {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue