| Summary: | Data loss when editing vendor.addressX | ||
|---|---|---|---|
| Product: | Koha | Reporter: | Jonathan Druart <jonathan.druart> |
| Component: | Acquisitions | Assignee: | Bugs List <koha-bugs> |
| Status: | NEW --- | QA Contact: | Testopia <testopia> |
| Severity: | major | ||
| Priority: | P5 - low | ||
| Version: | 24.11 | ||
| Hardware: | All | ||
| OS: | All | ||
| GIT URL: | Initiative type: | --- | |
| Sponsorship status: | --- | Comma delimited list of Sponsors: | |
| Crowdfunding goal: | 0 | Patch complexity: | --- |
| Documentation contact: | Documentation submission: | ||
| Text to go in the release notes: | Version(s) released in: | ||
| Circulation function: | |||
| Bug Depends on: | 38010 | ||
| Bug Blocks: | |||
It's related to this code from vue/components/Vendors/VendorFormAdd.vue + let physical = ""; + vendor.address1 && (physical += vendor.address1 + "\n"); + vendor.address2 && (physical += vendor.address2 + "\n"); + vendor.address3 && (physical += vendor.address3 + "\n"); + vendor.address4 && (physical += vendor.address4 + "\n"); + this.vendor.physical = physical; + if (vendor.physical) { + const addressLines = vendor.physical.split("\n"); + if (addressLines.length > 4) { + addressLines.length = 4; + } + addressLines.forEach((line, i) => { + vendor[`address${i + 1}`] = line; + }); + } The existing bug has been ported when writing bug 38010 but it should be fixed. If you enter physical address on more than 4 lines, save => Only the first 4 lines are kept.