diff --git a/octoprint_Octoslack/__init__.py b/octoprint_Octoslack/__init__.py index ba9f571..bed8bbf 100644 --- a/octoprint_Octoslack/__init__.py +++ b/octoprint_Octoslack/__init__.py @@ -108,7 +108,7 @@ def get_settings_defaults(self): "slack_rtm_authorized_users": "", "channel": "", "pushbullet_config": {"access_token": "", "channel": ""}, - "pushover_config": {"app_token": "", "user_key": ""}, + "pushover_config": {"app_token": "", "user_key": "", "device": ""}, "rocketchat_config": { "server_url": "", "username": "", @@ -3762,6 +3762,10 @@ def send_slack_message( ) return + pushoverDevice = self._settings.get( + ["pushover_config"], merged=True + ).get("device") + po_title = None po_body = None pb_image_url = None @@ -3829,6 +3833,7 @@ def send_slack_message( user=pushoverUserKey, title=po_title, message=po_body, + device=pushoverDevice, url=pb_image_url, url_title=pb_image_title, image=pb_image_local_path, diff --git a/octoprint_Octoslack/templates/Octoslack_settings.jinja2 b/octoprint_Octoslack/templates/Octoslack_settings.jinja2 index d874a34..611649d 100644 --- a/octoprint_Octoslack/templates/Octoslack_settings.jinja2 +++ b/octoprint_Octoslack/templates/Octoslack_settings.jinja2 @@ -358,20 +358,25 @@
App Token - -
- +
+ Register your Pushover application here. Your App Token will be available on the next screen
User/Group Key - -
- +
+ The message recipient's user or group key. Your user key is available on your Pushover dashboard page
+
+ Device +
+ + The device where the message will be sent to. Leave empty to send to all your devices. + +
@@ -545,7 +550,7 @@ Pushover
- Snapshot images will hosted by Pushover. Only Pushover hosted snapshots will render in the message. All other hosting options will simply be included as a URL in the message body + Snapshot images will be hosted by Pushover. Only Pushover hosted snapshots will render in the message. All other hosting options will simply be included as a URL in the message body