Class ReportSecurityManager

java.lang.Object
io.jmix.reports.impl.repository.ReportSecurityManager

@Component("report_ReportSecurityManager") public class ReportSecurityManager extends Object
Implementation detail. Use ReportRepository instead.
  • Field Details

  • Constructor Details

    • ReportSecurityManager

      public ReportSecurityManager()
  • Method Details

    • applySecurityPolicies

      public void applySecurityPolicies(LoadContext<Report> lc, @Nullable String screen, @Nullable org.springframework.security.core.userdetails.UserDetails userDetails)
      Apply security constraints for query to select reports available by roles and screen restrictions
      Parameters:
      lc - load context
      screen - screen id
      userDetails - user details
    • applyPoliciesByEntityParameters

      protected void applyPoliciesByEntityParameters(LoadContext<Report> lc, @Nullable MetaClass inputValueMetaClass)
      Apply constraints for query to select reports which have input parameter with class matching inputValueMetaClass
      Parameters:
      lc - load context
      inputValueMetaClass - meta class of input parameter value
    • applyOutputType

      protected void applyOutputType(LoadContext<Report> lc, @Nullable ReportOutputType outputType)
      Apply condition to the query: report must have at least one template with given output type.
    • getAvailableReports

      public List<Report> getAvailableReports(@Nullable String screenId, @Nullable org.springframework.security.core.userdetails.UserDetails user, @Nullable MetaClass inputValueMetaClass, @Nullable Boolean system, @Nullable ReportOutputType outputType, @Nullable Sort sort)
      Returns a sorted list of reports, available for certain screen, user and input parameter
      Parameters:
      screenId - - id of the screen
      user - - caller user
      inputValueMetaClass - - meta class of report input parameter
      sort - - sorting type for the reports list
      system - - system flag
      Returns:
      list of available reports
    • wrapCodeParameterForSearch

      protected String wrapCodeParameterForSearch(String value)