ICEfaces
  1. ICEfaces
  2. ICE-11420

Changing the filename on ace:dynamicResource does not have any effect in Showcase demo

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 4.3
    • Fix Version/s: EE-4.3.0.GA
    • Component/s: ACE-Components
    • Labels:
      None
    • Environment:
      Showcase IceSoft
    • Affects:
      Documentation (User Guide, Ref. Guide, etc.), Sample App./Tutorial

      Description

      In the Showcase, changing the name of the file on ace:dynamicResource does not have any effect. The downloaded file (attachment) is always the default one.
      See ICE-10654 which claims the problem to be fixed but it isn't.

      This is even worse if the Mime-Type changes dynamically eg. due to choosen Filetype to download by user. FileName and MimeType values of ace:dynamicResource must be forced reevaluated once the button is pressed in order to get the right values matching to the download at this moment.

      This is quite a heavy bug as it makes ace:dynamicResource more or less useless.


        Activity

        Markus Guenther created issue -
        Hide
        Markus Guenther added a comment - - edited

        Found finally a workaround. Do force a ajax render="id of the dynamicResource" or simply @all whenever there might have happened an action to change the filename or mime type within the UI.

        Note: In the Showcase this is done but only with event="valueChange" and this seems not to work there somehow. In my quite similar case it works with @all and no event selector

        Show
        Markus Guenther added a comment - - edited Found finally a workaround. Do force a ajax render="id of the dynamicResource" or simply @all whenever there might have happened an action to change the filename or mime type within the UI. Note: In the Showcase this is done but only with event="valueChange" and this seems not to work there somehow. In my quite similar case it works with @all and no event selector
        Arturo Zambrano made changes -
        Field Original Value New Value
        Assignee Arturo Zambrano [ artzambrano ]
        Ken Fyten made changes -
        Fix Version/s EE-4.3.0.GA [ 13103 ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #52777 Tue Nov 13 15:28:44 MST 2018 art.zambrano ICE-11420 corrected ace:dynamicResource > Advanced demo to correctly update the entered file name
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/samples/showcase/showcase/src/main/webapp/resources/examples/ace/dynamicResource/dynamicResourceAdvanced.xhtml
        Hide
        Arturo Zambrano added a comment -

        r52777: corrected ace:dynamicResource > Advanced demo to correctly update the entered file name

        The ICE-10654 issue was indeed fixed. However, there were some issues with the demo itself.

        First, the ace:textEntry component to change the file name had two ace:ajax tags. Simply having <ace:ajax render=@form" /> is enough to update the value in the server.

        The other issue is that values in a form are not submitted and updated in the server when the ace:dynamicResource type is 'image'. This is simply, because an anchor element is rendered with the image and the URL, so the form is not submitted. In order for the form to be submitted when the ace:dynamicResource component is clicked, the type must be 'button'. So, if an image is to be rendered for this button, it will have to be done via CSS, as shown in the updated demo. The 'image' time should only be for static resources that are not expected to change dynamically.

        Show
        Arturo Zambrano added a comment - r52777: corrected ace:dynamicResource > Advanced demo to correctly update the entered file name The ICE-10654 issue was indeed fixed. However, there were some issues with the demo itself. First, the ace:textEntry component to change the file name had two ace:ajax tags. Simply having <ace:ajax render=@form" /> is enough to update the value in the server. The other issue is that values in a form are not submitted and updated in the server when the ace:dynamicResource type is 'image'. This is simply, because an anchor element is rendered with the image and the URL, so the form is not submitted. In order for the form to be submitted when the ace:dynamicResource component is clicked, the type must be 'button'. So, if an image is to be rendered for this button, it will have to be done via CSS, as shown in the updated demo. The 'image' time should only be for static resources that are not expected to change dynamically.
        Arturo Zambrano made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ken Fyten made changes -
        Summary Changing the filename on ace:dynamicResource does not have any effect Changing the filename on ace:dynamicResource does not have any effect in Showcase demo
        Ken Fyten made changes -
        Affects Documentation (User Guide, Ref. Guide, etc.),Sample App./Tutorial [ 10003, 10001 ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #52846 Tue Dec 11 15:09:42 MST 2018 art.zambrano ICE-11420 improved the TLD documentation about the types of rendering of a dynamic resource and their capabilities
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/ace/component/src/org/icefaces/ace/component/dynamicresource/DynamicResourceMeta.java
        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Arturo Zambrano
            Reporter:
            Markus Guenther
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: