Skip to content

Commit

Permalink
PI-1764 Simplify message layout (#2977)
Browse files Browse the repository at this point in the history
  • Loading branch information
marcus-bcl authored Jan 4, 2024
1 parent 3e189fe commit 3ce51fa
Showing 1 changed file with 15 additions and 25 deletions.
40 changes: 15 additions & 25 deletions .github/workflows/reports.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
"type": "plain_text",
"text": "The following cases failed to allocate in Delius over the last 7 days. Please check and manually correct the cases if required."
},
"fields": ([
"fields": [
{
"type": "mrkdwn",
"text": "*CRN*"
Expand All @@ -52,32 +52,22 @@ jobs:
"type": "mrkdwn",
"text": "*Reason*"
}
] + (.[:4] | map([
{
type: "plain_text",
text: .[0]
},
{
type: "mrkdwn",
text: (.[1] + " (<https://portal.azure.com/#blade/AppInsightsExtension/DetailsV2Blade/DataModel/%7B%22eventId%22:%22" + .[2] + "%22,%22timestamp%22:%22" + .[3] + "%22%7D/ComponentId/%7B%22Name%22:%22nomisapi-prod%22,%22ResourceGroup%22:%22nomisapi-prod-rg%22,%22SubscriptionId%22:%22${{ secrets.APP_INSIGHTS_SUBSCRIPTION_ID }}%22%7D|Details>).")
}
]) | flatten))
]
}
] +
(.[4:] | [_nwise(5)] | map(
{
"type": "section",
"fields": (. | map([
{
type: "plain_text",
text: .[0]
},
{
type: "mrkdwn",
text: (.[1] + " (<https://portal.azure.com/#blade/AppInsightsExtension/DetailsV2Blade/DataModel/%7B%22eventId%22:%22" + .[3] + "%22,%22timestamp%22:%22" + .[4] + "%22%7D/ComponentId/%7B%22Name%22:%22nomisapi-prod%22,%22ResourceGroup%22:%22nomisapi-prod-rg%22,%22SubscriptionId%22:%22${{ secrets.APP_INSIGHTS_SUBSCRIPTION_ID }}%22%7D|Details>).")
}
]) | flatten)
})) +
(. | [_nwise(5)] | map({
"type": "section",
"fields": (. | map([
{
type: "plain_text",
text: .[0]
},
{
type: "mrkdwn",
text: (.[1] + " (<https://portal.azure.com/#blade/AppInsightsExtension/DetailsV2Blade/DataModel/%7B%22eventId%22:%22" + .[3] + "%22,%22timestamp%22:%22" + .[4] + "%22%7D/ComponentId/%7B%22Name%22:%22nomisapi-prod%22,%22ResourceGroup%22:%22nomisapi-prod-rg%22,%22SubscriptionId%22:%22${{ secrets.APP_INSIGHTS_SUBSCRIPTION_ID }}%22%7D|Details>).")
}
]) | flatten)
})) +
[
{
"type": "context",
Expand Down

0 comments on commit 3ce51fa

Please sign in to comment.