Commit Graph

318 Commits

Author SHA1 Message Date
Jocelyn Collado-Kuri
127367464e Standardization across Zabbix UI components (#2141)
## Summary

Throughout Zabbix we did not have a uniform UI - some drop-down were
using `Select` others `Combobox` others a custom one that we created.
Some had placeholders and others did not. This PR aims to standardize
our Zabbix UI across our query, variable and config editors

## Detailed summary 

- Migrate from `Select` to `Combobox` -> `Select` component is
deprecated
- Migrate from `HorizontalGroup` to `Stack` -> `HorizontalGroup` is also
deprecated
- Remove use of "custom" dropdown `MetricPickerMenu` in favor of
`Combobox` ensuring uniformity across our drop-down and removing
maintenance overhead for us down the line
- Standardize placeholders across all inputs

<img width="630" height="243" alt="Screenshot 2025-12-17 at 1 13 45 PM"
src="https://github.com/user-attachments/assets/9382057e-b443-4474-a9c8-850086d7f3d4"
/>

<img width="691" height="256" alt="Screenshot 2025-12-17 at 1 14 05 PM"
src="https://github.com/user-attachments/assets/a05ff2af-8603-4752-8d12-337dc381c0fd"
/>

## Why
To have a clean and standard UI and remove use of UI deprecated
packages.

## How to test
- Query Editor:
- By creating a new query in a dashboard or Explore and interacting with
all the different query types and drop-downs
     - All drop-downs should be searchable and have placeholders
- Config Editor:
- By going to a datasource and ensuring that the dropdown for Datasource
(when DB connection is enabled) and Auth type are responsive and working
as expected)


