Fixed UI bug with transactions unable to autochoose accounts, added new locations
This commit is contained in:
@@ -80,7 +80,7 @@
|
||||
value
|
||||
(expense-accounts-field/can-replace-with-default? (:accounts data)))
|
||||
[[:accounts] (expense-accounts-field/default-account (:accounts data)
|
||||
@(re-frame/subscribe [::subs/vendor-default-account value (:client data)])
|
||||
@(re-frame/subscribe [::subs/vendor-default-account (:id value) (:client data)])
|
||||
(:amount data)
|
||||
locations)]
|
||||
[])))))
|
||||
@@ -414,15 +414,20 @@
|
||||
:field [:vendor]
|
||||
:disabled (or (boolean (:payment data))
|
||||
should-disable-for-client?)}])
|
||||
(field nil
|
||||
[expense-accounts-field
|
||||
{:type "expense-accounts"
|
||||
:field [:accounts]
|
||||
:max (Math/abs (js/parseFloat (:amount data)))
|
||||
:descriptor "credit account"
|
||||
:disabled (or (boolean (:payment data))
|
||||
should-disable-for-client?)
|
||||
:locations locations}])
|
||||
(with-meta
|
||||
(field nil
|
||||
[expense-accounts-field
|
||||
{:type "expense-accounts"
|
||||
:field [:accounts]
|
||||
:max (Math/abs (js/parseFloat (:amount data)))
|
||||
:descriptor "credit account"
|
||||
:disabled (or (boolean (:payment data))
|
||||
should-disable-for-client?)
|
||||
:locations locations}])
|
||||
{:key (str (:id (:vendor data)))})
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user