X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=includes%2Fui%2Fui_lists.inc;h=0bc9ca0b92f7264bf116843358655e6d1c5b7504;hb=09b78473fba154c8749f6cc0eda7bd046a35716c;hp=eab6f4fa7cf5d58e09528184931a00805ba99f36;hpb=004760666ed0828f177b6055f91cf6f6ce905be2;p=fa-stable.git
diff --git a/includes/ui/ui_lists.inc b/includes/ui/ui_lists.inc
index eab6f4fa..0bc9ca0b 100644
--- a/includes/ui/ui_lists.inc
+++ b/includes/ui/ui_lists.inc
@@ -551,10 +551,11 @@ function supplier_list_cells($label, $name, $selected_id=null, $all_option=false
$submit_on_change=false, $all=false, $editkey = false)
{
if ($label != null)
- echo "
$label | \n";
- echo supplier_list($name, $selected_id, $all_option, $submit_on_change,
+ echo " | $label | \n";
+ echo "";
+ echo supplier_list($name, $selected_id, $all_option, $submit_on_change,
$all, $editkey);
- echo " | \n";
+ echo "\n";
}
function supplier_list_row($label, $name, $selected_id=null, $all_option = false,
@@ -1202,7 +1203,7 @@ function tax_types_list_row($label, $name, $selected_id=null, $none_option=false
function tax_groups_list($name, $selected_id=null,
$none_option=false, $submit_on_change=false)
{
- $sql = "SELECT id, name FROM ".TB_PREF."tax_groups";
+ $sql = "SELECT id, name, inactive FROM ".TB_PREF."tax_groups";
return combo_input($name, $selected_id, $sql, 'id', 'name',
array(
@@ -1311,25 +1312,27 @@ function sales_persons_list_row($label, $name, $selected_id=null, $spec_opt=fals
//------------------------------------------------------------------------------------
-function sales_areas_list($name, $selected_id=null)
+function sales_areas_list($name, $selected_id=null, $special_option=false)
{
$sql = "SELECT area_code, description, inactive FROM ".TB_PREF."areas";
- return combo_input($name, $selected_id, $sql, 'area_code', 'description', array());
+ return combo_input($name, $selected_id, $sql, 'area_code', 'description',
+ array('spec_option' => $special_option===true ? ' ' : $special_option,
+ 'order' => 'description', 'spec_id' => 0));
}
-function sales_areas_list_cells($label, $name, $selected_id=null)
+function sales_areas_list_cells($label, $name, $selected_id=null, $special_option=false)
{
if ($label != null)
echo "$label | \n";
echo "";
- echo sales_areas_list($name, $selected_id);
+ echo sales_areas_list($name, $selected_id, $special_option);
echo " | \n";
}
-function sales_areas_list_row($label, $name, $selected_id=null)
+function sales_areas_list_row($label, $name, $selected_id=null, $special_option=false)
{
echo "$label | ";
- sales_areas_list_cells(null, $name, $selected_id);
+ sales_areas_list_cells(null, $name, $selected_id, $special_option);
echo "
\n";
}
@@ -2637,12 +2640,12 @@ function subledger_list($name, $account, $selected_id=null)
FROM "
.TB_PREF."debtors_master d,"
.TB_PREF."cust_branch c
- WHERE d.debtor_no=c.debtor_no AND c.receivables_account=".db_escape($account);
+ WHERE d.debtor_no=c.debtor_no AND NOT d.inactive AND c.receivables_account=".db_escape($account);
else
$sql = "SELECT supplier_id as id, supp_ref as name
FROM "
.TB_PREF."suppliers s
- WHERE s.payable_account=".db_escape($account);
+ WHERE NOT s.inactive AND s.payable_account=".db_escape($account);
$mode = get_company_pref('no_customer_list');