1.匯入 data source 後,在 Edit panel 右方找到 overrides,點選 +Add field override
Learn More →
2.選擇 field with name,找到你想做 value mapping 的欄位
Learn More →
3.選擇 +Add override property,找到 Value mappings > value mappings
Learn More →
4.選擇 Add value mappings,在 Condition 欄位填入想進行 mapping 的值(有四種輸入格式: value, range, regex, special),並在 Display text 填入要對應顯示的文字或符號
Learn More →
Condition 這邊我輸入格式以 range 做示範
value: 0~30 -> bad, 31~60 -> normal, 61~100 -> good
Learn More →
5.Update後即完成! 檢查 value 是否有依預期的判斷式進行變化
Learn More →
1.在 +Add override property 新增 Cell display mode,並將預設的 Auto 改成 color text 指定更改文字顏色(選擇 color background 可以更改欄位底色)
Learn More →
2.在 value mappings 裡右邊的 Color 選擇顏色
Learn More →
3.文字顏色變更完成!
Learn More →
Grafana
tips
value mapping
一、Grafana 下載 & 登入 官方下載連結: https://grafana.com/grafana/download Version: Grafana 版本,本篇是選擇使用 v8.4.4 Edition: 選擇OSS(Open Source Software) 作業系統: 依照自身電腦選擇對應的即可 預設 port 為3000,網址: localhost:3000 預設登入帳號/密碼 : admin / admin
Aug 12, 2022如果想對下圖登入介面的紅框處 "Welcome to Grafana" 以及藍框處的分頁 Title 進行修改,可以參考本文的做法 1.打開資料夾 ...\grafana\public\build 2.以編輯器打開檔案 5893.****.js,如果找不到該名稱的檔案請參考下方補充的方法 3.搜尋 AppTitle 找到 o(l,"AppTitle","填入你想要的title") 進行修改 重新打開 Grafana 登入畫面發現分頁 Title 已經修改完成 (如果沒成功的話可以嘗試以訪客模式打開 http://localhost:3000)
Aug 12, 2022明明 MySQL 資料庫裡的 timestamp 已經是GMT+8的時間了,但在 Grafana 裡又因為時區 而自動幫你+8小時,導致資料的 timestamp 有錯誤,對觀看者的體驗影響很大 1.我們將以下 SQL Query 分別輸入至 MySQL 跟 Grafana SELECT dt as 'time', val FROM demo ORDER BY dt
Aug 5, 20221.進入 edit panel 中,找到 Query options 設定 2.將 Relative time 填入想要的時間範圍(從 now 往前推所填入的時間,s=秒 m=分 h=時 d=日) ++註:可以填入 variable 讓 relative time 隨著 variable 的輸入而改變,不用進入 edit panel 修改++ 3.即可讓該 panel 不受右上角的 absolute time range 影響而變化 如果想將右上角的 Last XXX 關掉,把 Hide time info 打開就會消失了
Aug 4, 2022or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up