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 2021/10/01 16:12:21 UTC
[GitHub] [superset] michael-s-molina commented on a change in pull request #16910: chore: add certified columns to top of list
michael-s-molina commented on a change in pull request #16910:
URL: https://github.com/apache/superset/pull/16910#discussion_r720373038
##########
File path: superset-frontend/src/explore/components/controls/FilterControl/AdhocFilter/index.js
##########
@@ -154,19 +154,24 @@ export default class AdhocFilter {
op => OPERATOR_ENUM_TO_OPERATOR_TYPE[op].operation,
);
if (this.expressionType === EXPRESSION_TYPES.SIMPLE) {
+ // console.log('isValid Meth', this.expressionType)
if (nullCheckOperators.indexOf(this.operator) >= 0) {
+ // console.log('Null Op --> opertator', this.operator)
+ // console.log('subject', this.subject)
return !!(this.operator && this.subject);
}
if (truthCheckOperators.indexOf(this.operator) >= 0) {
+ // console.log('i hit in truthCheckers', this.subject)
Review comment:
```suggestion
```
##########
File path: superset-frontend/src/explore/components/controls/FilterControl/AdhocFilter/index.js
##########
@@ -154,19 +154,24 @@ export default class AdhocFilter {
op => OPERATOR_ENUM_TO_OPERATOR_TYPE[op].operation,
);
if (this.expressionType === EXPRESSION_TYPES.SIMPLE) {
+ // console.log('isValid Meth', this.expressionType)
Review comment:
```suggestion
```
##########
File path: superset-frontend/src/explore/components/DatasourcePanel/index.tsx
##########
@@ -253,6 +257,11 @@ export default function DataSourcePanel({
setInputValue('');
}, [columns, datasource, metrics]);
+ const sortCertifiedFirst = (slice: ColumnMeta[]) => {
+ const sorted = slice.sort((a, b) => b.is_certified - a.is_certified);
+ return sorted;
+ };
Review comment:
```suggestion
const sortCertifiedFirst = (slice: ColumnMeta[]) =>
slice.sort((a, b) => b.is_certified - a.is_certified);
```
##########
File path: superset-frontend/src/explore/components/controls/FilterControl/AdhocFilter/index.js
##########
@@ -154,19 +154,24 @@ export default class AdhocFilter {
op => OPERATOR_ENUM_TO_OPERATOR_TYPE[op].operation,
);
if (this.expressionType === EXPRESSION_TYPES.SIMPLE) {
+ // console.log('isValid Meth', this.expressionType)
if (nullCheckOperators.indexOf(this.operator) >= 0) {
+ // console.log('Null Op --> opertator', this.operator)
+ // console.log('subject', this.subject)
return !!(this.operator && this.subject);
}
if (truthCheckOperators.indexOf(this.operator) >= 0) {
+ // console.log('i hit in truthCheckers', this.subject)
return !!(this.subject && this.comparator !== null);
}
if (this.operator && this.subject && this.clause) {
+ // console.log('i trio check', this.operator, 'subject ->', this.subject, 'clause', this.clause)
Review comment:
```suggestion
```
##########
File path: superset-frontend/src/explore/components/controls/FilterControl/AdhocFilter/index.js
##########
@@ -154,19 +154,24 @@ export default class AdhocFilter {
op => OPERATOR_ENUM_TO_OPERATOR_TYPE[op].operation,
);
if (this.expressionType === EXPRESSION_TYPES.SIMPLE) {
+ // console.log('isValid Meth', this.expressionType)
if (nullCheckOperators.indexOf(this.operator) >= 0) {
+ // console.log('Null Op --> opertator', this.operator)
+ // console.log('subject', this.subject)
Review comment:
```suggestion
```
--
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