id int (auto increment)
This is one of two "primary" tables dealing with membership
(the other is meminfo). Of the two, only custdata is present
at the checkout. Column meaning may not be quite identical
[Probably] The Same Everywhere:
- CardNo is the member's number. This identifies them.
- personNum is for stores that allow more than one person per membership.
personNum starts at 1.
The combination (CardNo, personNum) should be unique for each record.
- FirstName what it sounds like.
- LastName what it sounds like.
- Discount gives the member a percentage discount on purchases.
- Type identifies whether the record is for an actual member.
If Type is 'PC', the person is considered a member at the register.
This is a little confusing, but not everyone in the table has to be
- blueLine is displayed on the checkout screen when the member's number is entered.
- id just provides a guaranteed-unique row identifier.
[20Feb2014 Use of these fields is becoming more general]
- ChargeOk=1 if member may run a store charge balance; =0 may not.
- MemDiscountLimit is their store charge account limit.
(Deprecated in favour of ChargeLimit)
- ChargeLimit is their store charge account limit.
- Balance is a store charge balance as of the start of the day,
if the person has one.
Some records are for organizations, esp vendors,
that have charge accounts.
Is updated from ar_live_balance by cronjob arbalance.sanitycheck.php
and by its replacement cron/tasks/ArHistoryTask.php
[Probably] Just For Organizing:
The register is mostly unaware of these settings,
but they can be used on the backend for consistency checks
e.g., make sure all staff members have the appropriate percent discount
- staff identifies someone as an employee. Value: 1?
- memType allows a little more nuance than just member yes/no.
FK to memtype.memtype
- SSI probably because of a historic senior citizen discount.
(Sounds like it is obsolete or at least not used.)
- memCoupons indicates how many virtual coupons (tender MA) are available.
To the best of my (Andy's) knowledge, these have no meaning on the front or back end.
- Single edit: fannie/mem/search.php
- Single add: fannie/mem/new.php
- Batch import: fannie/mem/import/*.php
- custdata.Balance is updated from ar_live_balance by cronjob arbalance.sanitycheck.php
*//*--COMMENTS - - - - - - - - - - - - - - - - - - - -
* 12Dec12 EL Field LastChange
* MSSQL will probably need support like described at:
* 22Oct12 EL Comment about cron update of Balance.
* EL Comment about ChargeOK
* EL Maintenance section in comments.
* 26Jun12 Eric Lee Reformatted Use section
* epoch AT Original notes by Andy Theuninck.