Skip to content

Resolve "Business card string length limit"

Benjamin requested to merge 834-business-card-length-limitation into master

Closes #834 (closed)

What does this MR do?

when creating business cards, the street, plz and city were all together checked against the max length of 49 characters. When they were longer than 49 characters, there is a message, that the creation of business cards is not possible.

With the changes in this MR, the street itself and the plz + city are checks separate against 45 characters. If one of both is longer than 45 characters, there is a info-message that one of both gets shortened on the business card. The business card is created anyway.

How confident are you it won't break things if deployed?

some test would not be too bad ;)

Links to related issues

Any relevant links (issues, documentation, slack discussions). https://app.slack.com/client/T0B6WCFM5/C1T1ZM9A4/thread/C1T1ZM9A4-1589996147.002300

How to test

Steps a reviewer can take to verify that this MR does what it says it does e.g.

  1. Checkout branch locally
  2. Login as foodsaver
  3. Enter a long street, plz and city (http://localhost:18080/?page=settings&sub=general)
  4. Create a business card (http://localhost:18080/?page=bcard)
  5. Choose a role you like
  6. Check generated PDF with the business cards

Screenshots (if applicable)

Before the MR:

image image

After the MR:

image image image

Checklist

  • added a test, or explain why one is not needed/possible...
  • no unrelated changes
  • asked someone for a code review
  • set a "for:" label to indicate who will be affected by this change
  • use "state:" labels to track this MR's state until it was beta tested
  • added an entry to CHANGELOG.md
  • add a short text that can be used in the release notes
  • Once your MR has been merged, you are responsible to create a testing issue in Beta Testing Repo:
    • Consider writing a detailed description in German.
    • Describe in a few sentences, what should be tested from a user perspective.
    • Also mention different settings (e.g. different browsers, roles, ...). how this change can be tested.
    • Be aware, that also non technical people should understand.
Edited by Benjamin

Merge request reports