Class ObjectContextWeb

  • All Implemented Interfaces:

    public class ObjectContextWeb
    extends ObjectContext
    Object context for web application usage
    See Also:
    Serialized Form
    • Field Detail

      • formName

        public java.lang.String formName
        Form name
      • tab

        public int tab
      • focusField

        public java.lang.String focusField
        Focus field
      • parent

        public ObjectDB parent
        Parent object
      • parentId

        public java.lang.String parentId
        Parent object ID
      • cols

        public java.util.List<ObjectField> cols
        List columns
      • bulk

        public boolean bulk
        Activate the list selection for bulk actions
      • home

        public boolean home
        Home element ?
      • divId

        public java.lang.String divId
        Div ID of the element
      • session

        public transient javax.servlet.http.HttpSession session
        User session
    • Constructor Detail

      • ObjectContextWeb

        public ObjectContextWeb()
        Empty constructor
      • ObjectContextWeb

        public ObjectContextWeb​(javax.servlet.http.HttpSession session)
        Session constructor
      • ObjectContextWeb

        public ObjectContextWeb​(java.lang.String formName,
                                java.lang.String action,
                                ServletParameters params,
                                javax.servlet.http.HttpSession session)
        Generic object form constructor
    • Method Detail

      • initWebService

        public void initWebService​(ObjectDB obj,
                                   int context,
                                   Parameters.ContextParam p)

        Object init switch for use by webservices (and related APIs : Ajax, ...)

        obj - Business object
        context - Init context
        p - Parameters for panel lists, reference select, associate, datamap select, agenda, graph, crosstab, print template contexts
      • apply

        public void apply​(ObjectDB obj)

        Apply the context related to object: apply constraints, init hooks

        obj - contextual object
      • apply

        public void apply​(ObjectDB obj,
                          java.lang.String edit)

        Apply the context related to object: apply constraints, init hooks and user filters

        apply in class ObjectContext
        obj - contextual object
        edit - additional edit list context 'new' or 'rows'
      • initForm

        public void initForm​(ObjectDB obj)

        Prepare form

        obj - contextual object
      • initFocus

        public void initFocus​(ObjectDB obj,
                              boolean valued)

        Prepare the focus

        obj - contextual object
        valued - is object valued ?
      • initList

        public void initList​(ObjectDB obj)
        Hide all fields related to the parent object in panels.
        Display extended fields in case of LIST_ADD mode.
        Apply user preferences.
      • initList

        public static void initList​(ObjectDB obj,
                                    java.util.List<java.lang.String> prefs,
                                    ObjectDB parent,
                                    boolean inline)
        Hide all fields related to the parent object in panels.
        Display extended fields in case of LIST_ADD mode.
        Apply user preferences.
      • initAction

        public void initAction​(ObjectDB obj)
      • initSearch

        public void initSearch​(ObjectDB obj)
      • isFieldVisible

        public boolean isFieldVisible​(ObjectDB obj,
                                      ObjectField f,
                                      boolean ignoreMore)
        Checks if the field is visible
        obj - Object
        f - Field
        ignoreMore - true to ignore the 'more' property
      • isListVisible

        public boolean isListVisible​(ObjectDB o,
                                     FieldArea fa)
        Checks if an area is visible in a list context (one of its fields must be visible).
        o - object
        fa - field area
      • isFieldUpdatable

        public boolean isFieldUpdatable​(ObjectDB obj,
                                        ObjectField f)
        Checks if the field is updatable
        obj - object
        f - field
      • getTabIndex

        public int getTabIndex​(ObjectDB obj,
                               java.lang.String areaId)
        Current selected tab index
      • getCollapsed

        public java.lang.Boolean getCollapsed​(ObjectDB obj,
                                              java.lang.String areaId)
        Current toggle Area button
      • addPlus

        public void addPlus​(boolean std,
                            java.lang.String lineId,
                            java.lang.String btn)
      • keepAlive

        public java.lang.String keepAlive​(ObjectDB obj)
        Keep the session and this object alive during UI edition
      • initActivityObject

        public ObjectDB initActivityObject​(Processus p,
                                           ActivityFile context,
                                           boolean ajax)
        Prepare one object for the contextual activity
        p - Process definition
        context - Activity context
        Business object instance
      • readActivityContext

        public ObjectDB readActivityContext​(ActivityFile context,
                                            boolean ajax)
        Read any UI data into activity