Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for(var i=1; i <= rowCount-1; i++)
- {
- product[i-1] = [{
- 'product_id' : $('#product_id' + i).val(),
- 'name' : $('#item' + i).val(),
- 'model' : $('#model' + i).val(),
- 'reward' : $('#reward' +i).val(),
- 'subtract' : $('#subtract' + i).val(),
- 'minimum' : $('#minimum' + i).val(),
- 'shipping' : $('#shipping' + i).val(),
- 'tax_class_id' : $('#tax_class_id' + i).val(),
- 'weight' : $('#weight' + i).val(),
- 'quantity' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').val(),
- 'price' : $('table.order-table tbody tr[id=''+ i +'']').find('td.price').html(),
- 'total' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').parent().parent().find('td.total').html()
- }];
- }
- product[0][0][minimum]
- product[0][0][model] 326
- product[0][0][name] apple mac power
- product[0][0][price] 100.0000
- product[0][0][product_id] 50
- product[0][0][quantity] 5
- product[0][0][reward] 0
- product[0][0][shipping] 1
- product[0][0][subtract] 1
- product[0][0][tax_class_i... 0
- product[0][0][total] 500
- product[0][0][weight] 0.00000000
- product[1][0][minimum]
- product[1][0][model] 326
- product[1][0][name] apple mac power
- product[1][0][price] 100.0000
- product[1][0][product_id] 50
- product[1][0][quantity] 7
- product[1][0][reward] 0
- product[1][0][shipping] 1
- product[1][0][subtract] 1
- product[1][0][tax_class_i... 0
- product[1][0][total] 700
- product[0][name] = "apple mac power"
- for(var i=1; i <= rowCount-1; i++)
- {
- product = [{
- 'product_id' : $('#product_id' + i).val(),
- 'name' : $('#item' + i).val(),
- 'model' : $('#model' + i).val(),
- 'reward' : $('#reward' +i).val(),
- 'subtract' : $('#subtract' + i).val(),
- 'minimum' : $('#minimum' + i).val(),
- 'shipping' : $('#shipping' + i).val(),
- 'tax_class_id' : $('#tax_class_id' + i).val(),
- 'weight' : $('#weight' + i).val(),
- 'quantity' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').val(),
- 'price' : $('table.order-table tbody tr[id=''+ i +'']').find('td.price').html(),
- 'total' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').parent().parent().find('td.total').html()
- }];
- }
- product[0][minimum]
- product[0][model] 326
- product[0][name] apple mac power
- product[0][price] 100.0000
- product[0][product_id] 50
- product[0][quantity] 7
- product[0][reward] 0
- product[0][shipping] 1
- product[0][subtract] 1
- product[0][tax_class_i... 0
- product[0][total] 700
- for(var i=1; i <= rowCount-1; i++)
- {
- product[i-1] = {
- 'product_id' : $('#product_id' + i).val(),
- 'name' : $('#item' + i).val(),
- 'model' : $('#model' + i).val(),
- 'reward' : $('#reward' +i).val(),
- 'subtract' : $('#subtract' + i).val(),
- 'minimum' : $('#minimum' + i).val(),
- 'shipping' : $('#shipping' + i).val(),
- 'tax_class_id' : $('#tax_class_id' + i).val(),
- 'weight' : $('#weight' + i).val(),
- 'quantity' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').val(),
- 'price' : $('table.order-table tbody tr[id=''+ i +'']').find('td.price').html(),
- 'total' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').parent().parent().find('td.total').html()
- };
- }
- for(var i=1; i <= rowCount-1; i++)
- {
- product.push({
- 'product_id' : $('#product_id' + i).val(),
- 'name' : $('#item' + i).val(),
- 'model' : $('#model' + i).val(),
- 'reward' : $('#reward' +i).val(),
- 'subtract' : $('#subtract' + i).val(),
- 'minimum' : $('#minimum' + i).val(),
- 'shipping' : $('#shipping' + i).val(),
- 'tax_class_id' : $('#tax_class_id' + i).val(),
- 'weight' : $('#weight' + i).val(),
- 'quantity' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').val(),
- 'price' : $('table.order-table tbody tr[id=''+ i +'']').find('td.price').html(),
- 'total' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').parent().parent().find('td.total').html()
- });
- }
- for(var i=1; i <= rowCount-1; i++)
- {
- product[i-1] = { // Removed array open
- 'product_id' : $('#product_id' + i).val(),
- 'name' : $('#item' + i).val(),
- 'model' : $('#model' + i).val(),
- 'reward' : $('#reward' +i).val(),
- 'subtract' : $('#subtract' + i).val(),
- 'minimum' : $('#minimum' + i).val(),
- 'shipping' : $('#shipping' + i).val(),
- 'tax_class_id' : $('#tax_class_id' + i).val(),
- 'weight' : $('#weight' + i).val(),
- 'quantity' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').val(),
- 'price' : $('table.order-table tbody tr[id=''+ i +'']').find('td.price').html(),
- 'total' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').parent().parent().find('td.total').html()
- }; // Removed array close
- }
- product[0]['name'] = "apple mac power"
- product[0].name = "apple mac power"
- product[0][name] = "apple mac power"
- product[i-1] = {
- 'product_id' : $('#product_id' + i).val(),
- 'name' : $('#item' + i).val(),
- 'model' : $('#model' + i).val(),
- 'reward' : $('#reward' +i).val(),
- 'subtract' : $('#subtract' + i).val(),
- 'minimum' : $('#minimum' + i).val(),
- 'shipping' : $('#shipping' + i).val(),
- 'tax_class_id' : $('#tax_class_id' + i).val(),
- 'weight' : $('#weight' + i).val(),
- 'quantity' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').val(),
- 'price' : $('table.order-table tbody tr[id=''+ i +'']').find('td.price').html(),
- 'total' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').parent().parent().find('td.total').html()
- };
- product[i-1] = [{
- 'product_id' : $('#product_id' + i).val(),
- 'name' : $('#item' + i).val(),
- 'model' : $('#model' + i).val(),
- 'reward' : $('#reward' +i).val(),
- 'subtract' : $('#subtract' + i).val(),
- 'minimum' : $('#minimum' + i).val(),
- 'shipping' : $('#shipping' + i).val(),
- 'tax_class_id' : $('#tax_class_id' + i).val(),
- 'weight' : $('#weight' + i).val(),
- 'quantity' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').val(),
- 'price' : $('table.order-table tbody tr[id=''+ i +'']').find('td.price').html(),
- 'total' : $('table.order-table tbody tr td.quantity input[name='quantity'+ i +'']').parent().parent().find('td.total').html()
- }];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement