Commit Graph

27 Commits

Author SHA1 Message Date
Tomo Wang d33c4e5e7c Alarting: fix alarm messages in dingding (Fixes #29470) (#29482) 2020-12-02 11:09:49 +01:00
Peter Holmberg 400aafa3b3 Migration: Edit notification channel (#25980)
* implement edit page

* connectWithCleanup

* remove angular related code

* use loadingindicator

* use the correct loading component

* handle secureFields

* fixed implementation of secure fields

* Keep secureFields after rerendering the form

* CollapsableSection and Page refactor

* use checkbox instead of switch

* fix comment

* add cursor to section

* Fixed issues after PR review

* Fix issue with some settings being undefined

* new reducer and start with test

* algorithm to migrate secure fields

* UX: Minor UI Tweaks

* Added field around checkboxes, and missing required field

* fixed test

* tests for util

* minor tweaks and changes

* define as records

* fix typ error

* forward invalid to textarea and inputcontrol

* merge formdata and redux data in test

* fix issue with creating channel

* do not figure out securefields in migration

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2020-09-09 12:46:19 +02:00
Arve Knudsen 41d432b5ae Chore: Enable whitespace linter (#25903)
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2020-07-06 20:17:28 +02:00
Peter Holmberg 6465b2f0a3 Migration: Migrate New notification channel page (#25265)
* creating page

* add types select

* adding switches

* start with converting angular templates to json

* converting more alert channels to new format

* convert remaining channels

* typing the form

* add validation, update models

* fix default value in type select

* fix type

* fix issue with validation rule

* add missing settings

* fix type errors

* test notification

* add comments to structs

* fix selectable value and minor things on each channel

* More typings

* fix strictnull

* rename ModelValue -> PropertyName

* rename show -> showWhen

* add enums and adding comments

* fix comment

* break out channel options to component

* use try catch

* adding default case to OptionElement if element not supported
2020-06-29 13:39:12 +02:00
Marcus Efraimsson 6bd7411f04 Alerting: Only include image in notifier when enabled (#23194)
Fixes a bug when you had multiple notifiers for a rule, but not all 
had enabled to include image.

Fixes #22883
2020-03-31 00:46:01 +02:00
csyangchen 34299a1bd2 Alerting: Fix panic in dingding notifier (#20378)
dingding notifier fails to send alert messages containing JSON, 
This change use map and json.Marshal to always produce valid 
JSON body.

Fixes #9771
2019-12-11 17:01:01 +01:00
Carl Bergquist d8736a2547 Alerting: golint fixes for alerting (#17246) 2019-06-03 10:25:58 +02:00
Carl Bergquist bfa7c3d963 alerting: golint fixes for alert notifiers. (#17167) 2019-05-20 15:23:06 +02:00
Carl Bergquist 13f137a17d tech: avoid alias for importing models in alerting (#17041)
ref #14679
2019-05-14 08:15:05 +02:00
zhulongcheng 2fff8f77dc move log package to /infra (#17023)
ref #14679

Signed-off-by: zhulongcheng <zhulongcheng.me@gmail.com>
2019-05-13 08:45:54 +02:00
Athurg Feng 70b23ab73b Add string quote func 2019-02-02 13:36:10 +08:00
Athurg Feng bba92c0746 Remove option used to control within browser 2019-02-02 13:35:17 +08:00
Athurg Feng 919d00437e Add pic into actionCard message 2018-11-12 11:18:53 +08:00
Athurg Feng b7787db34e Add new option to set where to open the message url 2018-11-08 18:44:00 +08:00
Athurg Feng 201dd6bf65 Optimize the Dingding match values format 2018-10-25 18:53:45 +08:00
Athurg Feng cb86e38628 Add Dingding message type to support mass text notification 2018-10-25 18:34:34 +08:00
Athurg Feng 7f45afac63 Split text template into variable 2018-10-25 18:24:04 +08:00
Athurg Feng ca6dd73923 Add match values into Dingding notification message 2018-10-25 18:23:37 +08:00
Yuan Liu 68c460a957 fix cannot receive dingding alert bug 2018-10-19 17:17:38 +08:00
bergquist 7333d7b8d4 alerting: invert sendOnce to sendReminder 2018-06-05 10:44:17 +02:00
John Baublitz 3cb0e27e1c Revert changes post code review and move them to notification page 2018-06-04 13:19:14 +02:00
bergquist 93e1546f73 alerting: handle invalid json format
closes #11003
2018-04-10 22:22:12 +02:00
Corentin Chary d4d2b6d7da notitfiers: avoid ShouldNotify duplication 2018-03-15 10:48:29 +01:00
Thibault Chataigner fd633a1d5d Add a per-notifier ShouldNotify()
This way we are able to edit notification behavior per notifier.
This would be usefull to let some notifiers send notifications,
even when the state doesn't change, or with custom condition.

Signed-off-by: Thibault Chataigner <t.chataigner@criteo.com>
2017-12-12 17:35:54 +01:00
bergquist 2de94d6548 convert old metrics to prom metrics 2017-09-14 14:26:32 +02:00
Liang Jiameng f8d22385ce add a placeholder to DingTalk Url (#8820) 2017-07-10 16:51:03 +02:00
Liang Jiameng 109fd998ed Add a new notifier : DingTalk (#8473)
* add alerting notifier: DingDing

* add alerting notifier: DingDing

* add dingding unit test

* add dingding unit test

* delete debug code & format code style.

* fix build failed: dingding_test.go
2017-07-04 15:16:32 +02:00