Alerting: Remove dependency on alerting package in definitions (#65390)

* move export rules to definitions package
* move provisioning contact point methods to provisioning package
* move AlertRuleGroupWithFolderTitle to ngalert models and adapter functions to api's compat
* move rule_types files back to where they were before.
This commit is contained in:
Yuri Tseretyan
2023-03-29 13:34:59 -04:00
committed by GitHub
parent d23ebf63d2
commit 9eaffdf5a8
11 changed files with 233 additions and 238 deletions
@@ -136,6 +136,13 @@ type AlertRuleGroup struct {
Rules []AlertRule
}
// AlertRuleGroupWithFolderTitle extends AlertRuleGroup with orgID and folder title
type AlertRuleGroupWithFolderTitle struct {
*AlertRuleGroup
OrgID int64
FolderTitle string
}
// AlertRule is the model for alert rules in unified alerting.
type AlertRule struct {
ID int64 `xorm:"pk autoincr 'id'"`