-
Notifications
You must be signed in to change notification settings - Fork 463
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix not acknowledged problem color with a message #858
Merged
alexanderzobnin
merged 3 commits into
grafana:master
from
memfiz:hotfix/ack-severity-color
Jan 13, 2020
Merged
fix not acknowledged problem color with a message #858
alexanderzobnin
merged 3 commits into
grafana:master
from
memfiz:hotfix/ack-severity-color
Jan 13, 2020
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alexanderzobnin
requested changes
Jan 11, 2020
@@ -72,7 +72,7 @@ export default class AlertCard extends PureComponent<AlertCardProps, AlertCardSt | |||
let problemColor: string; | |||
if (problem.value === '0') { | |||
problemColor = panelOptions.okEventColor; | |||
} else if (panelOptions.markAckEvents && problem.acknowledges && problem.acknowledges.length) { | |||
} else if (panelOptions.markAckEvents && problem.lastEvent.acknowledged == "1") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be strict ===
Suggested change
} else if (panelOptions.markAckEvents && problem.lastEvent.acknowledged == "1") { | |
} else if (panelOptions.markAckEvents && problem.lastEvent.acknowledged === "1") { |
alexanderzobnin
approved these changes
Jan 13, 2020
alexanderzobnin
added a commit
that referenced
this pull request
Jan 15, 2020
* CI: fix shellcheck issues (#789) Signed-off-by: Mario Trangoni <[email protected]> * annotations: fix options in grafana 6.x, fix #813 * fix function editor in Grafana 6.4, closes #810 * add typings for grafana packages * Add $__range_series variable for calculating function over the whole series, #531 * fix tests * Don't set alert styles for react panels, fix #823 * docs: add range variables * docs: percentile reference * fix codespell * update packages (build with node 12) * update circleci node image to 12 * fix test configuration (babel) * Fix 817 (#851) * problems: update panel schema * update packages (build with node 12) * problems: use datasource from target * problems: fix query editor after schema update * problems: fix list layout * update circleci node image to 12 * fix tests * build(deps-dev): bump lodash from 4.17.10 to 4.17.13 (#852) Bumps [lodash](https://github.com/lodash/lodash) from 4.17.10 to 4.17.13. - [Release notes](https://github.com/lodash/lodash/releases) - [Commits](lodash/lodash@4.17.10...4.17.13) Signed-off-by: dependabot[bot] <[email protected]> * fix packages security alerts * problems: fix tags adding and removal * fix adding func from typeahead, closes #468 * update change log * bump plugin version to 3.10.5 * problems: fix tag removal (list layout) * Fix percentile() function, closes #862 (#863) Like the other aggregation functions, the datapoints need to be sorted in time before calling groupBy_perf(). * Update copyright, happy New Year! * fix not acknowledged problem color with a message (#858) * fix not acknowledged problem color with a message * fix not acknowledged problem color with a message, closes #857 * Variable query editor (#856) * refactor: convert module to typescript * refactor: covert utils to typescript * variable query editor WIP * variable editor: fix type error after grafana/ui update * variable editor: use FormLabel from grafana/ui * variable editor: refactor * variable editor: input validation and highlights * variable editor: fix tests * variable query: fix backward compatibility with empty queries * fix linter errors * variable editor: fix variable replacement in queries * Fixes for backend Co-authored-by: Mario Trangoni <[email protected]> Co-authored-by: Alexander Zobnin <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mark Reibert <[email protected]> Co-authored-by: memfiz <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR closes #857.
As described in the issue #857 if a problem contains a message without the acknowledgment, then the severity color is shown as acknowleged in both views: table and list.
Zabbix event object has property "acknowledged" which is 1 if the event has been acknowledged. I've used this property instead of "acknowledges" object, because acknowledges will contain the message attached to the event even if the event is not acknowleged.