Esri / geoportal-server

Geoportal Server is a standards-based, open source product that enables discovery and use of geospatial resources including data and services.
https://gptogc.esri.com/geoportal
Apache License 2.0
244 stars 149 forks source link

Regexp for validaint input in GXE #215

Open gcampanile opened 8 years ago

gcampanile commented 8 years ago

Which is the best way to implement special validation in the gxe editor ? For some fields we need to use some regexp, and I was going to use the "match" section and an XQuery expression with the matches($input, $regex) method but don't know if this method is supported and I'm not sure this is the best way to do it. Any suggestions ?

gcampanile commented 8 years ago

I think we found the best way: in the XTN_.xml use the "restriction" tag with a pattern. The gxe.js will do the rest in the ValidateinputField method. If possible it would be nice to have a confirmation that this is the best way to do the job. Thanks