forked from Wavyzz/dolibarr
FIX Change position of line in BOM
This commit is contained in:
@@ -47,8 +47,8 @@ top_httphead();
|
||||
print '<!-- Ajax page called with url '.dol_escape_htmltag($_SERVER["PHP_SELF"]).'?'.dol_escape_htmltag($_SERVER["QUERY_STRING"]).' -->'."\n";
|
||||
|
||||
// Registering the location of boxes
|
||||
if ((!empty($_POST['roworder'])) && (!empty($_POST['table_element_line']))
|
||||
&& (!empty($_POST['fk_element'])) && (!empty($_POST['element_id'])))
|
||||
if (GETPOST('roworder', 'alpha') && GETPOST('table_element_line', 'alpha', 2)
|
||||
&& GETPOST('fk_element', 'alpha', 2) && GETPOST('element_id', 'int', 2))
|
||||
{
|
||||
$roworder = GETPOST('roworder', 'alpha', 2);
|
||||
$table_element_line = GETPOST('table_element_line', 'alpha', 2);
|
||||
|
||||
@@ -8154,6 +8154,9 @@ abstract class CommonObject
|
||||
$sql .= ' FROM '.MAIN_DB_PREFIX.$objectline->table_element;
|
||||
$sql .= ' WHERE fk_'.$this->element.' = '.$this->id;
|
||||
if ($morewhere) $sql .= $morewhere;
|
||||
if (isset($objectline->fields['position'])) {
|
||||
$sql .= $this->db->order('position', 'ASC');
|
||||
}
|
||||
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql)
|
||||
|
||||
Reference in New Issue
Block a user