Hi Forum!
Is it possible to block saving or publishing metadata in case there are
validation errors on either XML Schema (xsd) or Schematron rules on GN
2.8.0?
I would like the metadata not to be saved if, for example, the title of the
metadata is empty.
When the title would be empty then the INSPIRE implementing rules would fire
and say that there is an error: "Resource title is missing."
<img src="http://osgeo-org.1560.n6.nabble.com/file/n5042454/title_empty.png"
border="0" alt="title is empty"/> <http://i.imgur.com/1WP4p8E.png>
/(To be correct, title is actually not "missing" but "empty". If the title
element would be missing then I would get a schema error... but maybe I am
wrong and "resource" means a different thing than "element"...)/
Since the metadata is saved before validating, then I presume that for
automatically removing the metadata after validation I would have to write
Java code which begins by checking the validation table in the database and
so on.
But maybe it is possible to block publishing with without writing java?
The GN with Widgets shows the last validation status for the metadata. Could
I check this information when publishing the metadata somehow... maybe in
javascript?
--
View this message in context: http://osgeo-org.1560.n6.nabble.com/Block-saving-or-publishing-metadata-when-validation-errors-occur-tp5042454.html
Sent from the GeoNetwork developer mailing list archive at Nabble.com.