Skip to content

Commit

Permalink
feat(backend): 监控策略 url 错误的问题 #3916
Browse files Browse the repository at this point in the history
# Reviewed, transaction id: 5476
  • Loading branch information
zhangzhw8 committed Apr 10, 2024
1 parent 9ac0bbc commit 4971436
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion dbm-ui/backend/db_monitor/models/alarm.py
Original file line number Diff line number Diff line change
Expand Up @@ -828,7 +828,7 @@ def clone(cls, params, username="system") -> dict:

policy.details = copy.deepcopy(parent.details)
policy.details.pop("id", None)
policy.details.update(name=policy.name)
policy.details.update(name=policy.name, is_enabled=True)

policy.creator = policy.updater = username
policy.id = None
Expand Down
3 changes: 2 additions & 1 deletion dbm-ui/backend/db_monitor/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,8 @@ def get_event_url(self, obj):
"queryString": _("策略ID : {} AND 状态 : {}").format(obj.monitor_policy_id, _("未恢复")),
"from": "now-30d",
"to": "now",
"bizIds": bk_biz_id,
# -2 代表有告警的空间
"bizIds": -2,
}
)

Expand Down

0 comments on commit 4971436

Please sign in to comment.