mirror of
https://github.com/NaN-tic/trytond-patches.git
synced 2023-12-14 06:03:03 +01:00
Remove issue11427
This commit is contained in:
parent
1ea96e207e
commit
323f3ae08e
|
@ -1,29 +0,0 @@
|
|||
diff --git a/stock.py b/stock.py
|
||||
index 6d831ce..e13a83f 100644
|
||||
--- a/trytond/trytond/modules/account_stock_continental/stock.py
|
||||
+++ b/trytond/trytond/modules/account_stock_continental/stock.py
|
||||
@@ -102,11 +102,22 @@ class Move(metaclass=PoolMeta):
|
||||
if self.product.type != 'goods':
|
||||
return
|
||||
|
||||
- date = self.effective_date or Date.today()
|
||||
- period_id = Period.find(self.company.id, date=date)
|
||||
+ today = Date.today()
|
||||
+ for date in [self.effective_date, today]:
|
||||
+ period_id = Period.find(
|
||||
+ self.company.id, date=date, exception=False, test_state=False)
|
||||
+ if not period_id and date < today:
|
||||
+ return
|
||||
+ elif period_id:
|
||||
+ break
|
||||
+ else:
|
||||
+ return
|
||||
period = Period(period_id)
|
||||
if not period.fiscalyear.account_stock_method:
|
||||
return
|
||||
+ if period.state != 'open':
|
||||
+ date = today
|
||||
+ period = Period(Period.find(self.company.id, date=date))
|
||||
|
||||
type_ = self._get_account_stock_move_type()
|
||||
if not type_:
|
1
series
1
series
|
@ -57,4 +57,3 @@ statement_of_account.diff # [account] Cumulate balance of previous fiscal years
|
|||
issue11306.diff # [analytic_invocie] Add compatibility between the analytic_invocie module and the account_invoice_defer module (only 6.0)
|
||||
issue11359.diff # [product_price_list_dates] add date in pattern to match price list
|
||||
|
||||
issue11427.diff # [account_stock_continental] Try to use effective date of stock move for accounting
|
||||
|
|
Loading…
Reference in a new issue