codeant-ai-for-open-source[bot] commented on code in PR #46008:
URL: https://github.com/apache/superset/pull/46008#discussion_r4467937642


##########
superset-frontend/plugins/plugin-chart-ag-grid-table/src/buildQuery.ts:
##########
@@ -186,31 +183,31 @@ export const buildQueryUncached: 
BuildQuery<TableChartFormData> = (
       }
 
       const temporalColumnsLookup = formData?.temporal_columns_lookup;
-      // Filter out the column if needed and prepare the temporal column object
-
-      columns = columns.filter(col => {
-        const shouldBeAdded =
+      let firstTemporalColumn: AdhocColumn | undefined;
+      columns = columns.map(col => {
+        if (
           isPhysicalColumn(col) &&
           time_grain_sqla &&
-          temporalColumnsLookup?.[col];
-
-        if (shouldBeAdded && !temporalColumnAdded) {
-          temporalColumn = {
+          temporalColumnsLookup?.[col]
+        ) {
+          const temporalColumn: AdhocColumn = {
             timeGrain: time_grain_sqla,
             columnType: 'BASE_AXIS',
             sqlExpression: col,
             label: col,
             expressionType: 'SQL',
-          } as AdhocColumn;
-          temporalColumnAdded = true;
-          return false; // Do not include this in the output; it's added 
separately
+          };

Review Comment:
   ✅ **CodeAnt verified this suggestion was addressed in subsequent commits and 
marked this thread resolved** as of `79eaf91`.
   
   Generated temporal adhoc columns now include `isColumnReference: true` when 
`isSemanticView` is true.
   
   <sub>If that's not right, unresolve this thread and CodeAnt will leave it 
open.</sub>
   
   <!-- codeant-auto-resolve-reply -->



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

  • [PR] fix(ta... PrakharAgarwal17 (via GitHub) via notifications
    • Re: [P... rebenitez1802 (via GitHub) via notifications
    • Re: [P... PrakharAgarwal17 (via GitHub) via notifications
    • Re: [P... PrakharAgarwal17 (via GitHub) via notifications
    • Re: [P... PrakharAgarwal17 (via GitHub) via notifications
    • Re: [P... netlify[bot] (via GitHub) via notifications
    • Re: [P... PrakharAgarwal17 (via GitHub) via notifications
    • Re: [P... codeant-ai-for-open-source[bot] (via GitHub) via notifications
    • Re: [P... codecov[bot] (via GitHub) via notifications
    • Re: [P... codeant-ai-for-open-source[bot] (via GitHub) via notifications
    • Re: [P... PrakharAgarwal17 (via GitHub) via notifications
    • Re: [P... PrakharAgarwal17 (via GitHub) via notifications
    • Re: [P... codeant-ai-for-open-source[bot] (via GitHub) via notifications
    • Re: [P... PrakharAgarwal17 (via GitHub) via notifications
    • Re: [P... codeant-ai-for-open-source[bot] (via GitHub) via notifications

Reply via email to