git-svn-id: http://locode01.ad.dom/svn/WEBMIP/trunk@50874 248e525c-4dfb-0310-94bc-949c084e9493
This commit is contained in:
233
Data/BulkLoad/EFT/Nominations/plsql/amfrw010$js$erlo.bdy
Normal file
233
Data/BulkLoad/EFT/Nominations/plsql/amfrw010$js$erlo.bdy
Normal file
@@ -0,0 +1,233 @@
|
||||
create or replace package body amfrw010$js$erlo is
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
-- Name: amfrw010$js$erlo.CreateViewJavaScript
|
||||
--
|
||||
-- Description:
|
||||
--
|
||||
-- Parameters:
|
||||
--
|
||||
--------------------------------------------------------------------------------
|
||||
procedure CreateViewJavaScript(
|
||||
VF_ROWS_UPDATED in integer,
|
||||
VF_ROWS_DELETED in integer,
|
||||
VF_ROWS_ERROR in integer,
|
||||
VF_BODY_ATTRIBUTES in varchar2,
|
||||
RL_REQUERY_BUT_ACTION in varchar2,
|
||||
LOV_FRAME in varchar2) is
|
||||
begin
|
||||
if not caco_security.security_check('amfrw010$erlo') then
|
||||
return;
|
||||
end if;
|
||||
|
||||
htp.p(WSGJSL.OpenScript);
|
||||
htp.p('var index = 0;');
|
||||
htp.p( 'var DataChangeErrors = false;' );
|
||||
htp.p( 'var DataChange = false;' );
|
||||
|
||||
|
||||
htp.p( 'var P_7 = new Array();' );
|
||||
htp.p( 'P_7[0] = "' || WSGL.EscapeURLParam(to_char(amfrw010$erlo.CURR_VAL.ERLO_ID)) || '";' );
|
||||
|
||||
htp.p(WSGJSL.RtnNotNull);
|
||||
htp.p(WSGJSL.RtnChkMaxLength);
|
||||
htp.p(WSGJSL.RtnCheckModified);
|
||||
htp.p(WSGJSL.RtnRevertForm);
|
||||
|
||||
WSGJSL.Output_Invoke_CAL_JS ('amfrw010$erlo', 'scrollbars=no,resizable=no,width=320,height=350');
|
||||
|
||||
|
||||
htp.p(WSGJSL.OpenEvent('ERLO','Validate'));htp.p('var index = 0;');
|
||||
|
||||
htp.p(WSGJSL.CallNotNull('ctl.form.P_SOURCE[index]', WSGL.MsgGetText(219, WSGLM.MSG219_MISSING_MANDATORY, '#Source#2167#:')));
|
||||
|
||||
htp.p(WSGJSL.CallNotNull('ctl.form.P_ERROR_CODE[index]', WSGL.MsgGetText(219, WSGLM.MSG219_MISSING_MANDATORY, '#Error Code#3525#:')));
|
||||
|
||||
htp.p(WSGJSL.CallNotNull('ctl.form.P_ERROR_MESSAGE[index]', WSGL.MsgGetText(219, WSGLM.MSG219_MISSING_MANDATORY, '#Error Message#3526#:')));
|
||||
htp.p(WSGJSL.CallChkMaxLength('ctl.form.P_ERROR_MESSAGE[index]', 2000, WSGL.MsgGetText(230, WSGLM.MSG230_MAXLEN_ERROR, '#Error Message#3526#:', '2000')
|
||||
));
|
||||
|
||||
htp.p(WSGJSL.CloseEvent);
|
||||
htp.p(WSGJSL.OpenEvent('ERLO','OnLoad'));
|
||||
htp.p('
|
||||
if ( FormType != "PostDelete")
|
||||
{
|
||||
form_num=0;
|
||||
do
|
||||
{
|
||||
elem_num=0;
|
||||
len = document.forms[form_num].elements.length;
|
||||
if (len > 0)
|
||||
{
|
||||
while (elem_num < len &&
|
||||
document.forms[form_num].elements[elem_num].type != "text" &&
|
||||
document.forms[form_num].elements[elem_num].type != "textarea")
|
||||
{
|
||||
elem_num++;
|
||||
}
|
||||
if (elem_num < len)
|
||||
{
|
||||
document.forms[form_num].elements[elem_num].focus();
|
||||
break;
|
||||
}
|
||||
}
|
||||
form_num++;
|
||||
} while ( form_num < document.forms.length );
|
||||
}
|
||||
');
|
||||
htp.p(WSGJSL.CloseEvent);
|
||||
htp.p(WSGJSL.OpenEvent('btnVFU','OnClick'));
|
||||
htp.p(' if (!ERLO_Validate(ctl)) { return false; }');
|
||||
htp.p(WSGJSL.StandardSubmit(false));
|
||||
|
||||
htp.p(WSGJSL.CloseEvent);
|
||||
htp.p(WSGJSL.OpenEvent('btnVFD','OnClick'));
|
||||
htp.p(WSGJSL.VerifyDelete(WSGL.MsgGetText(118, WSGLM.DSP118_CONFIRM_DELETE)));
|
||||
htp.p(WSGJSL.CloseEvent);
|
||||
htp.p(WSGJSL.OpenEvent('btnVFR','OnClick'));
|
||||
htp.p(WSGJSL.StandardSubmit(false));
|
||||
|
||||
htp.p(WSGJSL.CloseEvent);
|
||||
htp.p(WSGJSL.CloseScript);
|
||||
exception
|
||||
when others then
|
||||
WSGL.DisplayMessage(WSGL.MESS_EXCEPTION, SQLERRM, ''||' : '||'#View error logs#2163#',
|
||||
VF_BODY_ATTRIBUTES, 'amfrw010$js$erlo.CreateViewJavaScript');
|
||||
end;
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
-- Name: amfrw010$js$erlo.CreateQueryJavaScript
|
||||
--
|
||||
-- Description:
|
||||
--
|
||||
-- Parameters:
|
||||
--
|
||||
--------------------------------------------------------------------------------
|
||||
procedure CreateQueryJavaScript (
|
||||
LOV_FRAME in varchar2,
|
||||
QF_BODY_ATTRIBUTES in varchar2)
|
||||
is
|
||||
begin
|
||||
if not caco_security.security_check('amfrw010$erlo') then
|
||||
return;
|
||||
end if;
|
||||
|
||||
htp.p(WSGJSL.OpenScript);
|
||||
htp.p('var FormType = "Query";');
|
||||
|
||||
|
||||
|
||||
WSGJSL.Output_Invoke_CAL_JS ('amfrw010$erlo', 'scrollbars=no,resizable=no,width=320,height=350');
|
||||
|
||||
|
||||
|
||||
htp.p(
|
||||
'// CAL
|
||||
//
|
||||
//
|
||||
|
||||
function CAL(the_fieldname, the_value, the_format, the_prompt) {
|
||||
var filter = "";
|
||||
var the_pathname = location.pathname;
|
||||
var i = the_pathname.indexOf (''/:'');
|
||||
var j = the_pathname.indexOf (''/'', ++i);
|
||||
//var frmCAL; //B1777722 Needs to be global to remember state between calls.
|
||||
|
||||
if (i != -1)
|
||||
{
|
||||
|
||||
// Syntactically incorrect url so it needs to be corrected
|
||||
|
||||
the_pathname = the_pathname.substring (j, the_pathname.length);
|
||||
|
||||
}; // (i != -1)
|
||||
|
||||
// B1777722 and B1854252 for IE5
|
||||
if ( navigator.appName == "Microsoft Internet Explorer" && typeof frmCAL == "object" )
|
||||
{
|
||||
frmCAL.close();
|
||||
}
|
||||
|
||||
frmCAL = open ("amfrw010$erlo.ncalendar" +
|
||||
"?Z_FIELD_NAME=" + escape(the_fieldname) +
|
||||
"&Z_CALLER_URL=" + escape(location.protocol + ''//'' + location.host + the_pathname + location.search) +
|
||||
"&Z_FIELD_VALUE=" + escape(the_value) +
|
||||
"&Z_FIELD_FORMAT=" + escape(the_format) +
|
||||
"&Z_FIELD_PROMPT=" + escape(the_prompt),
|
||||
"winCAL", "scrollbars=no,resizable=no,width=320,height=350");
|
||||
|
||||
if (frmCAL.opener == null)
|
||||
{
|
||||
frmCAL.opener = self;
|
||||
}
|
||||
} ');
|
||||
htp.p(WSGJSL.OpenEvent('ERLO','OnLoad'));
|
||||
htp.p('
|
||||
if ( FormType != "PostDelete")
|
||||
{
|
||||
form_num=0;
|
||||
do
|
||||
{
|
||||
elem_num=0;
|
||||
len = document.forms[form_num].elements.length;
|
||||
if (len > 0)
|
||||
{
|
||||
while (elem_num < len &&
|
||||
document.forms[form_num].elements[elem_num].type != "text" &&
|
||||
document.forms[form_num].elements[elem_num].type != "textarea")
|
||||
{
|
||||
elem_num++;
|
||||
}
|
||||
if (elem_num < len)
|
||||
{
|
||||
document.forms[form_num].elements[elem_num].focus();
|
||||
break;
|
||||
}
|
||||
}
|
||||
form_num++;
|
||||
} while ( form_num < document.forms.length );
|
||||
}
|
||||
');
|
||||
htp.p(WSGJSL.CloseEvent);
|
||||
htp.p(WSGJSL.OpenEvent('btnQFQ','OnClick'));
|
||||
htp.p(WSGJSL.StandardSubmit(false));
|
||||
|
||||
htp.p(WSGJSL.CloseEvent);
|
||||
htp.p(WSGJSL.CloseScript);
|
||||
exception
|
||||
when others then
|
||||
WSGL.DisplayMessage(WSGL.MESS_EXCEPTION, SQLERRM, ''||' : '||'#View error logs#2163#',
|
||||
QF_BODY_ATTRIBUTES, 'amfrw010$js$erlo.CreateQueryJavaScript');
|
||||
end;
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
-- Name: amfrw010$js$erlo.CreateListJavaScript
|
||||
--
|
||||
-- Description:
|
||||
--
|
||||
-- Parameters:
|
||||
--
|
||||
--------------------------------------------------------------------------------
|
||||
procedure CreateListJavaScript (
|
||||
RL_BODY_ATTRIBUTES in varchar2)
|
||||
is
|
||||
begin
|
||||
if not caco_security.security_check('amfrw010$erlo') then
|
||||
return;
|
||||
end if;
|
||||
|
||||
htp.p(WSGJSL.OpenScript);
|
||||
htp.p('var FormType = "List";');
|
||||
|
||||
|
||||
htp.p( 'var P_7 = new Array();' );
|
||||
|
||||
htp.p(WSGJSL.CloseScript);
|
||||
exception
|
||||
when others then
|
||||
WSGL.DisplayMessage(WSGL.MESS_EXCEPTION, SQLERRM, ''||' : '||'#View error logs#2163#',
|
||||
RL_BODY_ATTRIBUTES, 'amfrw010$js$erlo.CreateListJavaScript');
|
||||
end;
|
||||
end;
|
||||
/
|
||||
Reference in New Issue
Block a user