Skip to content

Column Names not getting added on updates #67

Description

@paulb057

I came across a problem where adding additional "tabs" the header/column names where not added to the second tabs only the first one

I replace line 305
<cfset addRows( arguments.query, 1, 1, false, arguments.columnFormats, arguments.autoSizeColumns ) />

with
<!--- Add the column names to the first row
If arguments.columnames exist, use that value for the headers
otherwise use the columnlist from the query variable itself
--->
<cfif structKeyExists(arguments, "columnnames")>
<cfset addRow(arguments.columnnames, 1, 1, false) />

<cfset addRow(arguments.query.columnlist, 1, 1, false) />

        <!--- Add the data starting at the 2nd row, since the header
            was added to the first row
        ---->
        <cfset addRows( arguments.query, 2, 1, false, arguments.columnFormats, arguments.autoSizeColumns ) />

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions