HEX
Server: Apache/2.4.52 (Ubuntu)
System: Linux WebLive 5.15.0-79-generic #86-Ubuntu SMP Mon Jul 10 16:07:21 UTC 2023 x86_64
User: ubuntu (1000)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/www/html/wptrinityconsulting/wp-content/plugins/finbuzz-core/elementor/widgets/pricing-tab.php
<?php
/**
 * This file can be overridden by copying it to yourtheme/elementor-custom/about-box/class.php
 * 
 * @author  RadiusTheme
 * @since   1.0
 * @version 1.0
 */

namespace radiustheme\Finbuzz_Core;

use Elementor\Controls_Manager;
use Elementor\Group_Control_Typography;
use Elementor\Group_Control_Background;


if ( ! defined( 'ABSPATH' ) ) exit;

class Pricing_Tab extends Custom_Widget_Base {

	public function __construct( $data = [], $args = null ){
		$this->rt_name = __( 'Pricing Tab', 'finbuzz-core' );
		$this->rt_base = 'rt-pricing-tab';
		parent::__construct( $data, $args );
	}

	public function rt_fields(){
		$repeater = new \Elementor\Repeater();
		$repeater->add_control(
			'title',
			 [
				'type'    => Controls_Manager::TEXT,
				'label'   => esc_html__( 'Title', 'finbuzz-core' ),
				'default' => 'Basic Plan',
			]
		);
		$repeater->add_control(
			'monthly_price',
			 [
				'type'    => Controls_Manager::TEXT,
				'label'   => esc_html__( 'Monthly Price', 'finbuzz-core' ),
				'default' => '$19',
			]
		);
		$repeater->add_control(
			'yearly_price',
			 [
				'type'    => Controls_Manager::TEXT,
				'label'   => esc_html__( 'Yearly Price', 'finbuzz-core' ),
				'default' => '$60',
			]
		);
		$repeater->add_control(
			'content',
			 [
				'type'    => Controls_Manager::TEXT,
				'label'   => esc_html__( 'Content', 'finbuzz-core' ),
				'default' => 'Popularised in the follower with the etraset sheets containing.',
			]
		);
		$repeater->add_control(
			'list_item',
			 [
				'type'    => Controls_Manager::WYSIWYG,
				'label'   => esc_html__( 'Pricing List', 'finbuzz-core' ),
			]
		);
		$repeater->add_control(
			'btn_link',
			 [
				'type'    => Controls_Manager::URL,
				'label'   => esc_html__( 'Button Link', 'finbuzz-core' ),
			]
		);
		$fields = array(
			array(
				'id'      => 'sec_general',
				'mode'    => 'section_start',
				'label'   => __( 'General', 'finbuzz-core' ),
			),
			// Monthly
			array(
				'id'      => 'monthly_heading',
				'type' => Controls_Manager::HEADING,
				'label'   => __( 'Monthly', 'finbuzz-core' ),
				'separator' => 'before',
			),
			array(
				'id'      => 'monthly_label',
				'type'    => Controls_Manager::TEXT,
				'label'   => esc_html__( 'Label', 'finbuzz-core' ),
				'default' => 'MONTHLY',
				'label_block' => true,
			),      
			// Yearly 
			array(
				'id'      => 'yearly_heading',
				'type' => Controls_Manager::HEADING,
				'label'   => __( 'Yearly', 'finbuzz-core' ),
				'separator' => 'before',
			),
			array(
				'id'      => 'yearly_label',
				'type'    => Controls_Manager::TEXT,
				'label'   => esc_html__( 'Label', 'finbuzz-core' ),
				'default' => 'YEARLY',
				'label_block' => true,
			),
			array (
				'type'    => Controls_Manager::REPEATER,
				'id'      => 'prices_infos',
				'label'   => esc_html__( 'Add Plan', 'finbuzz-core' ),
				'fields' => $repeater->get_controls(),
				'default' => array(
					['title' => 'Basic Plan', ],
					['title' => 'Standard Plan', ],
					['title' => 'Premium Plan', ],
				),
			),
			array(
				'mode' => 'section_end',
			),
		);
		return $fields;
	}

	protected function render() {
		$data = $this->get_settings();

		$template = 'pricing-tab';

		return $this->rt_template( $template, $data );
	}
}