* @param columnIndex
* @return verdi
*/
public Object getValueAt(final int rowIndex, final int columnIndex) {
Ordln ordln = (Ordln) getRow(rowIndex);
switch (columnIndex) {
case 0:
return ordln.getLnno();
case 1:
if(ordln.getProd()!=null){
return ordln.getProd().getProdNo();
}
return null;
case 2:
return ordln.getDescription();
case 3:
if (ordln.getNoOrg() != null) {
return ordln.getNoOrg().setScale(2);
}
return null;
case 4:
if (ordln.getDiscount() != null) {
return ordln.getDiscount().setScale(2);
}
return null;
case 5:
if (ordln.getFree1() != null) {
return ordln.getFree1().setScale(2);
}
return null;
case 6:
if (ordln.getCostPrice() != null) {
return ordln.getCostPrice().setScale(2);
}
return null;
case 7:
if (ordln.getPrice() != null) {
return ordln.getPrice().setScale(2);
}
return null;
default:
throw new IllegalStateException("Unknown column");
}