Server IP : 108.163.255.210 / Your IP : 18.225.98.39 Web Server : Apache System : Linux blossom.urlnameserver.com 3.10.0-1160.80.1.el7.x86_64 #1 SMP Tue Nov 8 15:48:59 UTC 2022 x86_64 User : ( 1172) PHP Version : 7.2.34 Disable Function : eval,escapeshellarg,proc_close,proc_get_status,proc_nice,proc_open,symlink,system,pcntl_exec,getrusage,chown,chgp,closelog,openlog,syslog,define_syslog_variables,php_ini_loaded_file,getservbyname,getservbyport,posix_getgid,posix_getgrgid,proc_terminate,pfsockopen,apache_child_terminate,posix_mkfifo,posix_setpgid,posix_setuid,hypot,pg_host,pos,posix_access,posix_getcwd,posix_getservbyname,myshellexec,getpid,posix_getsid,posix_isatty,posix_kill,posix_mknod,posix_setgid,posix_setsid,posix_setuid,posix_times,posix_uname,ps_fill,posix_getpwuid,global,ini_restore,zip_open,zip_read,rar_open,bzopen,bzread,bzwrite,apache_get_modules,apache_get_version,phpversionphpinfo,php_ini_scanned_files,get_current_user,disk_total_space,diskfreespace,leak,imap_list,hypo,filedump,safe_mode,getmygid,apache_getenv,apache_setenv,bzread,bzwrite,bzopen,phpini,higlight_file,dos_conv,get_cwd,er_log,cmd,e_name,vdir,get_dir,only_read,ftok,ftpexec,posix_getpwnam,mysql_list_dbs,disk_free_space,session_save_path,confirm_phpdoc_compiled,zip_entry_rea,php_u,psockopen,crack_opendict,crack_getlastmessage,crack_closedict,crack_check,fpassthru,posix_get_last_error,posix_getlogin,posix_getgroups,posix_strerror,posix_getrlimit,posix_getpgrp,posix_getgrnam,pos,dl MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/unilinki/www/Intellilead/leads/ |
Upload File : |
<?php require_once "../includes/application_top.php"; $id = $_REQUEST['id']; $lead_id = $_POST['lead_id']; $remark = $_POST['remark']; $assign_to = $_POST['assign_lead']; $role = getRoleIdByUserId($assign_to); if(isset($_POST['save'])){ if($role <= '5'){ if($_SESSION['user_id']==$_POST['assign_lead']){ $sql="update mstr_leads SET assign_tc='".$assign_to."',lead_status = '5',remark='".$remark."' WHERE lead_id='$lead_id'"; }if($_SESSION['role_id']<='4'){ $sql="update mstr_leads SET assign_tc='".$assign_to."',remark='".$remark."',lead_status = '5' WHERE lead_id='$lead_id'"; }else{ $sql="update mstr_leads SET assign_tc='".$assign_to."',lead_status = '5',remark='".$remark."' where lead_id='$lead_id'"; } }else{ if($_SESSION['user_id']==$_POST['assign_lead']){ $sql="update mstr_leads SET sales_tc='".$assign_to."',lead_status = '5',remark='".$remark."' WHERE lead_id='$lead_id'"; }if($_SESSION['role_id']<='4'){ $sql="update mstr_leads SET sales_tc='".$assign_to."',remark='".$remark."',lead_status = '5' WHERE lead_id='$lead_id'"; }else{ $sql="update mstr_leads SET sales_tc='".$assign_to."',lead_status = '5',remark='".$remark."' where lead_id='$lead_id'"; } } $sql2="INSERT INTO mstr_history (lead_id,lead_status,msg,assign_by,assign_tc,company_id,user_id,datetime) values('$lead_id','5','".$remark."','".$_SESSION['user_id']."','".$_POST['assign_lead']."','".$_SESSION['company_id']."','".$_SESSION['user_id']."','".$DateTime."')"; executeQuery($sql2); executeQuery($sql); if($_SESSION['role_id']>='6'){ $page = "view_sales_leads.php"; }else{ $page = "view_leads.php"; } echo "<script type=\"text/javascript\"> alert(\"Lead successfully Assign.\"); window.location = \"$page\" </script>"; } if(isset($_POST['delete'])){ $sql= "update mstr_leads SET del_id='1' where lead_id='$lead_id'"; $sql2="INSERT INTO mstr_history (lead_id,del_id,company_id,user_id,datetime) values('$lead_id','1','".$_SESSION['company_id']."','".$_SESSION['user_id']."',NOW())"; executeQuery($sql2); executeQuery($sql); if($_SESSION['role_id']>='6'){ $page = "view_sales_leads.php"; }else{ $page = "view_leads.php"; } echo "<script type=\"text/javascript\"> alert(\"Lead (s) Deleted successfully.\"); window.location = \"view_leads.php\" </script>"; } if($id!=''){ $sql= "SELECT * FROM mstr_leads where lead_id='".checkInput($id)."'"; $result= executeQuery($sql); while($row=mysql_fetch_array($result)) { $pid=$row['lead_id']; } } else { //header('Location: view_leads.php'); exit(); } include('../template/header.php'); ?> <!-- page heading start--> <div class="panel box-shadow-none content-header"> <div class="panel-body"> <div class="col-md-12"> <h3 class="animated fadeInLeft">Re assign Lead</h3> <p class="animated fadeInDown"> Leads <span class="fa-angle-right fa"></span>Re Assign the Leads </p> </div> </div> </div> <!-- page heading end--> <!--body wrapper start--> <div class="col-md-12"> <?php include('../template/response.php');?> <div class="col-md-12 panel"> <div class="col-md-12 panel-heading"> <h4>Lead : <?php echo getLeadCode($id); ?></h4> </div> <form id="commentForm" method="post" enctype="multipart/form-data" action="edit_leads_form.php"> <div class="col-md-12 panel-body"> <div class="col-md-12"> <div class="col-md-6"> <input name="lead_id" type="hidden" value="<?php echo $pid; ?>"> <div class="form-group form-animate-text" style="margin-top:40px !important;"> <select class="form-control" name="assign_lead"> <?php if($_SESSION['role_id']=='4'){ $role = "role_id IN (4,5) and rep_head='".$_SESSION['user_id']."' or user_id='".$_SESSION['user_id']."'"; }else if($_SESSION['role_id']=='6'){ $role = "role_id IN (6,7,8)"; }else if($_SESSION['role_id']=='7'){ $role = "role_id IN (7,8) and rep_head='".$_SESSION['user_id']."' or user_id='".$_SESSION['user_id']."'"; }else{ $role = "role_id IN (2,3,4,5)"; } $Roleresult= executeQuery("SELECT user_id,name,role_id FROM mstr_user where status='Active' and company_id ='".$_SESSION['company_id']."' and user_type !='0' and $role"); while($row=mysql_fetch_array($Roleresult)) { ?> <option value="<?php echo $row['user_id'];?>"><?php echo $row['name'];?> - <?php echo getRoleName($row['role_id']);?></option> <?php }?> </select> </div> <div class="form-group form-animate-text" style="margin-top:40px !important;"> <textarea class="form-text mask-name" id="cemail" name="remark" ><?php echo $desc; ?></textarea> <span class="bar"></span> <label>Remarks</label> </div> </div> <div class="col-md-12"> <div class="col-md-3"> <button type="submit" name="save" style="margin-top:0px !important;" class="btn-flip btn btn-gradient btn-success"> <div class="flip"> <div class="side"> Submit <span class="fa fa-upload"></span> </div> <div class="side back"> are you sure? </div> </div> <span class="icon"></span> </button> </div> <div class="col-md-3"> <button type="submit" name="delete" style="margin-top:0px !important;" class="btn-flip btn btn-gradient btn-danger"> <div class="flip"> <div class="side"> Trash <span class="fa fa-trash"></span> </div> <div class="side back"> are you sure? </div> </div> <span class="icon"></span> </button> </div> </div> </div> </form> </div> </div> <!--body wrapper end--> <?php include('../template/footer.php');?>