Skip to content

Commit

Permalink
Merge pull request #23 from samuelthng/v2.0.1
Browse files Browse the repository at this point in the history
Fixed: `Custom Tag` and `Groups` not being set properly.
  • Loading branch information
samuelthng authored Dec 20, 2023
2 parents 8cd626a + aefb569 commit 4dd4d07
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 23 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ Repository for blueprints that is polished enough for public sharing.

| Name | Domain | Version | Import Blueprint | Github Link |
| --- | --- | --- | --- | --- |
| 🔔 Notifications | Script | 2.0 | [![Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.](https://my.home-assistant.io/badges/blueprint_import.svg)](https://my.home-assistant.io/redirect/blueprint_import/?blueprint_url=https%3A%2F%2Fgithub.com%2Fsamuelthng%2Ft-house-blueprints%2Fblob%2Fmain%2Fnotifications.yaml) | [🔗](https://github.com/samuelthng/t-house-blueprints/blob/main/notifications.yaml) |
| 🔔 Notifications | Script | 2.0.1 | [![Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.](https://my.home-assistant.io/badges/blueprint_import.svg)](https://my.home-assistant.io/redirect/blueprint_import/?blueprint_url=https%3A%2F%2Fgithub.com%2Fsamuelthng%2Ft-house-blueprints%2Fblob%2Fmain%2Fnotifications.yaml) | [🔗](https://github.com/samuelthng/t-house-blueprints/blob/main/notifications.yaml) |
30 changes: 8 additions & 22 deletions notifications.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
mode: restart
blueprint:
name: 🔔 Notifications (Version 2)
name: 🔔 Notifications (Version 2.0.1)
source_url: https://github.com/samuelthng/t-house-blueprints/blob/main/notifications.yaml
homeassistant:
min_version: 2023.11.0
Expand All @@ -9,7 +9,7 @@ blueprint:
description: >-
<div>
<h2>🔔 Notifications</h2>
<b>Version 2</b> | 🔗 <a href="https://github.com/samuelthng/t-house-blueprints/blob/main/notifications.yaml" target="_blank">Github Link</a> | 💬 <a href="https://community.home-assistant.io/t/notifications-actionable-mobile-notifications-script-with-optional-timeout-feature-and-camera-snapshots-works-with-ios-android/551552" target="_blank">Community Post</a>
<b>Version 2.0.1</b> | 🔗 <a href="https://github.com/samuelthng/t-house-blueprints/blob/main/notifications.yaml" target="_blank">Github Link</a> | 💬 <a href="https://community.home-assistant.io/t/notifications-actionable-mobile-notifications-script-with-optional-timeout-feature-and-camera-snapshots-works-with-ios-android/551552" target="_blank">Community Post</a>
</div>
<br>
Expand Down Expand Up @@ -42,25 +42,10 @@ blueprint:
<details>
<summary>Expand/collapse changelog</summary>
### Version 2 - *12 Dec 2023*
- Fixed: iOS showing `Failed to load attachment`
- Refactor: Build payload in templates
- Deprecated: `📲 Notification Strategy` due to refactor.
- Deprecated: `📲 Service to notify` due to refactor.
- Added: Support for [fields](https://www.home-assistant.io/integrations/script/#fields)
- Added: `🏷️ Title` field
- Added: `💬 Message` field
- Added: `🏷️ Subtitle` field
- Added: `📸 Attachment: Camera Entity: Camera Entity` field
- Added: Options show/hide fields
- Added: `⌛️ Enable Timeout` and `⌛️ Enable Timeout Action(s)` fields.
- Added: [`🚘 Show on Android Auto`](https://companion.home-assistant.io/docs/notifications/notifications-basic?_highlight=car_ui#android-auto-visibility) option.
- Added: `⌛️ Enable Timeout Action(s)` option and field.
> Notes:
> - When enabling boolean fields with value of false, be sure to toggle them to true once, and then to false.
> There seems to be a bug where the boolean value is not passed if it's enabled and value is false without the toggle.
> - If you rely on `📲 Service to notify`, do not upgrade, `Version 1.6.1` will be the last version supporting that feature.
### Version 2.0.1 - *20 Dec 2023*
- Fixed: `Custom Tag` and `Groups` not being set properly.
### Version 2 - *12 Dec 2023* [🔗](https://community.home-assistant.io/t/notifications-actionable-mobile-notifications-script-with-optional-timeout-feature-and-camera-snapshots-works-with-ios-android/551552/109)
### Version 1.6.1 - *26 Oct 2023* [🔗](https://community.home-assistant.io/t/notifications-actionable-mobile-notifications-script-with-optional-timeout-feature-and-camera-snapshots-works-with-ios-android/551552/66)
Expand Down Expand Up @@ -1062,7 +1047,8 @@ sequence:
}}}
options: >-
{{ [option_one, option_two, option_three] | selectattr('enabled') | list }}
tag: "{{ iif(custom_tag|length, tag, this.entity_id ~ '-' ~ context.id) }}"
tag: "{{ iif(custom_tag|length, custom_tag, this.entity_id ~ '-' ~ context.id) }}"
group: !input group
# Build OS specific notification payloads.
notification_data: >-
{% set apple_device = 'APPLE' in (device_attr(notify_device, "manufacturer")|upper) %}
Expand Down

0 comments on commit 4dd4d07

Please sign in to comment.