Fine0830 commented on a change in pull request #488:
URL: 
https://github.com/apache/skywalking-rocketbot-ui/pull/488#discussion_r631603720



##########
File path: src/views/components/trace/trace-detail.vue
##########
@@ -40,6 +40,13 @@ limitations under the License. -->
         </svg>
       </div>
 
+
+      <a class="rk-btn mr-5 sm r" :class="{ ghost: displayMode !== 
'statistics' }" @click="displayMode = 'statistics'">
+        <svg class="icon vm sm">

Review comment:
       Please use `rk-icon` component instead this

##########
File path: 
src/views/components/common/trace-chart-table/trace-statistics-container.vue
##########
@@ -0,0 +1,131 @@
+<!-- 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. -->
+
+<template>
+  <div class="trace">
+    <div class="trace-header">
+      <div :class="item.label" v-for="(item, index) in data" :key="index">
+        {{ item.value }}
+        <span class="r cp" @click="sortFunc(item.key)" :key="componentKey" 
v-if="item.key != 'endpointName'">
+          <svg class="icon">
+            <use xlink:href="#sort"></use>
+          </svg>
+        </span>
+      </div>
+    </div>
+    <Item :method="method" v-for="(item, index) in tableData" :data="item" 
:key="'key' + index" />
+    <slot></slot>
+  </div>
+</template>
+<script lang="js">

Review comment:
       Please use `ts`

##########
File path: 
src/views/components/common/trace-chart-table/trace-statistics-item.vue
##########
@@ -0,0 +1,84 @@
+<!-- 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. -->
+
+<template>
+  <div>
+    <div :class="['trace-item']" ref="traceItem">
+      <div :class="['method']" :style="{ 'text-indent': 10 + 'px', width: 
`${method}px` }">
+        <span v-tooltip:bottom="{ content: data.endpointName, popperCls: 
['trace-table-tooltip'] }">
+          {{ data.endpointName }}
+        </span>
+      </div>
+
+      <div class="max-time">
+        {{ data.maxTime }}
+      </div>
+      <div class="avg-time">
+        {{ parseInt(data.avgTime) }}
+      </div>
+      <div class="min-time">
+        {{ data.minTime }}
+      </div>
+      <div class="sum-time">
+        {{ data.sumTime }}
+      </div>
+      <div class="count">
+        {{ data.count }}
+      </div>
+    </div>
+  </div>
+</template>
+<script lang="js">

Review comment:
       Please use `ts`

##########
File path: src/views/components/common/trace-detail-statistics-table.vue
##########
@@ -0,0 +1,326 @@
+<!-- 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. -->
+<template>
+  <div class="trace-detail-chart-table">
+    <div class="rk-trace-t-loading" v-show="loading">
+      <svg class="icon loading">
+        <use xlink:href="#spinner"></use>
+      </svg>
+    </div>
+    <TraceContainer :tableData="tableData" :type="HeaderType">
+      <div class="trace-tips" v-if="!tableData.length">{{ $t('noData') }}</div>
+    </TraceContainer>
+  </div>
+</template>
+<style lang="scss">
+  .rk-tooltip-popper.trace-table-tooltip .rk-tooltip-inner {
+    max-width: 600px;
+  }
+  .trace-detail-chart-table {
+    position: relative;
+    min-height: 300px;
+    border-bottom: 1px solid #ccc;
+  }
+</style>
+
+<script lang="js">

Review comment:
       This component is same as common/trace-detail-chart-table . Please reuse 
existing components rather than creating a same components.




-- 
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:
[email protected]


Reply via email to