diff --git a/htdocs/categories/fiche.php b/htdocs/categories/fiche.php
index 9a9e45b2750..62265838efa 100644
--- a/htdocs/categories/fiche.php
+++ b/htdocs/categories/fiche.php
@@ -226,36 +226,11 @@ if ($user->rights->categorie->creer)
}
print '';
- if ($_GET['type'] == 0 && $conf->global->CATEGORY_ASSIGNED_TO_A_CUSTOMER)
- {
- if ($_REQUEST['catorigin'])
- {
- print '
| '.$langs->trans ("AddIn").' | ';
- print $html->select_all_categories($_GET['type'],$_REQUEST['catorigin']);
- print ' |
';
- print '| '.$langs->trans ("ContentsVisibleByAll").' | ';
- print $html->selectyesno("visible", 1,1);
- print ' |
';
- print '';
- }
- else
- {
- print '| '.$langs->trans ("AssignedToCustomer").' | ';
- print $html->select_societes($socid,'socid','s.client IN (1, 3) AND s.fournisseur = 0',1);
- print ' |
';
- print '';
- print '';
- }
- }
- else
- {
- print '| '.$langs->trans ("AddIn").' | ';
- print $html->select_all_categories($_GET['type']);
- print ' |
';
- print '| '.$langs->trans ("ContentsVisibleByAll").' | ';
- print $html->selectyesno("visible", 1,1);
- print ' |
';
- }
+
+ print '| '.$langs->trans ("AddIn").' | ';
+ print $html->select_all_categories($_GET['type'],$_REQUEST['catorigin']);
+ print ' |
';
+
print '';
print '
';
diff --git a/htdocs/categories/photos.php b/htdocs/categories/photos.php
index 30ff419faa6..d7a48b3e65f 100644
--- a/htdocs/categories/photos.php
+++ b/htdocs/categories/photos.php
@@ -1,6 +1,6 @@
- * Copyright (C) 2004-2009 Laurent Destailleur
+ * Copyright (C) 2004-2010 Laurent Destailleur
* Copyright (C) 2005 Eric Seigne
* Copyright (C) 2005-2009 Regis Houssin
*
@@ -147,7 +147,7 @@ if ($_GET["id"] || $_GET["ref"])
print '';
// Visibility
- if ($type == 0 && $conf->global->CATEGORY_ASSIGNED_TO_A_CUSTOMER)
+/* if ($type == 0 && $conf->global->CATEGORY_ASSIGNED_TO_A_CUSTOMER)
{
if ($c->socid)
{
@@ -188,6 +188,7 @@ if ($_GET["id"] || $_GET["ref"])
print ($c->visible ? $langs->trans("Visible") : $langs->trans("Invisible"));
print '';
}
+*/
print "\n";
diff --git a/htdocs/categories/viewcat.php b/htdocs/categories/viewcat.php
index 5d58601971c..e7a4f766fa3 100644
--- a/htdocs/categories/viewcat.php
+++ b/htdocs/categories/viewcat.php
@@ -1,6 +1,6 @@
- * Copyright (C) 2006-2009 Laurent Destailleur
+ * Copyright (C) 2006-2010 Laurent Destailleur
* Copyright (C) 2007 Patrick Raguin
* Copyright (C) 2005-2009 Regis Houssin
*
@@ -134,6 +134,7 @@ print nl2br($c->description);
print '';
// Visibility
+/*
if ($type == 0 && $conf->global->CATEGORY_ASSIGNED_TO_A_CUSTOMER)
{
if ($c->socid)
@@ -175,6 +176,7 @@ else
print ($c->visible ? $langs->trans("Visible") : $langs->trans("Invisible"));
print '';
}
+*/
print '';
@@ -226,6 +228,7 @@ else
print "\n";
print "\t\t".$cat->description." | \n";
+ /*
if ($cat->visible == 1)
{
print "\t\t".$langs->trans("ContentsVisibleByAllShort")." | \n";
@@ -234,6 +237,7 @@ else
{
print "\t\t".$langs->trans("ContentsNotVisibleByAllShort")." | \n";
}
+ */
print "\t\n";
}
diff --git a/htdocs/soc.php b/htdocs/soc.php
index c57c27c7f63..f6bab792f92 100644
--- a/htdocs/soc.php
+++ b/htdocs/soc.php
@@ -520,6 +520,7 @@ $_GET["action"] == 'create' || $_POST["action"] == 'create')
print '';
+ // Category
if ($soc->fournisseur)
{
$load = $soc->LoadSupplierCateg();
@@ -529,12 +530,13 @@ $_GET["action"] == 'create' || $_POST["action"] == 'create')
{
print '';
print '| '.$langs->trans('SupplierCategory').' | ';
- $form->select_array("fournisseur_categorie",$soc->SupplierCategories);
+ $form->select_array("fournisseur_categorie",$soc->SupplierCategories,$_POST["fournisseur_categorie"],1);
print ' |
';
}
}
}
+ // Barcode
if ($conf->global->MAIN_MODULE_BARCODE)
{
print '| '.$langs->trans('Gencod').' | ';
@@ -904,6 +906,7 @@ elseif ($_GET["action"] == 'edit' || $_POST["action"] == 'edit')
print ' |
';
+ // Category
if ($soc->fournisseur)
{
$load = $soc->LoadSupplierCateg();
@@ -913,7 +916,7 @@ elseif ($_GET["action"] == 'edit' || $_POST["action"] == 'edit')
{
print '';
print '| '.$langs->trans('SupplierCategory').' | ';
- $form->select_array("fournisseur_categorie",$soc->SupplierCategories);
+ $form->select_array("fournisseur_categorie",$soc->SupplierCategories,'',1);
print ' |
';
}
}
@@ -1061,13 +1064,15 @@ elseif ($_GET["action"] == 'edit' || $_POST["action"] == 'edit')
print '';
}
- print '| ';
- print '';
- print ' ';
- print '';
- print ' |
';
-
print '';
+ print '
';
+
+ print '';
+ print '';
+ print ' ';
+ print '';
+ print '';
+
print '';
}
}