Vulnerability in EPiServer.Forms
I have a problems with synchronization fields "DisplayName" and "Name in Url".(Episerver-commerce-catalog). I want that field "Name in Url" was formed by using field "DisplayName". How is it do better?
I work with Episerver 7.5 and MVC
When you manually edit the product, you can clear "Name in URL" and it will automatically be calculated from Name when you publish. There is no connection between Display name and Name though.
I resolved this issue so:
1. Add additional fields to form(commerce - catalog - new -category). - Inherite from class NodeContent and add properties with attribute [Required].
2. Subscribe to events CreatedContent of IContentEvents.
3. Checke that e.Conten is MyNodeContent.
4. GetLanguageBranches and CreateWritableClone
5. Change fields "Display Name" and "Name in Url" using values of additional fields and save(myRepository.Save)