Class PostAction

java.lang.Object
org.cxbox.core.dto.rowmeta.PostAction

public class PostAction extends Object
  • Constructor Details

    • PostAction

      public PostAction()
  • Method Details

    • refreshBc

      public static PostAction refreshBc(org.cxbox.api.data.BcIdentifier bcIdentifier)
    • refreshParentBc

      public static PostAction refreshParentBc(org.cxbox.api.data.BcIdentifier bcIdentifier)
    • downloadFile

      public static PostAction downloadFile(String fileId)
    • downloadFileByUrl

      public static PostAction downloadFileByUrl(String url)
    • openPickList

      public static PostAction openPickList(String pickList)
    • drillDown

      public static PostAction drillDown(DrillDownTypeSpecifier drillDownType, String url)
    • drillDown

      public static PostAction drillDown(DrillDownTypeSpecifier drillDownType, String url, String urlName)
    • delayedRefreshBC

      public static PostAction delayedRefreshBC(org.cxbox.api.data.BcIdentifier bcIdentifier, Number seconds)
    • showMessage

      public static PostAction showMessage(MessageType messageType, String messageText)
    • postDelete

      public static PostAction postDelete()
    • waitUntil

      public static <T extends org.cxbox.api.data.dto.DataResponseDTO, V> PostAction.WaitUntilBuilder<T,V> waitUntil(@NonNull @NonNull DtoField<? super T,V> successConditionField, @NonNull V successConditionValue)
      Creates a post-action that waits until a specified condition is met.
      Parameters:
      successConditionField - The field whose value will be monitored.
      successConditionValue - The value that indicates successful completion. Only String and Boolean types are supported now
      Returns:
      A builder for constructing a `waitUntil` post-action.

      Example usage:

       PostAction.waitUntil(CxboxRestController.clientEdit, ClientDTO_.statusField, true)
                .inProgressMessage("Fetching data...")
                .successMessage("Data received. Click OK to proceed.")
                .timeoutMessage("Timeout reached. Close the window and refresh.")
                .build();
       
    • drillDownAndWaitUntil

      public static <T extends org.cxbox.api.data.dto.DataResponseDTO, V> PostAction.WaitUntilBuilder<T,V> drillDownAndWaitUntil(@NonNull @NonNull String url, @NonNull @NonNull org.cxbox.api.data.BcIdentifier successConditionBc, @NonNull @NonNull DtoField<? super T,V> successConditionField, @NonNull V successConditionValue)
      Creates a post-action that performs a INNER drill-down and then waits until a specified condition is met.
      Parameters:
      url - The INNER drill-down URL to navigate to.
      successConditionBc - The business component on which the condition will be monitored after drill-down.
      successConditionField - The field whose value will be monitored.
      successConditionValue - The value that indicates successful completion. Only String and Boolean types are supported now
      Returns:
      A builder for constructing a `drillDownAndWaitUntil` post-action.

      Example usage:

       PostAction.drillDownAndWaitUntil("/screen/client/view/clientView/" + CxboxRestController.clientEdit + "/" + clientId,
                 CxboxRestController.clientEdit, ClientDTO_.statusField, true)
                .inProgressMessage("Navigating and fetching data...")
                .successMessage("Data loaded successfully.")
                .timeoutMessage("Failed to retrieve data in time.")
                .build();
       
    • getAttributes

      public Map<String,Object> getAttributes()
    • getAttribute

      public Object getAttribute(String key)
    • getURL

      public String getURL()
    • getType

      public String getType()
    • getDrillDownType

      public String getDrillDownType()
    • add

      public PostAction add(String key, Object value)