Skip to content
GitLab
Explorer
Connexion
Navigation principale
Rechercher ou aller à…
Projet
V
vracoop_pos_container_qrcode
Gestion
Activité
Membres
Labels
Programmation
Tickets
Tableaux des tickets
Jalons
Code
Requêtes de fusion
Dépôt
Branches
Validations
Étiquettes
Graphe du dépôt
Comparer les révisions
Analyse
Données d'analyse des chaînes de valeur
Analyse des contributeurs
Données d'analyse du dépôt
Aide
Aide
Support
Documentation de GitLab
Comparer les forfaits GitLab
Forum de la communauté GitLab
Contribuer à GitLab
Donner votre avis
Raccourcis clavier
?
Extraits de code
Groupes
Projets
Afficher davantage de fils d'Ariane
Le Filament
Vracoop
vracoop_pos_container_qrcode
Validations
b021279a
Valider
b021279a
rédigé
30 mars 2022
par
Juliana
Parcourir les fichiers
Options
Téléchargements
Correctifs
Plain Diff
[ADD]Add nomenclature to the table container
parent
fd88f4dd
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
Modifications
2
Afficher les modifications d'espaces
En ligne
Côte à côte
Affichage de
2 fichiers modifiés
__manifest__.py
+1
-1
1 ajout, 1 suppression
__manifest__.py
static/src/js/container.js
+10
-9
10 ajouts, 9 suppressions
static/src/js/container.js
avec
11 ajouts
et
10 suppressions
__manifest__.py
+
1
−
1
Voir le fichier @
b021279a
{
"
name
"
:
"
VRACOOP - POS Balance Container QRCode
"
,
"
summary
"
:
"
VRACOOP - POS Balance Container QRCode
"
,
"
version
"
:
"
12.0.1.
7
.0
"
,
"
version
"
:
"
12.0.1.
8
.0
"
,
"
development_status
"
:
"
Beta
"
,
"
author
"
:
"
Le Filament
"
,
"
maintainers
"
:
[
"
remi-filament
"
],
...
...
Ce diff est replié.
Cliquez pour l'agrandir.
static/src/js/container.js
+
10
−
9
Voir le fichier @
b021279a
...
...
@@ -29,7 +29,7 @@ odoo.define('vracoop_pos_container_qrcode.container_print_qr', function (require
init
:
function
(
parent
,
options
){
this
.
_super
(
parent
,
options
);
this
.
barcode_base64
;
this
.
barcode_base64
=
false
;
},
show
:
function
(){
...
...
@@ -54,7 +54,6 @@ odoo.define('vracoop_pos_container_qrcode.container_print_qr', function (require
else
{
count_it
=
0
;
if
(
self
.
weight
>
0
){
self
.
create_container
();
self
.
print
();
self
.
gui
.
show_screen
(
'
confirmation
'
);
}
...
...
@@ -91,7 +90,7 @@ odoo.define('vracoop_pos_container_qrcode.container_print_qr', function (require
/////////////////////////////
handle_auto_print
:
function
()
{
this
.
create_container
();
//
this.create_container();
this
.
print
();
this
.
click_next
();
},
...
...
@@ -112,7 +111,6 @@ odoo.define('vracoop_pos_container_qrcode.container_print_qr', function (require
var
categ_container
=
this
.
pos
.
config
.
categ_container
;
var
timestamp
=
Math
.
floor
((
new
Date
().
getTime
())
/
1000
);
// var weight_str = (this.weight * 1000).toString();
var
weight_str
=
parseInt
(
this
.
weight
*
1000
,
10
);
weight_str
=
(
"
0000
"
+
weight_str
).
slice
(
-
4
);
...
...
@@ -130,12 +128,14 @@ odoo.define('vracoop_pos_container_qrcode.container_print_qr', function (require
var
second_int
=
parseInt
(
ean20
.
substring
(
10
,
21
));
var
cle_int
=
parseInt
(
ean20
.
substr
(
-
1
));
// Conversion bae 36
// Conversion ba
s
e 36
var
base36_first
=
first_int
.
toString
(
36
);
var
base36_second
=
second_int
.
toString
(
36
);
var
base36_cle
=
cle_int
.
toString
(
36
);
var
url_qrcode
=
url_qr
.
concat
(
base36_cle
,
'
-
'
,
base36_first
,
'
-
'
,
base36_second
);
this
.
barcode_base64
=
base36_cle
.
concat
(
'
-
'
,
base36_first
,
'
-
'
,
base36_second
);
var
url_qrcode
=
url_qr
.
concat
(
this
.
barcode_base64
);
var
weight_gr
=
parseInt
(
weight_str
,
10
)
+
'
g
'
return
{
widget
:
this
,
...
...
@@ -151,7 +151,7 @@ odoo.define('vracoop_pos_container_qrcode.container_print_qr', function (require
this
.
_super
();
this
.
$
(
'
.next,.print-qrcode
'
).
click
(
function
(){
self
.
create_container
();
//
self.create_container();
self
.
print
();
});
},
...
...
@@ -177,9 +177,9 @@ odoo.define('vracoop_pos_container_qrcode.container_print_qr', function (require
print_xml
:
function
()
{
var
receipt
=
QWeb
.
render
(
'
XmlQR
'
,
this
.
get_receipt_render_env
());
this
.
create_container
();
this
.
pos
.
proxy
.
print_receipt
(
receipt
);
},
print
:
function
()
{
var
self
=
this
;
...
...
@@ -206,6 +206,7 @@ odoo.define('vracoop_pos_container_qrcode.container_print_qr', function (require
},
render_receipt
:
function
()
{
this
.
$
(
'
.pos-qr-container
'
).
html
(
QWeb
.
render
(
'
PosQR
'
,
this
.
get_receipt_render_env
()));
this
.
create_container
();
},
create_container
:
function
(){
var
self
=
this
;
...
...
@@ -213,7 +214,7 @@ odoo.define('vracoop_pos_container_qrcode.container_print_qr', function (require
fields
[
'
weight
'
]
=
this
.
weight
;
fields
.
barcode
=
false
;
fields
.
barcode
=
this
.
barcode_base64
;
fields
.
name
=
_t
(
'
Container
'
);
this
.
pos
.
push_container
(
fields
);
...
...
Ce diff est replié.
Cliquez pour l'agrandir.
Aperçu
0%
Chargement en cours
Veuillez réessayer
ou
joindre un nouveau fichier
.
Annuler
You are about to add
0
people
to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Enregistrer le commentaire
Annuler
Veuillez vous
inscrire
ou vous
se connecter
pour commenter