diff --git a/src/cljs/auto_ap/views/components/expense_accounts_field.cljs b/src/cljs/auto_ap/views/components/expense_accounts_field.cljs index 6be030d7..24ceefe6 100644 --- a/src/cljs/auto_ap/views/components/expense_accounts_field.cljs +++ b/src/cljs/auto_ap/views/components/expense_accounts_field.cljs @@ -94,7 +94,7 @@ [:i "New " descriptor])]] [:div.column.is-narrow (when-not disabled - [:a.button {:on-click (dispatch-event [::remove-expense-account event expense-accounts id])} [:span.icon [:i.fa.fa-times]]])]] + [:a.delete {:on-click (dispatch-event [::remove-expense-account event expense-accounts id])}])]] [:div.field [:div.columns [:div.column diff --git a/src/cljs/auto_ap/views/pages/transactions/form.cljs b/src/cljs/auto_ap/views/pages/transactions/form.cljs index 1acddb10..c4ecdd86 100644 --- a/src/cljs/auto_ap/views/pages/transactions/form.cljs +++ b/src/cljs/auto_ap/views/pages/transactions/form.cljs @@ -150,14 +150,15 @@ :subscription data}]]]] - (if (seq (:potential-payment-matches data)) + (if (and (seq (:potential-payment-matches data)) + (not (:payment data))) [:div.box [:div.columns [:div.column [:h1.subtitle.is-5 "Potentially matching payments:"]] [:div.column.is-narrow - [:a.button {:on-click (dispatch-event [::manual-match])} [:i.fa.fa-times]]]] + [:a.delete {:on-click (dispatch-event [::manual-match])} ]]] [:table.table.compact.is-borderless (list @@ -194,33 +195,26 @@ :disabled (boolean (:payment data)) :locations locations :event change-event - :subscription data}]]]]) + :subscription data}]]] - [:div.field - [:div.control - [:label.checkbox - [bind-field - [:input.checkbox {:type "checkbox" - :field [:exclude-from-ledger] - :subscription data - :event change-event} - ]] - " Exclude from ledger?" - ]]] + [:div.field + [:p.help] + [:div.control + [:label.checkbox + [bind-field + [:input.checkbox {:type "checkbox" + :field [:exclude-from-ledger] + :subscription data + :event change-event} + ]] + " Exclude from ledger?" + ]]] - (comment - [:div.field - [:p.control - [:label.checkbox - [:input.checkbox {:type "checkbox" - :field [:always-map] - :subscription data}] - " Always match Merchant '" (:merchant-name data) "' to '" (:vendor-name data) "'" ]]]) - (when error - ^{:key error} [:div.notification.is-warning.animated.fadeInUp - error]) - [:button.button.is-medium.is-primary.is-fullwidth {:disabled (if @(re-frame/subscribe [::can-submit]) - "" - "disabled") - :class (str @(re-frame/subscribe [::forms/loading-class ::edit-transaction]) - (when error " animated shake"))} "Save"]])]) + (when error + ^{:key error} [:div.notification.is-warning.animated.fadeInUp + error]) + [:button.button.is-medium.is-primary.is-fullwidth {:disabled (if @(re-frame/subscribe [::can-submit]) + "" + "disabled") + :class (str @(re-frame/subscribe [::forms/loading-class ::edit-transaction]) + (when error " animated shake"))} "Save"]])])])