2
0
forked from Wavyzz/dolibarr

Merge branch 'develop' of https://github.com/Dolibarr/dolibarr into develop

Conflicts:
	htdocs/admin/system/perf.php
This commit is contained in:
Geoffrey
2013-07-11 15:40:10 +02:00
28 changed files with 177 additions and 97 deletions

View File

@@ -186,7 +186,7 @@ for ($s = 0 ; $s < GEN_NUMBER_COMMANDE ; $s++)
$prodid = rand(1, $num_prods);
$product=new Product($db);
$result=$product->fetch($prodids[$prodid]);
$result=$com->addline($com->id, $product->description, $product->price, rand(1,5), 0, 0, 0, $prodids[$prodid], 0, 0, 0, $product->price_base_type, $product->price_ttc, '', '', $product->type);
$result=$com->addline($product->description, $product->price, rand(1,5), 0, 0, 0, $prodids[$prodid], 0, 0, 0, $product->price_base_type, $product->price_ttc, '', '', $product->type);
if ($result < 0)
{
dol_print_error($db,$propal->error);

View File

@@ -112,8 +112,12 @@ while ($i < GEN_NUMBER_FACTURE && $result >= 0)
$prodid = rand(1, $num_prods);
$product=new Product($db);
$result=$product->fetch($prodids[$prodid]);
$result=$facture->addline($facture->id,$product->description,$product->price, rand(1,5), 0, 0, 0, $prodids[$prodid], 0, '', '', 0, 0, '', $product->price_base_type, $product->price_ttc, $product->type);
$xnbp++;
$result=$facture->addline($product->description, $product->price, rand(1,5), 0, 0, 0, $prodids[$prodid], 0, '', '', 0, 0, '', $product->price_base_type, $product->price_ttc, $product->type);
if ($result < 0)
{
dol_print_error($db,$propal->error);
}
$xnbp++;
}
print " OK with ref ".$facture->ref."\n";;

View File

@@ -143,7 +143,9 @@ while ($i < GEN_NUMBER_PROPAL && $result >= 0)
while ($xnbp < $nbp)
{
$prodid = rand(1, $num_prods);
$result=$propal->addline($propal->id, 'Description '.$xnbp, '100', rand(1,5), '19.6', 0, 0, $prodids[$prodid], 0);
$product=new Product($db);
$result=$product->fetch($prodids[$prodid]);
$result=$propal->addline($product->description, $product->price, rand(1,5), 0, 0, 0, $prodids[$prodid], 0);
if ($result < 0)
{
dol_print_error($db,$propal->error);