Declines should be an Int
Previously this retured a string and everywhere that used it had to
convert it into an it, or handle it if it's nil.
That's dumb.
Now it's always an int, and `nil.to_i` is 0 anyway so I don't have to
check that either.
Do not allow nil tndetails
LazyObject is not nil, so safenav doesn't work
Order Transactions by Date
In my testing the natural order just happened to be the date order
because I had so little data.
But in the real world we should probably be more explicit!
Do not get CNAM during admin command
Since this is used by the billing cronjob and hitting BW so much is too expensive.
Refactor CustomerInfoForm to use find_by_format
Shunt call to voicemail on exception
Respond to Proper Cancel Stanza
Previously cancels would be treated as an error, but then would be
caught so that they could respond with receipt of the cancel later.
But, we weren't setting @iq in these cases, because it was an error, so
we would actually respond to the wrong stanza; specifically the one
before the cancel.
This was bad and wrong and led to the bot sitting there waiting for the
cancel before moving on with its life.
Set Sentry user from CustomerRepo
We don't always use this to get the current user, so make it optional.
Import some hotfixes from prod
Transaction Note Can Be Null
Not only is it allowed, but actually there's a ton of empty notes. Every
monthly account activation is missing a note, so practically every user
that has transactions will have empty notes.
Handle Empty Admin Menu Response
Some automated processes don't care for our menu, and rather than
crashing it should just consider our process to be done.
Merge branch 'tx-list'
* tx-list:
Admin Command Menu + Admin Financial View
Transactions List
Customer Financials
Telephone Link
Admin Command Menu + Admin Financial View
I've added a new command to show financial information about the user.
But more importantly I've added an infinite admin subsystem which allows
me to go into a user and then run multiple commands on them.
For now it's just these two info commands, but in the future I'd like to
add mutative commands here.
Finally, since I sometimes look up multiple users in a pretty short
timeframe I made the menu open and if I put something into the list that
doesn't parse as one of the actions it instead switches the current user
so I don't have to do "cancel", "customer", and then put the next one
in.
I can just have the session open and put stuff in as needed.
Transactions List
Using the new Financials object a user can list their transaction list
We only show the user the date, amount, and method.
Customer Financials
I've pulled out information about payment methods and bitcoin into its
own thing. It's kind of a repository, except that it only exposes
fetchers and doesn't load anything generally.
There's also a few new methods here that aren't used yet, but will be
shortly.