sorted even more dropdowns alphabetically

This commit is contained in:
johnny@pittpc.com 2020-04-04 23:35:54 -04:00
parent 76709bdada
commit 7e1ee10a7f
14 changed files with 35 additions and 35 deletions

View File

@ -117,7 +117,7 @@
<option value="">- Location -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM locations WHERE client_id = $client_id");
$sql = mysqli_query($mysqli,"SELECT * FROM locations WHERE client_id = $client_id ORDER BY location_name ASC");
while($row = mysqli_fetch_array($sql)){
$location_id = $row['location_id'];
$location_name = $row['location_name'];
@ -141,7 +141,7 @@
<option value="">- Contact -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM contacts WHERE client_id = $client_id");
$sql = mysqli_query($mysqli,"SELECT * FROM contacts WHERE client_id = $client_id ORDER BY contact_name ASC");
while($row = mysqli_fetch_array($sql)){
$contact_id = $row['contact_id'];
$contact_name = $row['contact_name'];
@ -165,7 +165,7 @@
<option value="">- Network -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM networks WHERE client_id = $client_id");
$sql = mysqli_query($mysqli,"SELECT * FROM networks WHERE client_id = $client_id ORDER BY network_name ASC");
while($row = mysqli_fetch_array($sql)){
$network_id = $row['network_id'];
$network_name = $row['network_name'];
@ -215,7 +215,7 @@
<option value="">- Vendor -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id");
$sql = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id ORDER BY vendor_name ASC");
while($row = mysqli_fetch_array($sql)){
$vendor_id = $row['vendor_id'];
$vendor_name = $row['vendor_name'];

View File

@ -30,7 +30,7 @@
<option value="">- Vendor -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id");
$sql = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id ORDER BY vendor_name ASC");
while($row = mysqli_fetch_array($sql)){
$vendor_id = $row['vendor_id'];
$vendor_name = $row['vendor_name'];
@ -54,7 +54,7 @@
<option value="">- Vendor -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id");
$sql = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id ORDER BY vendor_name ASC");
while($row = mysqli_fetch_array($sql)){
$vendor_id = $row['vendor_id'];
$vendor_name = $row['vendor_name'];

View File

@ -133,7 +133,7 @@
<option value="">- Contact -</option>
<?php
$sql_vendors = mysqli_query($mysqli,"SELECT * FROM contacts WHERE client_id = $client_id");
$sql_vendors = mysqli_query($mysqli,"SELECT * FROM contacts WHERE client_id = $client_id ORDER BY contact_name ASC");
while($row = mysqli_fetch_array($sql_vendors)){
$contact_id = $row['contact_id'];
$contact_name = $row['contact_name'];

View File

@ -96,7 +96,7 @@
<option value="">- Vendor -</option>
<?php
$sql_vendors = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id");
$sql_vendors = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id ORDER BY vendor_name ASC");
while($row = mysqli_fetch_array($sql_vendors)){
$vendor_id = $row['vendor_id'];
$vendor_name = $row['vendor_name'];
@ -120,7 +120,7 @@
<option value="">- Asset -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM assets WHERE client_id = $client_id");
$sql = mysqli_query($mysqli,"SELECT * FROM assets WHERE client_id = $client_id ORDER BY asset_name ASC");
while($row = mysqli_fetch_array($sql)){
$asset_id = $row['asset_id'];
$asset_name = $row['asset_name'];
@ -144,7 +144,7 @@
<option value="">- software -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM software WHERE client_id = $client_id");
$sql = mysqli_query($mysqli,"SELECT * FROM software WHERE client_id = $client_id ORDER BY software_name ASC");
while($row = mysqli_fetch_array($sql)){
$software_id = $row['software_id'];
$software_name = $row['software_name'];

View File

@ -70,7 +70,7 @@
<option value="">- Location -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM locations WHERE client_id = $client_id");
$sql = mysqli_query($mysqli,"SELECT * FROM locations WHERE client_id = $client_id ORDER BY location_name ASC");
while($row = mysqli_fetch_array($sql)){
$location_id = $row['location_id'];
$location_name = $row['location_name'];

View File

@ -53,7 +53,7 @@
<option value="">- Account -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id ORDER BY account_name ASC");
while($row = mysqli_fetch_array($sql)){
$account_id = $row['account_id'];
$account_name = $row['account_name'];
@ -93,7 +93,7 @@
<option value="">- Method of Payment -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM categories WHERE category_type = 'Payment Method' AND company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM categories WHERE category_type = 'Payment Method' AND company_id = $session_company_id ORDER BY category_name ASC");
while($row = mysqli_fetch_array($sql)){
$category_name = $row['category_name'];
?>

View File

@ -56,7 +56,7 @@
<option value="">- Account From -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id ORDER BY account_name ASC");
while($row = mysqli_fetch_array($sql)){
$account_id = $row['account_id'];
$account_name = $row['account_name'];
@ -94,7 +94,7 @@
<option value="">- Account To -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id ORDER BY account_name ASC");
while($row = mysqli_fetch_array($sql)){
$account_id = $row['account_id'];
$account_name = $row['account_name'];

View File

@ -64,7 +64,7 @@
<div class="tab-pane fade" id="pills-assign">
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM companies");
$sql = mysqli_query($mysqli,"SELECT * FROM companies ORDER BY company_name ASC");
while($row = mysqli_fetch_array($sql)){
$company_id = $row['company_id'];
@ -90,7 +90,7 @@
<option value="0">No Client Assignment</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM clients");
$sql = mysqli_query($mysqli,"SELECT * FROM clients ORDER BY client_name ASC");
while($row = mysqli_fetch_array($sql)){
$client_id = $row['client_id'];
$client_name = $row['client_name'];

View File

@ -116,7 +116,7 @@
<option value="">- Location -</option>
<?php
$sql_locations = mysqli_query($mysqli,"SELECT * FROM locations WHERE client_id = $client_id");
$sql_locations = mysqli_query($mysqli,"SELECT * FROM locations WHERE client_id = $client_id ORDER BY location_name ASC");
while($row = mysqli_fetch_array($sql_locations)){
$location_id_select = $row['location_id'];
$location_name_select = $row['location_name'];
@ -140,7 +140,7 @@
<option value="">- Contact -</option>
<?php
$sql_contacts = mysqli_query($mysqli,"SELECT * FROM contacts WHERE client_id = $client_id");
$sql_contacts = mysqli_query($mysqli,"SELECT * FROM contacts WHERE client_id = $client_id ORDER BY contact_name ASC");
while($row = mysqli_fetch_array($sql_contacts)){
$contact_id_select = $row['contact_id'];
$contact_name_select = $row['contact_name'];
@ -164,7 +164,7 @@
<option value="">- Network -</option>
<?php
$sql_networks = mysqli_query($mysqli,"SELECT * FROM networks WHERE client_id = $client_id");
$sql_networks = mysqli_query($mysqli,"SELECT * FROM networks WHERE client_id = $client_id ORDER BY network_name ASC");
while($row = mysqli_fetch_array($sql_networks)){
$network_id_select = $row['network_id'];
$network_name_select = $row['network_name'];
@ -214,7 +214,7 @@
<option value="">- Vendor -</option>
<?php
$sql_vendors = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id");
$sql_vendors = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id ORDER BY vendor_name ASC");
while($row = mysqli_fetch_array($sql_vendors)){
$vendor_id_select = $row['vendor_id'];
$vendor_name_select = $row['vendor_name'];

View File

@ -134,7 +134,7 @@
<option value="">- Contact -</option>
<?php
$sql_contacts = mysqli_query($mysqli,"SELECT * FROM contacts WHERE client_id = $client_id");
$sql_contacts = mysqli_query($mysqli,"SELECT * FROM contacts WHERE client_id = $client_id ORDER BY contact_name ASC");
while($row = mysqli_fetch_array($sql_contacts)){
$contact_id_select = $row['contact_id'];
$contact_name_select = $row['contact_name'];

View File

@ -105,7 +105,7 @@
<option value="0">- None -</option>
<?php
$sql_vendors = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id");
$sql_vendors = mysqli_query($mysqli,"SELECT * FROM vendors WHERE client_id = $client_id ORDER BY vendor_name ASC");
while($row = mysqli_fetch_array($sql_vendors)){
$vendor_id_select = $row['vendor_id'];
$vendor_name_select = $row['vendor_name'];
@ -129,7 +129,7 @@
<option value="0">- None -</option>
<?php
$sql_assets = mysqli_query($mysqli,"SELECT * FROM assets WHERE client_id = $client_id");
$sql_assets = mysqli_query($mysqli,"SELECT * FROM assets WHERE client_id = $client_id ORDER BY asset_name ASC");
while($row = mysqli_fetch_array($sql_assets)){
$asset_id_select = $row['asset_id'];
$asset_name_select = $row['asset_name'];
@ -153,7 +153,7 @@
<option value="0">- None -</option>
<?php
$sql_software = mysqli_query($mysqli,"SELECT * FROM software WHERE client_id = $client_id");
$sql_software = mysqli_query($mysqli,"SELECT * FROM software WHERE client_id = $client_id ORDER BY software_name ASC");
while($row = mysqli_fetch_array($sql_applications)){
$software_id_select = $row['software_id'];
$software_name_select = $row['software_name'];

View File

@ -70,7 +70,7 @@
<option value="">- Location -</option>
<?php
$sql_locations = mysqli_query($mysqli,"SELECT * FROM locations WHERE client_id = $client_id");
$sql_locations = mysqli_query($mysqli,"SELECT * FROM locations WHERE client_id = $client_id ORDER BY location_name ASC");
while($row = mysqli_fetch_array($sql_locations)){
$location_id_select = $row['location_id'];
$location_name_select = $row['location_name'];

View File

@ -55,7 +55,7 @@
<select class="form-control select2" name="account_from" required>
<?php
$sql_accounts = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id");
$sql_accounts = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id ORDER BY account_name ASC");
while($row = mysqli_fetch_array($sql_accounts)){
$account_id_select = $row['account_id'];
$account_name_select = $row['account_name'];
@ -93,7 +93,7 @@
<select class="form-control select2" name="account_to" required>
<?php
$sql2 = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id");
$sql2 = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id ORDER BY account_name ASC");
while($row = mysqli_fetch_array($sql2)){
$account_id2 = $row['account_id'];
$account_name = $row['account_name'];

View File

@ -18,7 +18,7 @@
<option value="0">- None -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id ORDER BY account_name ASC");
while($row = mysqli_fetch_array($sql)){
$account_id = $row['account_id'];
$account_name = $row['account_name'];
@ -43,7 +43,7 @@
<option value="0">- None -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id ORDER BY account_name ASC");
while($row = mysqli_fetch_array($sql)){
$account_id = $row['account_id'];
$account_name = $row['account_name'];
@ -68,7 +68,7 @@
<option value="0">- None -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id ORDER BY account_name ASC");
while($row = mysqli_fetch_array($sql)){
$account_id = $row['account_id'];
$account_name = $row['account_name'];
@ -93,7 +93,7 @@
<option value="0">- None -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM accounts WHERE company_id = $session_company_id ORDER BY account_name ASC");
while($row = mysqli_fetch_array($sql)){
$account_id = $row['account_id'];
$account_name = $row['account_name'];
@ -118,7 +118,7 @@
<option value="">- None -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM categories WHERE category_type = 'Payment Method' AND company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM categories WHERE category_type = 'Payment Method' AND company_id = $session_company_id ORDER BY category_name ASC");
while($row = mysqli_fetch_array($sql)){
$payment_method = $row['category_name'];
@ -142,7 +142,7 @@
<option value="">- None -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM categories WHERE category_type = 'Payment Method' AND company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM categories WHERE category_type = 'Payment Method' AND company_id = $session_company_id ORDER BY category_name ASC");
while($row = mysqli_fetch_array($sql)){
$payment_method = $row['category_name'];
@ -166,7 +166,7 @@
<option value="0">- None -</option>
<?php
$sql = mysqli_query($mysqli,"SELECT * FROM calendars WHERE company_id = $session_company_id");
$sql = mysqli_query($mysqli,"SELECT * FROM calendars WHERE company_id = $session_company_id ORDER BY calendar_name ASC");
while($row = mysqli_fetch_array($sql)){
$calendar_id = $row['calendar_id'];
$calendar_name = $row['calendar_name'];