Difference between revisions of "VbzCart/tables/ord pkg lines"
Jump to navigation
Jump to search
(correction... those fields weren't what I thought they were) |
(WhenVoided) |
||
Line 7: | Line 7: | ||
** '''2010-10-19''' Adding CostShItm and CostSale fields to record prices charged (parallels ChgShipItm and ChgShipPkg in {{vbzcart/table|ord_pkgs}}) | ** '''2010-10-19''' Adding CostShItm and CostSale fields to record prices charged (parallels ChgShipItm and ChgShipPkg in {{vbzcart/table|ord_pkgs}}) | ||
*** Those fields didn't exist until I created them just now (because I thought certain other fields were serving that function), but it's better to have too much data than too little for critical things like packages. | *** Those fields didn't exist until I created them just now (because I thought certain other fields were serving that function), but it's better to have too much data than too little for critical things like packages. | ||
+ | ** '''2011-10-08''' Added '''WhenVoided''' field so we have a quick way of removing lines from the package to put them back into stock (while still keeping a record of what was there). | ||
==SQL== | ==SQL== | ||
<section begin=sql /><mysql>CREATE TABLE `ord_pkg_lines` ( | <section begin=sql /><mysql>CREATE TABLE `ord_pkg_lines` ( | ||
Line 18: | Line 19: | ||
`QtyNotAvail` INT COMMENT "quantity which can't be filled", | `QtyNotAvail` INT COMMENT "quantity which can't be filled", | ||
`QtyFromStock` INT COMMENT "quantity which was moved from stock", | `QtyFromStock` INT COMMENT "quantity which was moved from stock", | ||
+ | `WhenVoided` DATETIME DEFAULT NULL COMMENT "when this line was voided", | ||
`CostSale` DECIMAL(9,2) DEFAULT NULL COMMENT "price charged for this item", | `CostSale` DECIMAL(9,2) DEFAULT NULL COMMENT "price charged for this item", | ||
`CostShItm` DECIMAL(9,2) DEFAULT NULL COMMENT "per-item shipping cost charged", | `CostShItm` DECIMAL(9,2) DEFAULT NULL COMMENT "per-item shipping cost charged", |
Revision as of 20:23, 8 October 2011
About
- Purpose: What's in an order package (
- REDIRECT Template:l/vc/table)
- Refers to: ord_pkgs (parent), ord_lines, cat_items
- Fields:
- QtyFromStock may be an obsolete field, as all package quantities should now come from stock.
- History:
- 2010-10-19 Adding CostShItm and CostSale fields to record prices charged (parallels ChgShipItm and ChgShipPkg in ord_pkgs)
- Those fields didn't exist until I created them just now (because I thought certain other fields were serving that function), but it's better to have too much data than too little for critical things like packages.
- 2011-10-08 Added WhenVoided field so we have a quick way of removing lines from the package to put them back into stock (while still keeping a record of what was there).
- 2010-10-19 Adding CostShItm and CostSale fields to record prices charged (parallels ChgShipItm and ChgShipPkg in ord_pkgs)
SQL
<mysql>CREATE TABLE `ord_pkg_lines` (
`ID` INT NOT NULL AUTO_INCREMENT, `ID_Pkg` INT NOT NULL COMMENT "ord_pkgs.ID", `ID_OrdLine` INT COMMENT "ord_lines.ID", `ID_Item` INT NOT NULL COMMENT "cat_items.ID", `QtyShipped` INT COMMENT "quantity shipped/charged in this package", `QtyExtra` INT COMMENT "quantity tossed in as freebies in this pkg", `QtyKilled` INT COMMENT "quantity fulfilled by being cancelled", `QtyNotAvail` INT COMMENT "quantity which can't be filled", `QtyFromStock` INT COMMENT "quantity which was moved from stock", `WhenVoided` DATETIME DEFAULT NULL COMMENT "when this line was voided", `CostSale` DECIMAL(9,2) DEFAULT NULL COMMENT "price charged for this item", `CostShItm` DECIMAL(9,2) DEFAULT NULL COMMENT "per-item shipping cost charged", `Notes` VARCHAR(255), PRIMARY KEY(`ID`)
) ENGINE = MYISAM;</mysql>