X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;ds=inline;f=includes%2Fui%2Fui_lists.inc;h=1d804985bff59a491343a73c0965bb81050f7169;hb=4d12907d400d8b7a9a5150b260a30c19a53d1010;hp=6170e79f41496303cda59347fc4fd520a38bb721;hpb=d1babda7c01b314d35fb89f2d195553b55936532;p=fa-stable.git
diff --git a/includes/ui/ui_lists.inc b/includes/ui/ui_lists.inc
index 6170e79f..1d804985 100644
--- a/includes/ui/ui_lists.inc
+++ b/includes/ui/ui_lists.inc
@@ -25,9 +25,9 @@ define('SELECT_BUTTON', " array(), // additional constraints
@@ -60,7 +60,8 @@ $opts = array( // default options
'box_hint' => null, // box/selectors hints; null = std see below
'category' => false, // category column name or false
'show_inactive' => false, // show inactive records.
- 'editable' => false // false, or length of editable entry field
+ 'editable' => false, // false, or length of editable entry field
+ 'editlink' => false // link to entity entry/edit page (optional)
);
// ------ merge options with defaults ----------
if($options != null)
@@ -149,7 +150,7 @@ $opts = array( // default options
foreach($opts['search'] as $i=> $s)
$opts['search'][$i] = $s . " LIKE "
.db_escape(($class=='combo3' ? '' : '%').$txt.'%');
- $opts['where'][] = '('. implode($opts['search'], ' OR ') . ')';
+ $opts['where'][] = '('. implode(' OR ', $opts['search']) . ')';
}
}
}
@@ -157,7 +158,7 @@ $opts = array( // default options
// sql completion
if (count($opts['where'])) {
$where = strpos($sql, 'WHERE')==false ? ' WHERE ':' AND ';
- $where .= '('. implode($opts['where'], ' AND ') . ')';
+ $where .= '('. implode(' AND ', $opts['where']) . ')';
$group_pos = strpos($sql, 'GROUP BY');
if ($group_pos) {
$group = substr($sql, $group_pos);
@@ -179,13 +180,14 @@ $opts = array( // default options
$found = false;
$lastcat = null;
$edit = false;
-//if($name=='stock_id') display_notification('