<?php
    include'connection.php';
    include'../Retailers/functions.php';
    $opCode=$_GET['opCode'];
    $api1=$_GET['api1'];
    $api2=$_GET['api2'];
    $AO=$_GET['AO'];
    $TL=$_GET['TL'];
    $LGID=$_GET['LGID'];
    $LGID2=$_GET['LGID2'];
    $uid=$_GET['uid'];
    $opName=getOpName($opCode);
    $update="UPDATE CommSlab SET API1='$api1', API2='$api2', AO='$AO', TxnLimit='$TL', LapuGroupId='$LGID', LapuGroupId2='$LGID2' WHERE OpCode='$opCode' AND Userid='$uid'";
    if(mysqli_query($con,$update))
    {
        echo "<div class='msg-div'>
		        <form method='post'>
				    <h3>".$opName." Set API1=".$api1.", API2=".$api2." Successfully !</h3><br>
					<i class='fa fa-check-circle' aria-hidden='true' id='okIcon'></i><br><br>
					<button type='submit' class='btnPopup'>OK</button><br><br>
				</form>
			</div>";
    }
    else
    {
        echo "<div class='msg-div'>
			        <form method='post'>
				        <h3>Something Error !</h3><br>
				        <i class='fa fa-ban' aria-hidden='true' id='NotokIcon'></i><br><br>
				        <button type='submit' class='btnPopup'>OK</button><br><br>
			        </form>
		        </div>";
    }
?>