mirror of
https://github.com/itflow-org/itflow
synced 2026-03-16 18:54:51 +00:00
BREAKING CHANGES: Major Backend Code Changes Updated Foreign keys to prepend their table names ex invoice_client_id, switched most queries over to JOIN instead of = Combined contacts and location into client removed client email, phone etc fields, tons of small bug fixes, and other small UI changes all across the board
This commit is contained in:
51
clients-test.php
Normal file
51
clients-test.php
Normal file
@@ -0,0 +1,51 @@
|
||||
<?php include("header.php");
|
||||
|
||||
$sql = mysqli_query($mysqli,"SELECT * FROM clients LEFT JOIN contacts ON clients.primary_contact = contacts.contact_id LEFT JOIN locations ON clients.primary_location = locations.location_id");
|
||||
|
||||
?>
|
||||
|
||||
<div class="card card-dark">
|
||||
<div class="card-header py-2">
|
||||
<h3 class="card-title mt-2"><i class="fa fa-fw fa-users"></i> Clients</h3>
|
||||
<div class="card-tools">
|
||||
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#addClientModal"><i class="fas fa-fw fa-plus"></i> New Client</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-body">
|
||||
<hr>
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped table-hover table-borderless">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Client ID</th>
|
||||
<th>Client</th>
|
||||
<th>Contact Name</th>
|
||||
<th>Location</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php
|
||||
|
||||
while($row = mysqli_fetch_array($sql)){
|
||||
$client_id = $row['client_id'];
|
||||
$client_name = $row['client_name'];
|
||||
$contact_name = $row['contact_name'];
|
||||
$location_address = $row['location_address'];
|
||||
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo $client_id; ?></td>
|
||||
<td><?php echo $client_name; ?></td>
|
||||
<td><?php echo $contact_name; ?></td>
|
||||
<td><?php echo $location_address; ?></td>
|
||||
</tr>
|
||||
|
||||
<?php } ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php include("footer.php");
|
||||
Reference in New Issue
Block a user