diff --git a/src/store/data.ts b/src/store/data.ts index fbff8ab7..2bcec6ff 100644 --- a/src/store/data.ts +++ b/src/store/data.ts @@ -34,7 +34,7 @@ export const ConfigData: any = { h: 12, i: "0", metrics: ["service_resp_time"], - queryMetricType: "readMetricsValues", + metricTypes: ["readMetricsValues"], type: "Widget", widget: { title: "Title", diff --git a/src/store/modules/dashboard.ts b/src/store/modules/dashboard.ts index 60b4185b..90936f7d 100644 --- a/src/store/modules/dashboard.ts +++ b/src/store/modules/dashboard.ts @@ -173,10 +173,10 @@ export const dashboardStore = defineStore({ return res.data; }, async fetchMetricValue(config: LayoutConfig) { - // if (!config.queryMetricType) { + // if (!config.metricTypes) { // return; // } - config.queryMetricType = "readMetricsValues"; + // config.metricTypes = "readMetricsValues"; const appStoreWithOut = useAppStoreWithOut(); const variable = { condition: { @@ -190,7 +190,7 @@ export const dashboardStore = defineStore({ duration: appStoreWithOut.durationTime, }; const res: AxiosResponse = await graph - .query(config.queryMetricType) + .query("readMetricsValues") .params(variable); return res.data; diff --git a/src/styles/reset.scss b/src/styles/reset.scss index 02c8d106..b65abdb9 100644 --- a/src/styles/reset.scss +++ b/src/styles/reset.scss @@ -24,7 +24,6 @@ body { sans-serif; text-rendering: optimizeLegibility; text-size-adjust: 100%; - text-size-adjust: 100%; } html, @@ -124,89 +123,3 @@ code, pre { font-family: Consolas, Menlo, Courier, monospace; } - -/* webkit core */ -.scroll_hide::-webkit-scrollbar { - width: 0; - height: 0; -} - -.scroll_hide::-webkit-scrollbar-button { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-webkit-scrollbar-track { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-webkit-scrollbar-track-piece { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-webkit-scrollbar-thumb { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-webkit-scrollbar-corner { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-webkit-scrollbar-resizer { - background-color: rgb(0 0 0 / 0%); -} - -/* o core */ -.scroll_hide .-o-scrollbar { - appearance: none !important; - background: rgb(0 255 0 / 0%) !important; -} - -.scroll_hide::-o-scrollbar-button { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-o-scrollbar-track { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-o-scrollbar-track-piece { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-o-scrollbar-thumb { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-o-scrollbar-corner { - background-color: rgb(0 0 0 / 0%); -} - -.scroll_hide::-o-scrollbar-resizer { - background-color: rgb(0 0 0 / 0%); -} - -/* IE10,IE11,IE12 */ -.scroll_hide { - -ms-scroll-chaining: chained; - -ms-overflow-style: none; - -ms-content-zooming: zoom; - -ms-scroll-rails: none; - -ms-content-zoom-limit-min: 100%; - -ms-content-zoom-limit-max: 500%; - scroll-snap-points-x: snaplist(100%, 200%, 300%, 400%, 500%); - overflow: auto; -} - -.scroll_bar_style::-webkit-scrollbar { - width: 9px; - height: 6px; -} - -.scroll_bar_style::-webkit-scrollbar-track { - background-color: #3d444f; -} - -.scroll_bar_style::-webkit-scrollbar-thumb { - border-radius: 5px; - background: rgb(196 200 225 / 20%); -} diff --git a/src/types/dashboard.ts b/src/types/dashboard.ts index 1bd2e6b7..6d4459cf 100644 --- a/src/types/dashboard.ts +++ b/src/types/dashboard.ts @@ -25,7 +25,7 @@ export interface LayoutConfig { standard?: StandardConfig; metrics?: string[]; type?: string; - queryMetricType?: string; + metricTypes?: string[]; children?: any; } diff --git a/src/views/dashboard/configuration/ConfigEdit.vue b/src/views/dashboard/configuration/ConfigEdit.vue index 7c69c52e..ac7fc9e3 100644 --- a/src/views/dashboard/configuration/ConfigEdit.vue +++ b/src/views/dashboard/configuration/ConfigEdit.vue @@ -39,43 +39,11 @@ limitations under the License. --> :style="{ '--el-collapse-header-font-size': '15px' }" > -
- -
-
- - - -
+
@@ -121,15 +89,12 @@ limitations under the License. -->
+ diff --git a/src/views/dashboard/controls/Widget.vue b/src/views/dashboard/controls/Widget.vue index f757782c..3ed1a26b 100644 --- a/src/views/dashboard/controls/Widget.vue +++ b/src/views/dashboard/controls/Widget.vue @@ -121,7 +121,7 @@ export default defineComponent({ } } watch( - () => [props.data.queryMetricType, props.data.metrics], + () => [props.data.metricTypes, props.data.metrics], (data, old) => { if (data[0] === old[0] && data[1] === old[1]) { return; diff --git a/src/views/dashboard/data.ts b/src/views/dashboard/data.ts index 40053266..c6e4612d 100644 --- a/src/views/dashboard/data.ts +++ b/src/views/dashboard/data.ts @@ -92,7 +92,7 @@ export enum MetricsType { HEATMAP = "HEATMAP", SAMPLED_RECORD = "SAMPLED_RECORD", } -export const ValuesTypes: { +export const MetricTypes: { [key: string]: Array<{ label: string; value: string }>; } = { REGULAR_VALUE: [ diff --git a/src/views/dashboard/graphs/EndpointList.vue b/src/views/dashboard/graphs/EndpointList.vue index 2ed83c5f..9bd742f7 100644 --- a/src/views/dashboard/graphs/EndpointList.vue +++ b/src/views/dashboard/graphs/EndpointList.vue @@ -17,7 +17,7 @@ limitations under the License. -->