diff --git a/admin/post/users.php b/admin/post/users.php index b670ed8b3..55eaf280f 100644 --- a/admin/post/users.php +++ b/admin/post/users.php @@ -355,7 +355,7 @@ if (isExportRequest('export_users')) { $sql = mysqli_query( $mysqli, - "SELECT user_status FROM users + "SELECT role_name, user_created_at, user_email, user_name, user_status FROM users LEFT JOIN user_roles ON user_role_id = role_id WHERE (user_name LIKE '%$q%' OR user_email LIKE '%$q%') AND user_type = 1 diff --git a/agent/post/quote.php b/agent/post/quote.php index e41deae9e..ef62fd8d9 100644 --- a/agent/post/quote.php +++ b/agent/post/quote.php @@ -734,7 +734,8 @@ if (isExportRequest('export_quotes')) { $sql = mysqli_query( $mysqli, - "SELECT quote_number, quote_prefix FROM quotes + "SELECT client_name, quote_amount, quote_date, quote_number, quote_prefix, quote_scope, + quote_status FROM quotes LEFT JOIN clients ON quote_client_id = client_id LEFT JOIN categories ON quote_category_id = category_id WHERE (CONCAT(quote_prefix,quote_number) LIKE '%$q%' OR quote_scope LIKE '%$q%' OR category_name LIKE '%$q%' OR quote_status LIKE '%$q%' OR quote_amount LIKE '%$q%' OR client_name LIKE '%$q%') diff --git a/agent/post/recurring_invoice.php b/agent/post/recurring_invoice.php index 62b2c9462..63266ea16 100644 --- a/agent/post/recurring_invoice.php +++ b/agent/post/recurring_invoice.php @@ -671,7 +671,9 @@ if (isExportRequest('export_recurring_invoices')) { $sql = mysqli_query( $mysqli, - "SELECT recurring_invoice_frequency, recurring_invoice_number, recurring_invoice_prefix FROM recurring_invoices + "SELECT client_name, recurring_invoice_amount, recurring_invoice_created_at, + recurring_invoice_frequency, recurring_invoice_number, recurring_invoice_prefix, + recurring_invoice_scope FROM recurring_invoices LEFT JOIN clients ON recurring_invoice_client_id = client_id LEFT JOIN categories ON recurring_invoice_category_id = category_id WHERE (CONCAT(recurring_invoice_prefix,recurring_invoice_number) LIKE '%$q%' OR recurring_invoice_frequency LIKE '%$q%' OR recurring_invoice_scope LIKE '%$q%' OR client_name LIKE '%$q%' OR category_name LIKE '%$q%') diff --git a/agent/post/software.php b/agent/post/software.php index ec07d5892..f5914b1f7 100644 --- a/agent/post/software.php +++ b/agent/post/software.php @@ -292,7 +292,9 @@ if (isExportRequest('export_software')) { $sql = mysqli_query( $mysqli, - "SELECT software_id FROM software + "SELECT software_description, software_expire, software_id, software_key, software_license_type, + software_name, software_notes, software_purchase, software_seats, software_type, + software_version FROM software LEFT JOIN clients ON client_id = software_client_id LEFT JOIN vendors ON vendor_id = software_vendor_id WHERE (software_name LIKE '%$q%' OR software_type LIKE '%$q%' OR software_key LIKE '%$q%' OR client_name LIKE '%$q%') diff --git a/agent/post/ticket.php b/agent/post/ticket.php index 85513ed6f..479fd2aa9 100644 --- a/agent/post/ticket.php +++ b/agent/post/ticket.php @@ -2906,7 +2906,9 @@ if (isExportRequest('export_tickets')) { // Get records from database - same shape as the tickets page list query $sql = mysqli_query( $mysqli, - "SELECT category_name, ticket_billable, ticket_number, ticket_prefix, user_name FROM tickets + "SELECT category_name, client_name, contact_name, ticket_billable, ticket_closed_at, + ticket_created_at, ticket_number, ticket_prefix, ticket_priority, ticket_resolved_at, + ticket_status_name, ticket_subject, user_name FROM tickets LEFT JOIN clients ON ticket_client_id = client_id LEFT JOIN contacts ON ticket_contact_id = contact_id LEFT JOIN users ON ticket_assigned_to = user_id