mirror of
https://github.com/itflow-org/itflow
synced 2026-02-28 02:44:53 +00:00
Updated Edit Location logic in contacts added Pop Over Title for archived Items in assets and contacts
This commit is contained in:
@@ -122,14 +122,20 @@
|
||||
<option value="">- Location -</option>
|
||||
<?php
|
||||
|
||||
$sql_locations = mysqli_query($mysqli, "SELECT * FROM locations WHERE (location_archived_at > '$contact_created_at' OR location_archived_at IS NULL) AND location_client_id = $client_id ORDER BY location_name ASC");
|
||||
$sql_locations = mysqli_query($mysqli, "SELECT * FROM locations WHERE location_id = $contact_location_id OR location_archived_at IS NULL AND location_client_id = $client_id ORDER BY location_name ASC");
|
||||
while ($row = mysqli_fetch_array($sql_locations)) {
|
||||
$location_id_select = intval($row['location_id']);
|
||||
$location_name_select = nullable_htmlentities($row['location_name']);
|
||||
$location_archived_at = nullable_htmlentities($row['location_archived_at']);
|
||||
if ($location_archived_at) {
|
||||
$location_name_select_display = "($location_name_select) - ARCHIVED";
|
||||
} else {
|
||||
$location_name_select_display = $location_name_select;
|
||||
}
|
||||
?>
|
||||
<option <?php if ($contact_location_id == $location_id_select) {
|
||||
echo "selected";
|
||||
} ?> value="<?php echo $location_id_select; ?>"><?php echo $location_name_select; ?></option>
|
||||
} ?> value="<?php echo $location_id_select; ?>"><?php echo $location_name_select_display; ?></option>
|
||||
<?php } ?>
|
||||
|
||||
</select>
|
||||
|
||||
Reference in New Issue
Block a user