VbzCart/packages

from HTYP, the free directory anyone can edit if they can prove to me that they're not a spambot
< VbzCart
Revision as of 18:42, 13 May 2014 by Woozle (talk | contribs) (update/simplification)
Jump to navigation Jump to search

See VbzCart/code/VBA/Form frmPackage and VbzCart/code/VBA/clsPackage for how this used to work in Access.

Fetching Items

This is where items are added to the package.

  • The web form indicates the locations of stock that might be used to fill the order.
  • User enters the quantity to use (remove) from each location, and presses "Fetch Stock" button.
    • If "do it for real" box is not checked, subsequent data changes are displayed as hypothetical rather than actually being done.
  • If the current package is "new", then a package record is created.
  • The code then creates or updates package line records as necessary to accommodate the stock being added to the package.
  • The code recalculates:
    • item sale amount(s)
    • per-item shipping (total)
    • per-package shipping (max)

Finalizing

This is where we sort of make the package "official": statuses are updated, totals computed, etc.

  • (We used to increment a "QtyDone" field in ord_lines for each line in the package, but now we recalculate that dynamically (as needed) by summing up the package quantities.)
  • (We used to calculate totals at this stage, but that is now done whenever the package contents are modified.)
  • Add a transaction record to the order for the amount owed for this package.
  • Time-stamp package as "finished".