diff --git a/htdocs/categories/photos.php b/htdocs/categories/photos.php index bbffe5865d364ada3e1dfb2145485c4091709c94..b64854e5b22f3a2e3ef2e4120b9c0fb17c5ad23d 100644 --- a/htdocs/categories/photos.php +++ b/htdocs/categories/photos.php @@ -3,6 +3,7 @@ * Copyright (C) 2004-2010 Laurent Destailleur <eldy@users.sourceforge.net> * Copyright (C) 2005 Eric Seigne <eric.seigne@ryxeo.com> * Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com> + * Copyright (C) 2014 Jean-François Ferry <jfefe@aternatik.fr> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -264,11 +265,11 @@ if ($object->id) // On propose la generation de la vignette si elle n'existe pas et si la taille est superieure aux limites if (!$obj['photo_vignette'] && preg_match('/(\.bmp|\.gif|\.jpg|\.jpeg|\.png)$/i',$obj['photo']) && ($object->imgWidth > $maxWidth || $object->imgHeight > $maxHeight)) { - print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->entity.'&action=addthumb&type='.$type.'&file='.urlencode($pdir.$viewfilename).'">'.img_picto($langs->trans('GenerateThumb'),'refresh').' </a>'; + print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=addthumb&type='.$type.'&file='.urlencode($pdir.$viewfilename).'">'.img_picto($langs->trans('GenerateThumb'),'refresh').' </a>'; } if ($user->rights->categorie->creer) { - print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->entity.'&action=delete&type='.$type.'&file='.urlencode($pdir.$viewfilename).'">'; + print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=delete&type='.$type.'&file='.urlencode($pdir.$viewfilename).'">'; print img_delete().'</a>'; } if ($nbbyrow) print '</td>'; diff --git a/htdocs/langs/en_US/categories.lang b/htdocs/langs/en_US/categories.lang index b6b08562438eb1a8663633e45807acaecb62800f..1740288683d2659e1479f6441007749fefd00603 100644 --- a/htdocs/langs/en_US/categories.lang +++ b/htdocs/langs/en_US/categories.lang @@ -105,3 +105,5 @@ CatProdLinks=Products CatCusLinks=Customer/Prospects CatSupLinks=Suppliers DeleteFromCat=Remove from category +DeletePicture=Picture delete +ConfirmDeletePicture=Confirm picture deletion? \ No newline at end of file