Commit 88130e4b authored by manohar's avatar manohar

Potency calculation changes and inv_alloc_det, workorder_bill update changes


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@101766 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 5bb49b08
This source diff could not be displayed because it is too large. You can view the blob instead.
package ibase.webitm.ejb.mfg;
import java.util.ArrayList;
import java.util.Comparator;
import java.text.SimpleDateFormat;
public class WorderStkBean
{
......@@ -9,7 +12,7 @@ public class WorderStkBean
java.sql.Timestamp expDate = null,mfgDate = null;
private String locCode = "",lotNo = "",lotSl = "",siteCode = "",itemCode = "",itemRef = "",alternate = "",itemDescr = "",
workOrder = "",expLevel = "",critItem = "",unit = "",dimension = "",reserveStk = "",reserveStkTranId = "",
siteCodeMfg ="",otherSiteYN = "",stockSufficient = "",isStockDetail = "",alternateItem = "";
siteCodeMfg ="",otherSiteYN = "N",stockSufficient = "N",isStockDetail = "",alternateItem = "";
private double minQtyReq = 0,quantity = 0;
int reserveLineNo = 0;
......@@ -59,11 +62,7 @@ public class WorderStkBean
public void setReserveStkQty(double reserveStkQty) {
this.reserveStkQty = reserveStkQty;
}
public int getReserveLineNo() {
return reserveLineNo;
}
......@@ -137,7 +136,6 @@ public class WorderStkBean
this.dimension = dimension;
}
public double getStkPotencyPerc() {
return stkPotencyPerc;
}
......@@ -146,9 +144,6 @@ public class WorderStkBean
this.stkPotencyPerc = stkPotencyPerc;
}
public String getLocCode() {
return locCode;
}
......@@ -231,7 +226,6 @@ public class WorderStkBean
this.altItemCodeList = altItemCodeList;
}
//Changed by wasim on 23-03-2016 to get/set minimum quantity required [START]
public double getMinQtyReq() {
return minQtyReq;
......@@ -257,4 +251,30 @@ public class WorderStkBean
{
return quantity;
}
/* 31-may-16 manoharan Comparator for sorting the list by work_order,exp_lev, exp_date*/
public static Comparator<WorderStkBean> WoStkBeanComparator = new Comparator<WorderStkBean>() {
public int compare(WorderStkBean s1, WorderStkBean s2)
{
String dateStr1 = "", dateStr2 = "";
if (s1.getExpDate() != null)
{
dateStr1 = (String) (new SimpleDateFormat("yyyy/MM/dd").format(s1.getExpDate()));
}
if (s2.getExpDate() != null)
{
dateStr2 = (String) (new SimpleDateFormat("yyyy/MM/dd").format(s2.getExpDate()));
}
String KeyStockBean1 = s1.getWorkOrder().toUpperCase() + s1.getExpLevel() + dateStr1;
String KeyStockBean2 = s2.getWorkOrder().toUpperCase() + s2.getExpLevel() + dateStr2;
//ascending order
return KeyStockBean1.compareTo(KeyStockBean2);
//descending order
//return KeyStockBean2.compareTo(KeyStockBean1);
}
};
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment