<?php include("../../include/dbconnect.php");?>
<html>
<head>
<title>Sales Tax Structure Entry</title>
</head>
<body background="../../images/fibermat.gif"><center>
<table cellpadding=0 cellspacing=4 width=590>
<tr>
<td style="padding:3px;" colspan=2 bgcolor="#93BEE2"><font ><b>Add Sales Tax Structure</b></font></td>
</tr><tr valign="top"><td colspan=2>
<font >&nbsp;</font>
</td>
</tr>
</table>
<table border=0 cellpadding=3 cellspacing=4 width="590">
<form name="form1" method="post" action="entry.php" >

<?
$result = mysqli_query($conn,"select max(taxtype) from salestax ") or die(mysqli_error());
$row = mysqli_fetch_row($result);
$maxtype = $row[0]+1;

?>
<tr>
      <td>
        <table border="0" cellspacing="1" cellpadding="4" align="center" width="500" bgcolor="#999999">
          <tr align="center"> 
            <td colspan="2"><font face="Arial, Helvetica, sans-serif" size="3" color="#003366"><b><font face="Verdana, Arial, Helvetica, sans-serif" size="1" color="#FFFFFF">Sales Tax Structure
              </font></b></font></td>
          </tr>


          <tr> 
            <td align="right" width="326" bgcolor="#FFFFFF"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><b><font color="#003366">Tax Type</font></b></font></td>
            <td width="319" bgcolor="#FFFFFF"> 
              <input type="text"    onKeyPress="return event.keyCode!=13"   name="taxtype" value="<?=$maxtype?>">
            </td>
          </tr>

          <tr> 
            <td align="right" width="326" bgcolor="#FFFFFF"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><b><font color="#003366">Description</font></b></font></td>
            <td width="319" bgcolor="#FFFFFF"> 
              <input type="text"    onKeyPress="return event.keyCode!=13"   name="description">
            </td>
          </tr>  

		  
          </tr>		  
          <tr> 
            <td align="right" width="326" bgcolor="#FFFFFF"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><b><font color="#003366">Tax %</font></b></font></td>
            <td width="319" bgcolor="#FFFFFF"> 
              <input type="text"    onKeyPress="return event.keyCode!=13"   name="tax">
            </td>
          </tr>
          

          <tr> 
            <td align="right" width="326" bgcolor="#FFFFFF"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><b><font color="#003366">Cess %</font></b></font></td>
            <td width="319" bgcolor="#FFFFFF"> 
              <input type="text"    onKeyPress="return event.keyCode!=13"   name="cess">
            </td>
          </tr>
                    
        <tr>
        <td width="132" height="31" align="left" ><strong><font color="#003366" size="1" face="Verdana, Arial, Helvetica, sans-serif">Map the GL for SGST</font></strong></td>
        <td>
        <?
        $stQuery = mysqli_query($conn," select acctcode,description from acctmast where acctgroup != '111206' and acctgroup != '111303' order by description ")or die( mysqli_error() );
        ?>
        
        <SELECT name='sgst_acctcode' >
        <?
        echo "<option selected value=\" 0\"> Select GL";
        while($row4 = mysqli_fetch_row($stQuery))
        {
        
        
            echo "<option value=\"$row4[0]\">$row4[1]";
        
        }
        ?>
        </SELECT></td></tr>
  


        <tr>
        <td width="132" height="31" align="left" ><strong><font color="#003366" size="1" face="Verdana, Arial, Helvetica, sans-serif">Map the GL for CGST</font></strong></td>
        <td>
        <?
        $stQuery = mysqli_query($conn," select acctcode,description from acctmast where acctgroup != '111206' and acctgroup != '111303' order by description ")or die( mysqli_error() );
        ?>
        
        <SELECT name='cgst_acctcode' >
        <?
        echo "<option selected value=\" 0\"> Select GL";
        while($row4 = mysqli_fetch_row($stQuery))
        {
        
        
            echo "<option value=\"$row4[0]\">$row4[1]";
        
        }
        ?>
        </SELECT></td></tr>
        

        <tr>
        <td width="132" height="31" align="left" ><strong><font color="#003366" size="1" face="Verdana, Arial, Helvetica, sans-serif">Map the GL for IGST</font></strong></td>
        <td>
        <?
        $stQuery = mysqli_query($conn," select acctcode,description from acctmast where acctgroup != '111206' and acctgroup != '111303' order by description ")or die( mysqli_error() );
        ?>
        
        <SELECT name='igst_acctcode' >
        <?
        echo "<option selected value=\" 0\"> Select GL";
        while($row4 = mysqli_fetch_row($stQuery))
        {
        
        
            echo "<option value=\"$row4[0]\">$row4[1]";
        
        }
        ?>
        </SELECT></td></tr>
  
        <tr>
        <td width="132" height="31" align="left" ><strong><font color="#003366" size="1" face="Verdana, Arial, Helvetica, sans-serif">Map the GL for CESS</font></strong></td>
        <td>
        <?
        $stQuery = mysqli_query($conn," select acctcode,description from acctmast where acctgroup != '111206' and acctgroup != '111303' order by description ")or die( mysqli_error() );
        ?>
        
        <SELECT name='cess_acctcode' >
        <?
        echo "<option selected value=\" 0\"> Select GL";
        while($row4 = mysqli_fetch_row($stQuery))
        {
        
        
            echo "<option value=\"$row4[0]\">$row4[1]";
        
        }
        ?>
        </SELECT></td></tr>        
                
        
        <tr>
        <td width="132" height="31" align="left" ><strong><font color="#003366" size="1" face="Verdana, Arial, Helvetica, sans-serif">Map the GL for Sales / Purchase</font></strong></td>
        <td>
        <?
        $stQuery = mysqli_query($conn," select acctcode,description from acctmast where acctgroup != '111206' and acctgroup != '111303'   order by description")or die( mysqli_error() );
        ?>
        
        <SELECT name='sp_acctcode' >
        <?
        echo "<option selected value=\" 0\"> Select GL";
        while($row4 = mysqli_fetch_row($stQuery))
        {
        
        
            echo "<option value=\"$row4[0]\">$row4[1]";
        
        }
        ?>
        </SELECT></td></tr>
  

		 
          <tr> 
            <td colspan="2" bgcolor="#FFFFFF"> 
              <table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
                <tr align="center"> 
                  <td> 
                    <input type="submit" name="accept" value="Submit">
                  </td>
                  <td> 
                    <input type="reset" name="reset" value="Clear">
                  </td>
                </tr>
              </table>
            </td>
          </tr>
          

</table>
</table>
<br><br><font size=1><center><a href= "index.html">Return to index page</center></font>
                                                                             
</body>
</html>




