Merge pull request #15837 from totten/master-prtmpl
[civicrm-core.git] / CRM / Core / QuickForm / Action / Back.php
1 <?php
2 /*
3 +--------------------------------------------------------------------+
4 | Copyright CiviCRM LLC. All rights reserved. |
5 | |
6 | This work is published under the GNU AGPLv3 license with some |
7 | permitted exceptions and without any warranty. For full license |
8 | and copyright information, see https://civicrm.org/licensing |
9 +--------------------------------------------------------------------+
10 */
11
12 /**
13 * Redefine the back action.
14 *
15 * @package CRM
16 * @copyright CiviCRM LLC https://civicrm.org/licensing
17 */
18 class CRM_Core_QuickForm_Action_Back extends CRM_Core_QuickForm_Action {
19
20 /**
21 * Class constructor.
22 *
23 * @param object $stateMachine
24 * Reference to state machine object.
25 *
26 * @return \CRM_Core_QuickForm_Action_Back
27 */
28 public function __construct(&$stateMachine) {
29 parent::__construct($stateMachine);
30 }
31
32 /**
33 * Processes the request.
34 *
35 * @param CRM_Core_Form $page
36 * The current form-page.
37 * @param string $actionName
38 * Current action name, as one Action object can serve multiple actions.
39 */
40 public function perform(&$page, $actionName) {
41 $this->_stateMachine->perform($page, $actionName, 'Back');
42 }
43
44 }