transform(quantity: number, unitprice: number): any {
if (isNaN(quantity) || quantity === null) return ''; // Handle non-numeric values
if (isNaN(unitprice) || unitprice === null) return '';
// Round the number to the specified decimal places
// const roundedValue = Number(value.toFixed(decimalPlaces));
const exitprice=quantity * unitprice;
return exitprice
}
Here based on two fields data should update.
so writen pipe
in html given pipe like this
[value]='orderItemObj.Quantity | exitprice:orderItemObj.UnitPrice' for input
firstvalue ,pipe,second value.
No comments:
Post a Comment