Skip to content

Commit

Permalink
Merge pull request #113 from Frosin/master
Browse files Browse the repository at this point in the history
Исправлен баг с некорректной передачей дробного количества
  • Loading branch information
gwinn authored Sep 18, 2019
2 parents 55a5266 + 6763a23 commit af86ba2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/include/order/class-wc-retailcrm-order-item.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class WC_Retailcrm_Order_Item extends WC_Retailcrm_Abstracts_Data
'offer' => array(),
'productName' => '',
'initialPrice' => 0.00,
'quantity' => 0
'quantity' => 0.00
);

/**
Expand Down Expand Up @@ -53,7 +53,7 @@ public function build($item)

$data['productName'] = $item['name'];
$data['initialPrice'] = (float)$price;
$data['quantity'] = $item['qty'];
$data['quantity'] = (double)$item['qty'];

$this->set_data_fields($data);
$this->set_offer($item);
Expand Down Expand Up @@ -126,7 +126,7 @@ public function reset_data()
'offer' => array(),
'productName' => '',
'initialPrice' => 0.00,
'quantity' => 0
'quantity' => 0.00
);
}
}

0 comments on commit af86ba2

Please sign in to comment.