PART
Repository name :   SampDB1
Repository location : C:\Versata_55\Samples\SampDB1
Analysis date :   Tue Sep 16 16:10:05 PDT 2003
Analysis run on machine : TYLER_DELL
Analysis run by user : Tyler
DataObject Name : PART
Description : A list of items currently offered for sale, and the heart of the a inventory tracking within the sample database.
Attributes Caption Nullability Persistent DataType Business Rule
PartNum Part# Required Persistent AutoNumber
Name Name Optional Persistent VarChar(50)
Make Make Optional Persistent Long Default(1)
Model Model Optional Persistent VarChar(16) CodedValueList( VALID_MODELAUTO )
Type Type Optional Persistent Long CodedValueList( VALID_PARTTYPE )
UnitOfSale Unit Optional Persistent VarChar(6) CodedValueList( VALID_UNIT )
Price Price Optional Persistent Currency Default(0)
AutoBucks Auto Bucks Optional Persistent Currency
QtyOnHand Qty On Hand Optional Persistent Long Formula(if Inserting then $value = 0elseif ( isCurrentEvent( 'ORDERS.Purge') = false ) then $value = QtyOnHand - (QtyShipped - :OLD.QtyShipped) + (QtyReceived - :OLD.QtyReceived)end if)
QtyUnshipped Qty Unshipped Optional Persistent Long Sum(OrderItems(ORDERITEM), QtyOrdered, RepositoryName = SampDB1 and AttrName = QtyUnshipped and DataObjectName = PART)
QtyShipped Qty Shipped Optional Persistent Long Sum(OrderItems(ORDERITEM), QtyOrdered, RepositoryName = SampDB1 and AttrName = QtyShipped and DataObjectName = PART)
QtyReorder Qty Reorder Optional Persistent Long Default(0)
QtyReceived Qty Received Optional Persistent Long Sum(PartsReceived(PARTSRECEIVED), Quantity, RepositoryName = SampDB1 and AttrName = QtyReceived and DataObjectName = PART)
NeedsReorder Needs Reorder Optional Persistent Boolean Formula( if ((QtyOnHand - QtyUnshipped) < QtyReorder) then $value = true /* Yes */ else $value = falseend if /* May be set when QtyUnshipped increases as orders are placed*/ )
LatestCost Latest Cost Optional Persistent Currency Default(0)
ImageName Picture Optional Derived VarChar(75) Formula(getPartImageName())
Constraints When Constraint Error Message
Event Condition Action Condition Action
SendMessageToSupplier NeedsReorder = True /* Yes */ sendMessage(getPartNum() + ',' + getQtyReorder() )
Parent Relationships Parent Child Enforced
PART_JN_ORDERITEM PART (Part) ORDERITEM (OrderItems) Enforced
PART_JN_PARTSRECEIVED PART (Part) PARTSRECEIVED (PartsReceived) Enforced
Child Relationships Child Parent Enforced
VALID_MODELAUTO_JN_PART PART (PartsFor) VALID_MODELAUTO (ModelFor) Enforced
Indexes
Make_Model_PART Make || Model ||
User Defined Methods Method Signature
afterUpdate public void SampDB1.PARTImpl.afterUpdate(versata.vls.DataObject)
addListeners public void SampDB1.PARTImpl.addListeners()
getNewObject public static SampDB1.PARTImpl SampDB1.PARTImpl.getNewObject(versata.vls.Session,boolean)
getPartImageName public java.lang.String SampDB1.PARTImpl.getPartImageName()
sendMessage public void SampDB1.PARTImpl.sendMessage(java.lang.String)
Used By Used In
ORDERITEM ParentReplicate Price
ORDERITEM ParentReplicate AutoBucks
OrderItemJoinPart QUERY
PartQuery QUERY
PART FORM Basic_HTML:pPART
PART FORM Business_Change:pPART
PART FORM ShoppingCart:pPART
PART FORM PDX_Basic_HTML:pPartList
PART FORM PDX_Basic_HTML:pPartDetails
PART FORM Automation_Demo:pPick_Parts
PART FORM Automation_Demo:pPART
PART FORM Automation_Demo:pPARTS
PART FORM SortCombo:pPART_Grid
PART FORM _Demo:PART
PART FORM _Pick:fPART_Grid_Pick
PART FORM Client_Share_Form:fPART
PART FORM Client_Subclass_ContainerEvents:fPART
PART FORM Client_Subclass_MenuTree:PARTS
PART FORM Client_Tree_Customers:PartList
PART FORM Server_Extended_Rules_Mods:PARTS