"Custom Objects" is created as standard framework functionality that works on a large majority of the pages in IFS Applications. Sometimes, framework functionality needs to be overridden to achieve desired functionality. In order to provide the flexibility to do this, there are some APIs which can be used to support Custom Objects functionality in such situations.
Application forms that have custom fields configured on it, will in runtime use the custom fields view and not the view defined in design time.
The property
ResolvedView
on application form base classes can be used to access the view that an
application form uses in runtime. This property is useful when an application
forms page overrides populate and/or search functionality in the framework. The
base classes cFormWindow
, cTableWindow
and
cChildTable
expose the property. When an application form does not use any
custom fields the view name defined in design time is returned. To
use the property when developing application forms simply write
this.View
.
When managing many of IFS Applications business objects (like Customer Order, Product Structure and so on) you commonly want to copy one business object when you create another new business object.
This is usually done from the context menu
"Copy [business object]", but specific
application functionality is also quite common. This
functionality is done in the server and usually copies the full
structure of a business object (e.g. Customer Order Header, lines and
deliveries). This is business logic that is
written by IFS. A server copy does not copy Custom Fields unless the
server logic makes a call to the Custom Fields copy API Custom_Objects_SYS.Copy_Cf_Instance
.
To copy between different LU's, the method
Custom_Objects_SYS.Copy_Between_Lu_Cf_Instance
should be used instead. This API is dependent on
the names of the custom fields being exactly the same in the different LU’s (e.g. between
Active Work Orders and Historical Work Orders). So only if it exists two
attributes with the same name in both of the LUs a copy of the custom fields
will be done. If an error occurs when copying custom fields the whole
transaction is rolled back.