Commit graph

273 commits

Author SHA1 Message Date
Bradley M. Kuhn
6d7bae7e02 Correct printout of email addresses for renewal. 2016-01-03 12:26:49 -08:00
Bradley M. Kuhn
d151b992c4 First past script to print t-shirt labels. 2016-01-02 11:21:17 -08:00
Bradley M. Kuhn
f985b1c1ef Modifications to the email notification. 2016-01-02 10:47:29 -08:00
Bradley M. Kuhn
a57ed11bd5 Additional verbosity that says what we did. 2016-01-02 10:47:22 -08:00
Bradley M. Kuhn
b85575c625 Don't warn, just print to STDERR with verbosity. 2016-01-02 10:47:09 -08:00
Bradley M. Kuhn
964755c3e3 This takes a hash as argument. 2016-01-02 10:36:35 -08:00
Bradley M. Kuhn
215ac05484 Fixed spelling on hash key. 2016-01-02 10:35:05 -08:00
Bradley M. Kuhn
2d52ce2cd1 Need to use Supporters! 2016-01-02 10:33:57 -08:00
Bradley M. Kuhn
09f25e9fc9 send-t-shirt.plx: First hack at it. 2016-01-02 10:33:35 -08:00
Bradley M. Kuhn
dcbc823f0b need $emailTo variable. 2015-12-31 02:24:32 -08:00
Bradley M. Kuhn
5e226a3483 Rename variable. 2015-12-31 02:24:26 -08:00
Bradley M. Kuhn
db43a3ed71 First draft of renewal-notices script. 2015-12-31 02:16:30 -08:00
Bradley M. Kuhn
f3b7ebc6e3 getEmailAddresses: tests and implementation. 2015-12-31 01:59:50 -08:00
Bradley M. Kuhn
4bd5ab4fd1 Wrote add-email-address.plx script. 2015-12-31 00:38:59 -08:00
Bradley M. Kuhn
8b233299c8 Properly use these strings. 2015-12-31 00:00:11 -08:00
Bradley M. Kuhn
8cc77b8dec mode change on file 2015-12-30 22:48:19 -08:00
Bradley M. Kuhn
a4eb7ac8ac First draft at add script. 2015-12-30 22:47:55 -08:00
Bradley M. Kuhn
b174fec8c3 Add FIXME for API call I want. 2015-12-30 21:47:29 -08:00
Bradley M. Kuhn
39faafcab6 supporterExpirationDate: fix reverse sort bug.
These two new tests:
  ok 222 - supporterExpirationDate(): same donation amount in year...
  ok 223 - supporterExpirationDate(): ...returns the latter date.

did not pass without this change.  The list for annuals in
supporterExpirationDate() was sorted in the wrong order, producing
erroneous results.
2015-12-30 21:26:48 -08:00
Bradley M. Kuhn
dbeb98d0f2 findDonor: empty criteria finds everyone.
Rather than die() when the criteria list is empty, instead return the
entire list.
2015-12-30 20:53:28 -08:00
Bradley M. Kuhn
97f08a7bd8 supporterExpirationDate: tests & implementation 2015-12-30 20:11:57 -08:00
Bradley M. Kuhn
7e424200c7 donorFirstGave: tests and initial implementation. 2015-12-30 19:32:31 -08:00
Bradley M. Kuhn
7d4ca1f746 Correct id in this test. 2015-12-30 19:01:19 -08:00
Bradley M. Kuhn
a57415ff6d donorLastGave: initial implementation. 2015-12-30 19:01:03 -08:00
Bradley M. Kuhn
f3a4ba8ef5 Add actual test command. 2015-12-30 18:59:41 -08:00
Bradley M. Kuhn
89a30119c7 Correct method name. 2015-12-30 18:59:34 -08:00
Bradley M. Kuhn
de51b50759 Correct data to quote $'s. 2015-12-30 18:59:23 -08:00
Bradley M. Kuhn
f57ac7d3f0 Remove dead code. 2015-12-30 18:13:30 -08:00
Bradley M. Kuhn
1c6441e135 setPublicAck: Implementation
ok 48 - setPublicAck: fails supporterId invalid
ok 49 - setPublicAck: fails supporterId is string
ok 50 - setPublicAck: fails supporterId is undef
ok 51 - setPublicAck: 1 failed calls changed nothing.
ok 52 - setPublicAck: 1 failed calls changed nothing.
ok 53 - setPublicAck: 1 failed calls changed nothing.
ok 54 - setPublicAck: lives when valid id is given for undefining...
ok 55 - setPublicAck: ...and suceeds in changing value.
ok 56 - setPublicAck: lives when valid id is given for off...
ok 57 - setPublicAck: ...and suceeds in changing value.
ok 58 - setPublicAck: lives when valid id is given for on...
ok 59 - setPublicAck: ...and suceeds in changing value.
2015-12-30 17:54:37 -08:00
Bradley M. Kuhn
2676dfba22 setPublicAck: initial tests and docs. 2015-12-30 17:53:54 -08:00
Bradley M. Kuhn
dcdfa51d23 setPublicAck: initial tests and docs. 2015-12-30 17:47:56 -08:00
Bradley M. Kuhn
21fa4a1379 getPublicAck: Additional die tests. 2015-12-30 17:42:56 -08:00
Bradley M. Kuhn
59d824e6b8 isSupporter: tests, implementation & docs. 2015-12-30 17:19:10 -08:00
Bradley M. Kuhn
21080cc4d5 getDisplayName: tests, implementation, and docs. 2015-12-30 17:12:58 -08:00
Bradley M. Kuhn
c9c85bb540 Correct auto-0 public_ack.
Actually, public_ack can be NULL and that's ok.  It indicates that the
donor has not answered the question yet.
2015-12-30 17:04:00 -08:00
Bradley M. Kuhn
990fa89f1d _getDonorField: generalize code for donor fields
This method can be used for a one-liner for any field in the donor
table.

