PageRenderTime 26ms CodeModel.GetById 0ms RepoModel.GetById 0ms app.codeStats 0ms

/modules/ecombill/confirmpayment.php

https://bitbucket.org/vincentbii/amurt
PHP | 242 lines | 195 code | 31 blank | 16 comment | 8 complexity | df7ea39d04b2a9fb09a878a24ce90fa2 MD5 | raw file
Possible License(s): GPL-2.0, Apache-2.0, LGPL-2.1, MPL-2.0-no-copyleft-exception, MIT, BSD-3-Clause, LGPL-2.0, GPL-3.0
  1. <?php
  2. error_reporting(E_COMPILE_ERROR|E_ERROR|E_CORE_ERROR);
  3. /**
  4. *
  5. *
  6. *
  7. *
  8. */
  9. require('./roots.php');
  10. require($root_path.'include/inc_environment_global.php');
  11. define('NO_CHAIN',1);
  12. $lang_tables[]='billing.php';
  13. define('LANG_FILE','aufnahme.php');
  14. $local_user='aufnahme_user';
  15. require_once($root_path.'include/inc_front_chain_lang.php');
  16. require_once($root_path.'include/inc_date_format_functions.php');
  17. /*include('includes/condb.php');
  18. error_reporting(0);
  19. connect_db();
  20. */
  21. $patqry="SELECT e.*,p.* FROM care_encounter AS e, care_person AS p WHERE e.encounter_nr=$patientno AND e.pid=p.pid";
  22. //$resultpatqry=mysql_query($patqry);
  23. if($resultpatqry=$db->Execute($patqry)){
  24. if($resultpatqry->RecordCount()){
  25. $patient=$resultpatqry->FetchRow();
  26. }
  27. }
  28. $presdatetime=date("Y-m-d H:i:s");
  29. $breakfile='patient_payment.php'.URL_APPEND.'&patientno='.$patientno.'&full_en='.$full_en;
  30. ?>
  31. <?php html_rtl($lang); ?>
  32. <head>
  33. <?php echo setCharSet(); ?>
  34. <title><?php echo $LDBillPayment; ?></title>
  35. <SCRIPT language="JavaScript">
  36. <!--
  37. function submitform()
  38. {
  39. document.confirmpayment.action = "postpayment.php";
  40. document.confirmpayment.submit();
  41. }
  42. //-->
  43. </SCRIPT>
  44. </head>
  45. <body bgcolor="#FFFFFF" topmargin=0 leftmargin=0 marginwidth=0 marginheight=0>
  46. <table border="0" width="101%" bgcolor=#99ccff>
  47. <tr>
  48. <td width="101%"><font color="#330066" size="+2" face="Arial"><strong><?php echo $LDeComBill; ?> -
  49. <?php echo $LDPaymentPreview; ?></strong></font></td>
  50. </tr>
  51. </table>
  52. <blockquote>
  53. <form name="confirmpayment" method="POST" action="">
  54. <div align="center">
  55. <table border="0" width="95%" bordercolor="#000000">
  56. <tr>
  57. <td colspan=5 valign="top" height=30 bordercolor="#FFFFFF"><b><?php echo $LDGeneralInfo; ?>:</b></td>
  58. </tr>
  59. <tr>
  60. <td valign=top width="20%"><?php echo $LDPatientName; ?>:</td>
  61. <td valign=top width="20%"><?php echo $patient['title'].' '.$patient['name_first'].' '.$patient['name_last'];?></td>
  62. <td valign=top width="20%">&nbsp;</td>
  63. <td valign=top width="10%"><?php echo $LDReceiptNumber; ?>:</td>
  64. <td valign=top width="30%">
  65. <?php
  66. echo $receipt_no;
  67. ?>
  68. </td>
  69. </tr>
  70. <tr>
  71. <td valign=top width="20%"><?php echo $LDPatientAddress; ?>:</td>
  72. <td valign=top width="20%"><?php echo $patient['addr_str'].' '.$patient['addr_str_nr'].'<br>'.$patient['addr_zip'].' '.$patient['addr_citytown_nr'];?></td>
  73. <td valign=top width="20%">&nbsp;</td>
  74. <td valign=top width="10%"><?php echo $LDBillDate; ?>:</td>
  75. <td valign=top width="30%">
  76. <?php
  77. if($receiptid=="")
  78. {
  79. echo formatDate2Local($presdatetime,$date_format,1);
  80. }
  81. else
  82. {
  83. $oldbillquery="SELECT payment_date from care_billing_payment WHERE receipt_no=$receipt_no";
  84. if($oldbillqueryresult=$db->Execute($oldbillquery)){
  85. if($oldbillqueryresult->RecordCount()){
  86. $ob=$oldbillqueryresult->FetchRow();
  87. echo formatDate2Local($ob['payment_date'],$date_format,1);
  88. }
  89. }
  90. }
  91. /* $oldbillqueryresult=mysql_query($oldbillquery);
  92. $oldbilldate=mysql_result($oldbillqueryresult,0,'bill_item_date');
  93. echo $oldbilldate;
  94. }
  95. */ ?>
  96. </td>
  97. </tr>
  98. <tr>
  99. <td valign=top width="20%"><?php echo $LDPatientType; ?>:</td>
  100. <td valign=top width="20%"><?php echo $patient['encounter_class_nr'];?></td>
  101. <td valign=top width="20%">&nbsp;</td>
  102. <td valign=top width="10%">&nbsp;</td>
  103. <td valign=top width="30%">&nbsp;</td>
  104. </tr>
  105. <tr>
  106. <td valign=top width="20%"><?php echo $LDDateofBirth; ?>:</td>
  107. <td valign=top width="20%"><?php echo $patient['date_birth'];?></td>
  108. <td valign=top width="20%">&nbsp;</td>
  109. <td valign=top width="10%">&nbsp;</td>
  110. <td valign=top width="30%">&nbsp;</td>
  111. </tr>
  112. <tr>
  113. <td valign=top width="20%"><?php echo $LDSex; ?>:</td>
  114. <td valign=top width="20%"><?php echo $patient['sex'];?></td>
  115. <td valign=top width="20%">&nbsp;</td>
  116. <td valign=top width="10%">&nbsp;</td>
  117. <td valign=top width="30%">&nbsp;</td>
  118. </tr>
  119. <tr>
  120. <td valign=top width="20%"><?php echo $LDPatientNumber; ?>:</td>
  121. <td valign=top width="20%"><?php echo $full_en;?></td>
  122. <td valign=top width="20%">&nbsp;</td>
  123. <td valign=top width="10%">&nbsp;</td>
  124. <td valign=top width="30%">&nbsp;</td>
  125. </tr>
  126. <tr>
  127. <td valign=top width="20%"><?php echo $LDDateofAdmission; ?>:</td>
  128. <td valign=top width="20%"><?php echo formatDate2Local($patient['encounter_date'],$date_format);?></td>
  129. <td valign=top width="20%">&nbsp;</td>
  130. <td valign=top width="10%">&nbsp;</td>
  131. <td valign=top width="30%">&nbsp;</td>
  132. </tr>
  133. <tr>
  134. <td colspan="5" height="1" width="641" bordercolor="#FFFFFF">&nbsp;</td>
  135. </tr>
  136. <tr>
  137. <td colspan="5" height="30" width="641" bordercolor="#FFFFFF"><p><b><?php echo $LDPaymentInformation; ?>:</b></p></td>
  138. </tr>
  139. </table>
  140. <table cellSpacing="1" cellPadding="3" width="522" bgColor="#999999" border="0" height="138">
  141. <tr bgColor="#eeeeee">
  142. <td align="left" height="37" width="7738"><font size="4" color="#FF0000">&nbsp;<?php echo $LDModeofPayment; ?>:</font></td>
  143. <?php
  144. if(strstr($_SERVER['QUERY_STRING'],"mode1")!="")
  145. {
  146. echo "<tr bgColor=\"#eeeeee\">";
  147. echo "<td align=\"center\" height=\"7\" width=\"3182\">";
  148. echo "<p align=\"left\">";
  149. echo "<i><b>$LDCash</b></i>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p>";
  150. echo "<p align=\"left\">$LDAmount&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  151. echo $amtcash;
  152. echo "<input type=\"hidden\" name=\"amtcash\" value=\"".$amtcash."\">";
  153. }
  154. ?>
  155. </td></tr>
  156. <?php
  157. if(strstr($_SERVER['QUERY_STRING'],"mode2")!="")
  158. {
  159. echo "<tr bgColor=\"#dddddd\" height=\"1\">";
  160. echo "<td height=\"5\" width=\"7738\">";
  161. echo "<img height=\"1\" src=\"pics/hor_bar.bmp\" width=\"5\"></td></tr><tr bgColor=\"#eeeeee\"><td align=\"center\" height=\"7\" width=\"3182\">";
  162. echo "<p style=\"line-height: 150%\" align=\"left\">";
  163. echo "<i><b>$LDCreditCard</b></i>";
  164. echo "<p style=\"line-height: 100%; word-spacing: 0; text-indent: 0; margin: 0\" align=\"left\">";
  165. echo "$LDCardNumber&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;".$cdno."&nbsp;</p>";
  166. echo "<p style=\"line-height: 100%; word-spacing: 0; text-indent: 0; margin: 0\" align=\"left\">
  167. $LDAmount&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;".$amtcc."</p>";
  168. echo "</td></tr>";
  169. echo "<input type=\"hidden\" name=\"cdno\" value=\"".$cdno."\">";
  170. echo "<input type=\"hidden\" name=\"amtcc\" value=\"".$amtcc."\">";
  171. }
  172. ?>
  173. <?php
  174. if(strstr($_SERVER['QUERY_STRING'],"mode3")!="")
  175. {
  176. echo "<tr bgColor=\"#dddddd\" height=\"1\"><td height=\"5\" width=\"7738\">";
  177. echo "<img height=\"1\" src=\"pics/hor_bar.bmp\" width=\"5\">";
  178. echo "</td></tr>";
  179. echo "<tr bgColor=\"#eeeeee\"><td align=\"center\" height=\"7\" width=\"3182\">";
  180. echo "<p style=\"line-height: 150%; word-spacing: 0; margin: 0\" align=\"left\"><i><b>$LDCheck</b>&nbsp;</i>";
  181. echo "<p style=\"line-height: 100%; word-spacing: 0; margin: 0\" align=\"left\">$LDCheckNumber";
  182. echo $chkno;
  183. echo "<p style=\"line-height: 100%; word-spacing: 0; margin: 0\" align=\"left\">$LDAmount&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  184. echo $amtcheque;
  185. echo "</td></tr>";
  186. echo "<input type=\"hidden\" name=\"chkno\" value=\"".$chkno."\">";
  187. echo "<input type=\"hidden\" name=\"amtcheque\" value=\"".$amtcheque."\">";
  188. }
  189. ?>
  190. <input type="hidden" name="patientno" value="<?php echo $patientno; ?>">
  191. <input type="hidden" name="hidden" value="C6#C7#C8#">
  192. <input type="hidden" name="receipt_no" value="<?php echo $receipt_no; ?>">
  193. <input type="hidden" name="lang" value="<?php echo $lang ?>">
  194. <input type="hidden" name="sid" value="<?php echo $sid ?>">
  195. <input type="hidden" name="full_en" value="<?php echo $full_en ?>">
  196. </table>
  197. <p>&nbsp;
  198. <a href="javascript:submitform();"><img <?php echo createLDImgSrc($root_path,'savedisc.gif','0'); ?>></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  199. <a href="<?php echo $breakfile ?>"><img <?php echo createLDImgSrc($root_path,'cancel.gif','0'); ?>></a> </center>
  200. </div>
  201. <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  202. <!-- <input type="button" value="Save" name="B1" Onclick="javascript:submitform();">
  203. <input type="button" value="Goback" name="B2" Onclick="javascript:history.go(-1);">
  204. --> </p>
  205. </form>
  206. </blockquote>
  207. <?php
  208. require($root_path.'include/inc_load_copyrite.php');
  209. ?>
  210. </body>
  211. </html>