export-page.php
2 years ago
gateways-pages-trait.php
2 years ago
payments-page.php
2 years ago
print-page.php
2 years ago
single-payment-page.php
2 years ago
single-payment-print-page.php
2 years ago
single-payment-page.php
54 lines
| 1 | <?php |
| 2 | |
| 3 | |
| 4 | namespace JFB_Modules\Gateways\Pages; |
| 5 | |
| 6 | use Jet_Form_Builder\Admin\Pages\Pages_Manager; |
| 7 | use Jet_Form_Builder\Admin\Single_Pages\Base_Single_Page; |
| 8 | use Jet_Form_Builder\Admin\Single_Pages\Meta_Containers; |
| 9 | use JFB_Modules\Gateways\Meta_Boxes\Payer_Box; |
| 10 | use JFB_Modules\Gateways\Meta_Boxes\Payer_Shipping_Box; |
| 11 | use Jet_Form_Builder\Gateways\Meta_Boxes\Payment_Details_Box; |
| 12 | use JFB_Modules\Gateways\Meta_Boxes\Payment_Actions_Box; |
| 13 | |
| 14 | // If this file is called directly, abort. |
| 15 | if ( ! defined( 'WPINC' ) ) { |
| 16 | die; |
| 17 | } |
| 18 | |
| 19 | class Single_Payment_Page extends Base_Single_Page { |
| 20 | |
| 21 | use Gateways_Pages_Trait; |
| 22 | |
| 23 | /** |
| 24 | * Page title |
| 25 | */ |
| 26 | public function title(): string { |
| 27 | return __( 'JetFormBuilder Payment', 'jet-form-builder' ); |
| 28 | } |
| 29 | |
| 30 | public function parent_slug(): string { |
| 31 | return Payments_Page::SLUG; |
| 32 | } |
| 33 | |
| 34 | public function meta_containers(): array { |
| 35 | return array( |
| 36 | new Meta_Containers\Normal_Meta_Container( |
| 37 | new Payer_Box(), |
| 38 | new Payer_Shipping_Box() |
| 39 | ), |
| 40 | new Meta_Containers\Side_Meta_Container( |
| 41 | new Payment_Details_Box(), |
| 42 | new Payment_Actions_Box() |
| 43 | ), |
| 44 | ); |
| 45 | } |
| 46 | |
| 47 | public function assets() { |
| 48 | wp_enqueue_style( Pages_Manager::STYLE_ADMIN ); |
| 49 | wp_enqueue_script( Pages_Manager::SCRIPT_VUEX_PACKAGE ); |
| 50 | |
| 51 | parent::assets(); |
| 52 | } |
| 53 | } |
| 54 |