PluginProbe
Booktics – Appointment Booking Calendar for Service Businesses / 1.0.3
Booktics – Appointment Booking Calendar for Service Businesses v1.0.3
1.0.29 1.0.28 1.0.27 1.0.26 1.0.25 1.0.24 1.0.23 1.0.22 1.0.21 1.0.20 1.0.19 trunk 1.0.0 1.0.1 1.0.10 1.0.11 1.0.12 1.0.13 1.0.14 1.0.15 1.0.16 1.0.17 1.0.18 1.0.2 1.0.3 All 31 releases
booktics / core / service / service-service-provider.php

service-service-provider.php in Booktics – Appointment Booking Calendar for Service Businesses 1.0.3, at core/service/service-service-provider.php

51 lines 1.2 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace Booktics\Service;
4
5 use Booktics\Providers\Base_Service_Provider;
6 use Booktics\Service\Controllers\Service_Controller;
7 use Booktics\Service\Templates\Single_Service_Template;
8
9 /**
10 * Service_Service_Provider will responsible for all service services
11 *
12 * @package Booktics/Service
13 */
14 class Service_Service_Provider extends Base_Service_Provider {
15 /**
16 * Store services
17 *
18 * @var array
19 */
20 protected array $services = array(
21 Service_Controller::class,
22 Single_Service_Template::class,
23 );
24
25 /**
26 * Register services
27 *
28 * @return array
29 */
30 public function get_services(): array {
31
32 register_post_type(
33 'booktics-service', array(
34 'labels' => array(
35 'name' => __( 'Services', 'booktics' ),
36 'singular_name' => __( 'Service', 'booktics' ),
37 ),
38 'public' => true,
39 'has_archive' => true,
40 'has_single' => true,
41 'rewrite' => array( 'slug' => 'services' ),
42 'supports' => array( 'title', 'editor', 'thumbnail' ),
43 'show_in_rest' => true,
44 'show_in_menu' => false,
45 )
46 );
47
48 return apply_filters( 'booktics_service_services', $this->services );
49 }
50 }
51