From: Janusz Dobrowolski Date: Sun, 15 May 2011 18:34:27 +0000 (+0200) Subject: [0000806] Branches were repeated in Customer Branches table when more than one genera... X-Git-Tag: 2.3-final~644 X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=commitdiff_plain;h=0622b346c43b166e29441faac20fdd6102568585;p=fa-stable.git [0000806] Branches were repeated in Customer Branches table when more than one general contact defined. --- diff --git a/sales/includes/db/branches_db.inc b/sales/includes/db/branches_db.inc index 2688d1b3..c02b74c2 100644 --- a/sales/includes/db/branches_db.inc +++ b/sales/includes/db/branches_db.inc @@ -164,7 +164,7 @@ function get_sql_for_customer_branches() AND b.debtor_no = ".db_escape($_POST['customer_id']); if (!get_post('show_inactive')) $sql .= " AND !b.inactive"; - $sql .= " ORDER BY branch_ref"; + $sql .= " GROUP BY b.branch_code ORDER BY branch_ref"; return $sql; }