ITPub博客

首页 > 数据库 > Oracle > 客製custom.pll實例

客製custom.pll實例

原创 Oracle 作者:longwansheng 时间:2006-10-19 16:34:22 0 删除 编辑

oracle erp 11.5.10

限定org_id為14與57的,在shiping transaction的delivery頁簽下的waybill與ship method為必須,且只在輸入後才可以撿料與ship confirm.

[@more@]

方法為改..au/11.5.0/resource/下的custom.pll

PROCEDURE EVENT(EVENT_NAME VARCHAR2) is

...

begin

...

/*
Subject: Making Waybill and Ship Method fields of the Shipping
Transactions form required fields for GUAC(14) and GUCA(57) only
Author: Henry Tuan
Date: August 21, 2006
modify by: longson.long at 2006.09
*/

if FND_PROFILE.VALUE('ORG_ID') IN (14,57) and form_name='WSHFSTRX' AND block_name='DLVY'
and GET_ITEM_PROPERTY('DLVY.NAME',DATABASE_VALUE) IS NOT NULL then

if GET_ITEM_PROPERTY('DLVY.WAYBILL',Visible)='TRUE' then
set_item_property('DLVY.WAYBILL',REQUIRED,PROPERTY_TRUE);
end if;

if GET_ITEM_PROPERTY('DLVY.SHIP_METHOD_NAME',Visible)='TRUE' then
set_item_property('DLVY.SHIP_METHOD_NAME',REQUIRED,PROPERTY_TRUE);
end if;

if get_item_property('DLVY.WAYBILL',DATABASE_VALUE) IS not NULL
and get_item_property('DLVY.SHIP_METHOD_NAME',DATABASE_VALUE) IS not NULL THEN
set_item_property('DLVY_BUTTONS.GO',ENABLED,PROPERTY_TRUE);
set_item_property('DLVY_BUTTONS.GO_MIR',ENABLED,PROPERTY_TRUE);
set_item_property('DLVY_BUTTONS.ACTIONS',ENABLED,PROPERTY_TRUE);
set_item_property('DLVY_BUTTONS.ACTIONS_MIR',ENABLED,PROPERTY_TRUE);
IF GET_item_property('DLVY_BUTTONS.BUTTON1',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON1',ENABLED,PROPERTY_TRUE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON2',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON2',ENABLED,PROPERTY_TRUE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON4',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON4',ENABLED,PROPERTY_TRUE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON5',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON5',ENABLED,PROPERTY_TRUE);
END IF;
else
set_item_property('DLVY_BUTTONS.GO',ENABLED,PROPERTY_FALSE);
set_item_property('DLVY_BUTTONS.GO_MIR',ENABLED,PROPERTY_FALSE);
set_item_property('DLVY_BUTTONS.ACTIONS',ENABLED,PROPERTY_FALSE);
set_item_property('DLVY_BUTTONS.ACTIONS_MIR',ENABLED,PROPERTY_FALSE);
set_item_property('DLVY_BUTTONS.DETAIL_DONE',ENABLED,PROPERTY_FALSE);
IF GET_item_property('DLVY_BUTTONS.BUTTON1',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON1',ENABLED,PROPERTY_FALSE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON2',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON2',ENABLED,PROPERTY_FALSE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON4',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON4',ENABLED,PROPERTY_FALSE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON5',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON5',ENABLED,PROPERTY_FALSE);
END IF;
END IF;

END IF;

if FND_PROFILE.VALUE('ORG_ID') IN (14,57) and form_name='WSHFSTRX' AND block_name='DLVY_S'
and GET_ITEM_PROPERTY('DLVY_S.NAME',DATABASE_VALUE) IS NOT NULL
then
if GET_ITEM_PROPERTY('DLVY_S.WAYBILL',Visible)='TRUE' then
set_item_property('DLVY_S.WAYBILL',REQUIRED,PROPERTY_TRUE);
end if;

if GET_ITEM_PROPERTY('DLVY_S.SHIP_METHOD_NAME',Visible)='TRUE' then
set_item_property('DLVY_S.SHIP_METHOD_NAME',REQUIRED,PROPERTY_TRUE);
end if;
if get_item_property('DLVY_S.WAYBILL',DATABASE_VALUE) IS not NULL
and get_item_property('DLVY_S.SHIP_METHOD_NAME',DATABASE_VALUE) IS not NULL THEN
set_item_property('DLVY_BUTTONS.GO',ENABLED,PROPERTY_TRUE);
set_item_property('DLVY_BUTTONS.GO_MIR',ENABLED,PROPERTY_TRUE);
set_item_property('DLVY_BUTTONS.ACTIONS',ENABLED,PROPERTY_TRUE);
set_item_property('DLVY_BUTTONS.ACTIONS_MIR',ENABLED,PROPERTY_TRUE);
set_item_property('DLVY_BUTTONS.DETAIL_DONE',ENABLED,PROPERTY_TRUE);
IF GET_item_property('DLVY_BUTTONS.BUTTON1',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON1',ENABLED,PROPERTY_TRUE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON2',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON2',ENABLED,PROPERTY_TRUE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON4',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON4',ENABLED,PROPERTY_TRUE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON5',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON5',ENABLED,PROPERTY_TRUE);
END IF;
else
set_item_property('DLVY_BUTTONS.GO',ENABLED,PROPERTY_FALSE);
set_item_property('DLVY_BUTTONS.GO_MIR',ENABLED,PROPERTY_FALSE);
set_item_property('DLVY_BUTTONS.ACTIONS',ENABLED,PROPERTY_FALSE);
set_item_property('DLVY_BUTTONS.ACTIONS_MIR',ENABLED,PROPERTY_FALSE);
set_item_property('DLVY_BUTTONS.DETAIL_DONE',ENABLED,PROPERTY_FALSE);
IF GET_item_property('DLVY_BUTTONS.BUTTON1',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON1',ENABLED,PROPERTY_FALSE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON2',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON2',ENABLED,PROPERTY_FALSE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON4',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON4',ENABLED,PROPERTY_FALSE);
END IF;
IF GET_item_property('DLVY_BUTTONS.BUTTON5',VISIBLE)='TRUE' THEN
set_item_property('DLVY_BUTTONS.BUTTON5',ENABLED,PROPERTY_FALSE);
END IF;
END IF;

END IF;
--END longson.long 2006.09

...

end;

ssh編譯命令:

..au/11.5.0/resource/

f60gen module=CUSTOM.pll userid=apps/apps module_type=LIBRARY

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/92289/viewspace-872660/,如需转载,请注明出处,否则将追究法律责任。

下一篇: ORACLE基本知識
请登录后发表评论 登录
全部评论

注册时间:2007-12-12

  • 博文量
    162
  • 访问量
    740638