Browse Source

hide insert button on collections page

tumao 4 years ago
parent
commit
9ce292058c
1 changed files with 24 additions and 24 deletions
  1. 24 24
      client/src/pages/collections/Collections.tsx

+ 24 - 24
client/src/pages/collections/Collections.tsx

@@ -229,30 +229,30 @@ const Collections = () => {
       },
       icon: 'add',
     },
-    {
-      label: btnTrans('insert'),
-      onClick: () => {
-        const component = (
-          <InsertContainer
-            collections={[]}
-            selectedCollection={''}
-            partitions={[]}
-            selectedPartition={''}
-            schema={[]}
-            handleInsert={() => {}}
-          />
-        );
-        handleInsertDialog(component);
-      },
-      /**
-       * insert validation:
-       * 1. At least 1 available collection
-       * 2. selected collections quantity shouldn't over 1
-       */
-      disabled: () =>
-        collectionList.length === 0 || selectedCollections.length > 1,
-      icon: 'upload',
-    },
+    // {
+    //   label: btnTrans('insert'),
+    //   onClick: () => {
+    //     const component = (
+    //       <InsertContainer
+    //         collections={[]}
+    //         selectedCollection={''}
+    //         partitions={[]}
+    //         selectedPartition={''}
+    //         schema={[]}
+    //         handleInsert={() => {}}
+    //       />
+    //     );
+    //     handleInsertDialog(component);
+    //   },
+    //   /**
+    //    * insert validation:
+    //    * 1. At least 1 available collection
+    //    * 2. selected collections quantity shouldn't over 1
+    //    */
+    //   disabled: () =>
+    //     collectionList.length === 0 || selectedCollections.length > 1,
+    //   icon: 'upload',
+    // },
     {
       type: 'iconBtn',
       onClick: () => {