You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/10/18 13:39:29 UTC

[GitHub] [superset] villebro commented on a diff in pull request #21847: fix: custom SQL in the XAxis

villebro commented on code in PR #21847:
URL: https://github.com/apache/superset/pull/21847#discussion_r998241950


##########
superset-frontend/packages/superset-ui-chart-controls/src/operators/prophetOperator.ts:
##########
@@ -16,15 +16,15 @@
  * specific language governing permissions and limitationsxw
  * under the License.
  */
-import { PostProcessingProphet, getXAxis } from '@superset-ui/core';
+import { PostProcessingProphet, getXAxisLabel } from '@superset-ui/core';
 import { PostProcessingFactory } from './types';
 
 /* eslint-disable @typescript-eslint/no-unused-vars */
 export const prophetOperator: PostProcessingFactory<PostProcessingProphet> = (
   formData,
   queryObject,
 ) => {
-  const xAxis = getXAxis(formData);
+  const xAxis = getXAxisLabel(formData);

Review Comment:
   same here (and in other places below, too)



##########
superset-frontend/packages/superset-ui-chart-controls/src/operators/pivotOperator.ts:
##########
@@ -30,7 +30,7 @@ export const pivotOperator: PostProcessingFactory<PostProcessingPivot> = (
   queryObject,
 ) => {
   const metricLabels = ensureIsArray(queryObject.metrics).map(getMetricLabel);
-  const xAxis = getXAxis(formData);
+  const xAxis = getXAxisLabel(formData);

Review Comment:
   Just a thought: As we now have different utils for extracting the column and the label, should we be more specific here and call this `xAxisLabel`



-- 
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: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org