mistercrunch commented on a change in pull request #8845: [dashboard] New, list 
view (react)
URL: 
https://github.com/apache/incubator-superset/pull/8845#discussion_r366541044
 
 

 ##########
 File path: superset/assets/src/views/dashboardList/DashboardList.tsx
 ##########
 @@ -0,0 +1,294 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import { SupersetClient } from '@superset-ui/connection';
+import { t } from '@superset-ui/translation';
+import moment from 'moment';
+import PropTypes from 'prop-types';
+import React from 'react';
+// @ts-ignore
+import { Button, Modal, Panel } from 'react-bootstrap';
+import ListView from 'src/components/ListView/ListView';
+import { FilterTypeMap } from 'src/components/ListView/types';
+import { FetchDataConfig } from 'src/components/ListView/types';
+import withToasts from 'src/messageToasts/enhancers/withToasts';
+
+import './DashboardList.less';
+
+const PAGE_SIZE = 25;
+
+interface Props {
+  addDangerToast: (msg: string) => void;
+}
+
+interface State {
+  dashboards: any[];
+  dashboardCount: number;
+  loading: boolean;
+  showDeleteModal: boolean;
+  deleteCandidate: any;
+  filterTypes: FilterTypeMap;
+  permissions: string[];
+  labelColumns: { [key: string]: string };
+}
+class DashboardList extends React.PureComponent<Props, State> {
+
+  get canEdit() {
+    return this.hasPerm('can_edit');
+  }
+
+  get canDelete() {
+    return this.hasPerm('can_delete');
+  }
+
+  public static propTypes = {
 
 Review comment:
   Wondered why we haven't used this syntax before and found this:
   <img width="739" alt="Screen Shot 2020-01-14 at 11 52 03 AM" 
src="https://user-images.githubusercontent.com/487433/72377404-5671a600-36c4-11ea-903e-1c5e019c0e96.png";>
   

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

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

Reply via email to