Skip to content

Commit

Permalink
Fix info and banner on societe
Browse files Browse the repository at this point in the history
  • Loading branch information
atm-maxime committed Nov 19, 2015
1 parent e4125c9 commit 826592c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion htdocs/product/card.php
Expand Up @@ -1305,7 +1305,7 @@
$picto=($object->type== Product::TYPE_SERVICE?'service':'product');
dol_fiche_head($head, 'card', $titre, 0, $picto);

dol_banner_tab($object, 'ref', '', ($user->societe_id?0:1), 'ref');
dol_banner_tab($object, 'id', '', ($user->societe_id?0:1), 'ref');


print '<div class="fichecenter">';
Expand Down
4 changes: 2 additions & 2 deletions htdocs/product/class/product.class.php
Expand Up @@ -4123,7 +4123,7 @@ public function getRights()
*/
function info($id)
{
$sql = "SELECT p.rowid, p.datec as date_creation, p.tms as date_modification,";
$sql = "SELECT p.rowid, p.ref, p.datec as date_creation, p.tms as date_modification,";
$sql.= " p.fk_user_author, p.fk_user_modif";
$sql.= " FROM ".MAIN_DB_PREFIX.$this->table_element." as p";
$sql.= " WHERE p.rowid = ".$id;
Expand All @@ -4149,7 +4149,7 @@ function info($id)
$this->user_modification = $muser;
}

$this->ref = $obj->name;
$this->ref = $obj->ref;
$this->date_creation = $this->db->jdate($obj->date_creation);
$this->date_modification = $this->db->jdate($obj->date_modification);
}
Expand Down
8 changes: 3 additions & 5 deletions htdocs/societe/info.php
Expand Up @@ -78,15 +78,13 @@
exit;
}

$object->info($socid);

$head = societe_prepare_head($object);

dol_fiche_head($head, 'info', $langs->trans("ThirdParty"), 0, 'company');

$linkback = '<a href="'.DOL_URL_ROOT.'/contact/list.php">'.$langs->trans("BackToList").'</a>';

dol_banner_tab($object, 'id', $linkback, 1, 'rowid', 'ref', '');
dol_banner_tab($object, 'socid', '', ($user->societe_id?0:1), 'rowid', 'nom');
$object->info($socid);


print '<div class="fichecenter">';
Expand Down

0 comments on commit 826592c

Please sign in to comment.