Used it to implement getLedgerEntityId and getPublicAck.
2015-12-30 17:03:07 -08:00
Bradley M. Kuhn
a07235f74d Declare variable in the right place. 2015-12-30 17:02:50 -08:00
Bradley M. Kuhn
ec7e50e8e0 getPublicAck: initial tests spec out API. 2015-12-30 16:51:04 -08:00
Bradley M. Kuhn
aba9894180 Add module to list. 2015-12-30 16:33:23 -08:00
Bradley M. Kuhn
a8dbc5ad76 lastGave(): initial tests to define API 2015-12-30 16:33:03 -08:00
Bradley M. Kuhn
195732b6b0 confess is better here than die.
Maybe I should use it throughout?
2015-12-30 16:09:59 -08:00
Bradley M. Kuhn
724cb77605 new: additional arguments related to ledger.
I'll need a full command line here, as it turns out, and also regular
expressions to use for searching for monthly vs. annual donations.
2015-12-30 12:08:33 -08:00
Bradley M. Kuhn
2e14c340ec getLedgerEntityId: Initial implementation.
All tests now pass:

ok 15 - getLedgerEntityId: fails when rows are not returned but _verifyId() somehow passed
ok 16 - getLedgerEntityId: fails when rows are not returned but _verifyId() somehow passed
ok 17 - getLedgerEntityId: lives when valid id is given...
ok 18 - getLedgerEntityId: ...and return value is correct.
2015-12-30 11:31:36 -08:00
Bradley M. Kuhn
0ca9d394e2 getLedgerEntityId: tests showing basic API & docs
These tests show the basic API for the getLedgerEntityId() method.

Documentation for the method also included.
2015-12-30 11:31:09 -08:00
Bradley M. Kuhn
2e9938738f Add license notice at top of these files. 2015-12-30 11:09:47 -08:00
Bradley M. Kuhn
ac90a63538 Note license in README. 2015-12-30 11:08:14 -08:00
Bradley M. Kuhn
e341a6b562 Create a README. 2015-12-30 11:07:31 -08:00
Bradley M. Kuhn
4cd05c9508 Remove blank line. 2015-12-30 06:10:12 -08:00
Bradley M. Kuhn
cb38348048 findDonor: initial implementation.
This seems to work and all existing tests for it pass:

ok 134 - findDonor: no search criteria dies
ok 135 - findDonor: 1 lookup of known missing succeeds ...
ok 136 - findDonor: ... but finds nothing.
ok 137 - findDonor: 2 lookup of known missing succeeds ...
ok 138 - findDonor: ... but finds nothing.
ok 139 - findDonor: 1 and'ed criteria succeeds   ...
ok 140 - findDonor: ... but finds nothing.
ok 141 - findDonor: 2 and'ed criteria succeeds   ...
ok 142 - findDonor: ... but finds nothing.
ok 143 - findDonor: 1 valid multiple criteria succeeds   ...
ok 144 - findDonor: ... and finds right entry.
ok 145 - findDonor: 2 valid multiple criteria succeeds   ...
ok 146 - findDonor: ... and finds right entry.
ok 147 - findDonor: 3 valid multiple criteria succeeds   ...
ok 148 - findDonor: ... and finds right entry.
ok 149 - findDonor: single criteria find expecting multiple records succeeds...
ok 150 - findDonor: ... and finds the right entires.
2015-12-30 06:09:43 -08:00
Bradley M. Kuhn
7e6e96d95f findDonor: API change: return multiple entries
Since the emailAddress criterion could find more than one entry, this
change has findDonor returning a list rather than a scalar integer and
thus finding multiple items are ok.

Tests are more extensive now that this API change is in effect.
2015-12-30 06:08:39 -08:00