[Vtigercrm-commits] [vtiger-commits] r4341 - /vtigercrm/trunk/include/js/general.js
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Mon Mar 20 10:37:28 EST 2006
Author: saraj
Date: Mon Mar 20 08:37:24 2006
New Revision: 4341
Log:
Changes made for Inventory
Modified:
vtigercrm/trunk/include/js/general.js
Modified: vtigercrm/trunk/include/js/general.js
==============================================================================
--- vtigercrm/trunk/include/js/general.js (original)
+++ vtigercrm/trunk/include/js/general.js Mon Mar 20 08:37:24 2006
@@ -1363,6 +1363,7 @@
var prev = tableName.rows.length;
var count = prev;
var row = tableName.insertRow(prev);
+ row.id = "row"+count;
if(count%2)
row.className = "dvtCellLabel";
else
@@ -1374,14 +1375,38 @@
var colfive = row.insertCell(4);
var colsix = row.insertCell(5);
var colseven = row.insertCell(6);
- colone.innerHTML="<input type='text' name='txtProduct'+count class='detailedViewProdTextBox' readonly/> <img src='themes/blue/images/search.gif' align='absmiddle' />";
+ colone.innerHTML="<input type='text' name='txtProduct"+count+"' class='detailedViewProdTextBox' readonly/> <img src='themes/blue/images/search.gif' onclick='productPickList(this)' align='absmiddle' /><input type='hidden' id='hdnProductId"+count+"' name='hdnProductId"+count+"'>";
coltwo.innerHTML=" ";
- colthree.innerHTML="<input type='text' name='txtQty'+count class='detailedViewTextBox' onfocus='this.className=\"detailedViewTextBoxOn\"' onblur='this.className=\"detailedViewTextBox\"'/> ";
- colfour.innerHTML=" ";
- colfive.innerHTML="<input type='text' name='txtListPrice'+count class='detailedViewProdTextBox' readonly/> <img src='themes/blue/images/pricebook.gif' align='absmiddle' /> ";
- colsix.innerHTML=" ";
+ colthree.innerHTML="<input type='text' name='txtQty"+count+"' class='detailedViewTextBox' onfocus='this.className=\"detailedViewTextBoxOn\"' onBlur='this.className=\"detailedViewTextBox\"; calcTotal(this);' /> ";
+ colfour.innerHTML=" <div id='qtyInStock"+count+"'></div><div id='unitPrice"+count+"'></div>";
+ colfive.innerHTML="<input type='text' name='txtListPrice"+count+"' class='detailedViewProdTextBox' readonly onBlur='calcTotal(this)'> <img src='themes/blue/images/pricebook.gif' onClick='priceBookPickList(this)' align='absmiddle' style='cursor:hand;cursor:pointer' title='Price Book' /> ";
+ colsix.innerHTML=" <div id='total"+count+"' align='right'></div><input type='hidden' id='hdnTotal"+count+"' name='hdnTotal"+count+"'>";
colseven.innerHTML="<span class='delTxt' onclick=\"deleteRow(this.parentNode.parentNode.rowIndex)\">Del</span>";
-
+
+}
+function fnAddRowForPO(){
+ var tableName = document.getElementById('proTab');
+ var prev = tableName.rows.length;
+ var count = prev;
+ var row = tableName.insertRow(prev);
+ row.id = "row"+count;
+ if(count%2)
+ row.className = "dvtCellLabel";
+ else
+ row.className = "dvtCellInfo";
+ var colone = row.insertCell(0);
+ var coltwo = row.insertCell(1);
+ var colthree = row.insertCell(2);
+ var colfour = row.insertCell(3);
+ var colfive = row.insertCell(4);
+ var colsix = row.insertCell(5);
+ colone.innerHTML="<input type='text' name='txtProduct"+count+"' class='detailedViewProdTextBox' readonly/> <img src='themes/blue/images/search.gif' onclick='productPickList(this)' align='absmiddle' /><input type='hidden' id='hdnProductId"+count+"' name='hdnProductId"+count+"'>";
+ coltwo.innerHTML="<input type='text' name='txtQty"+count+"' class='detailedViewTextBox' onfocus='this.className=\"detailedViewTextBoxOn\"' onBlur='this.className=\"detailedViewTextBox\"; calcTotal(this);' /> ";
+ colthree.innerHTML=" <div id='qtyInStock"+count+"'></div><div id='unitPrice"+count+"'></div>";
+ colfour.innerHTML="<input type='text' name='txtListPrice"+count+"' class='detailedViewProdTextBox' readonly onBlur='calcTotal(this)'> <img src='themes/blue/images/pricebook.gif' onClick='priceBookPickList(this)' align='absmiddle' style='cursor:hand;cursor:pointer' title='Price Book' /> ";
+ colfive.innerHTML=" <div id='total"+count+"' align='right'></div><input type='hidden' id='hdnTotal"+count+"' name='hdnTotal"+count+"'>";
+ colsix.innerHTML="<span class='delTxt' onclick=\"deleteRow(this.parentNode.parentNode.rowIndex)\">Del</span>";
+
}
More information about the vtigercrm-commits
mailing list