<?php
require_once  get_template_directory() . '/anps-framework/class-tgm-plugin-activation.php';
add_action('tgmpa_register', 'widebox_register_required_plugins');
function widebox_register_required_plugins() {
    $plugins = array(
        array(
            'name' => 'LayerSlider WP',
            'slug' => 'layersliderwp',
            'source' => 'http://astudio.si/preview/plugins/'.ANPS_TEMPLATE_LANG.'/layersliderwp.zip',
            'required' => false,
            'version' => '',
            'force_activation' => false,
            'force_deactivation' => false,
            'external_url' => '',
        ),
        array(
            'name' => 'Revolution Slider WP',
            'slug' => 'revslider',
            'source' => 'http://astudio.si/preview/plugins/'.ANPS_TEMPLATE_LANG.'/revslider.zip',
            'required' => false,
            'version' => '',
            'force_activation' => false,
            'force_deactivation' => false,
            'external_url' => '',
        ),
        array(
            'name' => 'Anps Restaurant',
            'slug' => 'anps_restaurant',
            'source' => 'http://astudio.si/preview/plugins/'.ANPS_TEMPLATE_LANG.'/anps_restaurant.zip',
            'required' => false,
            'version' => '',
            'force_activation' => false,
            'force_deactivation' => false,
            'external_url' => '',
        ),
        array(
            'name' => 'Visual Composer',
            'slug' => 'js_composer',
            'source' => 'http://astudio.si/preview/plugins/'.ANPS_TEMPLATE_LANG.'/js_composer.zip',
            'required' => false,
            'version' => '',
            'force_activation' => false,
            'force_deactivation' => false,
            'external_url' => '',
        ),
        array(
            'name' => 'WooCommerce',
            'slug' => 'woocommerce',
            'source' => 'http://downloads.wordpress.org/plugin/woocommerce.zip',
            'required' => false,
            'version' => '',
            'force_activation' => false,
            'force_deactivation' => false,
            'external_url' => '',
        ),
        array(
            'name' => 'Intuitive Custom Post Order',
            'slug' => 'intuitive-custom-post-order',
            'source' => 'https://downloads.wordpress.org/plugin/intuitive-custom-post-order.zip',
            'required' => false,
            'version' => '',
            'force_activation' => false,
            'force_deactivation' => false,
            'external_url' => '',
        )
    );
    $config = array(
        'domain' => ANPS_TEMPLATE_LANG,
        'default_path' => '',
        'parent_slug' => 'themes.php',
        'menu' => 'install-required-plugins', 
        'has_notices' => true,
        'is_automatic' => true,
        'message' => '',
    );
    tgmpa($plugins, $config);
}