Fixes:
https://github.com/orgs/grafana/projects/457/views/40?pane=issue&itemId=3740545830&issue=grafana%7Coss-big-tent-squad%7C139
2025-12-18 14:28:29 +00:00
ismail simsek
cc492b916d Update react-table to v8 (#2131)
Updating react-table to v8. 
- Migrating the existing table to v8
- Preserving the visuals and logic

What's done?
- Cell components are moved under `Cells` folder
- Old styles for react-table-6 is removed.
- Old types are removed
- All logic was preserved
- Some cell components are removed for simplicity


Fixes: https://github.com/grafana/oss-big-tent-squad/issues/125
2025-12-10 19:25:04 +01:00
ismail simsek
3da36ec2bb Chore: Convert problems to functional component (#2125)
This is a prerequisite for ugrading the react-table to v8.
- No logic change is introduced. 
- Update DataSourceRef imports. The old import was deprecated.
2025-12-03 14:55:35 +01:00
HH-Harry
b7adcea1fb More info about acknowledges from zabbix (#2071)
This PR is trying to add functionality requested in [#2061 More info
about acknowledges from
zabbix](https://github.com/grafana/grafana-zabbix/issues/2061)

### Key features

- already described in [Enhancement
request](https://github.com/grafana/grafana-zabbix/issues/2061)

### How It Works

- using bitwise AND checks of [**action** field in zabbix
event.acknowledges](https://www.zabbix.com/documentation/current/en/manual/api/reference/event/acknowledge)
keywords are added at beginning of ack.message field on problem panel in
grafana in fllowing order:
  - (un)acknowledged
  - (un)supressed
  - changed severity

### Testing
- No testing was done, sorry

---------

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2025-09-18 14:18:47 +02:00
github-actions[bot]
b13d567eee chore: bump @grafana/create-plugin configuration to 5.26.4 (#2082)
Bumps
[`@grafana/create-plugin`](https://github.com/grafana/plugin-tools/tree/main/packages/create-plugin)
configuration from 4.2.1 to 5.26.4.

**Notes for reviewer:**
This is an auto-generated PR which ran `@grafana/create-plugin update`.
Please consult the create-plugin
[CHANGELOG.md](https://github.com/grafana/plugin-tools/blob/main/packages/create-plugin/CHANGELOG.md)
to understand what may have changed.
Please review the changes thoroughly before merging.

---------

Co-authored-by: grafana-plugins-platform-bot[bot] <144369747+grafana-plugins-platform-bot[bot]@users.noreply.github.com>
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2025-09-17 20:33:12 +02:00
Christos Diamantis
30c0b0e982 Ability to execute "Manual event actions" on Zabbix Problems panel (#2024)
This PR resolves the below issues:
#2022 #1465 

Specifically, when executing a script on the problems panel, we do check
if the script scope is event or host.
Based on the script scope, the Zabbix API call is constructed
differently.

---------

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2025-07-09 13:56:14 +00:00
Zoltán Bedi
c0d212d3ae Feat: add option to show data source name (#2007)
Original [PR](https://github.com/grafana/grafana-zabbix/pull/2003)

Fixes #1766

---------

Co-authored-by: olaf <olaf@initworks.com>
2025-05-05 13:39:04 +02:00
Sriram
f4376363eb Fix problems panel broken when selecting triggers (#1960)
This PR fixes an issue where the problems panel breaks when you change
to query type to `Triggers`.

![](https://grafana.zendesk.com/attachments/token/MNBgVTPRKZkwa6TsMBbtBQdIp/?name=image.png)

How to reproduce:

1. Go to `Zabbix data source features` dashboard
2. Open Problems panel
3. Change`Query type` to `Triggers`
4. Select `Problems` from `Count by`
5. Change the `Group` to `Backend`
6. The problems panel should not error

---------

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2025-02-24 11:01:08 +01:00
Sriram
c4065fb0f3 config updates (#1800)
* cleanup

* update create plugin config and query help fix

* query types file

* Update docker-compose.yml

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>

* addressed review comments

---------

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2024-03-13 15:20:53 +00:00
Gareth Dawson
c9f515686c legacy form migration 2023-11-14 15:41:36 +00:00
Gábor Farkas
313a166be6 prettier fixes 2023-09-29 13:34:51 +02:00
Gareth Dawson
fd616b6446 track executed queries and panel clicks 2023-09-13 12:30:58 +01:00
Alexander Zobnin
308a6a1d46 Problems: fix pagination, fixes #1649 2023-08-01 16:15:34 +02:00
Alexander Zobnin
713678a32e Fix lastchange time in Problems list, closes #1596 2023-03-23 12:59:49 +01:00
Alexander Zobnin
f7150f9281 Show acknowledge author, fixes #1281
Also fix displaying time
2023-03-21 14:00:17 +01:00
Alexander Zobnin
f1c3c57c9f Fix uppercase label 2023-03-21 13:03:14 +01:00
Alexander Zobnin
41d292c51d Problems: Add operational data field, closes #1260 2023-01-20 16:52:48 +01:00
Alexander Zobnin
bc62e35477 Problems: Allow HTML in description (#1559)
* Problems: allow HTML in problem description, closes #1557

* Don't replace new line with <br>

* Replace line brakes with <br> if allowDangerousHTML enabled

* List layout: only show html formatted description if option is enabled
2023-01-20 15:11:12 +01:00
Alexander Zobnin
a5c239f77b Problems count mode (#1493)
* Problems count mode

* Use tooltip from grafana ui

* Add editors for new modes

* Fix macro mode

* Fix bugs

* Unify editors to use one Triggers editor for all count queries

* Use time range toggle for triggers query, #918

* Add item tags suport for triggers count mode

* Fix triggers count by items

* Use data frames for triggers data, #1441

* Return empty result if no items found

* Add migration for problems count mode

* bump version to 4.3.0-pre

* Add zip task to makefile

* Add schema to query model

* Minor refactor

* Refactor: move components to separate files

* Minor refactor

* Support url in event tags

* Add tooltip with link url

* Update grafana packages

* Fix adding new problems panel

* ProblemDetails: rewrite as a functional component

* minor refactor
2023-01-20 14:23:46 +01:00
Alexander Zobnin
445b46a6aa Fix host maintenance label 2022-12-29 16:48:03 +01:00
Alexander Zobnin
e3e896742b Build plugin with grafana toolkit (#1539)
* Use grafana toolkit template for building plugin

* Fix linter and type errors

* Update styles building

* Fix sass deprecation warning

* Remove empty js files produced by webpack building sass

* Fix signing script

* Replace classnames with cx

* Fix data source config page

* Use custom webpack config instead of overriding original one

* Use gpx_ prefix for plugin executable

* Remove unused configs

* Roll back react hooks dependencies usage

* Move plugin-specific ts config to root config file

* Temporary do not use rst2html for function description tooltip

* Remove unused code

* remove unused dependencies

* update react table dependency

* Migrate tests to typescript

* remove unused dependencies

* Remove old webpack configs

* Add sign target to makefile

* Add magefile

* Update CI test job

* Update go packages

* Update build instructions

* Downgrade go version to 1.18

* Fix go version in ci

* Fix metric picker

* Add comment to webpack config

* remove angular mocks

* update bra config

* Rename datasource-zabbix to datasource (fix mage build)

* Add instructions for building backend with mage

* Fix webpack targets

* Fix ci backend tests

* Add initial e2e tests

* Fix e2e ci tests

* Update docker compose for cypress tests

* build grafana docker image

* Fix docker stop task

* CI: add Grafana compatibility check
2022-12-09 14:14:34 +03:00
Alexander Zobnin
8aebc649db Problems: deactivate tooltip with hint for tags 2022-11-30 12:17:46 +01:00
Alexander Zobnin
9b2079c1da Migrate problems panel to React (#1532)
* Replace default angular app config editor

* Problems panel: migrate module to ts

* Problems panel options editor to react

* Problems panel react WIP

* Fix explore button

* Problems panel alert list layout WIP

* Refactor

* Minor tweaks on panel options

* remove outdated tests

* Update typescript

* Draft for tag event handling

* Remove unused files
2022-11-30 14:01:21 +03:00
Alexander Zobnin
504c9af226 Migrate query editor to react (#1520)
* Initial react query editor

* CI: run checks on all branches

* Update react packages

* Initial metric picker

* Load metrics

* Tweak styles

* Add variables to metric options

* Tweak styles

* Filtering and keyboard navigation

* Open menu with keyboard

* Update function editor

* Move functions in editor

* Add function component

* Edit func params

* Push alias functions to the end

* Tweak labels size

* Fix menu position

* Metric options editor

* Fix css styles building

* More work on query options

* Fix tests

* Refactor: extract metrics query editor and functions editor

* Refactor: move things around

* Text metrics editor

* Problems query editor

* Problems mode options

* Item id query editor

* IT services query editor

* Triggers query editor

* Refactor: remove unused

* remove derprecated theme usage

* Load proxy options

* Fetch metric options on variable change

* Remove angular query editor

* Migrate annotations editor to react

* Fix tests
2022-11-09 17:50:13 +03:00
Alexander Zobnin
c7c9412a14 Fix problems list panel error in new Grafana version 2022-04-18 16:19:57 +03:00
Alexander Zobnin
657bf771a4 Use tooltip from grafana/ui 2022-02-15 18:22:02 +03:00
Alexander Zobnin
709e3ff65a Fix type errors (tests are failed) 2022-02-15 18:08:13 +03:00
Alexander Zobnin
edde2bdf33 Fix error when opening problem details, #1357 2022-01-27 13:56:51 +03:00
Alexander Zobnin
2a6642811e Tweak problem details styles 2021-08-10 14:05:16 +03:00
Alexander Zobnin
8499d726b2 Fix Explore button, fixes #1240
Also pass dashboard time range to the explore view.
2021-08-09 17:55:37 +03:00
Alexander Zobnin
7af0d6a189 Fix tests 2021-08-06 14:40:46 +03:00
Alexander Zobnin
201d6cb19a Fix problem details layout, fixes #1252 2021-08-03 13:57:26 +03:00
Alexander Zobnin
12c4089a50 Fix building after update to Grafana 8 components 2021-08-02 18:37:48 +03:00
Alexander Zobnin
a596d3e18a update grafana packages 2021-03-09 18:23:34 +03:00
Alexander Zobnin
fdaadaf83e Problems: show item value in tooltip, fix #1145 2021-02-04 13:35:23 +03:00
Alexander Zobnin
cee10f54bf Preserve expanded problems, fix #1143 2021-01-20 15:27:19 +03:00
Alexander Zobnin
e6bf021ad3 Problems: don't limit ack message, fix #1122 2020-12-28 11:47:59 +03:00
Alexander Zobnin
0de6403be4 Problems: fix empty query editor, #988 2020-11-17 18:23:38 +03:00
Alexander Zobnin
965216a607 Chore: clean up 2020-11-09 18:37:10 +03:00
Alexander Zobnin
28488cecff Problems: fix long item values displaying 2020-11-09 17:54:57 +03:00
Alexander Zobnin
0206ad1448 Fix problems panel tests 2020-08-25 16:03:23 +03:00
Alexander Zobnin
804cc1cac6 Problems: invoke renderingCompleted() to update panelsRendered variable, fix #1016 2020-08-25 13:06:03 +03:00
Alexander Zobnin
83077f6723 Problems: fix sorting by severity, fixes #921 2020-08-06 13:28:21 +03:00
Alexander Zobnin
cf7f864112 Problems: show tooltip with full description 2020-07-21 13:18:26 +03:00
Alexander Zobnin
2bd04e9c22 fix tests 2020-07-21 10:12:56 +03:00
Alexander Zobnin
6a1145c9fc Problems: fix sorting 2020-07-21 09:47:06 +03:00
Alexander Zobnin
4c40e18c5b Problems: fix item value tooltip placement 2020-06-17 13:04:31 +03:00
Alexander Zobnin
5e5325ed35 Fix error handling in Ack and Exec modals 2020-06-02 13:01:31 +03:00
Alexander Zobnin
c4f8fb1501 Execute script modal: fix type errors 2020-06-02 12:31:04 +03:00
Alexander Zobnin
1cdd8a97e4 Merge branch 'exec-script' into backend 2020-06-02 12:29:08 +03:00