Custom Types (Already Exists?)
Posted: Tue 24 Sep 2019 08:58
Hi, I am using Entity Developer Version 6.5.823!
I have made a complex EF Core Model which I have to edit very often, it would be cool If I can create a custom types (string, int and so) with certain validation properties for example:
MyTypeEmail
Value: String
Validate Max Length: 128
Validate Format: Email
MyTypeUrl
Value: String
Validate Max Length: 255
In my model I have many entities which contain Emails (string type) the Idea is to map all this Email Properties with the MyTypeEmail so that If I need to change the Validate Max Length in the future I modify the properties of MyTypeEmail only and not each of the Email properties scattered throughout the model.
And also, next time I create a property that is an Email I map it to the corresponding MyTypeEmail.
Maybe this option already exists, but I have search in the Documentation and the forums and I can“t find any result.
Thanks in Advance!
I have made a complex EF Core Model which I have to edit very often, it would be cool If I can create a custom types (string, int and so) with certain validation properties for example:
MyTypeEmail
Value: String
Validate Max Length: 128
Validate Format: Email
MyTypeUrl
Value: String
Validate Max Length: 255
In my model I have many entities which contain Emails (string type) the Idea is to map all this Email Properties with the MyTypeEmail so that If I need to change the Validate Max Length in the future I modify the properties of MyTypeEmail only and not each of the Email properties scattered throughout the model.
And also, next time I create a property that is an Email I map it to the corresponding MyTypeEmail.
Maybe this option already exists, but I have search in the Documentation and the forums and I can“t find any result.
Thanks in Advance!