<?php
	$plural_name = '';
	if( function_exists( 'ultimate_booking_pro_cs_get_option' ) ) :
		$plural_name	=	ultimate_booking_pro_cs_get_option( 'singular-service-text', esc_html__('Service', 'ultimate-booking-pro') );
	endif;

	vc_map( array(
		"name" => $plural_name.esc_html__(' List', 'ultimate-booking-pro'),
		"base" => "dt_sc_service_list",
		"icon" => "dt_sc_service_list",
		"category" => esc_html__( 'Booking Manager', 'ultimate-booking-pro' ),
		"params" => array(

			# Terms
			array(
				'type' => 'autocomplete',
				'heading' => esc_html__( 'Terms', 'ultimate-booking-pro' ),
				'param_name' => 'terms',
				'settings' => array(
					'multiple' => true,
					'min_length' => 1,
					'groups' => true,
					'unique_values' => true,
					'display_inline' => true,
					'delay' => 500,
					'auto_focus' => true,
				),
				'param_holder_class' => 'vc_not-for-custom',
				'description' => esc_html__( 'Enter service category & pick.', 'ultimate-booking-pro' )
			),

			# Count
			array (
				"type" => "textfield",
				"heading" => esc_html__( "Products Per Page", 'ultimate-booking-pro' ),
				"param_name" => "posts_per_page",
				"value" => 3,
				"save_always" => true
			),
			
			# Order By
			array (
				"type" => "dropdown",
				"heading" => esc_html__( "Order by", 'ultimate-booking-pro' ),
				"param_name" => "orderby",
				'save_always' => true,
				"value" => array (
					esc_html__('ID','ultimate-booking-pro') => 'ID',
					esc_html__('Title','ultimate-booking-pro') => 'title',
					esc_html__('Name','ultimate-booking-pro') => 'name',
					esc_html__('Type','ultimate-booking-pro') => 'type',
					esc_html__('Date','ultimate-booking-pro') => 'date',
					esc_html__('Random','ultimate-booking-pro') => 'rand'
				)
			),

			# Order
			array (
				"type" => "dropdown",
				"heading" => esc_html__( "Sort order", 'ultimate-booking-pro' ),
				"param_name" => "order",
				'save_always' => true,
				"value" => array (
					esc_html__( 'Descending', 'ultimate-booking-pro' ) => 'desc',
					esc_html__( 'Ascending', 'ultimate-booking-pro' ) => 'asc'
				)
			),

			# Class
			array (
				"type" => "textfield",
				"heading" => esc_html__( 'Extra class name', 'ultimate-booking-pro' ),
				"param_name" => "el_class",
				"description" => esc_html__( "If you wish to style particular content element differently, then use this field to add a class name and then refer to it in your css file.", 'ultimate-booking-pro' )
			)
	     )
	) );