Uploaded image for project: 'Forge'
  1. Forge
  2. FORGE-2767

@WithAttributes should allow its use on Constructor injections

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.7.2.Final
    • Fix Version/s: None
    • Component/s: UI - API
    • Labels:
      None

      Description

      When creating a Command, you can specify the attributes of a UI field by using @WithAttributes and @Inject:

      @Inject
      @WithAttributes(label = "Version")
      private UIInput<String> version;
      

      The problem is we can't use this approach with constructor injection because @WithAttributes is not allowed on parameters.

      PS: This is easily avoided by instantiating UI inputs using the initializeUI method.

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            ataxexe Marcelo GuimarĂ£es
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: