diff --git a/src/accounting/static/js/journal-entry-form.js b/src/accounting/static/js/journal-entry-form.js index de50130..1792c4a 100644 --- a/src/accounting/static/js/journal-entry-form.js +++ b/src/accounting/static/js/journal-entry-form.js @@ -982,7 +982,7 @@ class LineItemSubForm { * @return {JournalEntryAccount|null} the account */ get account() { - return this.#accountCode.value === null? null: new JournalEntryAccount(this.#accountCode.value, this.#accountCode.dataset.text, "isNeedOffset" in this.#element.dataset); + return this.#accountCode.value === null? null: new JournalEntryAccount(this.#accountCode.value, this.#accountCode.dataset.text, this.#accountCode.classList.contains("accounting-is-need-offset")); } /** diff --git a/src/accounting/templates/accounting/journal-entry/include/form-line-item.html b/src/accounting/templates/accounting/journal-entry/include/form-line-item.html index f4e5be8..22372f6 100644 --- a/src/accounting/templates/accounting/journal-entry/include/form-line-item.html +++ b/src/accounting/templates/accounting/journal-entry/include/form-line-item.html @@ -20,13 +20,13 @@ Author: imacat@mail.imacat.idv.tw (imacat) First written: 2023/2/25 #} {#