Files
matrix/build/WebContent/WEB-INF/app/edp/tools/colony.jsp
2026-07-21 20:46:27 +05:30

326 lines
16 KiB
Plaintext

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<%@page language="java" session="true" %>
<%@taglib uri="http://www.springframework.org/tags/form" prefix="form"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<%@taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<script language="javascript" src="/matrix/js/lib/constants.js" type="text/javascript"></script>
<script language="javascript" src="/matrix/js/jquery1.7.2.js" type="text/javascript"></script>
<script language="javascript" src="/matrix/js/ui/uifuncs.js" type="text/javascript"></script>
<script language="javascript" src="/matrix/js/lib/jsfuncs.js" type="text/javascript"></script>
<script language="javascript" src="/matrix/js/ui/msgdialog.js" type="text/javascript"></script>
<script language="javascript" src="/matrix/js/ui/progressbar.js" type="text/javascript"></script>
<script language="javascript" src="/matrix/js/ui/select.js" type="text/javascript"></script>
<script language="javascript" src="/matrix/js/appjs/colony.js" type="text/javascript"></script>
<script language="javascript" src="/matrix/js/validator.js" type="text/javascript"></script>
<link href="/matrix/css/matrix.css" rel="stylesheet" type="text/css" />
<link href="/matrix/css/button.css" rel="stylesheet" type="text/css" />
<link href="/matrix/css/div.css" rel="stylesheet" type="text/css" />
<link href="/matrix/css/textbox.css" rel="stylesheet" type="text/css" />
<link href="/matrix/css/select.css" rel="stylesheet" type="text/css" />
<link href="/matrix/css/table.css" rel="stylesheet" type="text/css" />
<title>Cygnus 1.0 | Allocation</title>
<link href="/matrix/css/bootstrap-5.3.8.min.css" rel="stylesheet" type="text/css" />
<link href="/matrix/css/matrix-v2.css?v=6" rel="stylesheet" type="text/css" />
<link href="/matrix/css/matrix-shell-v2.css?v=7" rel="stylesheet" type="text/css" />
<link href="/matrix/css/tool-workspace-v3.css?v=2" rel="stylesheet" type="text/css" />
<link href="/matrix/css/edp-colony-v3.css?v=1" rel="stylesheet" type="text/css" />
<script src="/matrix/js/bootstrap-5.3.8.bundle.min.js" defer></script>
<script src="/matrix/js/matrix-shell-v2.js" defer></script>
<link href="/matrix/css/matrix-frame-dialog.css?v=6" rel="stylesheet" type="text/css" />
<script src="/matrix/js/matrix-frame-dialog.js?v=2" defer></script>
<script src="/matrix/js/matrix-accessibility-v1.js?v=1" defer></script>
<link href="/matrix/css/matrix-theme-v2.css?v=4" rel="stylesheet" type="text/css" />
</head>
<body class="matrix-v2 matrix-shell matrix-tool-workspace matrix-edp-colony">
<div id='PageFrame'>
<%@ include file="/WEB-INF/app/fragments/app-shell-header.jspf" %>
<%-- Shared shell owns ${Sessvals.menuHtml}. --%>
<div id="formcontainer" class="matrix-tool-workspace__content" style="max-width:1200px">
<form:form method="post" name="colony" id="colony" modelAttribute="beltAlloc" >
<!-- Common Details (Section1) Visible for all portfolios-->
<div>
<!-- Title -->
<div class="title">
<img class="matrix-title-icon" src="/matrix/images/sms.png" align="absmiddle" />
<span class="matrix-title-text" align="absmiddle">Colony Allocation</span>
<img class="matrix-title-action" src="/matrix/images/reload.png" title="Refresh Grid" onclick="SubmitForm('colony','_parent','beltAlloc')"/>
</div>
<!-- -->
<div id="FormPanel" class="FormPanel">
<table align="center" id="filtertab" style="width:98%;border:1px solid #a7abb4" cellspacing="0">
<tr>
<td>
<div id="crtverdiv" class="linkbutton" style="float:right" onclick="$('#verifierform').show();" >Create Verifier</div>
<div id="crtcoldiv" class="linkbutton" style="float:right" onclick="$('#colbeltdd').html($('#beltto').html());$('#colverdd').html($('#verf').html());$('#colonyform').show();">Create Colony</div>
<div id="crtbeltdiv" class="linkbutton" style="float:right" onclick="$('#beltform').show();">Create Belt</div>
<div id="trsbothdiv" class="linkbutton" style="float:right" onclick="toggleShowHide('widget2,widget3','',',','1');$('#hftransmode').val('3');">Transfer & Allocate Belt</div>
<div id="trscoldiv" class="linkbutton" style="float:right" onclick="toggleShowHide('widget2','widget3',',','1');$('#hftransmode').val('1');">Transfer Colony</div>
<div id="trsverdiv" class="linkbutton" style="float:right" onclick="toggleShowHide('widget3','widget2',',','1');$('#hftransmode').val('2');">Transfer Verifier</div>
</td>
<!-- <td id="progbarContainer" ><input type="button" class="button" name="btnbelt" style="float:left;" value="Create Belt" id="btnbelt" accesskey="B" /></td>
<td align="left"><input type="button" class="button" name="btncol" style="float:left;" value="Create Colony" id="btncol" accesskey="O" /></td>
<td align="left"><input type="button" class="button" name="btnver" style="float:left" value="Create Verifier" id="btnver" accesskey="V" /></td> -->
</tr>
<tr>
<td>
<div class="widget" id="widget1" >
<div class="lblcontainer">
Belt
</div>
<div class="inputcontainer">
<div class="divselect" id="divbelt" style="width:82px">
<select id="belts" style="width:100px" onchange="getColonyData(3);">
<option value="-1">Select</option>
<c:forEach items="${beltlist}" var="belt">
<option value="${belt[0]}" >${belt[1]}</option>
</c:forEach>
</select>
</div>
</div>
</div>
<div class="widget" id="widget2" >
<div class="lblcontainer">
To Belt
</div>
<div class="inputcontainer">
<div class="divselect" id="divbeltto" style="width:82px; ">
<select id="beltto" style="width:100px" onchange="">
<option value="-1">Select</option>
<c:forEach items="${beltlist}" var="belt">
<option value="${belt[0]}" >${belt[1]}</option>
</c:forEach>
</select>
</div>
</div>
</div>
<div class="widget" id="widget3" style="display:none;" >
<div class="lblcontainer">
Verifier
</div>
<div class="inputcontainer">
<div class="divselect" id="divverf" style="width:182px">
<select id="verf" style="width:200px">
<option value="-1">Select</option>
<c:forEach items="${verlist}" var="ver">
<option value="${ver[0]}" >${ver[1]}</option>
</c:forEach>
</select>
</div>
</div>
</div>
<div class="widget" id="ShifButtonDiv" >
<div class="inputcontainer">
<input type="button" class="button" name="transfer" style="float:right;width:60px;" value="Transfer" id="transfer" accesskey="T" onclick="getColonyData((validateTransfering() > 0 ) ? validateTransfering() : 0 )" />
</div>
</div>
</td>
</tr>
</table>
</div>
<div id="TablePanel" class="tableContainer">
<table border="0" cellspacing="0" width="100%" id="cutlist">
<thead class="thead" id="cutlisthead">
<tr title="Row Title" id="TitleRow">
<td width="6%" id="sno">S.No</td>
<td width="35%">Colony</td>
<td>Zone</td>
<td>City</td>
<td>Belt</td>
<td>Verifier</td>
<td><input type="checkbox" id="chkparent" value="" onclick="ToggleChecks('chkcol',this.checked);"></td>
</tr>
</thead>
<tbody id="cutlistbody" class="scrollContent">
</tbody>
</table>
</div>
</div>
</form:form>
<input type="hidden" id="hfusr" value="${Sessvals.getUserID()}" />
<input type="hidden" value="" id="hfdelstat" />
</div>
<div id="colonyform" style="position:absolute; margin-top:5px; width:400px; z-index:3;">
<div>
<!-- Title -->
<div class="title">
<img class="matrix-title-icon" src="/matrix/images/commondet.png" align="absmiddle" />
<span class="matrix-title-text" align="absmiddle">Create Colony</span>
</div>
<!-- -->
<!-- Form (Section1) -->
<div id="FormPanel1" class="FormPanel">
<table align="center" class="matrix-form-controls" style="width:395px">
<tr>
<td width="35%">Colony</td>
<td><input id="colonyname" class="textbox" maxlength="50" style="width:215px" type="text" value="" onblur="validate(this,'t','AlphaSpace');" /></td>
</tr>
<tr>
<td>Zone</td>
<td><input id="zon" class="textbox" maxlength="4" style="width:215px" type="text" value="" /></td>
</tr>
<tr>
<td>City</td>
<td>
<div class="divselect" id="citydiv" style="width:227px">
<select id="city" style="width:245px" onchange="if(this.value=='-1'){validate(this,'t','AlphaSpace');}else{validate(this,'f','');}" onblur="validate(this,'t','');">
<option value="-1">Select</option>
<c:forEach items="${citylist}" var="ctlt">
<option value="${ctlt[0]}" >${ctlt[1]}</option>
</c:forEach>
</select>
</div>
</td>
</tr>
<tr>
<td>Pincode</td>
<td><input id="pincode" class="textbox" maxlength="6" style="width:215px" type="text" value="" onkeydown="return NumberOnly(event);" onblur="validate(this,'t','Pincode');" /></td>
</tr>
<tr>
<td>Colony Group</td>
<td><input id="colgroup" class="textbox" maxlength="25" style="width:215px" type="text" value="" onblur="validate(this,'t','AlphaSpace');" /></td>
</tr>
<tr>
<td>Select Belt</td>
<td>
<div class="divselect" id="colbeltdddiv" style="width:162px">
<select id="colbeltdd" style="width:180px" onchange="if(this.value=='-1'){validate(this,'t','');}else{validate(this,'f','');}" onblur="validate(this,'t','');">
<option value="-1">Select</option>
</select>
</div><div class="linkbutton" onclick="$('#beltform').show();">Create Belt</div>
</td>
</tr>
<tr>
<td colspan="2"><input type="button" class="button" name="btnsave" style="float:right" value="Save" id="btnsave" accesskey="S" onclick="if(validateColony()){getColonyData(2);ClearForm('colonyname!C0L!zon!C0L!pincode!C0L!city!C0L!colgroup');removeErrorMarks();}else{alert('Please Filled Mandatory Field Properly.');};" /><input type="button" class="button" name="btncancel" style="float:right" value="Cancel" id="btncancel" accesskey="E" onclick="ClearForm('colonyname!C0L!zon!C0L!pincode!C0L!city!C0L!colgroup');removeErrorMarks();$('#colonyform').hide();" /></td>
</tr>
</table>
</div>
<!-- -->
</div>
</div>
<div id="verifierform" style="position:absolute; margin-top:5px; width:400px; z-index:3;" >
<div>
<!-- Title -->
<div class="title">
<img class="matrix-title-icon" src="/matrix/images/commondet.png" align="absmiddle" />
<span class="matrix-title-text" align="absmiddle">Create Verifier</span>
</div>
<!-- -->
<!-- Form (Section1) -->
<div id="FormPanel1" class="FormPanel">
<table align="center" class="matrix-form-controls">
<tr>
<td width="">Verifier's Code</td>
<td><input class="textbox" maxlength="3" style="width:50px; text-transform:uppercase;" id="vercode" type="text" value="" onblur="validate(document.getElementById('vercode'),'t','Alpha');" /></td>
</tr>
<tr>
<td>Verifier's Name</td>
<td><input class="textbox" maxlength="30" style="width:180px; text-transform:uppercase;" id="vername" type="text" value="" onblur="validate(document.getElementById('vername'),'t','AlphaSpace');" /></td>
</tr>
<tr>
<td>Mobile</td>
<td><input class="textbox" maxlength="10" style="width:180px; text-transform:uppercase;" id="mobile" type="text" value="" onblur="validate(document.getElementById('mobile'),'t','Mobile');" /></td>
</tr>
<tr>
<td>Monthly Limit</td>
<td><input class="textbox" maxlength="5" style="width:180px; text-transform:uppercase;" id="monthlimit" type="text" value="" onkeydown="return NumberOnly(event);" /></td>
</tr>
<tr>
<td>HDFC Code</td>
<td><input class="textbox" maxlength="10" style="width:180px; text-transform:uppercase;" id="hdfccod" type="text" value="" /></td>
</tr>
<tr>
<td>Current Zone</td>
<td><input class="textbox" maxlength="4" style="width:180px; text-transform:uppercase;" id="curzone" type="text" value="" /></td>
</tr>
<tr>
<td>Previous Zone</td>
<td><input class="textbox" maxlength="50" style="width:180px; text-transform:uppercase;" id="prezone" type="text" value="" /></td>
</tr>
<tr style="display:none">
<td>Select Belt</td>
<td>
<div class="divselect" id="verbeltdddiv" style="width:197px">
<select id="verbeltdd" style="width:215px" onchange="">
<option value="-1">Select</option>
</select>
</div>
</td>
</tr>
<tr>
<td colspan="2"><input type="button" class="button" name="btnsave" style="float:right" value="Save" id="btnsave" accesskey="C" onclick="if(validateVerifier()){getColonyData(1);ClearForm('vercode!C0L!vername!C0L!mobile!C0L!monthlimit!C0L!hdfccod!C0L!curzone!C0L!prezone!C0L!verbeltdd');removeErrorMarks();}else{alert('Please Fill All Form Fields Properly');}" /><input type="button" class="button" name="btncancel" style="float:right" value="Cancel" id="btncancel" accesskey="X" onclick="ClearForm('vercode!C0L!vername!C0L!mobile!C0L!monthlimit!C0L!hdfccod!C0L!curzone!C0L!prezone!C0L!verbeltdd');removeErrorMarks();$('#verifierform').hide();" /></td>
</tr>
</table>
</div>
<!-- -->
</div>
<!-- -->
</div>
<div id="beltform" style="position:absolute; margin-top:5px; width:400px; z-index:3;" >
<div>
<!-- Title -->
<div class="title">
<img class="matrix-title-icon" src="/matrix/images/commondet.png" align="absmiddle" />
<span class="matrix-title-text" align="absmiddle">Create Belt</span>
</div>
<!-- -->
<!-- Form (Section1) -->
<div id="FormPanel3" class="FormPanel">
<table align="center" class="matrix-form-controls">
<tr>
<td width="">Enter Belt Name</td>
<td><input class="textbox" maxlength="35" style="width:180px" id="newbelt" type="text" value="" onblur="validate(this,'t','AlphaSpace');" /></td>
</tr>
<tr>
<td>Verifier</td>
<td>
<div class="divselect" id="colverdiv" style="width:252px">
<select id="colverdd" style="width:270px" onchange="if(this.value=='-1'){validate(this,'t','');}else{validate(this,'f','');}" onblur="validate(this,'t','');">
<option value="-1">Select</option>
</select>
</div>
</td>
</tr>
<tr>
<td colspan="2"><input type="button" class="button" name="btnsave" style="float:right" value="Save" id="btnsave" accesskey="C" onclick="if(validateBelt()){createBelt(document.getElementById('newbelt').value,'belts');ClearForm('newbelt!C0L!colverdd');removeErrorMarks();}else{alert('Please Fill Form Properly Both Belt & Verifier Cannot be Blank.');}" /><input type="button" class="button" name="btncancel" style="float:right" value="Cancel" id="btncancel" accesskey="X" onclick="ClearForm('newbelt!C0L!colverdd');removeErrorMarks();$('#beltform').hide();" /></td>
</tr>
</table>
</div>
<!-- -->
</div>
<!-- -->
</div>
<input type="hidden" id="invalidfields" value="0" />
<input type="hidden" id="hfusr" value="${Sessvals.getUserID()}" />
<input type="hidden" value="" id="hfdelstat" />
<input type="hidden" value="1" id="hftransmode" />
</div>
</body>
<!-- Page Load Javascript -->
<script language="javascript" type="text/javascript">
$('#verifierform').hide();
$('#colonyform').hide();
$('#beltform').hide();
copyDDS('verf'+ColDelim+'beltto'+ColDelim+'beltto','colverdd'+ColDelim+'colbeltdd'+ColDelim+'verbeltdd','');
RemoveJunkChars("\\");
//InitPage();
//ProgressBar('progbarContainer','SMS','cutlist',12,'detailed');
</script>
<!-- -->
<!-- Process Message -->
<c:if test="${not empty optrAlloc.getErrMsg()}">
<script language="javascript" type="text/javascript"> CallMessage('${colAlloc.getErrMsg()}',3000,200,300); </script>
</c:if>
<!-- -->
</html>