Change product quantity compoent precision to 8

This commit is contained in:
2025-05-09 17:10:32 +00:00
parent e86a199c5e
commit f1a0b7be5e
7 changed files with 24 additions and 22 deletions

View File

@@ -70,10 +70,10 @@ var items = this.items;
if(total_quantity=='NaN'){
total_quantity=0;
}
$(row).val(QuantityFormat(total_quantity,6));
$(row).val(QuantityFormat(total_quantity,8));
console.log(items);
items[index ]['quantity'] = total_quantity.toFixed(6);
items[index ]['quantity'] = total_quantity.toFixed(8);
}
});
@@ -95,8 +95,8 @@ var items = this.items;
if(total_quantity=='NaN'){
total_quantity=0;
}
$(row).val(QuantityFormat(total_quantity,6));
items[index ]['quantity'] = total_quantity.toFixed(6);
$(row).val(QuantityFormat(total_quantity,8));
items[index ]['quantity'] = total_quantity.toFixed(8);
}
});

View File

@@ -1,5 +1,5 @@
<?php
// created: 2025-04-10 09:38:48
// created: 2025-04-29 21:26:15
$customDoms = array (
'ecmproducts_attribute_dom' =>
array (
@@ -76,6 +76,7 @@ $customDoms = array (
'e6900d92-6fde-90e6-b872-67d1938745e6' => 'Słoik 400 ml',
'e3e0c9da-6d08-e1e0-b9ba-67eaa437cb84' => 'Bottle B1_30ml',
'8bcf43bf-7b49-5dbf-6b86-67f6c12b82d7' => 'Softpack',
'd40c7d30-77bd-1f65-be9c-681142c7daf5' => 'LCD Liquid',
),
'ecmproducts_brand_dom' =>
array (
@@ -216,10 +217,10 @@ $customDoms = array (
),
'ecmactions_category_dom' =>
array (
'dd4ddbad-c949-0ee5-fb73-54cb9b6c86ef' => 'Line no 1',
'f87b0591-14fd-b35f-1da5-54d1d584fd25' => 'Line no 2',
'dd4ddbad-c949-0ee5-fb73-54cb9b6c86ef' => 'Filling Capping Labeling',
'f87b0591-14fd-b35f-1da5-54d1d584fd25' => 'Filling Capping',
'8519dfc8-5eec-0233-7f84-54d1fe00e9fc' => 'Sets',
'55020d96-73d5-7b29-3bab-654f4818e0cd' => 'Tablets',
'55020d96-73d5-7b29-3bab-654f4818e0cd' => 'Liquid Mixing',
),
'payment_method_dom' =>
array (

View File

@@ -1,5 +1,5 @@
<?php
// created: 2025-04-10 09:38:48
// created: 2025-04-29 21:26:15
$customDoms = array (
'ecmproducts_attribute_dom' =>
array (
@@ -76,6 +76,7 @@ $customDoms = array (
'e6900d92-6fde-90e6-b872-67d1938745e6' => 'Słoik 400 ml',
'e3e0c9da-6d08-e1e0-b9ba-67eaa437cb84' => 'Butelka B1_30ml',
'8bcf43bf-7b49-5dbf-6b86-67f6c12b82d7' => 'Softpack',
'd40c7d30-77bd-1f65-be9c-681142c7daf5' => 'Płyn LCD',
),
'ecmproducts_brand_dom' =>
array (
@@ -216,10 +217,10 @@ $customDoms = array (
),
'ecmactions_category_dom' =>
array (
'dd4ddbad-c949-0ee5-fb73-54cb9b6c86ef' => 'Linia nr 1',
'f87b0591-14fd-b35f-1da5-54d1d584fd25' => 'Linia nr 2',
'dd4ddbad-c949-0ee5-fb73-54cb9b6c86ef' => 'Nal. zakr. etyk.',
'f87b0591-14fd-b35f-1da5-54d1d584fd25' => 'Nal. zakr.',
'8519dfc8-5eec-0233-7f84-54d1fe00e9fc' => 'Składanie zestawów',
'55020d96-73d5-7b29-3bab-654f4818e0cd' => 'Tabletki',
'55020d96-73d5-7b29-3bab-654f4818e0cd' => 'Mieszanie płynów',
),
'payment_method_dom' =>
array (

View File

@@ -275,7 +275,7 @@ ccolumns[4] = {
ccolumns[4]['content'][0] = {
'name' : '',
'dataType' : 'number',
'precision' : 6,
'precision' : 8,
'quantity':true,
'attr' : {
'type' : 'text'
@@ -283,7 +283,7 @@ ccolumns[4]['content'][0] = {
'css' : {
'text-align' : 'right'
},
'onChange': '$(this).val(QuantityFormat($(this).val(),6));CTABLE.setRowDate(this,$(this).parent(\'td\').parent(\'tr\').index());'
'onChange': '$(this).val(QuantityFormat($(this).val(),8));CTABLE.setRowDate(this,$(this).parent(\'td\').parent(\'tr\').index());'
};
ccolumns[5] = {
'name' : 'divider',
@@ -294,7 +294,7 @@ ccolumns[5] = {
ccolumns[5]['content'][0] = {
'name' : '',
'dataType' : 'number',
'precision' : 6,
'precision' : 0,
'quantity':true,
'attr' : {
'type' : 'text'
@@ -302,7 +302,7 @@ ccolumns[5]['content'][0] = {
'css' : {
'text-align' : 'right'
},
'onChange': '$(this).val(QuantityFormat($(this).val(),6));CTABLE.setRowDate(this,$(this).parent(\'td\').parent(\'tr\').index());'
'onChange': '$(this).val(QuantityFormat($(this).val(),0));CTABLE.setRowDate(this,$(this).parent(\'td\').parent(\'tr\').index());'
};
ccolumns[6] = {
'name' : 'quantity',
@@ -314,7 +314,7 @@ ccolumns[6]['content'][0] = {
'name' : '',
'dataType' : 'number',
'quantity':true,
'precision' : 6,
'precision' : 8,
'attr' : {
'type' : 'text'
},
@@ -362,7 +362,7 @@ ccolumns[8] = {
ccolumns[8]['content'][0] = {
'name' : '',
'dataType' : 'number',
'precision' : 6,
'precision' : 8,
'readonly' : true,
'attr' : {
'type' : 'text',

View File

@@ -38,7 +38,7 @@ columns[3] = {
'content' : new Array(),
'align' : 'right',
};
columns[3]['content'][0] = {'name' : '', 'type': 'text', 'isNumber' : true, 'onChange' : 'checkProducts();', 'precision' : '4'};
columns[3]['content'][0] = {'name' : '', 'type': 'text', 'isNumber' : true, 'onChange' : 'checkProducts();', 'precision' : '8'};
//end: quantity
//begin: unit
columns[4] = {

View File

@@ -109,7 +109,7 @@ $dictionary['EcmStockOperation']=array(
'name' => 'quantity',
'vname' => 'LBL_QUANTITY',
'type' => 'decimal',
'len' => '15,4',
'len' => '15,8',
'required' => true,
'massupdate'=>false,
),

View File

@@ -97,8 +97,8 @@ $dictionary['EcmStockState']=array(
'name' => 'quantity',
'vname' => 'LBL_QUANTITY',
'type' => 'decimal',
'precision'=>4,
'len' => '15,4',
'precision'=>8,
'len' => '15,8',
'required' => true,
'massupdate'=>false,
),