Commit fa442ca7 authored by smestry's avatar smestry

W15ESUN005, Changed by Sneha. Updated the JSP for Location Stock Occupancy dashboard.


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@98599 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 12595a13
...@@ -408,14 +408,10 @@ span.appendChild(document.createTextNode(location)); ...@@ -408,14 +408,10 @@ span.appendChild(document.createTextNode(location));
<% <%
try { try {
String abc = request.getParameter("siteCode"); String site = request.getParameter("siteCode");
System.out.print("abc==nu ="+(abc==null)); //System.out.print("abc==nu ="+(abc==null));
System.out.print("abc== ="+(abc=="null")); //System.out.print("abc== ="+(abc=="null"));
// System.out.print("abc.equals( ="+(abc.equals("null")));
//System.out.print("abc.equals(null ="+(abc.equals(null));
//System.out.print("abc.equalsIgnoreCase(nu ="+abc.equalsIgnoreCase(null));
//System.out.print("abc.equalsIgnoreCas="+abc.equalsIgnoreCase("null"));
if (siteCode == null || siteCode.trim().length() == 0 ) if (siteCode == null || siteCode.trim().length() == 0 )
{ {
...@@ -424,11 +420,11 @@ span.appendChild(document.createTextNode(location)); ...@@ -424,11 +420,11 @@ span.appendChild(document.createTextNode(location));
siteCodeStr = scmdasBean.getSiteCode(); siteCodeStr = scmdasBean.getSiteCode();
System.out.print("Site code if null ::::::::: " + siteCodeStr); System.out.print("Site code if null ::::::::: " + siteCodeStr);
// End by Sneha, added site code dropdown on 17-08-2015, Request ID: SMWMS00008 // End by Sneha, added site code dropdown on 17-08-2015, Request ID: SMWMS00008
} }
System.out.print("siteCode"+abc+"sachin"); //System.out.print("siteCode"+abc+"sachin");
if(abc==null) if(site==null)
{ {
ibase.utility.UserInfoBean userInfo = (ibase.utility.UserInfoBean) session.getAttribute("USER_INFO"); ibase.utility.UserInfoBean userInfo = (ibase.utility.UserInfoBean) session.getAttribute("USER_INFO");
String user = userInfo.getLoginCode(); String user = userInfo.getLoginCode();
...@@ -440,7 +436,6 @@ span.appendChild(document.createTextNode(location)); ...@@ -440,7 +436,6 @@ span.appendChild(document.createTextNode(location));
siteCode = request.getParameter("siteCode"); siteCode = request.getParameter("siteCode");
System.out.print("siteCode from URL ::::::::: " ); System.out.print("siteCode from URL ::::::::: " );
} }
System.out.print("out side the else loop :::::::::: " );
// System.out.print("Site code from session UserInfoBean :::::::::: " + siteCode); // System.out.print("Site code from session UserInfoBean :::::::::: " + siteCode);
if(xmlString == "") if(xmlString == "")
...@@ -450,7 +445,7 @@ span.appendChild(document.createTextNode(location)); ...@@ -450,7 +445,7 @@ span.appendChild(document.createTextNode(location));
//add by Birendra Pandey on dated 21 Aug 2014 //add by Birendra Pandey on dated 21 Aug 2014
selectedArea = request.getParameter("area"); selectedArea = request.getParameter("area");
locationRange = request.getParameter("locationRange"); locationRange = request.getParameter("locationRange");
System.out.println("selectedArea ::::::::" + selectedArea);
// Changed by Sneha, added site code dropdown on 17-08-2015, Request ID: SMWMS00008 // Changed by Sneha, added site code dropdown on 17-08-2015, Request ID: SMWMS00008
// siteCode = request.getParameter("siteCode") == null ? "no" : request.getParameter("siteCode") ; // siteCode = request.getParameter("siteCode") == null ? "no" : request.getParameter("siteCode") ;
...@@ -898,9 +893,9 @@ span.appendChild(document.createTextNode(location)); ...@@ -898,9 +893,9 @@ span.appendChild(document.createTextNode(location));
</form> </form>
<script> <script>
areaCode ="<%=request.getParameter("area")%>";
locRange ="<%=this.locationRange%>"; locRange ="<%=this.locationRange%>";
siteCode ="<%=this.siteCode%>"; siteCode ="<%=this.siteCode%>";
areaCode ="<%=this.selectedArea%>";
document.getElementById("locationRange").value=locRange; document.getElementById("locationRange").value=locRange;
window.onload = new function() { window.onload = new function() {
...@@ -909,12 +904,16 @@ span.appendChild(document.createTextNode(location)); ...@@ -909,12 +904,16 @@ span.appendChild(document.createTextNode(location));
for (var m = 0; m < currList.options.length; m++) for (var m = 0; m < currList.options.length; m++)
{ {
var checkval = currList.options[m].value; var checkval = currList.options[m].value;
//alert("areaCode :::::::: " + areaCode);
if(areaCode != null)
{
areaCode = areaCode.trim();
if(areaCode == checkval) if(areaCode == checkval)
{ {
currList.options[m].selected = true; currList.options[m].selected = true;
} }
} }
}
var currListSiteCode = document.getElementById("siteCode"); var currListSiteCode = document.getElementById("siteCode");
for (var n = 0; n < currListSiteCode.options.length; n++) for (var n = 0; n < currListSiteCode.options.length; n++)
...@@ -925,7 +924,7 @@ span.appendChild(document.createTextNode(location)); ...@@ -925,7 +924,7 @@ span.appendChild(document.createTextNode(location));
//alert("SiteCode :::::::: " + siteCode); //alert("SiteCode :::::::: " + siteCode);
currListSiteCode.options[n].selected = true; currListSiteCode.options[n].selected = true;
} }
} }
}; };
......
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