Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose User and Owner variables for events #364

Merged
merged 2 commits into from
Jul 12, 2021

Conversation

slvrpdr
Copy link
Contributor

@slvrpdr slvrpdr commented Jun 13, 2021

This is my attempt at sort of answering #169, since it is not who is logged in, but who initiated the print/action.
It exposes two variables for the notifications: owner and user. The owner is who started the print and the user is who initiated the action.
From Telegram, it populates the user field using First name + Last name. When the print is initiated from the web interface, it uses the OctoPrint username.
It has the nice side effect of populating the User: field in OctoPrint's state panel when the print was started from Telegram.

@giloser
Copy link
Collaborator

giloser commented Jul 9, 2021

Hi,
thanks for the PR , just one question why did you put 'user =""' to all function except Gif and SuperGif where you just put 'user'?
thanks

@slvrpdr
Copy link
Contributor Author

slvrpdr commented Jul 9, 2021

Hi,
Because I had forgotten them. Added now.

@giloser giloser merged commit 4e0e1bd into fabianonline:master Jul 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants