| 1 |
<?php |
| 2 |
declare(strict_types=1); |
| 3 |
|
| 4 |
namespace WPDesk\FlexibleSubscriptions\Admin\Settings; |
| 5 |
|
| 6 |
use WPDesk\FlexibleSubscriptions\Form\Fields\AccountEndpointFields; |
| 7 |
use WPDesk\FlexibleSubscriptions\Form\Fields\Tab; |
| 8 |
|
| 9 |
class AccountTab extends Tab { |
| 10 |
|
| 11 |
public function __construct() { |
| 12 |
parent::__construct( $this->fields() ); |
| 13 |
} |
| 14 |
|
| 15 |
private function fields(): array { |
| 16 |
return [ |
| 17 |
( new AccountEndpointFields() ) |
| 18 |
->set_name( 'account_endpoints' ) |
| 19 |
->set_label( __( 'Account endpoints', 'flexible-subscriptions' ) ) |
| 20 |
->set_description( |
| 21 |
__( |
| 22 |
'Endpoints are appended to your page URLs to handle specific actions on the accounts pages. They should be unique and can be left blank to disable the endpoint. |
| 23 |
', |
| 24 |
'flexible-subscriptions' |
| 25 |
) |
| 26 |
), |
| 27 |
]; |
| 28 |
} |
| 29 |
} |
| 30 |
|