From 3453507230ed4aa6ea405ad88488dd604c34f93b Mon Sep 17 00:00:00 2001 From: Chad Little Date: Tue, 7 Jun 2016 20:55:18 -0700 Subject: [PATCH] Add print styles for Phortune carts Summary: Fixes T10899, adds styles specifically for printing Phortune carts. Test Plan: Print a Phortune cart Reviewers: epriestley Reviewed By: epriestley Subscribers: Korvin Maniphest Tasks: T10899 Differential Revision: https://secure.phabricator.com/D16079 --- resources/celerity/map.php | 4 ++-- .../phortune/controller/PhortuneCartViewController.php | 2 ++ webroot/rsrc/css/application/phortune/phortune.css | 10 ++++++++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/resources/celerity/map.php b/resources/celerity/map.php index 593aad51bd..9f7ad051bc 100644 --- a/resources/celerity/map.php +++ b/resources/celerity/map.php @@ -86,7 +86,7 @@ return array( 'rsrc/css/application/pholio/pholio-inline-comments.css' => '8e545e49', 'rsrc/css/application/pholio/pholio.css' => 'ca89d380', 'rsrc/css/application/phortune/phortune-credit-card-form.css' => '8391eb02', - 'rsrc/css/application/phortune/phortune.css' => '9149f103', + 'rsrc/css/application/phortune/phortune.css' => '5b99dae0', 'rsrc/css/application/phrequent/phrequent.css' => 'ffc185ad', 'rsrc/css/application/phriction/phriction-document-css.css' => '4282e4ad', 'rsrc/css/application/policy/policy-edit.css' => '815c66f7', @@ -814,7 +814,7 @@ return array( 'pholio-inline-comments-css' => '8e545e49', 'phortune-credit-card-form' => '2290aeef', 'phortune-credit-card-form-css' => '8391eb02', - 'phortune-css' => '9149f103', + 'phortune-css' => '5b99dae0', 'phrequent-css' => 'ffc185ad', 'phriction-document-css' => '4282e4ad', 'phui-action-panel-css' => '91c7b835', diff --git a/src/applications/phortune/controller/PhortuneCartViewController.php b/src/applications/phortune/controller/PhortuneCartViewController.php index 8d85ec70fe..e105973e11 100644 --- a/src/applications/phortune/controller/PhortuneCartViewController.php +++ b/src/applications/phortune/controller/PhortuneCartViewController.php @@ -8,6 +8,7 @@ final class PhortuneCartViewController $id = $request->getURIData('id'); $authority = $this->loadMerchantAuthority(); + require_celerity_resource('phortune-css'); $query = id(new PhortuneCartQuery()) ->setViewer($viewer) @@ -208,6 +209,7 @@ final class PhortuneCartViewController return $this->newPage() ->setTitle(pht('Cart %d', $cart->getID())) ->setCrumbs($crumbs) + ->addClass('phortune-cart-page') ->appendChild($view); } diff --git a/webroot/rsrc/css/application/phortune/phortune.css b/webroot/rsrc/css/application/phortune/phortune.css index 10ddf2c245..02199f93e6 100644 --- a/webroot/rsrc/css/application/phortune/phortune.css +++ b/webroot/rsrc/css/application/phortune/phortune.css @@ -24,3 +24,13 @@ margin: 0 0 8px 0; width: 100%; } + +.printable.phortune-cart-page .phui-two-column-view .phui-two-column-content + .phui-main-column { + width: auto; +} + +.printable.phortune-cart-page .phui-two-column-view .phui-two-column-content + .phui-side-column { + display: none; +}