2015-11-30 21:30:54 +00:00
|
|
|
/*----------------------------------------------------------------------------------| www.vdm.io |----/
|
|
|
|
Vast Development Method
|
|
|
|
/-------------------------------------------------------------------------------------------------------/
|
|
|
|
|
|
|
|
@version 1.2.9
|
2015-12-01 00:19:11 +00:00
|
|
|
@build 1st December, 2015
|
2015-11-30 21:30:54 +00:00
|
|
|
@created 22nd October, 2015
|
|
|
|
@package Sermon Distributor
|
|
|
|
@subpackage sermon.js
|
|
|
|
@author Llewellyn van der Merwe <https://www.vdm.io/>
|
|
|
|
@copyright Copyright (C) 2015. All Rights Reserved
|
|
|
|
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
|
|
|
|
____ _____ _____ __ __ __ __ ___ _____ __ __ ____ _____ _ _ ____ _ _ ____
|
|
|
|
(_ _)( _ )( _ )( \/ )( ) /__\ / __)( _ )( \/ )( _ \( _ )( \( )( ___)( \( )(_ _)
|
|
|
|
.-_)( )(_)( )(_)( ) ( )(__ /(__)\ ( (__ )(_)( ) ( )___/ )(_)( ) ( )__) ) ( )(
|
|
|
|
\____) (_____)(_____)(_/\/\_)(____)(__)(__) \___)(_____)(_/\/\_)(__) (_____)(_)\_)(____)(_)\_) (__)
|
|
|
|
|
|
|
|
/------------------------------------------------------------------------------------------------------*/
|
|
|
|
|
|
|
|
// Some Global Values
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_NKOinBhjcR_required = false;
|
|
|
|
jform_tcPmpLTZoG_required = false;
|
|
|
|
jform_gxilNjehSq_required = false;
|
|
|
|
jform_oQgboDxRIY_required = false;
|
|
|
|
jform_YcaNoltkqP_required = false;
|
2015-11-30 21:30:54 +00:00
|
|
|
|
|
|
|
// Initial Script
|
|
|
|
jQuery(document).ready(function()
|
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_NKOinBh = jQuery("#jform_source").val();
|
|
|
|
NKOinBh(source_NKOinBh);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_ALgjVVL = jQuery("#jform_source").val();
|
|
|
|
var build_ALgjVVL = jQuery("#jform_build input[type='radio']:checked").val();
|
|
|
|
ALgjVVL(source_ALgjVVL,build_ALgjVVL);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_tcPmpLT = jQuery("#jform_source").val();
|
|
|
|
var build_tcPmpLT = jQuery("#jform_build input[type='radio']:checked").val();
|
|
|
|
tcPmpLT(source_tcPmpLT,build_tcPmpLT);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
var build_gxilNje = jQuery("#jform_build input[type='radio']:checked").val();
|
|
|
|
var source_gxilNje = jQuery("#jform_source").val();
|
|
|
|
gxilNje(build_gxilNje,source_gxilNje);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_oQgboDx = jQuery("#jform_source").val();
|
|
|
|
oQgboDx(source_oQgboDx);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_YcaNolt = jQuery("#jform_source").val();
|
|
|
|
YcaNolt(source_YcaNolt);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
var link_type_VrtcKcp = jQuery("#jform_link_type input[type='radio']:checked").val();
|
|
|
|
VrtcKcp(link_type_VrtcKcp);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
var link_type_KohbyVh = jQuery("#jform_link_type input[type='radio']:checked").val();
|
|
|
|
KohbyVh(link_type_KohbyVh);
|
2015-11-30 21:30:54 +00:00
|
|
|
});
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the NKOinBh function
|
|
|
|
function NKOinBh(source_NKOinBh)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
if (isSet(source_NKOinBh) && source_NKOinBh.constructor !== Array)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var temp_NKOinBh = source_NKOinBh;
|
|
|
|
var source_NKOinBh = [];
|
|
|
|
source_NKOinBh.push(temp_NKOinBh);
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
else if (!isSet(source_NKOinBh))
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_NKOinBh = [];
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
var source = source_NKOinBh.some(source_NKOinBh_SomeFunc);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7986] set this function logic
|
2015-11-30 21:30:54 +00:00
|
|
|
if (source)
|
|
|
|
{
|
|
|
|
jQuery('#jform_build').closest('.control-group').show();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (jform_NKOinBhjcR_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('build',0);
|
|
|
|
jQuery('#jform_build').prop('required','required');
|
|
|
|
jQuery('#jform_build').attr('aria-required',true);
|
|
|
|
jQuery('#jform_build').addClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_NKOinBhjcR_required = false;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_build').closest('.control-group').hide();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (!jform_NKOinBhjcR_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('build',1);
|
|
|
|
jQuery('#jform_build').removeAttr('required');
|
|
|
|
jQuery('#jform_build').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_build').removeClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_NKOinBhjcR_required = true;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the NKOinBh Some function
|
|
|
|
function source_NKOinBh_SomeFunc(source_NKOinBh)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7973] set the function logic
|
|
|
|
if (source_NKOinBh == 2)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the ALgjVVL function
|
|
|
|
function ALgjVVL(source_ALgjVVL,build_ALgjVVL)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
if (isSet(source_ALgjVVL) && source_ALgjVVL.constructor !== Array)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var temp_ALgjVVL = source_ALgjVVL;
|
|
|
|
var source_ALgjVVL = [];
|
|
|
|
source_ALgjVVL.push(temp_ALgjVVL);
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
else if (!isSet(source_ALgjVVL))
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_ALgjVVL = [];
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
var source = source_ALgjVVL.some(source_ALgjVVL_SomeFunc);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
if (isSet(build_ALgjVVL) && build_ALgjVVL.constructor !== Array)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var temp_ALgjVVL = build_ALgjVVL;
|
|
|
|
var build_ALgjVVL = [];
|
|
|
|
build_ALgjVVL.push(temp_ALgjVVL);
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
else if (!isSet(build_ALgjVVL))
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var build_ALgjVVL = [];
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
var build = build_ALgjVVL.some(build_ALgjVVL_SomeFunc);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7986] set this function logic
|
2015-11-30 21:30:54 +00:00
|
|
|
if (source && build)
|
|
|
|
{
|
|
|
|
jQuery('.note_auto_dropbox').closest('.control-group').show();
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('.note_auto_dropbox').closest('.control-group').hide();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the ALgjVVL Some function
|
|
|
|
function source_ALgjVVL_SomeFunc(source_ALgjVVL)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7973] set the function logic
|
|
|
|
if (source_ALgjVVL == 2)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the ALgjVVL Some function
|
|
|
|
function build_ALgjVVL_SomeFunc(build_ALgjVVL)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7973] set the function logic
|
|
|
|
if (build_ALgjVVL == 2)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the tcPmpLT function
|
|
|
|
function tcPmpLT(source_tcPmpLT,build_tcPmpLT)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
if (isSet(source_tcPmpLT) && source_tcPmpLT.constructor !== Array)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var temp_tcPmpLT = source_tcPmpLT;
|
|
|
|
var source_tcPmpLT = [];
|
|
|
|
source_tcPmpLT.push(temp_tcPmpLT);
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
else if (!isSet(source_tcPmpLT))
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_tcPmpLT = [];
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
var source = source_tcPmpLT.some(source_tcPmpLT_SomeFunc);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
if (isSet(build_tcPmpLT) && build_tcPmpLT.constructor !== Array)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var temp_tcPmpLT = build_tcPmpLT;
|
|
|
|
var build_tcPmpLT = [];
|
|
|
|
build_tcPmpLT.push(temp_tcPmpLT);
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
else if (!isSet(build_tcPmpLT))
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var build_tcPmpLT = [];
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
var build = build_tcPmpLT.some(build_tcPmpLT_SomeFunc);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7986] set this function logic
|
2015-11-30 21:30:54 +00:00
|
|
|
if (source && build)
|
|
|
|
{
|
|
|
|
jQuery('#jform_manual_files').closest('.control-group').show();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (jform_tcPmpLTZoG_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('manual_files',0);
|
|
|
|
jQuery('#jform_manual_files').prop('required','required');
|
|
|
|
jQuery('#jform_manual_files').attr('aria-required',true);
|
|
|
|
jQuery('#jform_manual_files').addClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_tcPmpLTZoG_required = false;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
jQuery('.note_manual_dropbox').closest('.control-group').show();
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_manual_files').closest('.control-group').hide();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (!jform_tcPmpLTZoG_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('manual_files',1);
|
|
|
|
jQuery('#jform_manual_files').removeAttr('required');
|
|
|
|
jQuery('#jform_manual_files').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_manual_files').removeClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_tcPmpLTZoG_required = true;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
jQuery('.note_manual_dropbox').closest('.control-group').hide();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the tcPmpLT Some function
|
|
|
|
function source_tcPmpLT_SomeFunc(source_tcPmpLT)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7973] set the function logic
|
|
|
|
if (source_tcPmpLT == 2)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the tcPmpLT Some function
|
|
|
|
function build_tcPmpLT_SomeFunc(build_tcPmpLT)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7973] set the function logic
|
|
|
|
if (build_tcPmpLT == 1)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the gxilNje function
|
|
|
|
function gxilNje(build_gxilNje,source_gxilNje)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
if (isSet(build_gxilNje) && build_gxilNje.constructor !== Array)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var temp_gxilNje = build_gxilNje;
|
|
|
|
var build_gxilNje = [];
|
|
|
|
build_gxilNje.push(temp_gxilNje);
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
else if (!isSet(build_gxilNje))
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var build_gxilNje = [];
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
var build = build_gxilNje.some(build_gxilNje_SomeFunc);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
if (isSet(source_gxilNje) && source_gxilNje.constructor !== Array)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var temp_gxilNje = source_gxilNje;
|
|
|
|
var source_gxilNje = [];
|
|
|
|
source_gxilNje.push(temp_gxilNje);
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
else if (!isSet(source_gxilNje))
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_gxilNje = [];
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
var source = source_gxilNje.some(source_gxilNje_SomeFunc);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7986] set this function logic
|
2015-11-30 21:30:54 +00:00
|
|
|
if (build && source)
|
|
|
|
{
|
|
|
|
jQuery('#jform_manual_files').closest('.control-group').show();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (jform_gxilNjehSq_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('manual_files',0);
|
|
|
|
jQuery('#jform_manual_files').prop('required','required');
|
|
|
|
jQuery('#jform_manual_files').attr('aria-required',true);
|
|
|
|
jQuery('#jform_manual_files').addClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_gxilNjehSq_required = false;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
jQuery('.note_manual_dropbox').closest('.control-group').show();
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_manual_files').closest('.control-group').hide();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (!jform_gxilNjehSq_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('manual_files',1);
|
|
|
|
jQuery('#jform_manual_files').removeAttr('required');
|
|
|
|
jQuery('#jform_manual_files').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_manual_files').removeClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_gxilNjehSq_required = true;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
jQuery('.note_manual_dropbox').closest('.control-group').hide();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the gxilNje Some function
|
|
|
|
function build_gxilNje_SomeFunc(build_gxilNje)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7973] set the function logic
|
|
|
|
if (build_gxilNje == 1)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the gxilNje Some function
|
|
|
|
function source_gxilNje_SomeFunc(source_gxilNje)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7973] set the function logic
|
|
|
|
if (source_gxilNje == 2)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the oQgboDx function
|
|
|
|
function oQgboDx(source_oQgboDx)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
if (isSet(source_oQgboDx) && source_oQgboDx.constructor !== Array)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var temp_oQgboDx = source_oQgboDx;
|
|
|
|
var source_oQgboDx = [];
|
|
|
|
source_oQgboDx.push(temp_oQgboDx);
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
else if (!isSet(source_oQgboDx))
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_oQgboDx = [];
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
var source = source_oQgboDx.some(source_oQgboDx_SomeFunc);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7986] set this function logic
|
2015-11-30 21:30:54 +00:00
|
|
|
if (source)
|
|
|
|
{
|
|
|
|
jQuery('#jform_local_files').closest('.control-group').show();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (jform_oQgboDxRIY_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('local_files',0);
|
|
|
|
jQuery('#jform_local_files').prop('required','required');
|
|
|
|
jQuery('#jform_local_files').attr('aria-required',true);
|
|
|
|
jQuery('#jform_local_files').addClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_oQgboDxRIY_required = false;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_local_files').closest('.control-group').hide();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (!jform_oQgboDxRIY_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('local_files',1);
|
|
|
|
jQuery('#jform_local_files').removeAttr('required');
|
|
|
|
jQuery('#jform_local_files').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_local_files').removeClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_oQgboDxRIY_required = true;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the oQgboDx Some function
|
|
|
|
function source_oQgboDx_SomeFunc(source_oQgboDx)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7973] set the function logic
|
|
|
|
if (source_oQgboDx == 1)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the YcaNolt function
|
|
|
|
function YcaNolt(source_YcaNolt)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
if (isSet(source_YcaNolt) && source_YcaNolt.constructor !== Array)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var temp_YcaNolt = source_YcaNolt;
|
|
|
|
var source_YcaNolt = [];
|
|
|
|
source_YcaNolt.push(temp_YcaNolt);
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
else if (!isSet(source_YcaNolt))
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
var source_YcaNolt = [];
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
2015-12-01 00:51:07 +00:00
|
|
|
var source = source_YcaNolt.some(source_YcaNolt_SomeFunc);
|
2015-11-30 21:30:54 +00:00
|
|
|
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7986] set this function logic
|
2015-11-30 21:30:54 +00:00
|
|
|
if (source)
|
|
|
|
{
|
|
|
|
jQuery('#jform_url').closest('.control-group').show();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (jform_YcaNoltkqP_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('url',0);
|
|
|
|
jQuery('#jform_url').prop('required','required');
|
|
|
|
jQuery('#jform_url').attr('aria-required',true);
|
|
|
|
jQuery('#jform_url').addClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_YcaNoltkqP_required = false;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('#jform_url').closest('.control-group').hide();
|
2015-12-01 00:51:07 +00:00
|
|
|
if (!jform_YcaNoltkqP_required)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
updateFieldRequired('url',1);
|
|
|
|
jQuery('#jform_url').removeAttr('required');
|
|
|
|
jQuery('#jform_url').removeAttr('aria-required');
|
|
|
|
jQuery('#jform_url').removeClass('required');
|
2015-12-01 00:51:07 +00:00
|
|
|
jform_YcaNoltkqP_required = true;
|
2015-11-30 21:30:54 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the YcaNolt Some function
|
|
|
|
function source_YcaNolt_SomeFunc(source_YcaNolt)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [7973] set the function logic
|
|
|
|
if (source_YcaNolt == 3)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the VrtcKcp function
|
|
|
|
function VrtcKcp(link_type_VrtcKcp)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [8008] set the function logic
|
|
|
|
if (link_type_VrtcKcp == 2)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
jQuery('.note_link_directed').closest('.control-group').show();
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('.note_link_directed').closest('.control-group').hide();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-12-01 00:51:07 +00:00
|
|
|
// the KohbyVh function
|
|
|
|
function KohbyVh(link_type_KohbyVh)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
2015-12-01 00:51:07 +00:00
|
|
|
// [8008] set the function logic
|
|
|
|
if (link_type_KohbyVh == 1)
|
2015-11-30 21:30:54 +00:00
|
|
|
{
|
|
|
|
jQuery('.note_link_encrypted').closest('.control-group').show();
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
jQuery('.note_link_encrypted').closest('.control-group').hide();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// 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;
|
|
|
|
}
|