-
Notifications
You must be signed in to change notification settings - Fork 0
/
bill.php
116 lines (109 loc) · 3.77 KB
/
bill.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
<?php session_start() ?>
<?php include 'class/productClass.php' ?>
<?php include 'class/jabonClass.php' ?>
<?php include 'class/tonicoClass.php' ?>
<?php include 'class/billClass.php' ?>
<?php use barla\jabon\jabonClass as jabon ?>
<?php use barla\tonico\tonicoClass as tonico ?>
<?php use barla\bill\billClass as bill ?>
<?php $bill = new bill() ?>
<?php $tonico = new tonico() ?>
<?php $jabon = new jabon() ?>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>BARLA - Sistema de ventas</title>
<?php include 'html/head.php' ?>
</head>
<body>
<div class="container container-fluid">
<div class="well" id="wellMain">
<div class="page-header">
<h1><i class="mdi-action-assignment"></i> Factura de venta</h1>
</div>
<fieldset>
<legend>Datos de factura</legend>
<table class="table table-bordered">
<thead>
<tr>
<td colspan="2"><?php echo bill::COMPANY ?></td>
</tr>
<tr>
<td colspan="2"><?php echo bill::NIT ?></td>
</tr>
<tr>
<td class="tableColumn50"><?php echo number_format($bill->getIdClient(),0,',','.') ?></td>
<td class="tableColumn50"><?php echo $bill->getNameClient() ?></td>
</tr>
</thead>
</table>
</fieldset>
<?php if($bill->getTonico() > 0): ?>
<fieldset>
<legend><?php echo $tonico->getName() ?></legend>
<table class="table table-bordered">
<tbody>
<tr>
<td class="tableColumn50">Valor unitario</td>
<td class="tableColumn50">$ <?php echo number_format($tonico->getSalePrice()) ?></td>
</tr>
<tr>
<td>Cantidad comprada</td>
<td><?php echo $bill->getTonico() ?></td>
</tr>
<tr>
<td>Costo total del producto</td>
<td>$ <?php echo number_format(bill::getValorTotalTonico()) ?></td>
</tr>
</tbody>
</table>
</fieldset>
<?php endif ?>
<?php if($bill->getJabon() > 0): ?>
<fieldset>
<legend><?php echo $jabon->getName() ?></legend>
<table class="table table-bordered">
<tbody>
<tr>
<td class="tableColumn50">Valor unitario</td>
<td class="tableColumn50">$ <?php echo number_format($jabon->getSalePrice()) ?></td>
</tr>
<tr>
<td>Cantidad comprada</td>
<td><?php echo $bill->getJabon() ?></td>
</tr>
<tr>
<td>Costo total del producto</td>
<td>$ <?php echo number_format(bill::getValorTotalJabon()) ?></td>
</tr>
</tbody>
</table>
</fieldset>
<?php endif ?>
<fieldset>
<legend>Valores totales</legend>
<table class="table table-bordered">
<tbody>
<tr>
<td class="tableColumn50">SubTotal</td>
<td class="tableColumn50">$ <?php echo number_format(bill::getSubTotal()) ?></td>
</tr>
<tr>
<td>IVA</td>
<td>$ <?php echo number_format(bill::getTotalIVA(),1) ?></td>
</tr>
<tr>
<td>TOTAL</td>
<td>$ <?php echo number_format(bill::getGranTotal(),1) ?></td>
</tr>
</tbody>
</table>
</fieldset>
<a href="mainMenu.php" class="btn btn-block btn-primary">Volver</a>
</div>
</div>
<?php include 'html/foot.php' ?>
</body>
</html>
<?php bill::delete() ?>