Server IP : 162.240.98.243 / Your IP : 18.216.88.54 Web Server : Apache System : Linux server.bti.yaw.mybluehostin.me 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64 User : btiyawmy ( 1003) PHP Version : 7.2.34 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/btiyawmy/www/login.easenup.in/ |
Upload File : |
<?php session_start(); require_once("../dbconnection.php"); require_once('../DBManager.php'); require_once('../LoginManager.php'); $DisplayForm=True; $sql= "SELECT * FROM medicine_charge WHERE WHERE prescriptionid=$_GET[prescriptionid] AND patientid=$_GET[patientid] AND status='1' AND srno='$_GET[srno]'"; $qsql = mysqli_query($con,$sql); if($rh = mysqli_fetch_array($qsql)) { $DisplayForm=False; echo "<script>window.location='show_medicineinvace.php?prescriptionid=$rh[prescriptionid]&patientid=$_GET[patientid]&srno=$_GET[srno]'</script>"; } if($DisplayForm) { ?> <?php include("dbconnection.php"); require_once('../DBManager.php'); require_once('../patientmanager.php'); include("header.php"); include("dashboard_pharma.php"); if(isset($_POST['signup'])) { $sql="UPDATE medicine_slot SET discount='$_POST[discount]',pricetotal='$_POST[pricetotal]',price='$_POST[price]',paymentmode='$_POST[paymentmode]',action='$_POST[action]' WHERE srno='$_POST[srno]'"; if($qsql = mysqli_query($con,$sql)) { echo "<script>alert('Update successfully');</script><script> window.history.go(-2)</script>"; } } ?> <?php session_start(); require_once("../dbconnection.php"); require_once('../DBManager.php'); require_once('../LoginManager.php'); ?> <!DOCTYPE html> <html> <body> <body> <h2 align='center'>Invoice</h2> <style> #topright { position: absolute; right: 0; top: 0; margin-top: 73px; margin-right: 30px; display: block; height: 70px; width: 70px; background: url(TRbanner.gif) no-repeat; text-indent: -999em; text-decoration: none; } #toprightj { position: absolute; right: 0; top: 0; margin-top: 73px; margin-right: 120px; display: block; height: 70px; width: 70px; background: url(TRbanner.gif) no-repeat; text-indent: -999em; text-decoration: none; } #toprightb { position: absolute; right: 0; top: 0; margin-top: 73px; margin-right: 200px; display: block; height: 70px; width: 70px; background: url(TRbanner.gif) no-repeat; text-indent: -999em; text-decoration: none; } .center { border: 1px solid grey; text-align:; } .center2 { border: 5px solid grey; text-align:; } <style> h2 { color: #4287f5; } a img { border: none; } #memo { padding-top: 50px; margin: 0 20px 0 60px; border-bottom: 1px solid #ddd; height: 200px; } #memo .logo { float: left; margin-right: 20px; } #memo .logo img { width: 150px; height: 100px; } #memo .company-info { float: right; text-align: right; } #memo .company-info > div:first-child { font-weight: bold; font-size: 22px; color: #1e73be; } #memo .company-info span { font-size: 11px; min-width: 20px; } </style> </style> </head> <div class="content-wrapper"> <!-- Content Header (Page header) --> <div class='center'> <section id="memo"> <div class="logo"> <?php $narayan=LoginManager::currentUser(); $usertype=LoginManager::getUserTypeByuname("$narayan"); $sql ="SELECT * FROM site_users WHERE userno='$usertype'"; $qsql = mysqli_query($con,$sql); if($rs = mysqli_fetch_array($qsql)) { $sql ="SELECT * FROM hco WHERE adminid='$rs[entered_by]'"; $qsql = mysqli_query($con,$sql); if($rs = mysqli_fetch_array($qsql)) { $sql ="SELECT * FROM admin WHERE id='$rs[adminid]'"; $qsql = mysqli_query($con,$sql); if($ra = mysqli_fetch_array($qsql)) { $services ="SELECT * FROM `services` Where adminid='$ra[id]'"; $qservices = mysqli_query($con,$services); if($rservices = mysqli_fetch_array($qservices)) { echo" <img data-logo='$rs[Logo]' src='uploads/$rs[Logo]' /> </div> <div class='company-info'> <div>$rservices[pharmacyName]</div> <div> <span style='font-size:18px'>GST No: $rservices[GSTNo] | Lic NO: $rservices[LicNO]</br> <i class='fa fa-map-marker' aria-hidden='true'></i> $rs[Street] | $rs[Locality]</br> <i class='fa fa-envelope' aria-hidden='true'></i> $ra[EmailID] | <i class='fa fa-phone-square' aria-hidden='true'></i> $ra[numbers]</p></span> </div> "; } } }} ?> <br> </section> <br> <?php include("dbconnection.php"); $sql1 ="SELECT * FROM patient WHERE patientid='$_GET[patientid]'"; $qsql1 = mysqli_query($con,$sql1); if($rspi1 = mysqli_fetch_array($qsql1)) { $sqlpatient = "SELECT * FROM medicine_slot WHERE prescriptionid='$_GET[prescriptionid]' AND patientid='$_GET[patientid]'"; $qsqlpatient = mysqli_query($con,$sqlpatient); if($rsp = mysqli_fetch_array($qsqlpatient)) { $sqlpatient1 = "SELECT * FROM site_users WHERE userno='$rsp[entered_by]'"; $qsqlpatient1 = mysqli_query($con,$sqlpatient1); if($rsn = mysqli_fetch_array($qsqlpatient1)) { $medi_charge=$con->query("SELECT * FROM `medicine_charge` WHERE patientid='$_GET[patientid]' AND prescriptionid='$_GET[prescriptionid]' AND srno='$_GET[srno]'"); $row_medi_charge=$medi_charge->fetch_assoc(); echo" <div class='checkbox'><span style='float: left; font-size:19px;margin-left: 11px;'>Date :<b> $row_medi_charge[created_at]</b></span><span style='float: right; font-size:19px;margin-right: 11px;'>Invoice Number :<b>$_GET[srno]</b></span></div> <br> <div class='checkbox'><span style='float: left; font-size:19px;margin-left: 11px;'>UHID : <b>$rspi1[patientid]</b></span><span style='float: right; font-size:19px;margin-right: 11px;'>Name :<b>$rspi1[patientname]</b></span></div> <br> <div class='checkbox'><span style='float: left; font-size:19px;margin-left: 11px;'>Age: <b>$rspi1[dob]</b></span><span style='float: right; font-size:19px;margin-right: 11px;'>SEX :<b>$rspi1[gendor]</b></span></div> <div class='card-body'> "; }}} ?> <div id="container"> <table id='table' class='table table-bordered table-hover' style="width: 96%; margin-left: 10px;"> <form method="post" name="signup"> <tbody> <tr> <th>Medication Details</th> <th>Batch Number</th> <th>HSN Code</th> <th>Expiry Date</th> <th>Quantity</th> <th>MRP</th> </tr> </tbody> <?php include("dbconnection.php"); require_once('../DBManager.php'); require_once('../LoginManager.php'); $narayan=LoginManager::currentUser(); $usertype=LoginManager::getUserTypeByuname("$narayan"); $sql5 ="SELECT * FROM medicine_charge WHERE prescriptionid='$_GET[prescriptionid]' AND patientid='$_GET[patientid]' AND srno=$_GET[srno]"; $qsql5 = mysqli_query($con,$sql5); while($re5 = mysqli_fetch_array($qsql5)){ echo"<tr>"; echo "<td>"; echo $re5['MedicineName'];//what will do here echo" </td>"; echo"<td>"; echo $re5['batchNumber'];//what will do here echo "</td>"; echo "<td>"; echo $re5['HSN_No'];//what will do here echo "</td>"; echo "<td>"; echo $re5['Expiry_Date'];//what will do here echo "</td>"; echo"<td>"; echo $re5['Quantity'];//what will do here echo "</td>"; echo "<td>"; echo $re5['Price'];//what will do here echo "<input class='price' id='price' type='hidden' name='price[]' value='$re5[Price]'/>"; echo "<input class='FinalAmt' id='FinalAmt' type='hidden' name='FinalAmt[]' value='$re5[FinalAmt]'/>"; echo "</td>"; echo " </tr> "; } // echo "<tr><td>Total Amt</td><td></td><td></td><td></td><td></td><td><strong ><i class='fa fa-inr'></i> $re5[TotalAmt]<strong></td></tr>"; // echo "<tr><td colspan='7'><b style='float:right'>Gross Amt</b> </td><td><strong ><i class='fa fa-inr'></i> $re5[TotalAmt]<strong></td></tr>"; $sql5 ="SELECT * FROM medicine_charge WHERE prescriptionid='$_GET[prescriptionid]' AND patientid='$_GET[patientid]' AND srno='$_GET[srno]'"; $qsql5 = mysqli_query($con,$sql5); $re5 = mysqli_fetch_array($qsql5); echo "<tr><td colspan='5'><b style='float:right'>Total MRP</b> </td><td><strong > <b><i class='fa fa-inr'></i> <span align='right' id='val'></b></span></td></tr>"; echo "<tr><td colspan='5'><b style='float:right'>Discount</b> </td><td><strong > $re5[DisPrice] %<strong></td></tr>"; echo "<tr><td colspan='5'><b style='float:right'>GST</b> </td><td><strong ><i class='fa fa-inr'></i> $re5[Total_gst] <strong></td></tr>"; echo "<tr><td colspan='5'><b style='float:right'>Payable Amt</b> </td><td><strong ><b><i class='fa fa-inr'></i> <span align='right' id='Fprice'></b></span><strong></td></tr>"; $addaspatient ="SELECT * FROM addaspatient WHERE patientid='$_GET[patientid]' AND prescriptionid='$_GET[prescriptionid]'"; $qaddaspatient = mysqli_query($con,$addaspatient); $raddaspatient = mysqli_fetch_array($qaddaspatient); if($raddaspatient['typevisit']=='IPD' || $raddaspatient['typevisit']=='Ipd_Emergency'){ echo "<tr><td colspan='5'><b style='float:right'>Paid Amt</b> </td><td><strong ><b><i class='fa fa-inr'></i> $re5[PaidAmt] </b><strong></td></tr> <tr><td colspan='5'><b style='float:right'>Due Amt</b> </td><td><strong ><b><i class='fa fa-inr'></i> $re5[CalAmt]</b><strong></td></tr> "; } ?> </table> <?php $narayan=LoginManager::currentUser(); $usertype=LoginManager::getUserTypeByuname("$narayan"); $site_users ="SELECT * FROM site_users WHERE userno='$usertype'"; $qsite_users = mysqli_query($con,$site_users); $rsite_users = mysqli_fetch_array($qsite_users); $hco ="SELECT * FROM hco WHERE adminid='$rsite_users[entered_by]'"; $qhco = mysqli_query($con,$hco); $rhco = mysqli_fetch_array($qhco); ?> <div class='checkbox' style="margin-left:11px"> <b>Term & Conditions :</b></div> <div class='checkbox'><ol type='1'><li>Prices are inclusive of all taxes.</li> <li>Exchange is as per Excahnge policy displayed on the counter, In case of full strip or Sealed Pack only </li> <li>Original bill must be presented with the exchange.</li> <li>Please check the details of the medicine before leaving.Company does not owe any resposibility once you leave the pharmacy</li> <li>All Dispute Subject to <?php echo $rhco['District'] ?> Jurisdiction.</li> </ol> </div> <br> <br> </div> <?php } ?> <script> var table = document.getElementById("myTable"), sumVal = 0; $(".price").each(function() { sumVal += Number($(this).val()); }); document.getElementById("val").innerHTML = "" + sumVal; $('#total_value').val(sumVal); </script> <script> var table = document.getElementById("myTable"), FsumVal = 0; $(".FinalAmt").each(function() { FsumVal += Number($(this).val()); }); document.getElementById("Fprice").innerHTML = "" + FsumVal; </script>