19 package org.turro.erp.purchase;
21 import org.turro.erp.entity.OrderReference;
22 import org.turro.erp.entity.ReceiptItem;
23 import org.turro.erp.entity.Task;
24 import org.turro.erp.entity.WorkOrder;
25 import org.turro.financials.product.IProduct;
26 import org.turro.math.Zero;
36 private long workOrderId;
39 private double units, cost;
40 private String description;
63 this.description = concept;
79 if(this.orderRef != orderRef) {
80 orderReference =
null;
83 if(or.getOrderRef() == orderRef) {
89 this.orderRef = orderRef;
93 return orderReference;
97 this.orderReference = orderReference;
105 this.iProduct = product;
106 if(cost == 0 && product !=
null) {
136 this.workOrder = workOrder;
144 if(this.workOrderId != workOrderId) {
147 orderReference =
null;
150 this.workOrderId = workOrderId;
154 return task !=
null && iProduct !=
null &&
RequiredUsage getRequiredUsage()
OrderReference getOrderReference()
static WorkOrder getByWorkOrderId(long value)
Set< OrderReference > getOrderReferences()
void setConcept(String concept)
void setIProduct(IProduct product)
void setOrderReference(OrderReference orderReference)
void setUnits(double units)
void setCost(double cost)
ProductsItem(ReceiptItem ri)
OrderReference getOrderReference()
void setOrderRef(int orderRef)
void setWorkOrderId(long workOrderId)
void setWorkOrder(WorkOrder workOrder)
static boolean near(double value, int digits)