<?php
ob_start();
error_reporting(0);
include("connect.php");
session_start();
$ver2=$_SESSION['customer_id'];
$ver = $_SESSION['distributor_user_id'];
$user_role= $_SESSION['user_role'];

$id=$_GET['id']; 
$res = mysqli_query($con,"select * from tbl_master_customer where customer_id='$id'");
$ver1 = mysqli_fetch_assoc($res);
$delete_status=$ver1['status'];

if($delete_status=='Active')
{
	$uq1=mysqli_query($con,"UPDATE tbl_master_customer SET status='Deactive' where customer_id='$id'");
}
if($delete_status=='Deactive')
{
	$uq1=mysqli_query($con,"UPDATE tbl_master_customer SET status='Active' where customer_id='$id'");
}
if($uq1){ header('Location:customer-master.php'); }
 ?>