Saved Items for a Bill-to
Purpose: We want to create MOD items once for a given Bill to Location.
Overview: We have been saving items at the contact level, we need to bring that up to the billto customer level. This will require changing multiple routines and changing reads and write statements accordingly.
File Structure:
File Name: MOD.ITMMST.USR
ID: COMPANY.ID*BILLTO.NBR*CPN / MOD ITEM NUMBER
F1: Catalog Code
F2: Item Type
F3: Date Saved
F4: Billto Customer Part Number
F5: Ship To Customer Numbers
F6: Ship To Customer Part Numbers
F7: Quote Numbers
F7: Width
F8: Depth
F9: Length
F10: Gauge
F11: Full Gauge
F12: Material
F13: Anti Static Resin
F14: Anti Static Type
F15: Anti Static Milspec
F16: Anti Static Percent
F17: Metallocene
F18: Metallocene Percent
F19: Anti-Block
F20: UVI
F21: UVI Percent
F22: Color
F23: Opacity
F24: Print Plate
F25: Plate Name
F26: Plate Height
F27: Plate Width
F28: Print Color
F29: Print Direction
F30: Print Reading Orientation
F31: Hole Type
F32: Hole Placement
F33: Hole Alignment
F34: Hole Count
F35: Hole From Bottom
F36: Hole From Side
F37: Hole Between
F38: Folded
F39: Unit Weight
F40: Unit Of measure
File Name: CONTACT.ITEM.XRF.USR
ID: COMPANY*CONTACT.NBR*CPN / MOD ITEM NUMBER
F1: Product Use Tags
F2: Location Tags
F3: Share IDs
F4: Date saved
F5: Date Deleted
F6: FAVORITE.FLAG
F7: Quote Numbers
I-TYPE fields:
- WIDTH
- DEPTH
- LENGTH
- GAUGE
Code Changes:
LDLIB RPC$MODITEM_CREATE
Change record structure before write of CONTACT.ITEM.XRF.USR to reflect new structure.
Find MOD.ITMMST.USR record based on configuration fields.
Update / create MOD.ITMMST.USR record.
LDLIB RPC$CONTACTITEM_DELETE
Change code to update new field position of DELETED.DATE
LDLIB RPC$CONTACTITEM_GETBYFILTER
Read ITEM.TYPE from MOD.ITMMST.USR instead of CONTACT.ITEM.XRF.USR
For ITEM.TYPE = “M” read dimensions, and category
LDLIB RPC$CONTACTITEM_GETBYID
Read ITEM.TYPE from MOD.ITMMST.USR instead of CONTACT.ITEM.XRF.USR
For ITEM.TYPE = “M” read dimensions, and category from MOD.ITMMST.USR else read from ITMMST.UST
LDLIB RPC$CONTACTITEM_SAVE
Remove the CUST.PN logic. It will be moved to a completely different routine.
IF ITEM.TYPE = “M” check existence of MODITMMST.USR record based on Configuration fields, and create it if it is missing.
Change record structure of CONTACT.ITEM.XRF.USR before save to reflect new structure.
LDLIB RPC$ITEMTAG_GETBYFILTER
No changes necessary.
LDLIB RPC$ITEMTAG_GETBYFILTER2
No changes necessary.
LDLIB RPC$ITEMTAG_SELECT
Remove Updates to SLSCONTACT.USR for Most Recently Used tags since we are no longer going to be using them anywhere.
Remove Updates of CUST.PN to CONTACT.ITEM.XRF.USR as this is going to be moved to another routine completely.
LDLIB RPC$QUOTEITEM_GETBYSAVEDITEM
Change the READVU to be based on the new structure.
LDLIB RPC$SHAREDITEM_GETBYFILTER
Change the parsing routine where it sets SHAREITEM.IDS to read field 3 instead of field 9.
LDLIB RPC$SHAREDITEM_SAVE
Change the CONTACT.ITEM.XRF.USR record building part routine to set field 3 instead of field 9.
LDLIB RPC$SHIPMENTBUNDLING_GETBYFILTER