X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=includes%2Fui%2Fui_lists.inc;h=3c16809af728bca9a21dd621dc97cf80707cb5de;hb=9b413697aa4ca30f7f336dbf5fd04bf8caf2bc43;hp=e27d245ecaea5675654fb772aed1a604694d3786;hpb=9b5d1dfb37f7ebb58a5277920c8c4bea2a8b4a97;p=fa-stable.git
diff --git a/includes/ui/ui_lists.inc b/includes/ui/ui_lists.inc
index e27d245e..3c16809a 100644
--- a/includes/ui/ui_lists.inc
+++ b/includes/ui/ui_lists.inc
@@ -748,58 +748,13 @@ function sales_local_items_list_row($label, $name, $selected_id=null, $all_optio
}
//------------------------------------------------------------------------------------
-function base_stock_items_list($where, $name, $selected_id=null,
- $all_option=false, $submit_on_change=false)
-{
- global $all_items;
-
- $sql = "SELECT stock_id, s.description, c.description
- FROM ".TB_PREF."stock_master s,".TB_PREF."stock_category c WHERE
- s.category_id=c.category_id";
-
- return combo_input($name, $selected_id, $sql, 'stock_id', 's.description',
- array(
- 'format' => '_format_stock_items',
- 'spec_option' => $all_option==true ? _("All Items") : $all_option,
- 'spec_id' => $all_items,
- 'select_submit'=> $submit_on_change,
- 'where' => $where,
- 'category' => 2 ) );
-}
-//------------------------------------------------------------------------------------
-
-function stock_bom_items_list($name, $selected_id=null, $all_option=false, $submit_on_change=false)
-{
-
- return base_stock_items_list("s.mb_flag='M'",
- $name, $selected_id, $all_option, $submit_on_change);
-}
-/*
-function stock_bom_items_list_cells($label, $name, $selected_id=null, $all_option=false, $submit_on_change=false)
-{
- if ($label != null)
- echo "
$label | \n";
- echo "";
- $str = stock_bom_items_list($name, $selected_id, $all_option, $submit_on_change);
- echo " | \n";
- return $str;
-}
-
-function stock_bom_items_list_row($label, $name, $selected_id=null, $all_option=false, $submit_on_change=false)
-{
- echo "\n";
- $str = stock_bom_items_list_cells($label, $name, $selected_id, $all_option, $submit_on_change);
- echo "
\n";
- return $str;
-}
-*/
-//------------------------------------------------------------------------------------
-
function stock_manufactured_items_list($name, $selected_id=null,
$all_option=false, $submit_on_change=false)
{
- return base_stock_items_list("s.mb_flag='M'",
- $name, $selected_id, $all_option, $submit_on_change);
+ $str = stock_items_list($name, $selected_id, $all_option, $submit_on_change,
+ array('where'=>array("mb_flag= 'M'"),
+ 'edit_submit' => true));
+ return $str;
}
function stock_manufactured_items_list_cells($label, $name, $selected_id=null,
@@ -808,8 +763,7 @@ function stock_manufactured_items_list_cells($label, $name, $selected_id=null,
if ($label != null)
echo "$label | \n";
echo "";
- $str = stock_manufactured_items_list($name, $selected_id, $all_option,
- $submit_on_change);
+ $str = stock_manufactured_items_list($name, $selected_id, $all_option, $submit_on_change);
echo " | \n";
return $str;
}
@@ -818,8 +772,7 @@ function stock_manufactured_items_list_row($label, $name, $selected_id=null,
$all_option=false, $submit_on_change=false)
{
echo "\n";
- $str = stock_manufactured_items_list_cells($label, $name, $selected_id,
- $all_option, $submit_on_change);
+ $str = stock_manufactured_items_list_cells($label, $name, $selected_id, $all_option, $submit_on_change);
echo "
\n";
return $str;
}
@@ -927,10 +880,7 @@ function stock_units_list_row($label, $name, $value=null, $enabled=true)
while($unit = db_fetch($result))
$units[$unit['abbr']] = $unit['name'];
- array_selector($name, $value, $units,
- array(
- 'select_submit'=> true,
- 'disabled' => !$enabled) );
+ array_selector($name, $value, $units, array( 'disabled' => !$enabled) );
echo "\n";
}
@@ -1699,7 +1649,8 @@ function payment_person_types_list($name, $selected_id=null, $submit_on_change=f
{
if (payment_person_types::has_items($type['id']))
{
- $items[$type['id']] = $type['name'];
+ if ($type['id'] != payment_person_types::WorkOrder())
+ $items[$type['id']] = $type['name'];
}
}
@@ -2066,4 +2017,17 @@ function quick_entry_types_list_row($label, $name, $selected_id=null, $submit_on
}
+function class_types_list_row($label, $name, $selected_id=null, $submit_on_change=false)
+{
+ global $class_types;
+
+ echo "$label | ";
+ array_selector($name, $selected_id, $class_types,
+ array(
+ 'select_submit'=> $submit_on_change
+ ) );
+ echo " |
\n";
+}
+
+
?>
\ No newline at end of file