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/07/07 09:14:19 UTC

[GitHub] [superset] zhaoyongjie commented on a diff in pull request #20338: chore: removing Druid from front- and back- end

zhaoyongjie commented on code in PR #20338:
URL: https://github.com/apache/superset/pull/20338#discussion_r915649330


##########
superset-frontend/packages/superset-ui-core/src/query/types/QueryFormData.ts:
##########
@@ -194,30 +194,20 @@ export interface SqlaFormData extends BaseFormData {
   /**
    * Name of the Time Column. Time column is optional.
    */
+  granularity?: string;
   granularity_sqla?: string;
   time_grain_sqla?: TimeGranularity;
   having?: string;
 }
 
-/**
- * Form data for Druid datasources.
- */
-export interface DruidFormData extends BaseFormData {
-  granularity?: string;
-  having_druid?: string;
-  druid_time_origin?: string;
-}
-
-export type QueryFormData = DruidFormData | SqlaFormData;
+export type QueryFormData = SqlaFormData;
 
 //---------------------------------------------------
 // Type guards
 //---------------------------------------------------
 
-export function isDruidFormData(
-  formData: QueryFormData,
-): formData is DruidFormData {
-  return 'granularity' in formData;
+export function isSavedMetric(metric: QueryFormMetric): metric is SavedMetric {
+  return typeof metric === 'string';

Review Comment:
   `isSavedMetric` has moved to `superset-ui-core/src/query/types/Metrics`



-- 
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