Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #! python3
- # email_template.py -> stores email templates and copies them to the clipboard
- import sys, pyperclip
- # Yes i am aware this code is ugly and breaks PEP8. Im a n00b, cut me some slack
- # Future changes ->Build a GUI, add more templates
- def SLA_GENERIC():
- CustName = input("Enter the Customers Full name:\n")
- DateTime = input("\n\nEnter the Date and time you are going to contact the customer -> 'today at 3pm', or 'tomorr"
- "w at noon'")
- template = 'Hello ' + CustName + ',\n\nMy name is Adam Petersen and I am the Microsoft Support Engineer who will b' \
- 'e working with you on your case. I have a few questions I would like to ask so that I can better und' \
- 'erstand the issue and help to resolve it. Are you available at ' + DateTime + ' for a phone call? If' \
- ' not, or if you would rather communicate over email, please let me know. I look forward to working wi' \
- 'th you to resolve this issue!'
- pyperclip.copy(template)
- print("\n\nTEMPLATE COPIED TO CLIPBOARD\n")
- def SLA_EMAIL_ONLY():
- CustName = input("Enter the Customers full name:\n")
- template = 'Hello ' + CustName + ',\n\nThank you for contacting Microsoft Support. My name is Adam Petersen and I a' \
- 'm the Support engineer who will be working with you today. feel free to reach out to me at any time u' \
- 'sing my contact information at the bottom of this email. As you have requested email only contact, I' \
- ' will only reach out to you through email. However, I would be more than happy to speak over the phone' \
- '. Just provide me with a phone number and time/date that works best for you.\n\nIn order for me to bett' \
- 'er understand your problem, I have included a few questions for you. Please provide as much detail as' \
- ' possible. I look forward to working together and will do my best to ensure this issue is resolved as ' \
- 'quickly as possible.\n\n1. How does this issue affect your business activities?\n2. Are you currently' \
- ' working under some sort of deadline or timeline that this issue affects?\n3. How many users does ' \
- 'this issue affect?\n4. Can you provide a rough estimate of financial impact?\n5. Is there anything' \
- ' else this issue affects?\n'
- pyperclip.copy(template)
- print("\n\nTEMPLATE COPIED TO CLIPBOARD\n")
- def BUSINESS_IMPACT():
- template = '1. How does this issue affect your business activities?\n2. Are you currently working under some sor' \
- 't of deadline or timeline that this issue affects?\n3. How many users does this issue affect? \n4.' \
- ' Is there a rough estimate on financial impact?\n'
- pyperclip.copy(template)
- print("\n\nTEMPLATE COPIED TO CLIPBOARD\n")
- def SCOPE_AGREEMENT():
- Problem = input("Enter the problem -> will be in this format:\n'we have found a solution to your probelm of ___")
- template = 'You agree that this case will be considered resolved if one of the following conditions are met:\n1.' \
- ' We have found a solution to your problem of ' + Problem + '.\n2. There is a workaround that will help sol' \
- 've your business need.\n3. Show you that what you are attempting to do is not a Microsoft supported ' \
- 'configuration.\n4. The issue you are experiencing turns out to be a "By Design" behavior.'
- pyperclip.copy(template)
- print("\n\nTEMPLATE COPIED TO CLIPBOARD\n")
- main_loop = True
- while main_loop == True:
- print("\n\nEMAIL TEMPLATES SCRIPT.\n\n")
- choose_template = input("Choose your template.\n'sla gen' for SLA GENERIC\n'sla email' for SLA EMAIL ONLY\n'bi' for"
- " BUSINESS IMPACT\n'scope' for SCOPE AGREEMENT\nQ to quit.")
- if choose_template == 'sla gen':
- SLA_GENERIC()
- elif choose_template == 'sla email':
- SLA_EMAIL_ONLY()
- elif choose_template == 'bi':
- BUSINESS_IMPACT()
- elif choose_template == 'scope':
- SCOPE_AGREEMENT()
- elif choose_template == ('q' or 'Q'):
- print('Exiting')
- sys.exit()
Add Comment
Please, Sign In to add comment