Summary: | Simplify keep_text Javascript function | ||
---|---|---|---|
Product: | Koha | Reporter: | David Cook <dcook> |
Component: | Staff interface | Assignee: | Bugs List <koha-bugs> |
Status: | CLOSED INVALID | QA Contact: | Testopia <testopia> |
Severity: | enhancement | ||
Priority: | P5 - low | CC: | cornejo.alvaro, gmcharlt |
Version: | unspecified | ||
Hardware: | All | ||
OS: | All | ||
GIT URL: | Change sponsored?: | --- | |
Patch complexity: | --- | Documentation contact: | |
Documentation submission: | Text to go in the release notes: | ||
Version(s) released in: | Circulation function: | ||
Bug Depends on: | 14189, 26249 | ||
Bug Blocks: | |||
Attachments: |
Bug 26248: Simplify keep_text function used in header search
Example pendings on last-borrower Bug 26248: Simplify keep_text function used in header search |
Description
David Cook
2020-08-19 05:13:41 UTC
Created attachment 108567 [details] [review] Bug 26248: Simplify keep_text function used in header search The current code is functional but not very readable. This patch simplifies the code to be more readable and to be more efficient. To test: 1) Apply patch 2) Refresh browser cache 3) Type "A" in "Check out" tab 4) Click "Check in" (and other tabs) 5) Observe that text is persisted from original tab 6) Type "B" in "Search the catalog" tab 7) Click "Renew" tab 8) Observe that text is persisted from latest changed tab Hmm working fine on mainpage.pl but having an issue clicking on "Search the catalog" on search.pl... For some reason that tab is passing an index value of 4 rather than 3... Ahh the keep_text isn't set correctly in "koha-tmpl/intranet-tmpl/prog/en/includes/cat-search.inc" Created attachment 108959 [details] Example pendings on last-borrower As per comment #3 Comment on attachment 108959 [details]
Example pendings on last-borrower
Sorry wrong bug!!!
Created attachment 115262 [details] [review] Bug 26248: Simplify keep_text function used in header search The current code is functional but not very readable. This patch simplifies the code to be more readable and to be more efficient. To test: 1) Apply patch 2) Refresh browser cache 3) Type "A" in "Check out" tab 4) Click "Check in" (and other tabs) 5) Observe that text is persisted from original tab 6) Type "B" in "Search the catalog" tab 7) Click "Renew" tab 8) Observe that text is persisted from latest changed tab Signed-off-by: Mazen Khallaf <mazen.i.khallaf@gamil.com> I believe there is still a small glitch here: When I - enter something in one tab - move to the next - empty the input field - switch tab again - the deleted string reappears (In reply to Katrin Fischer from comment #9) > I believe there is still a small glitch here: > When I > - enter something in one tab > - move to the next > - empty the input field > - switch tab again > - the deleted string reappears Hmm weird. I thought that I'd thoroughly tested this. I probably don't have time to work on this again for a long time, but that's a useful note! I don't recall why I cared about this in the first place... |