Solve Document Field Problems with the blockDocument property (CPF) #135
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What is the purpose of this pull request?
Solve the problems of the document field (CPF). This fix also fixes the problem that this PR is fixing Solve the problem of the document field (CPF) blocking even with the empty document.
What problem is this solving?
This pull request is for fixing bugs, currently, this block document property has two issues that have been resolved in this PR:
How should this be manually tested?
Pass the blockDocument property in the declaration of the my-account application in the store
Link the vtex.my-account application to the tksio-549 branch in the my-account module. It is a dependency.
Link the three store / my-account / profile-form repositories and change the property value in the store. By default, the speaker is insufficient.
If you do not pass the property or pass the false value, the field allows changes.
If it is set to true and the field still has no saved value, the field will also allow editing, if the field is already saved, the field is blocked.
WS to test
https://dcnv208--tokstokio.myvtex.com
Screenshots or example usage
1st bugfix
Before
cpf.blocked.with.1.digit.mp4
After
field only block after submit
bugfix-cpf.blocked.after.submit.mp4
2nd bugfix
Before
After
Types of changes