diff --git a/check_login.php b/check_login.php index be452ffa..ed30cb4d 100644 --- a/check_login.php +++ b/check_login.php @@ -1,36 +1,36 @@

Assets

- +
@@ -84,7 +84,7 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()"));
- s"> + s">
@@ -92,30 +92,30 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()"));
@@ -169,19 +169,19 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()")); $asset_serial = htmlentities($row['asset_serial']); if (empty($asset_serial)) { $asset_serial_display = "-"; - }else{ + } else { $asset_serial_display = $asset_serial; } $asset_os = htmlentities($row['asset_os']); if (empty($asset_os)) { $asset_os_display = "-"; - }else{ + } else { $asset_os_display = $asset_os; } $asset_ip = htmlentities($row['asset_ip']); if (empty($asset_ip)) { $asset_ip_display = "-"; - }else{ + } else { $asset_ip_display = "$asset_ip"; } $asset_mac = htmlentities($row['asset_mac']); @@ -191,7 +191,7 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()")); $asset_install_date = $row['asset_install_date']; if (empty($asset_install_date)) { $asset_install_date_display = "-"; - }else{ + } else { $asset_install_date_display = $asset_install_date; } $asset_notes = htmlentities($row['asset_notes']); @@ -203,29 +203,29 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()")); if ($asset_type == 'Laptop') { $device_icon = "laptop"; - }elseif ($asset_type == 'Desktop') { + } elseif ($asset_type == 'Desktop') { $device_icon = "desktop"; - }elseif ($asset_type == 'Server') { + } elseif ($asset_type == 'Server') { $device_icon = "server"; - }elseif ($asset_type == 'Printer') { + } elseif ($asset_type == 'Printer') { $device_icon = "print"; - }elseif ($asset_type == 'Camera') { + } elseif ($asset_type == 'Camera') { $device_icon = "video"; - }elseif ($asset_type == 'Switch' || $asset_type == 'Firewall/Router') { + } elseif ($asset_type == 'Switch' || $asset_type == 'Firewall/Router') { $device_icon = "network-wired"; - }elseif ($asset_type == 'Access Point') { + } elseif ($asset_type == 'Access Point') { $device_icon = "wifi"; - }elseif ($asset_type == 'Phone') { + } elseif ($asset_type == 'Phone') { $device_icon = "phone"; - }elseif ($asset_type == 'Mobile Phone') { + } elseif ($asset_type == 'Mobile Phone') { $device_icon = "mobile-alt"; - }elseif ($asset_type == 'Tablet') { + } elseif ($asset_type == 'Tablet') { $device_icon = "tablet-alt"; - }elseif ($asset_type == 'TV') { + } elseif ($asset_type == 'TV') { $device_icon = "tv"; - }elseif ($asset_type == 'Virtual Machine') { + } elseif ($asset_type == 'Virtual Machine') { $device_icon = "cloud"; - }else{ + } else { $device_icon = "tag"; } @@ -345,10 +345,10 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()")); @@ -356,13 +356,11 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()"));
- +
- - +require_once("client_asset_add_modal.php"); +require_once("client_asset_import_modal.php"); +require_once include("footer.php"); diff --git a/client_files.php b/client_files.php index e74d6ccf..bdc2b3b3 100644 --- a/client_files.php +++ b/client_files.php @@ -1,4 +1,4 @@ - -
-
-

Files

-
- -
-
-
- -

No Records Here

"; - } - - ?> - -
- - - -
-
- - "> - - +
+
+

Files

+
+
-
+
+
- -
+ + echo "

No Records Here

"; + } - + ?> - +
-
- - - - + + + + + + + +
+ +
" target="_blank" class="text-secondary"> - " download="" class="text-secondary float-left ml-1"> - )" class="text-secondary float-left ml-1"> - -
+ + + + + + + + + + + - - - - +require_once("client_file_add_modal.php"); +require_once("share_modal.php"); +require_once("footer.php"); diff --git a/client_overview.php b/client_overview.php index bf10e5b6..2a33df92 100644 --- a/client_overview.php +++ b/client_overview.php @@ -1,4 +1,4 @@ - 0) { ?> -
+
-
-
-
Important Contacts
-
-
-
" target="_blank" class="text-secondary"> + " download="" class="text-secondary float-left ml-1"> + )" class="text-secondary float-left ml-1"> + +
- - - - - +
+
+
Important Contacts
+
+
+
- -
- -
- - $contact_phone $contact_extension"; ?> - - -
-
- -
-
+ while ($row = mysqli_fetch_array($sql_important_contacts)) { + $contact_id = $row['contact_id']; + $contact_name = htmlentities($row['contact_name']); + $contact_title = htmlentities($row['contact_title']); + $contact_email = htmlentities($row['contact_email']); + $contact_phone = formatPhoneNumber($row['contact_phone']); + $contact_extension = htmlentities($row['contact_extension']); + $contact_mobile = formatPhoneNumber($row['contact_mobile']); + + ?> + + + +
+ + + + + $contact_phone $contact_extension"; ?> + + +
+
+ + + + + + +
-
0 || mysqli_num_rows($sql_vendors) > 0) { ?> -
+
-
-
-
Recently Updated
-
-
+
+
+
Recently Updated
+
+
- -

- - -

- +

+ + +

+ -

- - -

- + +

+ + +

+ + +
-
- 0 - || mysqli_num_rows($sql_asset_warranties_expiring) > 0 - || mysqli_num_rows($sql_asset_retire) > 0 + 0 + || mysqli_num_rows($sql_asset_warranties_expiring) > 0 + || mysqli_num_rows($sql_asset_retire) > 0 ) { ?> - -
-
-
-
Upcoming Expirations
-
-
- - -

- - - -- -

- - - -

- - - -- -

+
+
+
+
Upcoming Expirations
+
+
- +

+ + + -- +

+ -

- - - -- -

+ while ($row = mysqli_fetch_array($sql_asset_warranties_expiring)) { + $asset_id = $row['asset_id']; + $asset_name = htmlentities($row['asset_name']); + $asset_warranty_expire = $row['asset_warranty_expire']; + + ?> +

+ + + -- +

+ + + + + +

+ + + -- +

+ + + +
-
0) { ?> - + -
+
-
-
-
Stale Tickets (14d)
-
-
- - - - - - - - - +
+
+
Stale Tickets (14d)
+
+
+
+ - -
+ while ($row = mysqli_fetch_array($sql_tickets_stale)) { + $ticket_id = $row['ticket_id']; + $ticket_prefix = htmlentities($row['ticket_prefix']); + $ticket_number = $row['ticket_number']; + $ticket_subject = htmlentities($row['ticket_subject']); + $ticket_created_at = $row['ticket_created_at']; + + ?> + + + + + + + + + + +
-
@@ -276,6 +276,4 @@ $sql_domains_expiring = mysqli_query($mysqli, "SELECT * FROM domains +require_once("footer.php"); diff --git a/invoice.php b/invoice.php index 5ad0aea5..21610614 100644 --- a/invoice.php +++ b/invoice.php @@ -1,6 +1,6 @@
- "> + " alt="Company logo">
@@ -483,12 +483,12 @@ if (isset($_GET['invoice_id'])) {
+ -
-
-

Notifications

-
- - 0) { ?> Dismiss All - Dismissed +
+
+

Notifications

+
+ + 0) { ?> Dismiss All + Dismissed +
+
+
+ 0) { ?> + +
+ + + + + + + + + + + + $client_name"; + } + + ?> + + + + + + + + + + + +
TimestampTypeNotificationClientDismiss
+
+
+ + +
+

No Notifications

+
+ +
-
-
- 0) { ?> -
- - - - - - - - - - - - $client_name"; - } - - ?> - - - - - - - - - - - -
TimestampTypeNotificationClientDismiss
-
-
- - -
-

No Notifications

-
- - -
- - - - 0) { - while ($row = mysqli_fetch_array($products_sql)) { - $products[] = $row; + $row = mysqli_fetch_array($sql); + $quote_id = $row['quote_id']; + $quote_prefix = htmlentities($row['quote_prefix']); + $quote_number = htmlentities($row['quote_number']); + $quote_scope = htmlentities($row['quote_scope']); + $quote_status = htmlentities($row['quote_status']); + $quote_date = $row['quote_date']; + $quote_amount = floatval($row['quote_amount']); + $quote_currency_code = htmlentities($row['quote_currency_code']); + $quote_note = htmlentities($row['quote_note']); + $quote_url_key = htmlentities($row['quote_url_key']); + $quote_created_at = $row['quote_created_at']; + $category_id = $row['quote_category_id']; + $client_id = $row['client_id']; + $client_name = htmlentities($row['client_name']); + $location_address = htmlentities($row['location_address']); + $location_city = htmlentities($row['location_city']); + $location_state = htmlentities($row['location_state']); + $location_zip = htmlentities($row['location_zip']); + $contact_email = htmlentities($row['contact_email']); + $contact_phone = formatPhoneNumber($row['contact_phone']); + $contact_extension = htmlentities($row['contact_extension']); + $contact_mobile = formatPhoneNumber($row['contact_mobile']); + $client_website = htmlentities($row['client_website']); + $client_currency_code = htmlentities($row['client_currency_code']); + $client_net_terms = htmlentities($row['client_net_terms']); + if ($client_net_terms == 0) { + $client_net_terms = $config_default_net_terms; + } + $company_id = $row['company_id']; + $company_name = htmlentities($row['company_name']); + $company_country = htmlentities($row['company_country']); + $company_address = htmlentities($row['company_address']); + $company_city = htmlentities($row['company_city']); + $company_state = htmlentities($row['company_state']); + $company_zip = htmlentities($row['company_zip']); + $company_phone = formatPhoneNumber($row['company_phone']); + $company_email = htmlentities($row['company_email']); + $company_website = htmlentities($row['company_website']); + $company_logo = htmlentities($row['company_logo']); + if (!empty($company_logo)) { + $company_logo_base64 = base64_encode(file_get_contents("uploads/settings/$company_id/$company_logo")); } - $json_products = json_encode($products); - } -?> + $sql_history = mysqli_query($mysqli,"SELECT * FROM history WHERE history_quote_id = $quote_id ORDER BY history_id DESC"); - + //Set Badge color based off of quote status + if ($quote_status == "Sent") { + $quote_badge_color = "warning text-white"; + }elseif ($quote_status == "Viewed") { + $quote_badge_color = "primary"; + }elseif ($quote_status == "Accepted") { + $quote_badge_color = "success"; + }elseif ($quote_status == "Declined") { + $quote_badge_color = "danger"; + }elseif ($quote_status == "Invoiced") { + $quote_badge_color = "info"; + }else{ + $quote_badge_color = "secondary"; + } -
-
+ //Product autocomplete + $products_sql = mysqli_query($mysqli,"SELECT product_name AS label, product_description AS description, product_price AS price FROM products WHERE company_id = $session_company_id"); -
+ if (mysqli_num_rows($products_sql) > 0) { + while ($row = mysqli_fetch_array($products_sql)) { + $products[] = $row; + } + $json_products = json_encode($products); + } -
- - - -
- -
-
- "> -
-
-

Quote

-
-
-
-
-
    -
  • -
  • -
  • -
  • -
  • -
-
-
-
    -
  • -
  • -
  • -
  • -
  • -
  • -
-
-
-
-
-
-
- - - - - -
Date
-
-
- - - -
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +
ItemDescriptionQtyPriceTaxTotal
- - -
- + + + + + + + + + + + + + + - - - - - - -
DateStatusDescription
- -
- - - - -
-
-
-
- Notes -
- - - +
+
-
-
-
-
-
- -
- - - - - - - 0) { ?> - - - - - - - - - - -
Subtotal
Tax
Total
-
-
+ -
-
+} -
-
-
-
- History -
- - -
-
-
- - - - - - - - - - - - - - - - - - -
DateStatusDescription
-
-
-
-
- - @@ -406,406 +405,406 @@ include("footer.php"); diff --git a/recurring_invoice.php b/recurring_invoice.php index a6d7b465..4d96b417 100644 --- a/recurring_invoice.php +++ b/recurring_invoice.php @@ -1,4 +1,4 @@ - diff --git a/settings_backup.php b/settings_backup.php index 8ac2c4dc..ce21b22d 100644 --- a/settings_backup.php +++ b/settings_backup.php @@ -4,10 +4,8 @@

Download Database

-
-
-

Download
-
+
@@ -16,18 +14,20 @@

Backup Master Encryption Key

-
+
-
-
- +
+
+
+ +
+
-
-
+
-

Update

-
-
+
- - -
- - + if (!empty($git_log)) { ?> @@ -83,4 +77,4 @@ $git_log = shell_exec("git log $repo_branch..origin/$repo_branch --pretty=format