Commit 9c528df5 authored by steurwadkar's avatar steurwadkar

Wavegen Wizard changes Check-in by Santosh


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@104067 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 910acd71
......@@ -116,8 +116,7 @@ button.accordion {
button.accordion.active, button.accordion:hover {
border : 1px solid #ddd !important;
}
button.activeAccor{
border : 1px solid #fbd850 !important;
button.accordion.activeAccor{
background-color: #fdf5ce;
}
button.accordion.active{
......@@ -128,9 +127,9 @@ button.accordionSO.accordion {
background-color: white;
border:0px solid #ddd !important;
border-top:1px solid #ddd !important;
border-bottom:1px solid #ddd !important;
border-bottom:0px solid #ddd !important;
border-radius:0px;
padding: 6px;
padding: 4px;
color: #000;
cursor: pointer;
width: 100%;
......@@ -141,31 +140,28 @@ button.accordionSO.accordion {
transition: 0.6s;
line-height: 20px;
}
button.accordionSO, button.accordion:first-child{
margin-top:2px !important;
}
button.accordionSO.active, button.accordionSO:hover {
border-top:1px solid #ccc !important;
border-bottom:1px solid #ccc !important;
background-color: #eee;
}
button.accordionSO.active{
border-bottom : 0px solid #fbd850 !important;
background-color: #eee;
}
div.panel {
padding:0px;
border:1px solid #ddd !important;
border:1px solid #ccc !important;
background-color: white;
max-height: 0;
overflow: hidden;
transition: 0.4s ease-in-out;
opacity: 0;
overflow: auto;
}
.panel.panelSO {
border: none !important;
}
div.panel.show {
border-top:1px solid lightgray !important;
border-top:0px solid lightgray !important;
opacity: 1;
max-height: 2000px;
}
......@@ -175,7 +171,7 @@ div.panel.show {
padding-top:2px;
}
div.panelSO.show{
padding : 2 0px;
padding : 0px;
border:0px solid lightgray !important;
border-bottom:0px solid lightgray !important;
overflow-x:scroll;
......@@ -224,3 +220,55 @@ div.panelSO.show{
margin: 0px !important;
z-index:0 !important;
}
.custImg{
z-index: 25 !important;
width: 32px;
height: 32px;
top: 4px;
left: 4px;
border-radius:50%;
position: absolute;
}
.itemImg{
width: 24px;
height: 24px;
border-radius:50%;
margin-top:6px;
margin-right:3px;
float: left;
}
.qtyHighlight{
width: 5px;
height: 5px;
float: right;
margin-top:10px;
}
.imagePanel
{
display:none;
float:right;
right:0;
margin-top:2px;
margin-right:8px;
width:200px;
height:250px;
border:1px solid lightgray;
position: absolute;
z-index: 30;
background: white;
}
.closeDiv{
position: absolute;
float: left;
margin:-8px;
text-align:center;
line-height:22px;
background-color: #777;
color:white;
width:22px;
height:22px;
border-radius:50%;
cursor: pointer;
}
......@@ -781,7 +781,6 @@ function updateDisplaySummary(custId,tableId,tableNo)
var custPercentage = Math.round(custTotalAllocQty/custTotalQty*100);
document.getElementById("custPercVal"+custId).innerHTML = custPercentage;
document.getElementById("custLine"+custId).innerHTML = custLineCnt;
document.getElementById("custPercText"+custId).innerHTML = custPercentage+"%";
var custPecrObj = document.getElementById("percClass"+custId);
custPecrObj.className = "c100 small";
......@@ -803,7 +802,6 @@ function updateDisplaySummary(custId,tableId,tableNo)
var prevCustPerc = document.getElementById("prevCustPerc"+custId).value;
custPecrObj.className = "c100 small";
custPecrObj.classList.add("p"+prevCustPerc);
document.getElementById("custPercText"+custId).innerHTML = prevCustPerc+"%";
}
tableObj = document.getElementById(tableId);
......@@ -839,7 +837,7 @@ function updateDisplaySummary(custId,tableId,tableNo)
}
function setCheckboxRow(event,curRow,tableNo,custId,tableId)
{
if (event.target.type !== 'checkbox' && event.target.type != 'select-one' && event.target.type != 'text')
if (event.target.nodeName !== 'INPUT' && event.target.nodeName != 'SELECT' && event.target.nodeName != 'IMG')
{
if(curRow.cells[0].childNodes != undefined)
{
......@@ -871,7 +869,16 @@ function setCheckboxRow(event,curRow,tableNo,custId,tableId)
checkedCount += 1;
}
}
if(checkedCount == chkElements.length)
{
document.getElementById("selectAll"+tableNo).checked = (checkedCount === chkElements.length);
document.getElementById("selectAll"+tableNo).setAttribute('checked','checked');
}
else
{
document.getElementById("selectAll"+tableNo).checked = false;
document.getElementById("selectAll"+tableNo).removeAttribute('checked');
}
}
updateDisplaySummary(custId,tableId,tableNo);
......@@ -933,7 +940,17 @@ function selectThisRow(curObj, rowId, tableNo, custId, tableId)
checkedCount += 1;
}
}
if(checkedCount == chkElements.length)
{
document.getElementById("selectAll"+tableNo).checked = (checkedCount === chkElements.length);
document.getElementById("selectAll"+tableNo).setAttribute('checked','checked');
}
else
{
document.getElementById("selectAll"+tableNo).checked = false;
document.getElementById("selectAll"+tableNo).removeAttribute('checked');
}
}
updateDisplaySummary(custId,tableId,tableNo);
......@@ -986,3 +1003,42 @@ function displayDataFromSession(retHtmlData)
overlay.removeAttribute('style');
document.getElementById("buttonreplacement").style.display = "none";
}
function showItemImage(itemCode,itemDescr)
{
var url = "/ibase/WavegenWizServlet?REF_ID="+itemCode+"&action=GET_IMG_PATH&ITEM_DESCR="+itemDescr+"";
makeRequest(url, getImgPath);
}
function getImgPath(retVal)
{
document.getElementById("sideImagePanel").style.display="block";
if(document.getElementById("sideImagePanel").innerHTML != "")
{
document.getElementById("sideImagePanel").innerHTML = "";
}
var xmlDoc = loadXMLString(retVal);
var imgNode = xmlDoc.getElementsByTagName("imgPath")[0];
var imgPath = imgNode.childNodes[0].nodeValue;
var closeDiv = document.createElement("div");
closeDiv.setAttribute("class","closeDiv");
closeDiv.innerHTML = "X";
document.getElementById("sideImagePanel").appendChild(closeDiv);
var imgElement = document.createElement("img");
imgElement.setAttribute("src", imgPath);
imgElement.setAttribute("class", "imagePanelSrc");
imgElement.setAttribute("height", "100%");
imgElement.setAttribute("width", "100%");
document.getElementById("sideImagePanel").appendChild(imgElement);
}
window.onclick = function (event)
{
if(!event.target.matches(".imagePanelSrc") && !event.target.matches(".itemImg"))
{
document.getElementById("sideImagePanel").style.display="none";
}
}
......@@ -149,7 +149,7 @@
</xsl:for-each>
</table>
</div>
<div id="sideImagePanel" class="imagePanel"></div>
<div id="popHelpContainer"></div>
<div id="overlay"></div>
<div id="mainPageHeaderContatiner">
......@@ -240,11 +240,12 @@
</xsl:if>
<xsl:if test ="$dbID != '0'">
<xsl:variable name="custDbID"><xsl:value-of select="@domID"/></xsl:variable>
<xsl:variable name="custCode"><xsl:value-of select="cust_code"/></xsl:variable>
<button class="accordion" id="custPerc{$custDbID}" type="button" expanded="false">
<xsl:variable name="allocPerc"><xsl:value-of select="total_alloc_perc"/></xsl:variable>
<input type="hidden" id="prevCustPerc{$custDbID}" value="{$allocPerc}"/>
<div id="percClass{$custDbID}" class="c100 small p{$allocPerc}">
<span id="custPercText{$custDbID}" class="percText"><xsl:value-of select="total_alloc_perc"/>%</span>
<img src="/ibase/resource/customer/{$custCode}.png" class="custImg"/>
<div class="slice">
<div id="custbar{$custDbID}" class="bar"></div>
<div id="custfill{$custDbID}" class="fill"></div>
......@@ -265,7 +266,7 @@
<xsl:variable name="soAllocPerc"><xsl:value-of select="alloc_perc"/></xsl:variable>
<input type="hidden" id="prevSoPerc{$soDbID}" value="{$soAllocPerc}"/>
<button class="accordion accordionSO" type="button" expanded="false">
<div id="soPercClass{$soDbID}" class="c100 small p{$soAllocPerc}" style="margin-left:5px !important;">
<div id="soPercClass{$soDbID}" class="c100 small p{$soAllocPerc}" style="margin-left:10px !important;">
<span id="soPercText{$soDbID}" class="percText"><xsl:value-of select="alloc_perc"/>%</span>
<div class="slice">
<div id="sobar{$soDbID}" class="bar"></div>
......@@ -355,6 +356,8 @@
<xsl:variable name="exp_lev"><xsl:value-of select="exp_lev"/></xsl:variable>
<xsl:variable name="last_col"><xsl:value-of select="last_col"/></xsl:variable>
<xsl:variable name="part_qty_real"><xsl:value-of select="part_qty_real"/></xsl:variable>
<xsl:variable name="qty_highlighter"><xsl:value-of select="qty_highlighter"/></xsl:variable>
<xsl:variable name="image_path"><xsl:value-of select="image_path"/></xsl:variable>
<tr class='trClass' id="{$linedbID}" onclick="setCheckboxRow(event,this,{$soDbID},'{$custDbID}','details{$soDbID}');">
<td nowrap="true" style="border-left:0px solid black !important;">
<Input type='checkbox' value="true" class="selectAll{$soDbID}" name="Detail2.{normalize-space($linedbID)}.selectbox" id="Detail2.{normalize-space($linedbID)}.selectbox" onclick="setCheckbox(this,'{$linedbID}','{$soDbID}','{$custDbID}','details{$soDbID}');" tabindex="-1" />
......@@ -387,8 +390,9 @@
<xsl:value-of select="due_date"/>
<input type="hidden" name="Detail2.{normalize-space($linedbID)}.due_date" value="{$due_date}"></input>
</td>
<td nowrap="true">
<td nowrap="true" style="padding:0 3px;">
<xsl:value-of select="item_code"/>
<img type="image" src="{$image_path}" class="itemImg" onclick="showItemImage('{normalize-space($item_code)}','{$item_descr}');" />
<input type="hidden" name="Detail2.{normalize-space($linedbID)}.item_code" value="{$item_code}"></input>
</td>
<td nowrap="true">
......@@ -407,8 +411,9 @@
<xsl:value-of select="stock_quantity"/>
<input type="hidden" name="Detail2.{normalize-space($linedbID)}.stock_quantity" value="{$stock_quantity}"></input>
</td>
<td nowrap="true" align="right">
<input type="text" name="Detail2.{normalize-space($linedbID)}.qty_alloc" id="Detail2.{normalize-space($linedbID)}.qty_alloc" value="{$qty_alloc}" onchange="selectThisRow(this,{$linedbID}, {$soDbID},'{$custDbID}','details{$soDbID}');" onpaste="return false;" onkeypress="return isNumberKey(event);" style="text-align:right;width:65px;"></input>
<td nowrap="true" align="right" style="padding: 0 3px;vertical-align:middle;">
<input type="text" name="Detail2.{normalize-space($linedbID)}.qty_alloc" id="Detail2.{normalize-space($linedbID)}.qty_alloc" value="{$qty_alloc}" onchange="selectThisRow(this,{$linedbID}, {$soDbID},'{$custDbID}','details{$soDbID}');" onpaste="return false;" onkeypress="return isNumberKey(event);" style="text-align:right;width:65px;float:left;"></input>
<div class="qtyHighlight" style="background-color:{$qty_highlighter}"></div>
</td>
<td nowrap="true" align="right">
<xsl:value-of select="hold_qty"/>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment