You are not logged in.
Pages: 1
There are in mormot some class to make validate in DTOs records?
I need make some simple validates on service before call my repositories passing DTOs. what u think about this?
Other question. Where I found documentation or sample to translate Tsynvalidate messages?
Offline
Please try
https://github.com/synopse/mORMot2/commit/f5d80f61
Now you can use TRttiFilter to filter and/or validate any class or record.
See the regression tests as reference:
https://github.com/synopse/mORMot2/commit/08259ec2
Offline
Where I found documentation or sample to translate Tsynvalidate messages?
Offline
I look on regression tests, on blog in on source.
I need change the default error message of TSynValidate. for sample:
function TSynValidateEmail.Process(aFieldIndex: integer; const value: RawUtf8;
var ErrorMsg: string): boolean;
...
ErrorMsg := Format(sInvalidEmailAddress, [Utf8ToString(value)]); <<<<<<< i need change this message for my language
result := false;
end;
I dont see no parameter to change this.
Offline
How I can do this, I see a some time ago that we can use UpdateResource of windows to change resources, but i dunno if will be multiplatarform.
Mormot have something to make this multiplataform way? where i can find instrutions about it?
Could TSynValidates classes have something method that we could override to change this messages?
Offline
Pages: 1