jquery validator is deprecated, may not be used in future.It seems that
there is an issue with AEM loading dialog-ready function using
extraClientlibs attribute in AEM 6.1,it doesn't load first timeI
resolved by creating a generic function which loads when script is
calledOnly issue with this fix is it calls my function multiple times1.
during page load2. during dialog open3. during dialog-ready