Monday, 23 January 2017

Add Attachment field in OAF

Steps to add Attachment field in OAF.
-------------------------------------------
1. For creating Attachment , first we need to create Entity in Application.
Steps to Create Entity:
-----------------------
1.Login into Application --> Ak HTML Forms Resp--> AK Entities
Click on Create Button .
Enter Mandatory fields such as Table Name,Application Id, Entity Id and First PK Attribute Name.
First PK Attribute Name should be primary key of the Table.
2. Once we attach any item ,this Entity name and Primary key values will get stored in 'entity_name' and 'pk1_value' columns of 'FND_ATTACHED_DOCUMENTS' table along with the attachment .
-----------------
2. Create an item of type Attachment Link to any region in OAF Page. Give View Object in View Instance property of BC4J. This table in View object should be same as the table name given while creating entity.
3. If we want to store attachment after adding, update 'Automatic Save' Property as 'True' in the property Inspector. Otherwise if we do commit , attached document will get stored in FND_ATTACHED_DOCUMENTS table.
4.Once we create Attachment Link Item entity Map will be created along with Primary keys and CategoryMap.
5. In Primary key Item , Update view attribute property with Primary key.
6. In Category Map Item , update Category property with MISC (Miscellaneous).






2 comments:

  1. Hi,

    Is there any option to make attachment link mandatory?

    ReplyDelete
  2. Dears,

    I have advance table and inside it i have added Attachmentlink for each line and set the property Autosave to true but after adding attachments against each line i am nof able to find record in fnd attached documents transaction is still not commited as auto save property is on so why it is not storing data in base table?
    Autosave property true should commit automatically? Its not happening please suggest am i missing something.

    ReplyDelete