title: jquery display decimals in val
body: <p>I have the below syntax, each of these functions sets the value of an input box.</p>
  
  <p>Discount, 1 decimal place
  adjusted price, 2 decimal places (currency)</p>
  
  <p>How do I show the decimal places with for each function.</p>
  
  <pre><code>   function calculateRow(row) {
          var price = +row.find('input[name^="adjustedprice"]').val();
          var qty = +row.find('input[name^="qty"]').val();
          row.find('input[name^="linetotal"]').val((price * qty).toFixed(2));
          var listprice = +row.find('input[name^="price"]').val();
          var discount = 0;
          var discount = Math.round(100 - (price / listprice) * 100);
          row.find('input[name^="discount"]').val(discount);
      }
  
      function calculateAjustedPrice(row) {
          var listprice = +row.find('input[name^="price"]').val();
          var discount = +row.find('input[name^="discount"]').val();
          var adjustedprice = Math.round((listprice/100)*(100-discount));
          row.find('input[name^="adjustedprice"]').val(adjustedprice);
          calculateRow(row);
          calculateGrandTotal();
      }
  </code></pre>
  
  <p>Thanks in advance.</p>