Removed the "#selector" attribute from the JavaScript JournalEntryAccountOption class. It is only used in the constructor. There is no need to hold a reference to it.
This commit is contained in:
parent
562bc47be7
commit
202d51a032
@ -190,12 +190,6 @@ class JournalEntryAccountSelector {
|
|||||||
*/
|
*/
|
||||||
class JournalEntryAccountOption {
|
class JournalEntryAccountOption {
|
||||||
|
|
||||||
/**
|
|
||||||
* The account selector
|
|
||||||
* @type {JournalEntryAccountSelector}
|
|
||||||
*/
|
|
||||||
#selector;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The element
|
* The element
|
||||||
* @type {HTMLLIElement}
|
* @type {HTMLLIElement}
|
||||||
@ -239,7 +233,6 @@ class JournalEntryAccountOption {
|
|||||||
* @param element {HTMLLIElement} the element
|
* @param element {HTMLLIElement} the element
|
||||||
*/
|
*/
|
||||||
constructor(selector, element) {
|
constructor(selector, element) {
|
||||||
this.#selector = selector;
|
|
||||||
this.#element = element;
|
this.#element = element;
|
||||||
this.code = element.dataset.code;
|
this.code = element.dataset.code;
|
||||||
this.text = element.dataset.text;
|
this.text = element.dataset.text;
|
||||||
@ -247,7 +240,7 @@ class JournalEntryAccountOption {
|
|||||||
this.isNeedOffset = element.classList.contains("accounting-account-is-need-offset");
|
this.isNeedOffset = element.classList.contains("accounting-account-is-need-offset");
|
||||||
this.#queryValues = JSON.parse(element.dataset.queryValues);
|
this.#queryValues = JSON.parse(element.dataset.queryValues);
|
||||||
|
|
||||||
this.#element.onclick = () => this.#selector.lineItemEditor.saveAccount(this);
|
this.#element.onclick = () => selector.lineItemEditor.saveAccount(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user