I have did a customization where using the pre assigned lot serial nbr feature to show the next lot serial nbr. i have did using the below code
PXResult<InventoryItem, INLotSerClass> result = new PXResult<InventoryItem, INLotSerClass>(invitm.Current, iNLotSerClass);
ILotSerNumVal numVal = INLotSerialNbrAttribute.ReadLotSerNumVal(this, result);
numVal.LotSerNumVal = numVal.LotSerNumVal + iNLotSerClass.AutoNextNbr;
string autoincrementnbr = INLotSerialNbrAttribute.GetNextNumber(invsetting.Cache, iNLotSerClass, numVal);
// invsetting.Current.LotSerNumVal = INLotSerialNbrAttribute.GetNextNumber(invsetting.Cache, iNLotSerClass, numVal);
Where it was working fine in 21R1 but when i check these in the 22R1 its not generating the next lot serial nbr using INLotSerialNbrAttribute.GetNextNumber(invsetting.Cache, iNLotSerClass, numVal);
all the time the lotserialnbr = LREX0000