com_extensiondistributor/media/js/package.js

134 lines
4.1 KiB
JavaScript

/*----------------------------------------------------------------------------------| www.vdm.io |----/
Agence Agerix
/-------------------------------------------------------------------------------------------------------/
@version 1.x.x
@build 2nd June, 2022
@created 12th December, 2020
@package Extension Distributor
@subpackage package.js
@author Emmanuel Danan <https://agerix.fr>
@copyright Copyright (C) 2021. All Rights Reserved.
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
____ _____ _____ __ __ __ __ ___ _____ __ __ ____ _____ _ _ ____ _ _ ____
(_ _)( _ )( _ )( \/ )( ) /__\ / __)( _ )( \/ )( _ \( _ )( \( )( ___)( \( )(_ _)
.-_)( )(_)( )(_)( ) ( )(__ /(__)\ ( (__ )(_)( ) ( )___/ )(_)( ) ( )__) ) ( )(
\____) (_____)(_____)(_/\/\_)(____)(__)(__) \___)(_____)(_/\/\_)(__) (_____)(_)\_)(____)(_)\_) (__)
/------------------------------------------------------------------------------------------------------*/
// Initial Script
jQuery(document).ready(function()
{
var add_php_method_uninstall_vvvvvvv = jQuery("#jform_add_php_method_uninstall input[type='radio']:checked").val();
vvvvvvv(add_php_method_uninstall_vvvvvvv);
var add_php_postflight_install_vvvvvvw = jQuery("#jform_add_php_postflight_install input[type='radio']:checked").val();
vvvvvvw(add_php_postflight_install_vvvvvvw);
var add_php_postflight_update_vvvvvvx = jQuery("#jform_add_php_postflight_update input[type='radio']:checked").val();
vvvvvvx(add_php_postflight_update_vvvvvvx);
var add_php_preflight_install_vvvvvvy = jQuery("#jform_add_php_preflight_install input[type='radio']:checked").val();
vvvvvvy(add_php_preflight_install_vvvvvvy);
var add_php_preflight_uninstall_vvvvvvz = jQuery("#jform_add_php_preflight_uninstall input[type='radio']:checked").val();
vvvvvvz(add_php_preflight_uninstall_vvvvvvz);
var add_php_preflight_update_vvvvvwa = jQuery("#jform_add_php_preflight_update input[type='radio']:checked").val();
vvvvvwa(add_php_preflight_update_vvvvvwa);
});
// the vvvvvvv function
function vvvvvvv(add_php_method_uninstall_vvvvvvv)
{
// set the function logic
if (add_php_method_uninstall_vvvvvvv == 1)
{
jQuery('#jform_php_method_uninstall-lbl').closest('.control-group').show();
}
else
{
jQuery('#jform_php_method_uninstall-lbl').closest('.control-group').hide();
}
}
// the vvvvvvw function
function vvvvvvw(add_php_postflight_install_vvvvvvw)
{
// set the function logic
if (add_php_postflight_install_vvvvvvw == 1)
{
jQuery('#jform_php_postflight_install-lbl').closest('.control-group').show();
}
else
{
jQuery('#jform_php_postflight_install-lbl').closest('.control-group').hide();
}
}
// the vvvvvvx function
function vvvvvvx(add_php_postflight_update_vvvvvvx)
{
// set the function logic
if (add_php_postflight_update_vvvvvvx == 1)
{
jQuery('#jform_php_postflight_update-lbl').closest('.control-group').show();
}
else
{
jQuery('#jform_php_postflight_update-lbl').closest('.control-group').hide();
}
}
// the vvvvvvy function
function vvvvvvy(add_php_preflight_install_vvvvvvy)
{
// set the function logic
if (add_php_preflight_install_vvvvvvy == 1)
{
jQuery('#jform_php_preflight_install-lbl').closest('.control-group').show();
}
else
{
jQuery('#jform_php_preflight_install-lbl').closest('.control-group').hide();
}
}
// the vvvvvvz function
function vvvvvvz(add_php_preflight_uninstall_vvvvvvz)
{
// set the function logic
if (add_php_preflight_uninstall_vvvvvvz == 1)
{
jQuery('#jform_php_preflight_uninstall-lbl').closest('.control-group').show();
}
else
{
jQuery('#jform_php_preflight_uninstall-lbl').closest('.control-group').hide();
}
}
// the vvvvvwa function
function vvvvvwa(add_php_preflight_update_vvvvvwa)
{
// set the function logic
if (add_php_preflight_update_vvvvvwa == 1)
{
jQuery('#jform_php_preflight_update-lbl').closest('.control-group').show();
}
else
{
jQuery('#jform_php_preflight_update-lbl').closest('.control-group').hide();
}
}
// the isSet function
function isSet(val)
{
if ((val != undefined) && (val != null) && 0 !== val.length){
return true;
}
return false;
}