Hello Everyone,
I want a report where I can show the On hand inventory both in Inventory unit and purchase unit.i.e. inventory unit is KG and purchase unit is PCS.unit conversion of KG to PCS available,how do I show both Inventory unit and purchase unit on hand on the report.
Thanks,
There is no such standard report. You may have to add another column that converts the inventory qty to qty in purchasing unit of measure.
It you are able to convert necessary conversions then as Kranthi said, add another field with method that contains the conversion code in standard Inventory report.
Thank you very much kranti and amol for your reply.
Can you please highlight me on the coding side.unit conversion are stored on UnitConvert table and onhand are stored on InventSum table.
I have created one column in InventSum for purchase on hand.how I call Unitconvert conversion to here.
Thanks,
You don’t have to add a column to InventSum table. If you add, then you have to update it as well. That would impact the performance. You need to modify the report to show the current on hand quantity in purchasing unit.
You can use \Classes\InventItemUnitConvert\qty for conversion.
Dear Mr.Kranthi,
Thanks for your reply,when I am using the said class in my new report,it is not showing to me the correct value the conversion one.I assigned one new real control in the body of report and this control I am assigning the QTY field to show it but it is not showing.
Thanks,
Hi, if possible please show us the code that you are using for the conversion.
Dear Mr.Kranthi,
Kindly check below code.
public Qty qty(Qty qtyFrom,
UnitID unitFrom,
UnitID unitTo,
ItemId _itemId,
boolean roundOff = true)
{
;
if (! unitFrom || ! unitTo || unitFrom == unitTo)
return qtyFrom;
this.setParameters(_itemId, unitFrom, unitTo);
return unitConvert.convertQty(qtyFrom, unitFrom, unitTo, roundOff);
Thanks,
That is standard code from \Classes\InventItemUnitConvert\qty
I am asking how you are calling it in the report? BTW, you can debug to see why the conversion is not happening.
Dear Mr.Kranthi,
what is the standard practice to make it happen.I tried by 2-3 ways but all failed.
Thanks
Hi, Can you able to share the code?
look at the cross references of that method, to understand how to use it.