2018-02-15 00:42:39 +00:00
|
|
|
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
|
|
|
|
__ __ _ _____ _ _ __ __ _ _ _
|
|
|
|
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
|
|
|
|
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
|
|
|
|
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
|
|
|
|
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
|
|
|
|
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
|
|
|
|
| |
|
|
|
|
|_|
|
|
|
|
/-------------------------------------------------------------------------------------------------------------------------------/
|
|
|
|
|
|
|
|
@version 2.6.x
|
|
|
|
@created 30th April, 2015
|
|
|
|
@package Component Builder
|
|
|
|
@subpackage server.js
|
|
|
|
@author Llewellyn van der Merwe <http://joomlacomponentbuilder.com>
|
|
|
|
@github Joomla Component Builder <https://github.com/vdm-io/Joomla-Component-Builder>
|
|
|
|
@copyright Copyright (C) 2015. All Rights Reserved
|
|
|
|
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
|
|
|
|
|
|
|
|
Builds Complex Joomla Components
|
|
|
|
|
|
|
|
/-----------------------------------------------------------------------------------------------------------------------------*/
|
|
|
|
|
|
|
|
// Some Global Values
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwad_required = false;
|
2018-03-09 03:26:44 +00:00
|
|
|
jform_vvvvwavwae_required = false;
|
|
|
|
jform_vvvvwavwaf_required = false;
|
|
|
|
jform_vvvvwavwag_required = false;
|
|
|
|
jform_vvvvwavwah_required = false;
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwawwai_required = false;
|
|
|
|
jform_vvvvwaxwaj_required = false;
|
|
|
|
jform_vvvvwazwak_required = false;
|
|
|
|
jform_vvvvwbbwal_required = false;
|
2018-02-15 00:42:39 +00:00
|
|
|
|
|
|
|
// Initial Script
|
|
|
|
jQuery(document).ready(function()
|
|
|
|
{
|
|
|
|
var protocol_vvvvwav = jQuery("#jform_protocol").val();
|
2018-03-09 03:26:44 +00:00
|
|
|
vvvvwav(protocol_vvvvwav);
|
|
|
|
|
|
|
|
var protocol_vvvvwaw = jQuery("#jform_protocol").val();
|
|
|
|
vvvvwaw(protocol_vvvvwaw);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
|
|
|
var protocol_vvvvwax = jQuery("#jform_protocol").val();
|
2018-02-17 22:47:01 +00:00
|
|
|
var authentication_vvvvwax = jQuery("#jform_authentication").val();
|
2018-02-15 00:42:39 +00:00
|
|
|
vvvvwax(protocol_vvvvwax,authentication_vvvvwax);
|
|
|
|
|
2018-02-27 12:17:38 +00:00
|
|
|
var protocol_vvvvwaz = jQuery("#jform_protocol").val();
|
|
|
|
var authentication_vvvvwaz = jQuery("#jform_authentication").val();
|
|
|
|
vvvvwaz(protocol_vvvvwaz,authentication_vvvvwaz);
|
|
|
|
|
|
|
|
var protocol_vvvvwbb = jQuery("#jform_protocol").val();
|
|
|
|
var authentication_vvvvwbb = jQuery("#jform_authentication").val();
|
|
|
|
vvvvwbb(protocol_vvvvwbb,authentication_vvvvwbb);
|
2018-03-09 03:26:44 +00:00
|
|
|
|
|
|
|
var protocol_vvvvwbd = jQuery("#jform_protocol").val();
|
|
|
|
var authentication_vvvvwbd = jQuery("#jform_authentication").val();
|
|
|
|
vvvvwbd(protocol_vvvvwbd,authentication_vvvvwbd);
|
2018-02-15 00:42:39 +00:00
|
|
|
});
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwav function
|
|
|
|
function vvvvwav(protocol_vvvvwav)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(protocol_vvvvwav) && protocol_vvvvwav.constructor !== Array)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwav = protocol_vvvvwav;
|
|
|
|
var protocol_vvvvwav = [];
|
|
|
|
protocol_vvvvwav.push(temp_vvvvwav);
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(protocol_vvvvwav))
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol_vvvvwav = [];
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol = protocol_vvvvwav.some(protocol_vvvvwav_SomeFunc);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
// set this function logic
|
|
|
|
if (protocol)
|
|
|
|
{
|
|
|
|
jQuery('#jform_authentication').closest('.control-group').show();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (jform_vvvvwavwad_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('authentication',0);
|
|
|
|
jQuery('#jform_authentication').prop('required','required');
|
|
|
|
jQuery('#jform_authentication').attr('aria-required',true);
|
|
|
|
jQuery('#jform_authentication').addClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwad_required = false;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
jQuery('#jform_host').closest('.control-group').show();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (jform_vvvvwavwae_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('host',0);
|
|
|
|
jQuery('#jform_host').prop('required','required');
|
|
|
|
jQuery('#jform_host').attr('aria-required',true);
|
|
|
|
jQuery('#jform_host').addClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwae_required = false;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
jQuery('#jform_port').closest('.control-group').show();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (jform_vvvvwavwaf_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('port',0);
|
|
|
|
jQuery('#jform_port').prop('required','required');
|
|
|
|
jQuery('#jform_port').attr('aria-required',true);
|
|
|
|
jQuery('#jform_port').addClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwaf_required = false;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
jQuery('#jform_path').closest('.control-group').show();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (jform_vvvvwavwag_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('path',0);
|
|
|
|
jQuery('#jform_path').prop('required','required');
|
|
|
|
jQuery('#jform_path').attr('aria-required',true);
|
|
|
|
jQuery('#jform_path').addClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwag_required = false;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
jQuery('.note_ssh_security').closest('.control-group').show();
|
|
|
|
jQuery('#jform_username').closest('.control-group').show();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (jform_vvvvwavwah_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('username',0);
|
|
|
|
jQuery('#jform_username').prop('required','required');
|
|
|
|
jQuery('#jform_username').attr('aria-required',true);
|
|
|
|
jQuery('#jform_username').addClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwah_required = false;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_authentication').closest('.control-group').hide();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (!jform_vvvvwavwad_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('authentication',1);
|
|
|
|
jQuery('#jform_authentication').removeAttr('required');
|
|
|
|
jQuery('#jform_authentication').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_authentication').removeClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwad_required = true;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
jQuery('#jform_host').closest('.control-group').hide();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (!jform_vvvvwavwae_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('host',1);
|
|
|
|
jQuery('#jform_host').removeAttr('required');
|
|
|
|
jQuery('#jform_host').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_host').removeClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwae_required = true;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
jQuery('#jform_port').closest('.control-group').hide();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (!jform_vvvvwavwaf_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('port',1);
|
|
|
|
jQuery('#jform_port').removeAttr('required');
|
|
|
|
jQuery('#jform_port').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_port').removeClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwaf_required = true;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
jQuery('#jform_path').closest('.control-group').hide();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (!jform_vvvvwavwag_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('path',1);
|
|
|
|
jQuery('#jform_path').removeAttr('required');
|
|
|
|
jQuery('#jform_path').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_path').removeClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwag_required = true;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
jQuery('.note_ssh_security').closest('.control-group').hide();
|
|
|
|
jQuery('#jform_username').closest('.control-group').hide();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (!jform_vvvvwavwah_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('username',1);
|
|
|
|
jQuery('#jform_username').removeAttr('required');
|
|
|
|
jQuery('#jform_username').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_username').removeClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwavwah_required = true;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwav Some function
|
|
|
|
function protocol_vvvvwav_SomeFunc(protocol_vvvvwav)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (protocol_vvvvwav == 2)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwaw function
|
|
|
|
function vvvvwaw(protocol_vvvvwaw)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(protocol_vvvvwaw) && protocol_vvvvwaw.constructor !== Array)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwaw = protocol_vvvvwaw;
|
|
|
|
var protocol_vvvvwaw = [];
|
|
|
|
protocol_vvvvwaw.push(temp_vvvvwaw);
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(protocol_vvvvwaw))
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol_vvvvwaw = [];
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol = protocol_vvvvwaw.some(protocol_vvvvwaw_SomeFunc);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
// set this function logic
|
|
|
|
if (protocol)
|
|
|
|
{
|
|
|
|
jQuery('.note_ftp_signature').closest('.control-group').show();
|
|
|
|
jQuery('#jform_signature').closest('.control-group').show();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (jform_vvvvwawwai_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('signature',0);
|
|
|
|
jQuery('#jform_signature').prop('required','required');
|
|
|
|
jQuery('#jform_signature').attr('aria-required',true);
|
|
|
|
jQuery('#jform_signature').addClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwawwai_required = false;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('.note_ftp_signature').closest('.control-group').hide();
|
|
|
|
jQuery('#jform_signature').closest('.control-group').hide();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (!jform_vvvvwawwai_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('signature',1);
|
|
|
|
jQuery('#jform_signature').removeAttr('required');
|
|
|
|
jQuery('#jform_signature').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_signature').removeClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwawwai_required = true;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwaw Some function
|
|
|
|
function protocol_vvvvwaw_SomeFunc(protocol_vvvvwaw)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (protocol_vvvvwaw == 1)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwax function
|
|
|
|
function vvvvwax(protocol_vvvvwax,authentication_vvvvwax)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(protocol_vvvvwax) && protocol_vvvvwax.constructor !== Array)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwax = protocol_vvvvwax;
|
|
|
|
var protocol_vvvvwax = [];
|
|
|
|
protocol_vvvvwax.push(temp_vvvvwax);
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(protocol_vvvvwax))
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol_vvvvwax = [];
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol = protocol_vvvvwax.some(protocol_vvvvwax_SomeFunc);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(authentication_vvvvwax) && authentication_vvvvwax.constructor !== Array)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwax = authentication_vvvvwax;
|
|
|
|
var authentication_vvvvwax = [];
|
|
|
|
authentication_vvvvwax.push(temp_vvvvwax);
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(authentication_vvvvwax))
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var authentication_vvvvwax = [];
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var authentication = authentication_vvvvwax.some(authentication_vvvvwax_SomeFunc);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
// set this function logic
|
|
|
|
if (protocol && authentication)
|
|
|
|
{
|
|
|
|
jQuery('#jform_password').closest('.control-group').show();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (jform_vvvvwaxwaj_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('password',0);
|
|
|
|
jQuery('#jform_password').prop('required','required');
|
|
|
|
jQuery('#jform_password').attr('aria-required',true);
|
|
|
|
jQuery('#jform_password').addClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwaxwaj_required = false;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_password').closest('.control-group').hide();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (!jform_vvvvwaxwaj_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('password',1);
|
|
|
|
jQuery('#jform_password').removeAttr('required');
|
|
|
|
jQuery('#jform_password').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_password').removeClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwaxwaj_required = true;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwax Some function
|
|
|
|
function protocol_vvvvwax_SomeFunc(protocol_vvvvwax)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (protocol_vvvvwax == 2)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwax Some function
|
|
|
|
function authentication_vvvvwax_SomeFunc(authentication_vvvvwax)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (authentication_vvvvwax == 1 || authentication_vvvvwax == 3 || authentication_vvvvwax == 5)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwaz function
|
|
|
|
function vvvvwaz(protocol_vvvvwaz,authentication_vvvvwaz)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(protocol_vvvvwaz) && protocol_vvvvwaz.constructor !== Array)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwaz = protocol_vvvvwaz;
|
|
|
|
var protocol_vvvvwaz = [];
|
|
|
|
protocol_vvvvwaz.push(temp_vvvvwaz);
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(protocol_vvvvwaz))
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol_vvvvwaz = [];
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol = protocol_vvvvwaz.some(protocol_vvvvwaz_SomeFunc);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(authentication_vvvvwaz) && authentication_vvvvwaz.constructor !== Array)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwaz = authentication_vvvvwaz;
|
|
|
|
var authentication_vvvvwaz = [];
|
|
|
|
authentication_vvvvwaz.push(temp_vvvvwaz);
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(authentication_vvvvwaz))
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var authentication_vvvvwaz = [];
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var authentication = authentication_vvvvwaz.some(authentication_vvvvwaz_SomeFunc);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
// set this function logic
|
|
|
|
if (protocol && authentication)
|
|
|
|
{
|
|
|
|
jQuery('#jform_private').closest('.control-group').show();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (jform_vvvvwazwak_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('private',0);
|
|
|
|
jQuery('#jform_private').prop('required','required');
|
|
|
|
jQuery('#jform_private').attr('aria-required',true);
|
|
|
|
jQuery('#jform_private').addClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwazwak_required = false;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_private').closest('.control-group').hide();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (!jform_vvvvwazwak_required)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('private',1);
|
|
|
|
jQuery('#jform_private').removeAttr('required');
|
|
|
|
jQuery('#jform_private').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_private').removeClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwazwak_required = true;
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwaz Some function
|
|
|
|
function protocol_vvvvwaz_SomeFunc(protocol_vvvvwaz)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (protocol_vvvvwaz == 2)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwaz Some function
|
|
|
|
function authentication_vvvvwaz_SomeFunc(authentication_vvvvwaz)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (authentication_vvvvwaz == 2 || authentication_vvvvwaz == 3)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwbb function
|
|
|
|
function vvvvwbb(protocol_vvvvwbb,authentication_vvvvwbb)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(protocol_vvvvwbb) && protocol_vvvvwbb.constructor !== Array)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwbb = protocol_vvvvwbb;
|
|
|
|
var protocol_vvvvwbb = [];
|
|
|
|
protocol_vvvvwbb.push(temp_vvvvwbb);
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(protocol_vvvvwbb))
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol_vvvvwbb = [];
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol = protocol_vvvvwbb.some(protocol_vvvvwbb_SomeFunc);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(authentication_vvvvwbb) && authentication_vvvvwbb.constructor !== Array)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwbb = authentication_vvvvwbb;
|
|
|
|
var authentication_vvvvwbb = [];
|
|
|
|
authentication_vvvvwbb.push(temp_vvvvwbb);
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(authentication_vvvvwbb))
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var authentication_vvvvwbb = [];
|
2018-02-15 00:42:39 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var authentication = authentication_vvvvwbb.some(authentication_vvvvwbb_SomeFunc);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
// set this function logic
|
2018-02-27 12:17:38 +00:00
|
|
|
if (protocol && authentication)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
2018-02-27 12:17:38 +00:00
|
|
|
jQuery('#jform_private_key').closest('.control-group').show();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (jform_vvvvwbbwal_required)
|
2018-03-06 02:28:44 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('private_key',0);
|
|
|
|
jQuery('#jform_private_key').prop('required','required');
|
|
|
|
jQuery('#jform_private_key').attr('aria-required',true);
|
|
|
|
jQuery('#jform_private_key').addClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwbbwal_required = false;
|
2018-03-06 02:28:44 +00:00
|
|
|
}
|
|
|
|
|
2018-02-27 12:17:38 +00:00
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_private_key').closest('.control-group').hide();
|
2018-03-11 22:36:14 +00:00
|
|
|
if (!jform_vvvvwbbwal_required)
|
2018-03-06 02:28:44 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('private_key',1);
|
|
|
|
jQuery('#jform_private_key').removeAttr('required');
|
|
|
|
jQuery('#jform_private_key').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_private_key').removeClass('required');
|
2018-03-11 22:36:14 +00:00
|
|
|
jform_vvvvwbbwal_required = true;
|
2018-03-06 02:28:44 +00:00
|
|
|
}
|
2018-02-27 12:17:38 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwbb Some function
|
|
|
|
function protocol_vvvvwbb_SomeFunc(protocol_vvvvwbb)
|
2018-02-27 12:17:38 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (protocol_vvvvwbb == 2)
|
2018-02-27 12:17:38 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwbb Some function
|
|
|
|
function authentication_vvvvwbb_SomeFunc(authentication_vvvvwbb)
|
2018-02-27 12:17:38 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (authentication_vvvvwbb == 4 || authentication_vvvvwbb == 5)
|
2018-02-27 12:17:38 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwbd function
|
|
|
|
function vvvvwbd(protocol_vvvvwbd,authentication_vvvvwbd)
|
2018-02-27 12:17:38 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(protocol_vvvvwbd) && protocol_vvvvwbd.constructor !== Array)
|
2018-02-27 12:17:38 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwbd = protocol_vvvvwbd;
|
|
|
|
var protocol_vvvvwbd = [];
|
|
|
|
protocol_vvvvwbd.push(temp_vvvvwbd);
|
2018-02-27 12:17:38 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(protocol_vvvvwbd))
|
2018-02-27 12:17:38 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol_vvvvwbd = [];
|
2018-02-27 12:17:38 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var protocol = protocol_vvvvwbd.some(protocol_vvvvwbd_SomeFunc);
|
2018-02-15 00:42:39 +00:00
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
if (isSet(authentication_vvvvwbd) && authentication_vvvvwbd.constructor !== Array)
|
2018-02-27 12:17:38 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var temp_vvvvwbd = authentication_vvvvwbd;
|
|
|
|
var authentication_vvvvwbd = [];
|
|
|
|
authentication_vvvvwbd.push(temp_vvvvwbd);
|
2018-02-27 12:17:38 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
else if (!isSet(authentication_vvvvwbd))
|
2018-02-27 12:17:38 +00:00
|
|
|
{
|
2018-03-09 03:26:44 +00:00
|
|
|
var authentication_vvvvwbd = [];
|
2018-02-27 12:17:38 +00:00
|
|
|
}
|
2018-03-09 03:26:44 +00:00
|
|
|
var authentication = authentication_vvvvwbd.some(authentication_vvvvwbd_SomeFunc);
|
2018-02-27 12:17:38 +00:00
|
|
|
|
|
|
|
|
|
|
|
// set this function logic
|
|
|
|
if (protocol && authentication)
|
|
|
|
{
|
2018-02-15 00:42:39 +00:00
|
|
|
jQuery('#jform_secret').closest('.control-group').show();
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_secret').closest('.control-group').hide();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwbd Some function
|
|
|
|
function protocol_vvvvwbd_SomeFunc(protocol_vvvvwbd)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (protocol_vvvvwbd == 2)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2018-03-09 03:26:44 +00:00
|
|
|
// the vvvvwbd Some function
|
|
|
|
function authentication_vvvvwbd_SomeFunc(authentication_vvvvwbd)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
// set the function logic
|
2018-03-09 03:26:44 +00:00
|
|
|
if (authentication_vvvvwbd == 2 || authentication_vvvvwbd == 3 || authentication_vvvvwbd == 4 || authentication_vvvvwbd == 5)
|
2018-02-15 00:42:39 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
// update required fields
|
|
|
|
function updateFieldRequired(name,status)
|
|
|
|
{
|
|
|
|
var not_required = jQuery('#jform_not_required').val();
|
|
|
|
|
|
|
|
if(status == 1)
|
|
|
|
{
|
|
|
|
if (isSet(not_required) && not_required != 0)
|
|
|
|
{
|
|
|
|
not_required = not_required+','+name;
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
not_required = ','+name;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
if (isSet(not_required) && not_required != 0)
|
|
|
|
{
|
|
|
|
not_required = not_required.replace(','+name,'');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
jQuery('#jform_not_required').val(not_required);
|
|
|
|
}
|
|
|
|
|
|
|
|
// the isSet function
|
|
|
|
function isSet(val)
|
|
|
|
{
|
|
|
|
if ((val != undefined) && (val != null) && 0 !== val.length){
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|