Search in sources :

Example 1 with ViewAsPreconditionsContext

use of de.metas.ui.web.process.ViewAsPreconditionsContext in project metasfresh-webui-api by metasfresh.

the class ViewProcessInstancesRepository method streamDocumentRelatedProcesses.

@Override
public Stream<WebuiRelatedProcessDescriptor> streamDocumentRelatedProcesses(final WebuiPreconditionsContext preconditionsContext) {
    final ViewAsPreconditionsContext viewContext = ViewAsPreconditionsContext.castOrNull(preconditionsContext);
    if (viewContext == null) {
        return Stream.empty();
    }
    final IView view = viewContext.getView();
    return getViewActionDescriptors(view).streamDocumentRelatedProcesses(viewContext);
}
Also used : IView(de.metas.ui.web.view.IView) ViewAsPreconditionsContext(de.metas.ui.web.process.ViewAsPreconditionsContext)

Aggregations

ViewAsPreconditionsContext (de.metas.ui.web.process.ViewAsPreconditionsContext)1 IView (de.metas.ui.web.view.IView)1