You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2020/12/02 04:36:56 UTC

[GitHub] [apisix-dashboard] guoqqqi opened a new pull request #949: add: Static Info Pages

guoqqqi opened a new pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949


   resolve #850  I have made a static page at present. Is the page style like this? I have some questions and need help:
   1 When I add an icon to the Info page in the antd <IconFont> component, I don't seem to have permission to add icons and view existing icons. So I used an antd icon, but it didn't show up. At the top of the menu bar!
   2 The page style is currently written inline. If there is no problem with the style, I will write it in styles.less.
   3 The rest is the <select> dynamic display table, which is being done..


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (969424f) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/478cbebd82cd7912f8cdac5f85a6086ceea191c2?el=desc) (478cbeb) will **increase** coverage by `0.53%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master     #949      +/-   ##
   ==========================================
   + Coverage   42.95%   43.49%   +0.53%     
   ==========================================
     Files          18       18              
     Lines        1271     1299      +28     
   ==========================================
   + Hits          546      565      +19     
   - Misses        633      642       +9     
     Partials       92       92              
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [api/internal/utils/utils.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL3V0aWxzL3V0aWxzLmdv) | `51.42% <0.00%> (-7.84%)` | :arrow_down: |
   | [api/internal/handler/service/service.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvc2VydmljZS9zZXJ2aWNlLmdv) | `27.65% <0.00%> (-0.61%)` | :arrow_down: |
   | [api/internal/core/entity/query.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L3F1ZXJ5Lmdv) | `0.00% <0.00%> (ø)` | |
   | [api/internal/core/entity/entity.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2VudGl0eS5nbw==) | `0.00% <0.00%> (ø)` | |
   | [api/internal/handler/consumer/consumer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvY29uc3VtZXIvY29uc3VtZXIuZ28=) | `34.92% <0.00%> (ø)` | |
   | [api/internal/handler/route/route.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvcm91dGUvcm91dGUuZ28=) | `46.56% <0.00%> (+0.11%)` | :arrow_up: |
   | [api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=) | `79.22% <0.00%> (+0.93%)` | :arrow_up: |
   | [api/internal/core/store/validate.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvdmFsaWRhdGUuZ28=) | `58.04% <0.00%> (+2.96%)` | :arrow_up: |
   | [api/internal/core/entity/format.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2Zvcm1hdC5nbw==) | `60.46% <0.00%> (+8.08%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [478cbeb...969424f](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736998704


   ![image](https://user-images.githubusercontent.com/2106987/100831841-845d0600-34a1-11eb-9df8-6b8e4d0dc75a.png)
   
   for this check, you need to add the Apache Software Foundation's License header at the top of your changed files, please refer to other pages.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on a change in pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on a change in pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#discussion_r537202706



##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,125 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import styles from './Info.less';
+
+const detailData = [
+  {
+    category: 'system',
+    name: 'version',
+    value: '2.0',
+    name2: 'apisix_id',
+    value2: '2.1',
+  },
+  {
+    category: 'categoryA',
+    name: 'keyA',
+    value: 'valueA',
+    name2: 'customKeyA',
+    value2: 'valueKeyA',
+  },
+  {
+    category: 'categoryB',
+    name: 'keyB',
+    value: 'valueB',
+    name2: 'customKeyB',
+    value2: 'valueKeyB',
+  },
+  {
+    category: 'categoryC',
+    name: 'keyC',
+    value: 'valueC',
+    name2: 'customKeyC',
+    value2: 'valueKeyC',
+  },
+];
+
+const nodeListData = [
+  {
+    key: 'key1',
+    value: 'value1',
+  },
+  {
+    key: 'key2',
+    value: 'value2',
+  },
+  {
+    key: 'key3',
+    value: 'value3',
+  },
+];
+
+const Info: React.FC = () => {
+  const [detail, setDetail] = useState([] as any);

Review comment:
       ugly typing!

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,125 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import styles from './Info.less';
+
+const detailData = [
+  {
+    category: 'system',
+    name: 'version',
+    value: '2.0',
+    name2: 'apisix_id',
+    value2: '2.1',
+  },
+  {
+    category: 'categoryA',
+    name: 'keyA',
+    value: 'valueA',
+    name2: 'customKeyA',
+    value2: 'valueKeyA',
+  },
+  {
+    category: 'categoryB',
+    name: 'keyB',
+    value: 'valueB',
+    name2: 'customKeyB',
+    value2: 'valueKeyB',
+  },
+  {
+    category: 'categoryC',
+    name: 'keyC',
+    value: 'valueC',
+    name2: 'customKeyC',
+    value2: 'valueKeyC',
+  },
+];
+
+const nodeListData = [
+  {
+    key: 'key1',
+    value: 'value1',
+  },
+  {
+    key: 'key2',
+    value: 'value2',
+  },
+  {
+    key: 'key3',
+    value: 'value3',
+  },
+];
+
+const Info: React.FC = () => {
+  const [detail, setDetail] = useState([] as any);
+  const [nodeList, setNodeList] = useState([] as any);
+  const { formatMessage } = useIntl();
+  const { Option } = Select;
+
+  useEffect(() => {
+    setNodeList(nodeListData);
+  });
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
+      <div className={styles.select}>
+        <Select
+          showSearch
+          style={{ width: '130px' }}
+          placeholder="Please select"

Review comment:
       select what?

##########
File path: web/src/helpers.tsx
##########
@@ -20,11 +20,17 @@ import { MenuDataItem } from '@ant-design/pro-layout';
 import { history } from 'umi';
 import moment from 'moment';
 
+import InfoCircleOutlined from '@ant-design/icons';

Review comment:
       1. ![image](https://user-images.githubusercontent.com/2106987/101305289-4daa3580-387d-11eb-8471-db0291cdbaef.png)
   
   2. You may use the wrong import method
   
   ```ts
   import {InfoCircleOutlined} from '@ant-design/icons';
   ```

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,125 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import styles from './Info.less';
+
+const detailData = [
+  {
+    category: 'system',
+    name: 'version',
+    value: '2.0',
+    name2: 'apisix_id',
+    value2: '2.1',
+  },
+  {
+    category: 'categoryA',
+    name: 'keyA',
+    value: 'valueA',
+    name2: 'customKeyA',
+    value2: 'valueKeyA',
+  },
+  {
+    category: 'categoryB',
+    name: 'keyB',
+    value: 'valueB',
+    name2: 'customKeyB',
+    value2: 'valueKeyB',
+  },
+  {
+    category: 'categoryC',
+    name: 'keyC',
+    value: 'valueC',
+    name2: 'customKeyC',
+    value2: 'valueKeyC',
+  },
+];
+
+const nodeListData = [
+  {
+    key: 'key1',
+    value: 'value1',
+  },
+  {
+    key: 'key2',
+    value: 'value2',
+  },
+  {
+    key: 'key3',
+    value: 'value3',
+  },
+];
+
+const Info: React.FC = () => {
+  const [detail, setDetail] = useState([] as any);

Review comment:
       bad variable name, use `data` here.

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,125 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import styles from './Info.less';
+
+const detailData = [
+  {
+    category: 'system',
+    name: 'version',
+    value: '2.0',
+    name2: 'apisix_id',
+    value2: '2.1',
+  },
+  {
+    category: 'categoryA',
+    name: 'keyA',
+    value: 'valueA',
+    name2: 'customKeyA',
+    value2: 'valueKeyA',
+  },
+  {
+    category: 'categoryB',
+    name: 'keyB',
+    value: 'valueB',
+    name2: 'customKeyB',
+    value2: 'valueKeyB',
+  },
+  {
+    category: 'categoryC',
+    name: 'keyC',
+    value: 'valueC',
+    name2: 'customKeyC',
+    value2: 'valueKeyC',
+  },
+];
+
+const nodeListData = [
+  {
+    key: 'key1',
+    value: 'value1',
+  },
+  {
+    key: 'key2',
+    value: 'value2',
+  },
+  {
+    key: 'key3',
+    value: 'value3',
+  },
+];
+
+const Info: React.FC = () => {
+  const [detail, setDetail] = useState([] as any);
+  const [nodeList, setNodeList] = useState([] as any);
+  const { formatMessage } = useIntl();
+  const { Option } = Select;
+
+  useEffect(() => {
+    setNodeList(nodeListData);
+  });
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
+      <div className={styles.select}>
+        <Select
+          showSearch
+          style={{ width: '130px' }}
+          placeholder="Please select"
+          onChange={() => {
+            setDetail(detailData);
+          }}
+        >
+          {nodeList.map((item: any) => (
+            <Option value={item.key} lable={item.key}>

Review comment:
       use key for loop
   
   <Option key={xxx} />

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,125 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import styles from './Info.less';
+
+const detailData = [
+  {
+    category: 'system',
+    name: 'version',
+    value: '2.0',
+    name2: 'apisix_id',
+    value2: '2.1',
+  },
+  {
+    category: 'categoryA',
+    name: 'keyA',
+    value: 'valueA',
+    name2: 'customKeyA',
+    value2: 'valueKeyA',
+  },
+  {
+    category: 'categoryB',
+    name: 'keyB',
+    value: 'valueB',
+    name2: 'customKeyB',
+    value2: 'valueKeyB',
+  },
+  {
+    category: 'categoryC',
+    name: 'keyC',
+    value: 'valueC',
+    name2: 'customKeyC',
+    value2: 'valueKeyC',
+  },
+];
+
+const nodeListData = [
+  {
+    key: 'key1',
+    value: 'value1',
+  },
+  {
+    key: 'key2',
+    value: 'value2',
+  },
+  {
+    key: 'key3',
+    value: 'value3',
+  },
+];
+
+const Info: React.FC = () => {
+  const [detail, setDetail] = useState([] as any);
+  const [nodeList, setNodeList] = useState([] as any);
+  const { formatMessage } = useIntl();
+  const { Option } = Select;
+
+  useEffect(() => {
+    setNodeList(nodeListData);
+  });
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
+      <div className={styles.select}>
+        <Select
+          showSearch
+          style={{ width: '130px' }}
+          placeholder="Please select"
+          onChange={() => {
+            setDetail(detailData);
+          }}
+        >
+          {nodeList.map((item: any) => (

Review comment:
       why any?

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,125 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import styles from './Info.less';
+
+const detailData = [
+  {
+    category: 'system',
+    name: 'version',
+    value: '2.0',
+    name2: 'apisix_id',
+    value2: '2.1',
+  },
+  {
+    category: 'categoryA',
+    name: 'keyA',
+    value: 'valueA',
+    name2: 'customKeyA',
+    value2: 'valueKeyA',
+  },
+  {
+    category: 'categoryB',
+    name: 'keyB',
+    value: 'valueB',
+    name2: 'customKeyB',
+    value2: 'valueKeyB',
+  },
+  {
+    category: 'categoryC',
+    name: 'keyC',
+    value: 'valueC',
+    name2: 'customKeyC',
+    value2: 'valueKeyC',
+  },
+];
+
+const nodeListData = [
+  {
+    key: 'key1',
+    value: 'value1',
+  },
+  {
+    key: 'key2',
+    value: 'value2',
+  },
+  {
+    key: 'key3',
+    value: 'value3',
+  },
+];
+
+const Info: React.FC = () => {
+  const [detail, setDetail] = useState([] as any);
+  const [nodeList, setNodeList] = useState([] as any);
+  const { formatMessage } = useIntl();
+  const { Option } = Select;
+
+  useEffect(() => {
+    setNodeList(nodeListData);
+  });
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
+      <div className={styles.select}>
+        <Select
+          showSearch
+          style={{ width: '130px' }}
+          placeholder="Please select"
+          onChange={() => {
+            setDetail(detailData);
+          }}
+        >
+          {nodeList.map((item: any) => (
+            <Option value={item.key} lable={item.key}>
+              {item.key}
+            </Option>
+          ))}
+          ;

Review comment:
       ?

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,125 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import styles from './Info.less';
+
+const detailData = [
+  {
+    category: 'system',
+    name: 'version',
+    value: '2.0',
+    name2: 'apisix_id',
+    value2: '2.1',
+  },
+  {
+    category: 'categoryA',
+    name: 'keyA',
+    value: 'valueA',
+    name2: 'customKeyA',
+    value2: 'valueKeyA',
+  },
+  {
+    category: 'categoryB',
+    name: 'keyB',
+    value: 'valueB',
+    name2: 'customKeyB',
+    value2: 'valueKeyB',
+  },
+  {
+    category: 'categoryC',
+    name: 'keyC',
+    value: 'valueC',
+    name2: 'customKeyC',
+    value2: 'valueKeyC',
+  },
+];
+
+const nodeListData = [
+  {
+    key: 'key1',
+    value: 'value1',
+  },
+  {
+    key: 'key2',
+    value: 'value2',
+  },
+  {
+    key: 'key3',
+    value: 'value3',
+  },
+];
+
+const Info: React.FC = () => {
+  const [detail, setDetail] = useState([] as any);
+  const [nodeList, setNodeList] = useState([] as any);
+  const { formatMessage } = useIntl();
+  const { Option } = Select;
+
+  useEffect(() => {
+    setNodeList(nodeListData);
+  });

Review comment:
       what's the difference when using `[]` and without `[]`?

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,125 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import styles from './Info.less';
+
+const detailData = [
+  {
+    category: 'system',
+    name: 'version',
+    value: '2.0',
+    name2: 'apisix_id',
+    value2: '2.1',
+  },
+  {
+    category: 'categoryA',
+    name: 'keyA',
+    value: 'valueA',
+    name2: 'customKeyA',
+    value2: 'valueKeyA',
+  },
+  {
+    category: 'categoryB',
+    name: 'keyB',
+    value: 'valueB',
+    name2: 'customKeyB',
+    value2: 'valueKeyB',
+  },
+  {
+    category: 'categoryC',
+    name: 'keyC',
+    value: 'valueC',
+    name2: 'customKeyC',
+    value2: 'valueKeyC',
+  },
+];
+
+const nodeListData = [
+  {
+    key: 'key1',
+    value: 'value1',
+  },
+  {
+    key: 'key2',
+    value: 'value2',
+  },
+  {
+    key: 'key3',
+    value: 'value3',
+  },
+];
+
+const Info: React.FC = () => {
+  const [detail, setDetail] = useState([] as any);
+  const [nodeList, setNodeList] = useState([] as any);
+  const { formatMessage } = useIntl();
+  const { Option } = Select;
+
+  useEffect(() => {
+    setNodeList(nodeListData);
+  });
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
+      <div className={styles.select}>
+        <Select
+          showSearch
+          style={{ width: '130px' }}
+          placeholder="Please select"
+          onChange={() => {
+            setDetail(detailData);
+          }}
+        >
+          {nodeList.map((item: any) => (
+            <Option value={item.key} lable={item.key}>
+              {item.key}
+            </Option>
+          ))}
+          ;
+        </Select>
+      </div>
+      <div className={styles.wrap}>
+        {detail.map((item: any) => {
+          return (
+            <table className={styles.table}>
+              <thead>
+                <th>{item.category}</th>
+                <th>&nbsp;</th>
+              </thead>
+              <tbody>
+                <tr>
+                  <td>{item.name}</td>
+                  <td>{item.value}</td>
+                </tr>
+                <tr>
+                  <td>{item.name2}</td>
+                  <td>{item.value2}</td>

Review comment:
       2?

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,125 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import styles from './Info.less';
+
+const detailData = [
+  {
+    category: 'system',
+    name: 'version',
+    value: '2.0',
+    name2: 'apisix_id',
+    value2: '2.1',
+  },
+  {
+    category: 'categoryA',
+    name: 'keyA',
+    value: 'valueA',
+    name2: 'customKeyA',
+    value2: 'valueKeyA',
+  },
+  {
+    category: 'categoryB',
+    name: 'keyB',
+    value: 'valueB',
+    name2: 'customKeyB',
+    value2: 'valueKeyB',
+  },
+  {
+    category: 'categoryC',
+    name: 'keyC',
+    value: 'valueC',
+    name2: 'customKeyC',
+    value2: 'valueKeyC',
+  },
+];
+
+const nodeListData = [
+  {
+    key: 'key1',
+    value: 'value1',
+  },
+  {
+    key: 'key2',
+    value: 'value2',
+  },
+  {
+    key: 'key3',
+    value: 'value3',
+  },
+];
+
+const Info: React.FC = () => {
+  const [detail, setDetail] = useState([] as any);
+  const [nodeList, setNodeList] = useState([] as any);
+  const { formatMessage } = useIntl();
+  const { Option } = Select;
+
+  useEffect(() => {
+    setNodeList(nodeListData);
+  });
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
+      <div className={styles.select}>
+        <Select
+          showSearch
+          style={{ width: '130px' }}
+          placeholder="Please select"
+          onChange={() => {
+            setDetail(detailData);

Review comment:
       call api then set data when api is ready




----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-740219277


   emm selector is used to select nodes, not category. 


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (d49f4d4) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **not change** coverage.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@           Coverage Diff           @@
   ##           master     #949   +/-   ##
   =======================================
     Coverage   40.50%   40.50%           
   =======================================
     Files          27       27           
     Lines        1627     1627           
   =======================================
     Hits          659      659           
     Misses        873      873           
     Partials       95       95           
   ```
   
   
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...d49f4d4](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] starsz edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
starsz edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-740584908


   ### Get server_info
   Method: Get
   URI: /apisix/server_info/{id}
   Response:
   ```
   {
       "code":0,
       "message":"",
       "data":{
           "id":1,
           "last_report_time":1607400888,
           "up_time":100,
           "boot_time":1607400745,
           "etcd_version":"3.5.0",
           "hostname":"gentoo",
           "version":"2.0"
       },
       "request_id":"afd668da-5245-40c4-a674-011014a22753"
   }
   ```
   
   ### list server_info
   Method: Get
   URI: /apisix/server_info?hostname={hostname}&page_size={page_size}&page={page}
   Response:
   ```
   {
       "code":0,
       "message":"",
       "data":{
           "rows":[
               {
                   "id":1,
                   "last_report_time":1607400888,
                   "up_time":100,
                   "boot_time":1607400745,
                   "etcd_version":"3.5.0",
                   "hostname":"gentoo",
                   "version":"2.0"
               }
           ],
           "total_size":1
       },
       "request_id":"66f1a516-3ed9-411a-a8dc-9d5cc130fedc"
   }
   ```
   
   |field|value|note|
   |---|---|---|
   |hostname|default ""|If the hostname is not "", the API only returns the server_info whose `hostname` field contains hostname.
   |page_size|default 0|If the `page_size` is larger than zero. The API only returns the `page_size` number value of data per request.
   |page|default 0|If the `page` is lager than zero.The api only returns the [(page-1)\*page_size, page\*page_size).Otherwise it will return whole server_infos.
   ----
   
   BTW, I add `hostname` for filter response if there are lots of apisix instances


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736997856


   This PR still looks like a draft, let's convert it as draft.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan edited a comment on pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736997856






----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] guoqqqi commented on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
guoqqqi commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-748448361


   ![Uploading image.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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-737703894


   Any update?


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] guoqqqi commented on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
guoqqqi commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-740081050


   <img width="2380" alt="WeChate6a77b6a1a56e4931dadb01f48b59a2a" src="https://user-images.githubusercontent.com/72343596/101386461-30ff1380-38f8-11eb-819a-3d6836d3e9d1.png">
   <img width="2396" alt="WeChate114c86b55ebdea37f60761dac054250" src="https://user-images.githubusercontent.com/72343596/101386467-33616d80-38f8-11eb-98fa-c7a11bc2a327.png">
   1. Update the selected node and the corresponding information appears. Wait for the api interface, and then update asynchronously to obtain data.
   2. At present, when the title of the table is first loaded, the data page will crash if it is not obtained. I will comment it out first and I will try to solve it tomorrow.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on a change in pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on a change in pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#discussion_r533904811



##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,99 @@
+import React from 'react';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+const Info: React.FC = () => {
+  const { formatMessage } = useIntl();
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
+      <select className="selector" id="selector" style={{ backgroundColor: "#fff", width: "100%", height: "24px", textAlign: "right", padding: "16px 24px", marginBottom: "15px" }}>
+        <option value="categoryA">CategoryA</option>
+        <option value="categoryB">CategoryB</option>
+        <option value="categoryC">CategoryC</option>
+      </select>
+      <div className="wrap" style={{ width: "100%", height: "740px", padding: "16px 24px", margin: "0 auto", backgroundColor: "#fff" }}>

Review comment:
       Using div and other HTML tags look good to me, but you should move those inline style to a standalone file.

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,99 @@
+import React from 'react';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+const Info: React.FC = () => {
+  const { formatMessage } = useIntl();
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
+      <select className="selector" id="selector" style={{ backgroundColor: "#fff", width: "100%", height: "24px", textAlign: "right", padding: "16px 24px", marginBottom: "15px" }}>
+        <option value="categoryA">CategoryA</option>
+        <option value="categoryB">CategoryB</option>
+        <option value="categoryC">CategoryC</option>
+      </select>
+      <div className="wrap" style={{ width: "100%", height: "740px", padding: "16px 24px", margin: "0 auto", backgroundColor: "#fff" }}>
+        <table style={{ color: "rgba(0, 0, 0, 0.45)", width: "100%", borderBottom: "1px solid grey", borderCollapse: "collapse", borderTop: "1px solid grey" }}>
+          <thead>
+            <tr>
+              <th style={{ padding: "12px 8px" }}>categoryA</th>
+              <th></th>
+            </tr>
+          </thead>
+          <tbody>
+            <tr style={{ backgroundColor: "#f3f4f5" }}>
+              <td style={{ padding: "12px 8px" }}>key</td>
+              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
+            </tr>
+            <tr>
+              <td style={{ padding: "12px 8px" }}>key</td>
+              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
+            </tr>
+            <tr style={{ backgroundColor: "#f3f4f5" }}>
+              <td style={{ padding: "12px 8px" }}>key</td>
+              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
+            </tr>
+            <tr>
+              <td style={{ padding: "12px 8px" }}>key</td>
+              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
+            </tr>
+          </tbody>
+        </table>
+        <table style={{ color: "rgba(0, 0, 0, 0.45)", width: "100%", borderBottom: "1px solid grey", borderCollapse: "collapse", }}>
+          <thead>
+            <tr>
+              <th style={{ padding: "12px 8px" }}>categoryA</th>
+              <th></th>
+            </tr>
+          </thead>
+          <tbody>
+            <tr style={{ backgroundColor: "#f3f4f5" }}>
+              <td style={{ padding: "12px 8px" }}>key</td>
+              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
+            </tr>
+            <tr>
+              <td style={{ padding: "12px 8px" }}>key</td>
+              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
+            </tr>
+            <tr style={{ backgroundColor: "#f3f4f5" }}>
+              <td style={{ padding: "12px 8px" }}>key</td>
+              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
+            </tr>
+            <tr>
+              <td style={{ padding: "12px 8px" }}>key</td>
+              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
+            </tr>
+          </tbody>
+        </table>
+        <table style={{ color: "rgba(0, 0, 0, 0.45)", width: "100%", borderBottom: "1px solid grey", borderCollapse: "collapse", }}>
+          <thead>
+            <tr>
+              <th style={{ padding: "12px 8px" }}>categoryA</th>
+              <th></th>
+            </tr>
+          </thead>
+          <tbody>
+            <tr style={{ backgroundColor: "#f3f4f5" }}>

Review comment:
       Why not use an array loop?

##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,99 @@
+import React from 'react';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+const Info: React.FC = () => {
+  const { formatMessage } = useIntl();
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
+      <select className="selector" id="selector" style={{ backgroundColor: "#fff", width: "100%", height: "24px", textAlign: "right", padding: "16px 24px", marginBottom: "15px" }}>

Review comment:
       1. Use antd's Selector component;

##########
File path: web/src/pages/Info/styles.less
##########
@@ -0,0 +1,6 @@
+@import '~antd/es/style/themes/default.less';
+
+//未引入,将内联css放这里,待执行。

Review comment:
       Only English is allowed for comments.

##########
File path: web/src/pages/Info/locales/en-US.ts
##########
@@ -0,0 +1,3 @@
+export default {
+    'page.info.pageContainer.title': 'About Apache APISIX',

Review comment:
       2 spaces




----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on a change in pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on a change in pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#discussion_r534950777



##########
File path: web/src/pages/Info/List.tsx
##########
@@ -1,96 +1,92 @@
+/*
+ * 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 React from 'react';
+import { Select } from 'antd';
 import { PageContainer } from '@ant-design/pro-layout';
 import { useIntl } from 'umi';
 
 const Info: React.FC = () => {
   const { formatMessage } = useIntl();
+  const { Option } = Select;
+  const mydata = [
+    {
+      "category": "system",
+      "name": "version",
+      "value": "2.0",
+      "name2": "apisix_id",
+      "value2": "2.1",
+    },
+    {
+      "category": "categoryA",
+      "name": "keyA",
+      "value": "valueA",
+      "name2": "customKeyA",
+      "value2": "valueKeyA",
+    },
+    {
+      "category": "categoryB",
+      "name": "keyB",
+      "value": "valueB",
+      "name2": "customKeyB",
+      "value2": "valueKeyB",
+    },
+    {
+      "category": "categoryC",
+      "name": "keyC",
+      "value": "valueC",
+      "name2": "customKeyC",
+      "value2": "valueKeyC",
+    },
+  ];
 
   return (
     <PageContainer title={formatMessage({ id: 'page.info.pageContainer.title' })}>
-      <select className="selector" id="selector" style={{ backgroundColor: "#fff", width: "100%", height: "24px", textAlign: "right", padding: "16px 24px", marginBottom: "15px" }}>
-        <option value="categoryA">CategoryA</option>
-        <option value="categoryB">CategoryB</option>
-        <option value="categoryC">CategoryC</option>
-      </select>
-      <div className="wrap" style={{ width: "100%", height: "740px", padding: "16px 24px", margin: "0 auto", backgroundColor: "#fff" }}>
-        <table style={{ color: "rgba(0, 0, 0, 0.45)", width: "100%", borderBottom: "1px solid grey", borderCollapse: "collapse", borderTop: "1px solid grey" }}>
-          <thead>
-            <tr>
-              <th style={{ padding: "12px 8px" }}>categoryA</th>
-              <th></th>
-            </tr>
-          </thead>
-          <tbody>
-            <tr style={{ backgroundColor: "#f3f4f5" }}>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-            <tr>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-            <tr style={{ backgroundColor: "#f3f4f5" }}>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-            <tr>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-          </tbody>
-        </table>
-        <table style={{ color: "rgba(0, 0, 0, 0.45)", width: "100%", borderBottom: "1px solid grey", borderCollapse: "collapse", }}>
-          <thead>
-            <tr>
-              <th style={{ padding: "12px 8px" }}>categoryA</th>
-              <th></th>
-            </tr>
-          </thead>
-          <tbody>
-            <tr style={{ backgroundColor: "#f3f4f5" }}>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-            <tr>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-            <tr style={{ backgroundColor: "#f3f4f5" }}>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-            <tr>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-          </tbody>
-        </table>
-        <table style={{ color: "rgba(0, 0, 0, 0.45)", width: "100%", borderBottom: "1px solid grey", borderCollapse: "collapse", }}>
-          <thead>
-            <tr>
-              <th style={{ padding: "12px 8px" }}>categoryA</th>
-              <th></th>
-            </tr>
-          </thead>
-          <tbody>
-            <tr style={{ backgroundColor: "#f3f4f5" }}>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-            <tr>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-            <tr style={{ backgroundColor: "#f3f4f5" }}>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-            <tr>
-              <td style={{ padding: "12px 8px" }}>key</td>
-              <td style={{ textAlign: "right", padding: "12px 8px" }}>value</td>
-            </tr>
-          </tbody>
-        </table>
+      <Select
+        showSearch
+        style={{ backgroundColor: "#fff", width: "100%", textAlign: "right", padding: "16px 24px", marginBottom: "15px" }}

Review comment:
       Inline styles should be moved to a `.less`file

##########
File path: web/src/global.less
##########
@@ -45,6 +45,27 @@ ol {
   list-style: none;
 }
 
+.InfoWrap {

Review comment:
       No, this is a global file, not for Info page only.




----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (faf5a85) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/478cbebd82cd7912f8cdac5f85a6086ceea191c2?el=desc) (478cbeb) will **increase** coverage by `0.53%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master     #949      +/-   ##
   ==========================================
   + Coverage   42.95%   43.49%   +0.53%     
   ==========================================
     Files          18       18              
     Lines        1271     1299      +28     
   ==========================================
   + Hits          546      565      +19     
   - Misses        633      642       +9     
     Partials       92       92              
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [api/internal/utils/utils.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL3V0aWxzL3V0aWxzLmdv) | `51.42% <0.00%> (-7.84%)` | :arrow_down: |
   | [api/internal/handler/service/service.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvc2VydmljZS9zZXJ2aWNlLmdv) | `27.65% <0.00%> (-0.61%)` | :arrow_down: |
   | [api/internal/core/entity/query.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L3F1ZXJ5Lmdv) | `0.00% <0.00%> (ø)` | |
   | [api/internal/core/entity/entity.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2VudGl0eS5nbw==) | `0.00% <0.00%> (ø)` | |
   | [api/internal/handler/consumer/consumer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvY29uc3VtZXIvY29uc3VtZXIuZ28=) | `34.92% <0.00%> (ø)` | |
   | [api/internal/handler/route/route.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvcm91dGUvcm91dGUuZ28=) | `46.56% <0.00%> (+0.11%)` | :arrow_up: |
   | [api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=) | `79.22% <0.00%> (+0.93%)` | :arrow_up: |
   | [api/internal/core/store/validate.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvdmFsaWRhdGUuZ28=) | `58.04% <0.00%> (+2.96%)` | :arrow_up: |
   | [api/internal/core/entity/format.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2Zvcm1hdC5nbw==) | `60.46% <0.00%> (+8.08%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [478cbeb...faf5a85](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] guoqqqi commented on a change in pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
guoqqqi commented on a change in pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#discussion_r546219318



##########
File path: web/src/pages/ServerInfo/locales/en-US.ts
##########
@@ -0,0 +1,22 @@
+/*
+ * 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.
+ */
+export default {
+  'page.serverinfo.pageContainer.title': 'Server Info',
+  'page.serverinfo.select.placeholder': 'Please select node',
+  'page.serverinfo.desc': 'The relevant plugin need to be enabled to report server info.',
+  'page.serverinfo.link': ' How to enable?',

Review comment:
       update




----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (295b1c5) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **not change** coverage.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@           Coverage Diff           @@
   ##           master     #949   +/-   ##
   =======================================
     Coverage   40.50%   40.50%           
   =======================================
     Files          27       27           
     Lines        1627     1627           
   =======================================
     Hits          659      659           
     Misses        873      873           
     Partials       95       95           
   ```
   
   
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...295b1c5](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] LiteSun commented on a change in pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
LiteSun commented on a change in pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#discussion_r546218376



##########
File path: web/src/pages/ServerInfo/List.tsx
##########
@@ -0,0 +1,100 @@
+/*
+ * 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 React, { useEffect, useState } from 'react';
+import { Select, Empty, Form } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+import { fetchInfoList } from './service';
+import styles from './style.less';
+
+const ServerInfo: React.FC = () => {
+  const [data, setData] = useState<ServerInfoModule.Node>();
+  const [nodeList, setNodeList] = useState<ServerInfoModule.Node[]>([]);
+  const { formatMessage } = useIntl();
+  const { Option } = Select;
+
+  const [form] = Form.useForm();
+
+  useEffect(() => {
+    fetchInfoList().then((list) => {
+      setNodeList(list);
+      if (list.length) {
+        form.setFieldsValue({
+          nodeId: list[0].id,
+        });
+
+        setData(list[0]);
+      }
+    });
+  }, []);
+
+  return (
+    <PageContainer title={formatMessage({ id: 'page.serverinfo.pageContainer.title' })}>
+      <div className={styles.select}>
+        <Form form={form}>
+          <Form.Item wrapperCol={{ span: 5 }} style={{ marginBottom: 0 }} name="nodeId">
+            <Select
+              placeholder={formatMessage({ id: 'page.serverinfo.select.placeholder' })}
+              onChange={(value) => {
+                setData(
+                  nodeList.find((item) => {
+                    return item.id === value;
+                  }),

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.

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



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (f04c0c2) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **not change** coverage.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@           Coverage Diff           @@
   ##           master     #949   +/-   ##
   =======================================
     Coverage   40.50%   40.50%           
   =======================================
     Files          27       27           
     Lines        1627     1627           
   =======================================
     Hits          659      659           
     Misses        873      873           
     Partials       95       95           
   ```
   
   
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...f04c0c2](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] guoqqqi edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
guoqqqi edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-748448361


   ![image](https://user-images.githubusercontent.com/72343596/102686046-ec407a00-421f-11eb-8677-e74885ca7959.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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-738457818


   This style looks good to me, i will check why that info icon is missing.
   
   Any suggestion for this style? 
   
   cc @moonming @liuxiran @tokers @starsz 


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-738500315


   cc @guoqqqi This PR's checks have failed, just click the details link to see what's happened.
   
   ![image](https://user-images.githubusercontent.com/2106987/101111135-8942c680-3615-11eb-9d6b-c4d0ee268274.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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (13247ac) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **not change** coverage.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@           Coverage Diff           @@
   ##           master     #949   +/-   ##
   =======================================
     Coverage   40.50%   40.50%           
   =======================================
     Files          27       27           
     Lines        1627     1627           
   =======================================
     Hits          659      659           
     Misses        873      873           
     Partials       95       95           
   ```
   
   
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...13247ac](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] LiteSun commented on a change in pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
LiteSun commented on a change in pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#discussion_r546218668



##########
File path: web/src/pages/ServerInfo/locales/en-US.ts
##########
@@ -0,0 +1,22 @@
+/*
+ * 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.
+ */
+export default {
+  'page.serverinfo.pageContainer.title': 'Server Info',
+  'page.serverinfo.select.placeholder': 'Please select node',
+  'page.serverinfo.desc': 'The relevant plugin need to be enabled to report server info.',
+  'page.serverinfo.link': ' How to enable?',

Review comment:
       ```suggestion
     'page.serverinfo.link': 'How to enable?',
   ```
   why whitespace here?




----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] guoqqqi commented on pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
guoqqqi commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-737706517


   > Any update?
   
   Wait a minute, I will update the progress.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io commented on pull request #949: add: Static Info Pages

Posted by GitBox <gi...@apache.org>.
codecov-io commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (61cf310) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/478cbebd82cd7912f8cdac5f85a6086ceea191c2?el=desc) (478cbeb) will **increase** coverage by `0.06%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master     #949      +/-   ##
   ==========================================
   + Coverage   42.95%   43.02%   +0.06%     
   ==========================================
     Files          18       18              
     Lines        1271     1290      +19     
   ==========================================
   + Hits          546      555       +9     
   - Misses        633      643      +10     
     Partials       92       92              
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [api/internal/utils/utils.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL3V0aWxzL3V0aWxzLmdv) | `51.61% <0.00%> (-7.65%)` | :arrow_down: |
   | [api/internal/handler/service/service.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvc2VydmljZS9zZXJ2aWNlLmdv) | `27.65% <0.00%> (-0.61%)` | :arrow_down: |
   | [api/internal/core/entity/query.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L3F1ZXJ5Lmdv) | `0.00% <0.00%> (ø)` | |
   | [api/internal/core/entity/entity.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2VudGl0eS5nbw==) | `0.00% <0.00%> (ø)` | |
   | [api/internal/handler/consumer/consumer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvY29uc3VtZXIvY29uc3VtZXIuZ28=) | `34.92% <0.00%> (ø)` | |
   | [api/internal/handler/route/route.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvcm91dGUvcm91dGUuZ28=) | `46.56% <0.00%> (+0.11%)` | :arrow_up: |
   | [api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=) | `78.57% <0.00%> (+0.28%)` | :arrow_up: |
   | [api/internal/core/entity/format.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2Zvcm1hdC5nbw==) | `60.46% <0.00%> (+8.08%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [478cbeb...61cf310](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan merged pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan merged pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949


   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] guoqqqi commented on pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
guoqqqi commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-738211900


   <img width="2382" alt="WeChat82997997eab173ce6f069a584829fb60" src="https://user-images.githubusercontent.com/72343596/101073196-0c462b80-35da-11eb-87e7-2b5d614068fc.png">
   <img width="2386" alt="WeChatbd644c596d6bd3c38275ea2084d094d5" src="https://user-images.githubusercontent.com/72343596/101073203-11a37600-35da-11eb-8048-3bfddfb27533.png">
   1. After the change, the icon of the information page in the menu bar is still not displayed.
   2. After debugging, click <Select> to search, and <table> is displayed, whether the style needs further optimization.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on a change in pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on a change in pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#discussion_r534956696



##########
File path: web/src/pages/Info/List.tsx
##########
@@ -0,0 +1,95 @@
+/*
+ * 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 React from 'react';
+import { Select } from 'antd';
+import { PageContainer } from '@ant-design/pro-layout';
+import { useIntl } from 'umi';
+
+const Info: React.FC = () => {
+  const { formatMessage } = useIntl();
+  const { Option } = Select;
+  const mydata = [

Review comment:
       Why not use useState? then you could update it by using setXXX

##########
File path: web/config/routes.ts
##########
@@ -23,6 +23,10 @@ const routes = [
     path: '/metrics',
     component: './Metrics',
   },
+  {
+    path: '/info/list',

Review comment:
       `/info` is enough

##########
File path: web/src/helpers.tsx
##########
@@ -22,9 +22,15 @@ import moment from 'moment';
 
 import { codeMessage } from './constants';
 import IconFont from './iconfont';
+import InfoCircleOutlined from '@ant-design/icons';

Review comment:
       move this line to the top




----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] guoqqqi commented on pull request #949: feat: info page

Posted by GitBox <gi...@apache.org>.
guoqqqi commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-737734457


   At present, an onChange function needs to be added to make the Select component and the table linkage.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197






----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-748418233


   https://github.com/apache/apisix-dashboard/pull/1076
   
   We use `/apisix/admin` as prefix.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] guoqqqi commented on a change in pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
guoqqqi commented on a change in pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#discussion_r546219318



##########
File path: web/src/pages/ServerInfo/locales/en-US.ts
##########
@@ -0,0 +1,22 @@
+/*
+ * 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.
+ */
+export default {
+  'page.serverinfo.pageContainer.title': 'Server Info',
+  'page.serverinfo.select.placeholder': 'Please select node',
+  'page.serverinfo.desc': 'The relevant plugin need to be enabled to report server info.',
+  'page.serverinfo.link': ' How to enable?',

Review comment:
       updated 




----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-740376380


   ## APIs
   
   ### Fetch Node List
   TODO
   
   ### Fetch Node Detail
   ```json
   {
       "id": "ddea4053-4ffd-4f09-b176-b8c5e919916b",
       "hostname": "localhost.local",
       "version": "2.0",
       "etcd_version": "3.5.0",
       "uptime": 3600,
       "last_report_at": 1606121591,
       "boot_time": 1606121501
   }
   ```


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (9477459) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **decrease** coverage by `0.06%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master     #949      +/-   ##
   ==========================================
   - Coverage   40.50%   40.44%   -0.07%     
   ==========================================
     Files          27       27              
     Lines        1627     1627              
   ==========================================
   - Hits          659      658       -1     
   - Misses        873      874       +1     
     Partials       95       95              
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=) | `78.57% <0.00%> (-0.65%)` | :arrow_down: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...9477459](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (3c16f9e) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **not change** coverage.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@           Coverage Diff           @@
   ##           master     #949   +/-   ##
   =======================================
     Coverage   40.50%   40.50%           
   =======================================
     Files          27       27           
     Lines        1627     1627           
   =======================================
     Hits          659      659           
     Misses        873      873           
     Partials       95       95           
   ```
   
   
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...3c16f9e](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (cf1e987) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/478cbebd82cd7912f8cdac5f85a6086ceea191c2?el=desc) (478cbeb) will **increase** coverage by `1.08%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master     #949      +/-   ##
   ==========================================
   + Coverage   42.95%   44.04%   +1.08%     
   ==========================================
     Files          18       18              
     Lines        1271     1310      +39     
   ==========================================
   + Hits          546      577      +31     
   - Misses        633      642       +9     
   + Partials       92       91       -1     
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [api/internal/utils/utils.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL3V0aWxzL3V0aWxzLmdv) | `51.42% <0.00%> (-7.84%)` | :arrow_down: |
   | [api/internal/handler/service/service.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvc2VydmljZS9zZXJ2aWNlLmdv) | `27.65% <0.00%> (-0.61%)` | :arrow_down: |
   | [api/internal/core/entity/query.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L3F1ZXJ5Lmdv) | `0.00% <0.00%> (ø)` | |
   | [api/internal/core/entity/entity.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2VudGl0eS5nbw==) | `0.00% <0.00%> (ø)` | |
   | [api/internal/handler/consumer/consumer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvY29uc3VtZXIvY29uc3VtZXIuZ28=) | `34.92% <0.00%> (ø)` | |
   | [api/internal/handler/route/route.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvcm91dGUvcm91dGUuZ28=) | `46.56% <0.00%> (+0.11%)` | :arrow_up: |
   | [api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=) | `79.22% <0.00%> (+0.93%)` | :arrow_up: |
   | [api/internal/core/store/validate.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvdmFsaWRhdGUuZ28=) | `61.68% <0.00%> (+6.61%)` | :arrow_up: |
   | [api/internal/core/entity/format.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2Zvcm1hdC5nbw==) | `60.46% <0.00%> (+8.08%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [478cbeb...cf1e987](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (417ea70) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **not change** coverage.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@           Coverage Diff           @@
   ##           master     #949   +/-   ##
   =======================================
     Coverage   40.50%   40.50%           
   =======================================
     Files          27       27           
     Lines        1627     1627           
   =======================================
     Hits          659      659           
     Misses        873      873           
     Partials       95       95           
   ```
   
   
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...417ea70](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-748452060


   E2E failed @nic-chen 


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (e9790a0) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **not change** coverage.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@           Coverage Diff           @@
   ##           master     #949   +/-   ##
   =======================================
     Coverage   40.50%   40.50%           
   =======================================
     Files          27       27           
     Lines        1627     1627           
   =======================================
     Hits          659      659           
     Misses        873      873           
     Partials       95       95           
   ```
   
   
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...e9790a0](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] starsz commented on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
starsz commented on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-740584908


   ### Get server_info
   Method: Get
   URI: /apisix/server_info/{id}
   Response:
   ```
   {
       "code":0,
       "message":"",
       "data":{
           "id":1,
           "last_report_time":1607400888,
           "up_time":100,
           "boot_time":1607400745,
           "etcd_version":"3.5.0",
           "hostname":"gentoo",
           "version":"2.0"
       },
       "request_id":"afd668da-5245-40c4-a674-011014a22753"
   }
   ```
   
   ### list server_info
   Method: Get
   URI: /apisix/server_info?hostname={hostname}&page_size={page_size}&page={page}
   Response:
   ```
   {
       "code":0,
       "message":"",
       "data":{
           "rows":[
               {
                   "id":1,
                   "last_report_time":1607400888,
                   "up_time":100,
                   "boot_time":1607400745,
                   "etcd_version":"3.5.0",
                   "hostname":"gentoo",
                   "version":"2.0"
               }
           ],
           "total_size":2
       },
       "request_id":"66f1a516-3ed9-411a-a8dc-9d5cc130fedc"
   }
   ```
   
   |field|value|note|
   |---|---|---|
   |hostname|default ""|If the hostname is not "", the API only returns the server_info whose `hostname` field contains hostname.
   |page_size|default 0|If the `page_size` is larger than zero. The API only returns the `page_size` number value of data per request.
   |page|default 0|If the `page` is lager than zero.The api only returns the [(page-1)\*page_size, page\*page_size).Otherwise it will return whole server_infos.
   ----
   
   BTW, I add `hostname` for filter response if there are lots of apisix instances


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (d3e5114) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/478cbebd82cd7912f8cdac5f85a6086ceea191c2?el=desc) (478cbeb) will **increase** coverage by `0.53%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master     #949      +/-   ##
   ==========================================
   + Coverage   42.95%   43.49%   +0.53%     
   ==========================================
     Files          18       18              
     Lines        1271     1299      +28     
   ==========================================
   + Hits          546      565      +19     
   - Misses        633      642       +9     
     Partials       92       92              
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [api/internal/utils/utils.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL3V0aWxzL3V0aWxzLmdv) | `51.42% <0.00%> (-7.84%)` | :arrow_down: |
   | [api/internal/handler/service/service.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvc2VydmljZS9zZXJ2aWNlLmdv) | `27.65% <0.00%> (-0.61%)` | :arrow_down: |
   | [api/internal/core/entity/query.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L3F1ZXJ5Lmdv) | `0.00% <0.00%> (ø)` | |
   | [api/internal/core/entity/entity.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2VudGl0eS5nbw==) | `0.00% <0.00%> (ø)` | |
   | [api/internal/handler/consumer/consumer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvY29uc3VtZXIvY29uc3VtZXIuZ28=) | `34.92% <0.00%> (ø)` | |
   | [api/internal/handler/route/route.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvcm91dGUvcm91dGUuZ28=) | `46.56% <0.00%> (+0.11%)` | :arrow_up: |
   | [api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=) | `79.22% <0.00%> (+0.93%)` | :arrow_up: |
   | [api/internal/core/store/validate.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvdmFsaWRhdGUuZ28=) | `58.04% <0.00%> (+2.96%)` | :arrow_up: |
   | [api/internal/core/entity/format.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2Zvcm1hdC5nbw==) | `60.46% <0.00%> (+8.08%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [478cbeb...d3e5114](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (f8ffd4f) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **not change** coverage.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@           Coverage Diff           @@
   ##           master     #949   +/-   ##
   =======================================
     Coverage   40.50%   40.50%           
   =======================================
     Files          27       27           
     Lines        1627     1627           
   =======================================
     Hits          659      659           
     Misses        873      873           
     Partials       95       95           
   ```
   
   
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...f8ffd4f](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] juzhiyuan commented on a change in pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on a change in pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#discussion_r546210483



##########
File path: web/src/pages/Info/locales/en-US.ts
##########
@@ -15,5 +15,5 @@
  * limitations under the License.
  */
 export default {
-  'page.info.pageContainer.title': 'About Apache APISIX',
+  'page.info.pageContainer.title': 'Server info',

Review comment:
       Info

##########
File path: web/src/pages/Info/service.ts
##########
@@ -19,14 +19,14 @@ import { request } from 'umi';
 // Waiting for api.
 export const fetchInfoList = () => {
   return request<Res<ResListData<NodeListData>>>(
-    '/server_info?hostname={hostname}&page_size={page_size}&page={page}',
+    `/server_info`,

Review comment:
       ''

##########
File path: web/src/pages/Info/typing.d.ts
##########
@@ -15,16 +15,21 @@
  * limitations under the License.
  */
 type NodeDetail = {
-  id: string;
+  id: number;
+  last_report_time: number;
+  up_time: number;
+  boot_time: number;
+  etcd_version: string;
   hostname: string;
   version: string;
-  etcd_version: string;
-  uptime: number;
-  last_report_at: number;
-  boot_time: number;
 };
 
 type NodeListData = {

Review comment:
       ?

##########
File path: web/src/pages/Info/service.ts
##########
@@ -19,14 +19,14 @@ import { request } from 'umi';
 // Waiting for api.
 export const fetchInfoList = () => {
   return request<Res<ResListData<NodeListData>>>(
-    '/server_info?hostname={hostname}&page_size={page_size}&page={page}',
+    `/server_info`,
   ).then(({ data }) => ({
-    data: data.rows,
+    data: data.rows
   }));
 };
 
 export const fetchInfoData = () => {

Review comment:
       remove this 




----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [apisix-dashboard] codecov-io edited a comment on pull request #949: feat: added info page

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #949:
URL: https://github.com/apache/apisix-dashboard/pull/949#issuecomment-736991197


   # [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=h1) Report
   > Merging [#949](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=desc) (398f9e1) into [master](https://codecov.io/gh/apache/apisix-dashboard/commit/c6f730b2d8a232916ccb006cf8e20923f59023cf?el=desc) (c6f730b) will **decrease** coverage by `0.06%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/apisix-dashboard/pull/949/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P)](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master     #949      +/-   ##
   ==========================================
   - Coverage   40.50%   40.44%   -0.07%     
   ==========================================
     Files          27       27              
     Lines        1627     1627              
   ==========================================
   - Hits          659      658       -1     
   - Misses        873      874       +1     
     Partials       95       95              
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/949/diff?src=pr&el=tree#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=) | `78.57% <0.00%> (-0.65%)` | :arrow_down: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=footer). Last update [c6f730b...398f9e1](https://codecov.io/gh/apache/apisix-dashboard/pull/949?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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:
users@infra.apache.org