2 Replies Latest reply: Feb 11, 2013 3:34 PM by David Elms RSS

    ColumnStretching override?

    David Elms
      I'm using Jdeveloper and the associated JHS.
      ColumnStretching on a table is, by default in Jdev, set to last. I'd like to change that to another column but when I re-run the JAG it resets to the default, i.e. last.
      Is there any way to maintain my preferred setting whilst still being able to change and re-generate the page fragment in JHS?
        • 1. Re: ColumnStretching override?
          Steven Davelaar-Oracle

          There is no property in the JHeadstart Application Definition Editor to change this behavior.
          But you can always create a custom template to preserve post-generation changes.

          In your case, you should make a custom template for tableGroup.vm. You could make this custom template generic so it reads one of the group-level custom properties to set the columnStretching.

          See chapter 12 "Customizing Generator Output" in the JHeadstart Developers Guide for much more info on this topic: http://download.oracle.com/consulting/jhsdevguide1111.pdf

          Steven Davelaar,
          JHeadstart Team.
          • 2. Re: ColumnStretching override?
            David Elms
            I was expecting the templates to be the answer... thanks for confirming that.

            I customised tableGroup.vm at the group level and just replaced columnStretching="last" with columnStretching="${JHS.current.group.columnToStretch}". The custom property name columnToStretch has a value of column:AllAgencyTypesNameCol. Is this what you meant by making a "+custom template generic so it reads one of the group-level custom properties to set the columnStretching+"? If I created the template at a higher level, i.e. service or application, would each group require a field to be stretched? Would this work with form layouts as well as with tables?

            The manual suggested using the Additional Properties for styles so I set this to contentStyle="text-transform:uppercase;" for a code field. It's good that you don't need a custom template using this method but perhaps I should have created a custom template at a higher level, assuming that all codes will be in uppercase. Do you think that's a better approach?