shopware
shopware copied to clipboard
Feature/allow numbers in contenttype names
1. Why is this change necessary?
After SW-26513 numbers are no longer allowed in naming of content types
2. What does this change do, exactly?
Changes regex to allow numbers.
3. Describe each step to reproduce the issue or behaviour.
Create a content type with a number in the name. For example "b2b".
4. Please link to the relevant issues (if any).
5. Which documentation changes (if any) need to be made because of this PR?
6. Checklist
- [x] I have written tests and verified that they fail without my change
- [x] I have squashed any insignificant commits
- [x] This change has comments for package types, values, functions, and non-obvious lines of code
- [x] I have read the contribution requirements and fulfill them.
thanks for your contribution 🙂👍
@xf- does this look okay for you? 😉
Edit: Code changed and/fixed.
Regex looks fine, no clue if all the converter into SQL, PHP, and JS do the right job. Tried KISS, I will continue to avoid numbers
Thanks! :wink:
Hi @xf- , that's right, only for the last section. The first section says the name should always contain 1 letter. [A-z] -> single character, followed by zero or more [A-z0-9]
Saw a different version or overlooked the unchanged non highlighted part. I noticed & edited the comment, while you wrote the last one.
Hello,
thank you for creating this pull request. I have opened an issue on our Issue Tracker for you. See the issue link: https://issues.shopware.com/issues/SW-26953
Please use this issue to track the state of your pull request.
thanks for your contribution @bforbird 👍🎉💙
merged with https://github.com/shopware/shopware/commit/2ec8463b880b4a7620c9927adca73c869859fcec Will be part of 5.7.17