Utilisation de conf->upload
This commit is contained in:
parent
e12244e270
commit
d797d59fc6
@ -43,7 +43,7 @@ $types[1] = $langs->trans("Service");
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if ( $_POST["sendit"] && defined('MAIN_UPLOAD_DOC') && MAIN_UPLOAD_DOC == 1)
|
if ( $_POST["sendit"] && $conf->upload)
|
||||||
{
|
{
|
||||||
if ($_GET["id"])
|
if ($_GET["id"])
|
||||||
{
|
{
|
||||||
@ -126,7 +126,7 @@ if ($_GET["id"])
|
|||||||
* Ajouter une photo
|
* Ajouter une photo
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
if ($_GET["action"] == 'ajout_photo' && $user->rights->produit->creer && $product->isproduct)
|
if ($_GET["action"] == 'ajout_photo' && $user->rights->produit->creer && $product->isproduct && $conf->upload)
|
||||||
{
|
{
|
||||||
print_titre($langs->trans("AddPhoto"));
|
print_titre($langs->trans("AddPhoto"));
|
||||||
|
|
||||||
@ -158,7 +158,7 @@ if ($_GET["id"])
|
|||||||
|
|
||||||
if ($_GET["action"] == '')
|
if ($_GET["action"] == '')
|
||||||
{
|
{
|
||||||
if ( $user->rights->produit->creer && $product->isproduct)
|
if ( $user->rights->produit->creer && $product->isproduct && $conf->upload)
|
||||||
{
|
{
|
||||||
print '<a class="tabAction" href="photos.php?action=ajout_photo&id='.$product->id.'">';
|
print '<a class="tabAction" href="photos.php?action=ajout_photo&id='.$product->id.'">';
|
||||||
print $langs->trans("AddPhoto").'</a>';
|
print $langs->trans("AddPhoto").'</a>';
|
||||||
|
|||||||
@ -43,7 +43,7 @@ $types[1] = $langs->trans("Service");
|
|||||||
/*
|
/*
|
||||||
* Upload photo
|
* Upload photo
|
||||||
*/
|
*/
|
||||||
if ( $_POST["sendit"] && defined('MAIN_UPLOAD_DOC') && MAIN_UPLOAD_DOC == 1)
|
if ( $_POST["sendit"] && $conf->upload)
|
||||||
{
|
{
|
||||||
if ($_POST["id"])
|
if ($_POST["id"])
|
||||||
{
|
{
|
||||||
@ -550,7 +550,7 @@ else
|
|||||||
* Ajouter une photo
|
* Ajouter une photo
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
if ($_GET["action"] == 'ajout_photo' && $user->rights->produit->creer && $product->isproduct)
|
if ($_GET["action"] == 'ajout_photo' && $conf->upload && $user->rights->produit->creer && $product->isproduct)
|
||||||
{
|
{
|
||||||
print_titre($langs->trans("AddPhoto"));
|
print_titre($langs->trans("AddPhoto"));
|
||||||
|
|
||||||
@ -670,7 +670,7 @@ if ($_GET["action"] == '')
|
|||||||
print $langs->trans("Order").'</a>';
|
print $langs->trans("Order").'</a>';
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( $user->rights->produit->creer && $product->isproduct)
|
if ( $user->rights->produit->creer && $product->isproduct && $conf->upload)
|
||||||
{
|
{
|
||||||
print '<a class="tabAction" href="fiche.php?action=ajout_photo&id='.$product->id.'">';
|
print '<a class="tabAction" href="fiche.php?action=ajout_photo&id='.$product->id.'">';
|
||||||
print $langs->trans("AddPhoto").'</a>';
|
print $langs->trans("AddPhoto").'</a>';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user