Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dolibarr
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Software_Artifact_Infrastructure_Repository
dolibarr
Commits
44ee8631
Commit
44ee8631
authored
15 years ago
by
Regis Houssin
Browse files
Options
Downloads
Patches
Plain Diff
Fix: add picto
parent
6cad2ac1
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
htdocs/product/barcode.php
+7
-17
7 additions, 17 deletions
htdocs/product/barcode.php
htdocs/product/photos.php
+2
-2
2 additions, 2 deletions
htdocs/product/photos.php
with
9 additions
and
19 deletions
htdocs/product/barcode.php
+
7
−
17
View file @
44ee8631
<?php
<?php
/* Copyright (C) 2001-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
/* Copyright (C) 2001-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-200
9
Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2005-20
1
0 Regis Houssin <regis@dolibarr.fr>
*
*
* This program is free software; you can redistribute it and/or modify
* 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
* it under the terms of the GNU General Public License as published by
...
@@ -62,18 +62,16 @@ if ($_POST['action'] == 'setbarcode' && $user->rights->barcode->creer)
...
@@ -62,18 +62,16 @@ if ($_POST['action'] == 'setbarcode' && $user->rights->barcode->creer)
{
{
$product
=
new
Product
(
$db
);
$product
=
new
Product
(
$db
);
$product
->
fetch
(
$_GET
[
"id"
]);
$product
->
fetch
(
$_GET
[
"id"
]);
$product
->
barcode
=
$_POST
[
'barcode'
];
//Todo: ajout v
�
rification de la validit
�
du code barre en fonction du type
$product
->
barcode
=
$_POST
[
'barcode'
];
//Todo: ajout v
e
rification de la validit
e
du code barre en fonction du type
$result
=
$product
->
update_barcode
(
$user
);
$result
=
$product
->
update_barcode
(
$user
);
Header
(
"Location: barcode.php?id="
.
$_GET
[
"id"
]);
Header
(
"Location: barcode.php?id="
.
$_GET
[
"id"
]);
exit
;
exit
;
}
}
/* *****************************************/
/*
/* */
* Mode vue et edition
/* Mode vue et edition */
*/
/* */
/* *************************************** */
llxHeader
(
""
,
""
,
$langs
->
trans
(
"BarCode"
));
llxHeader
(
""
,
""
,
$langs
->
trans
(
"BarCode"
));
...
@@ -84,10 +82,10 @@ $product = new Product($db);
...
@@ -84,10 +82,10 @@ $product = new Product($db);
if
(
$_GET
[
"ref"
])
$result
=
$product
->
fetch
(
''
,
$_GET
[
"ref"
]);
if
(
$_GET
[
"ref"
])
$result
=
$product
->
fetch
(
''
,
$_GET
[
"ref"
]);
if
(
$_GET
[
"id"
])
$result
=
$product
->
fetch
(
$_GET
[
"id"
]);
if
(
$_GET
[
"id"
])
$result
=
$product
->
fetch
(
$_GET
[
"id"
]);
$head
=
product_prepare_head
(
$product
,
$user
);
$head
=
product_prepare_head
(
$product
,
$user
);
$titre
=
$langs
->
trans
(
"CardProduct"
.
$product
->
type
);
$titre
=
$langs
->
trans
(
"CardProduct"
.
$product
->
type
);
dol_fiche_head
(
$head
,
'barcode'
,
$titre
);
$picto
=
(
$product
->
type
==
1
?
'service'
:
'product'
);
dol_fiche_head
(
$head
,
'barcode'
,
$titre
,
0
,
$picto
);
print
'<table class="border" width="100%">'
.
"
\n
"
;
print
'<table class="border" width="100%">'
.
"
\n
"
;
...
@@ -171,14 +169,6 @@ print '</td></tr>'."\n";
...
@@ -171,14 +169,6 @@ print '</td></tr>'."\n";
print
"</table>
\n
"
;
print
"</table>
\n
"
;
print
"</div>
\n
"
;
print
"</div>
\n
"
;
/*
* Affiche code barre
*/
$db
->
close
();
$db
->
close
();
llxFooter
(
'$Date$ - $Revision$'
);
llxFooter
(
'$Date$ - $Revision$'
);
...
...
This diff is collapsed.
Click to expand it.
htdocs/product/photos.php
+
2
−
2
View file @
44ee8631
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
/* Copyright (C) 2001-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
/* Copyright (C) 2001-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005 Eric Seigne <eric.seigne@ryxeo.com>
* Copyright (C) 2005 Eric Seigne <eric.seigne@ryxeo.com>
* Copyright (C) 2005-200
9
Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2005-20
1
0 Regis Houssin <regis@dolibarr.fr>
*
*
* This program is free software; you can redistribute it and/or modify
* 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
* it under the terms of the GNU General Public License as published by
...
@@ -82,8 +82,8 @@ $html = new Form($db);
...
@@ -82,8 +82,8 @@ $html = new Form($db);
if
(
$_GET
[
"id"
]
||
$_GET
[
"ref"
])
if
(
$_GET
[
"id"
]
||
$_GET
[
"ref"
])
{
{
$product
=
new
Product
(
$db
);
$product
=
new
Product
(
$db
);
if
(
$_GET
[
"ref"
])
$result
=
$product
->
fetch
(
''
,
$_GET
[
"ref"
]);
if
(
$_GET
[
"ref"
])
$result
=
$product
->
fetch
(
''
,
$_GET
[
"ref"
]);
if
(
$_GET
[
"id"
])
$result
=
$product
->
fetch
(
$_GET
[
"id"
]);
if
(
$_GET
[
"id"
])
$result
=
$product
->
fetch
(
$_GET
[
"id"
]);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment