Viewing Attachments

The View Attachment icon is hidden by default on the Dispatch List, Search Job, and Search Serial Number pages. This program provides the ability to view attachments and also restrict the ability to view for user specific conditions. Attachments are added at the operations level on the discrete job.

Configure your view on these pages in the Personalization Structure page to view attachments on these pages. See: Configuring Document Attachments

Procedure: get_attachment_exists

function get_attachment_exists(p_wip_entity_id IN NUMBER,
p_organization_id IN NUMBER,
p_operation_seq_num IN NUMBER,
p_department_id IN NUMBER) return NUMBER
is
l_dummy number;
begin
l_dummy := 0;

/* ---Enter information in the following code lines.

You can customize the program per your business requirements at various levels and the type of attachments according to the setting in the Attachment Sources parameter. If the return values is:

*/
begin
select 1 into l_dummy from fnd_attached_documents
where entity_name='WIP_DISCRETE_OPERATIONS'
and pk1_value=p_wip_entity_id
Custom Hooks Page 5 of 16
and pk2_value=p_operation_seq_num
and pk3_value=p_organization_id;
exception
when no_data_found then
l_dummy := 0;
end;
return l_dummy;
end get_attachment_exists;