Jump to content

allenrowand

Member
  • Posts

    4
  • Joined

  • Last visited

Posts posted by allenrowand

  1.  

    I take business payments via Stripe on my website and Square in person, and track the processing fees as an expense. I created these workflows to quickly calculate the fee paid; enter or paste the amount received into the workflow, and it will return the fee paid and put it on the clipboard.

    740726792_ScreenShot2021-01-04at8_39_40PM.thumb.png.814bdea0efe993cf106c05219cc52fe7.png2132023199_ScreenShot2021-01-04at8_39_51PM.png.a76397eb76464bff38ea9f00c1a3c4a3.png

     

    https://github.com/allenrowand/alfred-stripe-calculator

    https://github.com/allenrowand/alfred-square-calculator

     

    I'm not affiliated with Stripe or Square other than being a customer.

  2. Hello,

    I'm trying to strip the ending characters from the output of a python script and I can't get anything to work. The script is:

     

    import decimal
    
    query = float("{query}")
    
    output = str(round(decimal.Decimal((query*.029)+.3),2))
    
    print(output)

     

    I've tried appending .strip() (and several other techniques) to the end of the output variable, but the newline is still there when I paste the result. I apologize if this is ridiculously simple, but I'm not used to working in python and am not much of a programmer.

     

    For what it's worth, the workflow asks for input and then computes how much Stripe is charging for payment processing. I put in the invoice amount and get the charge paid so that I can enter the expense in my books. As it stands when I paste the result into my financial software there's a trailing space and if I paste into a text editor I get a newline.

     

    Any help would be appreciated, thanks!

×
×
  • Create New...