APIv4 - smarter parsing of Entity docblocks
[civicrm-core.git] / CRM / Admin / Page / PaymentProcessorType.php
CommitLineData
6a488035
TO
1<?php
2/*
3 +--------------------------------------------------------------------+
bc77d7c0 4 | Copyright CiviCRM LLC. All rights reserved. |
6a488035 5 | |
bc77d7c0
TO
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 |
6a488035 9 +--------------------------------------------------------------------+
d25dd0ee 10 */
6a488035
TO
11
12/**
13 *
14 * @package CRM
ca5cec67 15 * @copyright CiviCRM LLC https://civicrm.org/licensing
6a488035
TO
16 */
17
18/**
ce064e4f 19 * Page for displaying list of payment processors.
6a488035
TO
20 */
21class CRM_Admin_Page_PaymentProcessorType extends CRM_Core_Page_Basic {
22
23 /**
eceb18cc 24 * The action links that we need to display for the browse screen.
6a488035
TO
25 *
26 * @var array
6a488035 27 */
62d3ee27 28 public static $_links = NULL;
6a488035
TO
29
30 /**
eceb18cc 31 * Get BAO Name.
6a488035 32 *
a6c01b45
CW
33 * @return string
34 * Classname of BAO.
6a488035 35 */
00be9182 36 public function getBAOName() {
6a488035
TO
37 return 'CRM_Financial_BAO_PaymentProcessorType';
38 }
39
40 /**
eceb18cc 41 * Get action Links.
6a488035 42 *
a6c01b45
CW
43 * @return array
44 * (reference) of action links
6a488035 45 */
00be9182 46 public function &links() {
6a488035 47 if (!(self::$_links)) {
be2fb01f
CW
48 self::$_links = [
49 CRM_Core_Action::UPDATE => [
6a488035
TO
50 'name' => ts('Edit'),
51 'url' => 'civicrm/admin/paymentProcessorType',
52 'qs' => 'action=update&id=%%id%%&reset=1',
53 'title' => ts('Edit Payment ProcessorType'),
be2fb01f
CW
54 ],
55 CRM_Core_Action::DISABLE => [
6a488035 56 'name' => ts('Disable'),
4d17a233 57 'ref' => 'crm-enable-disable',
6a488035 58 'title' => ts('Disable Payment ProcessorType'),
be2fb01f
CW
59 ],
60 CRM_Core_Action::ENABLE => [
6a488035 61 'name' => ts('Enable'),
4d17a233 62 'ref' => 'crm-enable-disable',
6a488035 63 'title' => ts('Enable Payment ProcessorType'),
be2fb01f
CW
64 ],
65 CRM_Core_Action::DELETE => [
6a488035
TO
66 'name' => ts('Delete'),
67 'url' => 'civicrm/admin/paymentProcessorType',
68 'qs' => 'action=delete&id=%%id%%',
69 'title' => ts('Delete Payment ProcessorType'),
be2fb01f
CW
70 ],
71 ];
6a488035
TO
72 }
73 return self::$_links;
74 }
75
76 /**
eceb18cc 77 * Get name of edit form.
6a488035 78 *
a6c01b45
CW
79 * @return string
80 * Classname of edit form.
6a488035 81 */
00be9182 82 public function editForm() {
6a488035
TO
83 return 'CRM_Admin_Form_PaymentProcessorType';
84 }
85
86 /**
eceb18cc 87 * Get edit form name.
6a488035 88 *
a6c01b45
CW
89 * @return string
90 * name of this page.
6a488035 91 */
00be9182 92 public function editName() {
6a488035
TO
93 return 'Payment Processor Type';
94 }
95
96 /**
97 * Get user context.
98 *
dd244018
EM
99 * @param null $mode
100 *
a6c01b45
CW
101 * @return string
102 * user context.
6a488035 103 */
00be9182 104 public function userContext($mode = NULL) {
6a488035
TO
105 return 'civicrm/admin/paymentProcessorType';
106 }
96025800 107
7c9e1b3b
EM
108 /**
109 * Get any properties that should always be present in each row (null if no value).
110 *
111 * @return array
112 */
113 protected function getExpectedRowProperties(): array {
114 return ['class', 'description'];
115 }
116
6a488035 117}