Commit graph

21 commits

Author SHA1 Message Date
Bradley M. Kuhn
eeb5689212 View UserOperation_contact_setting_change: initial implementation 2022-06-22 14:47:19 -07:00
Bradley M. Kuhn
72f2b5aebd Implement UserOperation_donor_update view and its triggers
Note my comment that the error messages don't work properly on NULL
values.  I once in my life spent years wondering about how to handle
three-valued logic problems in SQL.  I thought that part of my life
was apparently over, but I guess not.  🤷
2022-06-22 10:53:05 -07:00
Bradley M. Kuhn
fe0cda3232 Change name of table as we'll use it for other views too. 2022-06-22 10:15:37 -07:00
Bradley M. Kuhn
e7bdf7db27 UserOperation_fix_tshirt_size_request view: first implementation
The `UserOperation_fix_tshirt_size_request` view is designed to allow
end-users edit t-shirt sizes in the request using a program like
`sqlitebrowser`.

This is the first implementation attempt of a user operation that
allows changing the T-Shirt size.
2022-06-21 13:58:21 -07:00
Bradley M. Kuhn
f6b0ac1903 Add field for invalid postal addresses 2022-06-21 10:09:27 -07:00
Bradley M. Kuhn
60260bd59c Supporters db: add rt_ticket field. 2021-01-13 12:04:05 -08:00
Bradley M. Kuhn
2cde8096a9 Begin work on delivery_error database tables.
No code supports this yet, IIRC.
2019-12-10 09:35:16 -08:00
Bradley M. Kuhn
89bd74a50a Implement ability to put requests on hold.
Requests can now be placed "on hold", and getRequest() can ignore held
requests.

This required addition of a table, and another API call holdRequest().

Tests were not written here, which was a mistake.  Unit tests and docs
are needed.  A FIXME was added, at least.

Also, minor imporvements to reporting on fulfilled requests.
2016-12-08 15:10:16 -08:00
Bradley M. Kuhn
c6b52c42dd fulfillment_id should not be in request table.
Since fulfillment table has request_id, fulfillment_id shouldn't be in
the request table.
2015-12-30 04:31:37 -08:00
Bradley M. Kuhn
95ef1fce28 Change table to donor; add is_supporter field.
Up until now, this software has been focused on just Supporters, but
really there is no reason this should not be a general donor database.
Therefore, don't use the name supporter in the database, and add a
field.

public_ack is now allowed to be NULL, because the idea being we don't
have an answer from all who donate whether or not they want public
acknowledgment.

the is_supporter boolean is added to record whether or not they came
through the supporter program.
2015-12-30 03:10:07 -08:00
Bradley M. Kuhn
7e82e94b55 Can't enforce one preferred email with UNIQUE key
The problem is that the supporter can have multiple non-preferred email
addresses.

I'd have to investigate if there's a way to make a UNIQUE key on a value
set to a specific value.
2015-12-20 17:49:09 -08:00
Bradley M. Kuhn
b62283dc74 Each supporter only makes each type of request 1x. 2015-12-20 14:07:57 -08:00
Bradley M. Kuhn
aff5e66786 fulfillRequest(): basic implementation.
First attempt at implementing fulfillRequest() method.

It seems that request_id was incorrectly missing from the fulfillment
table.
2015-12-20 13:59:50 -08:00
Bradley M. Kuhn
4331093cee Basic implementation of addRequestConfigurations
Adjusted one test slightly: there was a missing argument.  Also,
corrected test count.

While implementing, I realized a failure mode that forces a rollback:
duplication on the input list of configurations.  Tests are now needed
for that.
2015-12-13 13:37:52 -08:00
Bradley M. Kuhn
2d54621dce These are now done by mapping tables. 2015-12-06 18:30:03 -08:00
Bradley M. Kuhn
9b3e1a70af Missing , 2015-12-06 17:07:57 -08:00
Bradley M. Kuhn
6c15d3973f Correct details on postal_address table.
Also, correct name of index on email.
2015-12-06 17:07:29 -08:00
Bradley M. Kuhn
89c1a9fff7 Remove incorrect ,'s in various places. 2015-12-06 17:06:22 -08:00
Bradley M. Kuhn
e48ae089dc Add DROP TABLEs and fix index. 2015-12-06 17:05:37 -08:00
Bradley M. Kuhn
203d810498 First pass at v0.2 of supporter database.
Redesign of database, mainly for three reasons:

   (a) we need to send renewal notices to Supporters, and need to keep a
       record of when we've sent them,

   (b) We need to keep better track of t-shirt requests,

   (c) We need to allow for different email addresses for contact other
       than the PayPal payer one.

Before doing this, I briefly looked again at CiviCRM.  While I can
complete this conversion and all my scripts in just a matter of a few
hours, setup of CiviCRM would take a minimum of a few hours just to
investigate its viability for us and whether I'd be able to maintain it.
So, we're doing custom, ad-hoc stuff still.

This commit has not been tested, it's a first pass that I'll adjust.
2015-12-06 17:04:02 -08:00
Bradley M. Kuhn
9c70debfb1 First step to import of Supporter donations.
Ultimately, I decided I had little choice but to create a database of
supporters.  There is really no easy way to track all this properly with
ledger, since ledger is transaction based and this is data that spans
many transactions.

Indeed, even in the NPO Accounting project, we knew there would be
separate data stores for contacts, etc.  This is an ad-hoc start to
that, I guess.
2015-12-06 16:46:43 -08:00