mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-09-20 23:16:15 +08:00
Merge pull request #4045 from artoscinote/ma_SCI_6762
Fix snapshot creation with stock consumption [SCI-6762]
This commit is contained in:
commit
42f79255df
|
@ -16,6 +16,8 @@ class RepositoryStockValue < ApplicationRecord
|
|||
validates :repository_cell, presence: true
|
||||
|
||||
after_create do
|
||||
next if is_a?(RepositoryStockConsumptionValue)
|
||||
|
||||
repository_ledger_records.create!(user: created_by,
|
||||
amount: amount,
|
||||
balance: amount,
|
||||
|
|
Loading…
Reference in a new issue