mirror of https://github.com/itflow-org/itflow
Updated the Shared items box UI/UX on Client overview
This commit is contained in:
parent
b583e7f8c9
commit
436b10c577
|
|
@ -21,7 +21,7 @@
|
|||
|
||||
<ul class="nav nav-pills nav-justified mb-3">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link active" data-toggle="pill" href="#pills-details<?php echo $contact_id; ?>"><i class="fa fa-fw fa-user mr-2"></i>Details</a>
|
||||
<a class="nav-link active" data-toggle="pill" href="#pills-details<?php echo $contact_id; ?>"><i class="fa fa-fw fa-id-badge mr-2"></i>Details</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" data-toggle="pill" href="#pills-photo<?php echo $contact_id; ?>"><i class="fa fa-fw fa-image mr-2"></i>Photo</a>
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()"));
|
|||
|
||||
<div class="card card-dark">
|
||||
<div class="card-header py-2">
|
||||
<h3 class="card-title mt-2"><i class="fa fa-fw fa-users mr-2"></i>Contacts</h3>
|
||||
<h3 class="card-title mt-2"><i class="fa fa-fw fa-address-book mr-2"></i>Contacts</h3>
|
||||
<div class="card-tools">
|
||||
<div class="btn-group">
|
||||
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#addContactModal">
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@
|
|||
<label>Name <strong class="text-danger">*</strong></label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-user"></i></span>
|
||||
<span class="input-group-text"><i class="fa fa-fw fa-id-badge"></i></span>
|
||||
</div>
|
||||
<input type="text" class="form-control" name="name" placeholder="Name or Company"
|
||||
value="<?php echo $client_name; ?>" required>
|
||||
|
|
|
|||
|
|
@ -179,16 +179,6 @@ $sql_asset_retire = mysqli_query(
|
|||
</div>
|
||||
<div class="card-body p-2">
|
||||
<table class="table table-borderless table-sm">
|
||||
<thead class="text-dark">
|
||||
<tr>
|
||||
<th>Item Name</th>
|
||||
<th>Item Type</th>
|
||||
<th>Share Note</th>
|
||||
<th>Views</th>
|
||||
<th>Expires</th>
|
||||
<th class="text-center">Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php
|
||||
|
||||
|
|
@ -203,40 +193,33 @@ $sql_asset_retire = mysqli_query(
|
|||
$item_view_limit = nullable_htmlentities($row['item_view_limit']);
|
||||
$item_created_at = nullable_htmlentities($row['item_created_at']);
|
||||
$item_expire_at = nullable_htmlentities($row['item_expire_at']);
|
||||
$item_expire_at_human = timeAgo($row['item_expire_at']);
|
||||
|
||||
if ($item_type == 'Login') {
|
||||
$share_item_sql = mysqli_query($mysqli, "SELECT login_name FROM logins WHERE login_id = '$item_related_id' AND login_client_id = '$client_id'");
|
||||
$share_item_sql = mysqli_query($mysqli, "SELECT login_name FROM logins WHERE login_id = $item_related_id AND login_client_id = $client_id");
|
||||
$share_item = mysqli_fetch_array($share_item_sql);
|
||||
$item_name = nullable_htmlentities($share_item['login_name']);
|
||||
$item_icon = "fas fa-key";
|
||||
} elseif ($item_type == 'Document') {
|
||||
$share_item_sql = mysqli_query($mysqli, "SELECT document_name FROM documents WHERE document_id = '$item_related_id' AND document_client_id = '$client_id'");
|
||||
$share_item_sql = mysqli_query($mysqli, "SELECT document_name FROM documents WHERE document_id = $item_related_id AND document_client_id = $client_id");
|
||||
$share_item = mysqli_fetch_array($share_item_sql);
|
||||
$item_name = nullable_htmlentities($share_item['document_name']);
|
||||
$item_icon = "fas fa-folder";
|
||||
} elseif ($item_type == 'File') {
|
||||
$share_item_sql = mysqli_query($mysqli, "SELECT file_name FROM files WHERE file_id = '$item_related_id' AND file_client_id = '$client_id'");
|
||||
$share_item_sql = mysqli_query($mysqli, "SELECT file_name FROM files WHERE file_id = $item_related_id AND file_client_id = $client_id");
|
||||
$share_item = mysqli_fetch_array($share_item_sql);
|
||||
$item_name = nullable_htmlentities($share_item['file_name']);
|
||||
$item_icon = "fas fa-paperclip";
|
||||
}
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo $item_name; ?></td>
|
||||
<td><?php echo $item_type ?></td>
|
||||
<td><?php echo $item_note ?></td>
|
||||
<td><?php echo "$item_views / $item_view_limit" ?></td>
|
||||
<td><?php echo $item_expire_at ?></td>
|
||||
<td><i class="<?php echo $item_icon; ?> mr-2 text-secondary"></i><?php echo $item_name; ?></td>
|
||||
<td>Views: <?php echo "$item_views / $item_view_limit" ?></td>
|
||||
<td>Expires <?php echo $item_expire_at_human ?></td>
|
||||
<td>
|
||||
<?php if ($session_user_role == 3) { ?>
|
||||
<div class="dropdown dropleft text-center">
|
||||
<button class="btn btn-secondary btn-sm" type="button" data-toggle="dropdown">
|
||||
<i class="fas fa-ellipsis-h"></i>
|
||||
</button>
|
||||
<div class="dropdown-menu">
|
||||
<a class="dropdown-item text-danger confirm-link" href="post.php?deactivate_shared_item=<?php echo $item_id; ?>">
|
||||
<i class="fas fa-fw fa-times mr-2"></i>Deactivate
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<a class="text-danger confirm-link" href="post.php?deactivate_shared_item=<?php echo $item_id; ?>">
|
||||
<i class="fas fa-fw fa-calendar-times mr-2"></i>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
|
||||
<li class="nav-item">
|
||||
<a href="client_contacts.php?client_id=<?php echo $client_id; ?>" class="nav-link <?php if (basename($_SERVER["PHP_SELF"]) == "client_contacts.php" || basename($_SERVER["PHP_SELF"]) == "client_contact_details.php") { echo "active"; } ?>">
|
||||
<i class="nav-icon fas fa-users"></i>
|
||||
<i class="nav-icon fas fa-address-book"></i>
|
||||
<p>
|
||||
Contacts
|
||||
<?php
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
</li>
|
||||
<li class="nav-item">
|
||||
<a href="clients.php" class="nav-link <?php if (basename($_SERVER["PHP_SELF"]) == "clients.php") { echo "active"; } ?>">
|
||||
<i class="nav-icon fas fa-user-friends"></i>
|
||||
<i class="nav-icon fas fa-users"></i>
|
||||
<p>
|
||||
Clients
|
||||
<?php if ($num_active_clients) { ?>
|
||||
|
|
|
|||
Loading…
Reference in New Issue