[GeoNetwork-devel] Display elements no existing in the metadata xml in a custom view

Hi

I want to display 2 fields for gmd:equivalentScale and gmd:distance in a custom view. The gmd:spatialResolution can be missing in the metadata, so if possible display them anyway or at least display the button to add them

According to config-editor.xsd doc:

  • To display a field if exist in the metadata document or providing a add button in case it does not exist (specify in and or attribute):

  • Activate the “flat” mode at the tab level to make the form display only existing elements

  1. The add buttons are rendered, but both using the label defined for spatialResolution, so it’s confusing. Both buttons require to have the following (see full snippet below), if changed name or or attributes, the buttons are not displayed:

<action type=“add” name=“spatialResolution” or=“spatialResolution”
in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification”

Is possible to setup a custom label for the actions?

  1. Also tried to add in the view flatModeExceptions for the following elements, expecting that then would the fields would be displayed even if not in the xml and even if no Add buttons are configured, but no success:

Not sure if I’m missing something here or what I expect is not correct?

···

Vriendelijke groeten / Kind regards,

Jose García


Veenderweg 13
6721 WD Bennekom
The Netherlands
T: +31 (0)318 416664

Please consider the environment before printing this email.

Hi,

···

2016-07-07 13:16 GMT+02:00 Jose Garcia <jose.garcia@anonymised.com>:

Hi

I want to display 2 fields for gmd:equivalentScale and gmd:distance in a custom view. The gmd:spatialResolution can be missing in the metadata, so if possible display them anyway or at least display the button to add them

According to config-editor.xsd doc:

  • To display a field if exist in the metadata document or providing a add button in case it does not exist (specify in and or attribute):

  • Activate the “flat” mode at the tab level to make the form display only existing elements

  1. The add buttons are rendered, but both using the label defined for spatialResolution, so it’s confusing. Both buttons require to have the following (see full snippet below), if changed name or or attributes, the buttons are not displayed:

<action type=“add” name=“spatialResolution” or=“spatialResolution”
in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification”

Is possible to setup a custom label for the actions?

See https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1083

  1. Also tried to add in the view flatModeExceptions for the following elements, expecting that then would the fields would be displayed even if not in the xml and even if no Add buttons are configured, but no success:

Not sure if I’m missing something here or what I expect is not correct?

An easier way of doing this could be to use @if instead of @or/@in+flat
https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1011

Francois


This is the snippet for the fields configuration:

<field

name=“equivalentScale”

xpath=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:equivalentScale”

or=“equivalentScale”

in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*” />

gmd:spatialResolution

gmd:MD_Resolution

gmd:equivalentScale

gmd:MD_RepresentativeFraction

gmd:denominator

gco:Integer</gco:Integer>

</gmd:denominator>

</gmd:MD_RepresentativeFraction>

</gmd:equivalentScale>

</gmd:MD_Resolution>

</gmd:spatialResolution>

<field

name=“distance”

xpath=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance”

or=“distance”

in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*” />

gmd:spatialResolution

gmd:MD_Resolution

gmd:distance

gco:Distance</gco:Distance>

</gmd:distance>

</gmd:MD_Resolution>

</gmd:spatialResolution>

Regards,
Jose García

Vriendelijke groeten / Kind regards,

Jose García


Veenderweg 13
6721 WD Bennekom
The Netherlands
T: +31 (0)318 416664

Please consider the environment before printing this email.


Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San
Francisco, CA to explore cutting-edge tech and listen to tech luminaries
present their vision of the future. This family event has something for
everyone, including kids. Get more information and register today.
http://sdm.link/attshape


GeoNetwork-devel mailing list
GeoNetwork-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geonetwork-devel
GeoNetwork OpenSource is maintained at http://sourceforge.net/projects/geonetwork

Hi Francois

See feedback inline.

Regards,
Jose García

···

On Thu, Jul 7, 2016 at 1:33 PM, Francois Prunayre <fx.prunayre@anonymised.com> wrote:

Hi,

Ok, I have an old version of develop and the xsd seem not updated with that, but the attribute works. That’s much better.

Just to be sure, you mean that I can use this and that should display the button also?:

But this doesn’t show the input text if the element is missing in the xml without requiring any button. Is there’re any way to do that? From the documentation, seem it says that.

2016-07-07 13:16 GMT+02:00 Jose Garcia <jose.garcia@anonymised.com…437…>:

Hi

I want to display 2 fields for gmd:equivalentScale and gmd:distance in a custom view. The gmd:spatialResolution can be missing in the metadata, so if possible display them anyway or at least display the button to add them

According to config-editor.xsd doc:

  • To display a field if exist in the metadata document or providing a add button in case it does not exist (specify in and or attribute):

  • Activate the “flat” mode at the tab level to make the form display only existing elements

  1. The add buttons are rendered, but both using the label defined for spatialResolution, so it’s confusing. Both buttons require to have the following (see full snippet below), if changed name or or attributes, the buttons are not displayed:

<action type=“add” name=“spatialResolution” or=“spatialResolution”
in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification”

Is possible to setup a custom label for the actions?

See https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1083

  1. Also tried to add in the view flatModeExceptions for the following elements, expecting that then would the fields would be displayed even if not in the xml and even if no Add buttons are configured, but no success:

Not sure if I’m missing something here or what I expect is not correct?

An easier way of doing this could be to use @if instead of @or/@in+flat
https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1011

Francois


This is the snippet for the fields configuration:

<field

name=“equivalentScale”

xpath=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:equivalentScale”

or=“equivalentScale”

in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*” />

gmd:spatialResolution

gmd:MD_Resolution

gmd:equivalentScale

gmd:MD_RepresentativeFraction

gmd:denominator

gco:Integer</gco:Integer>

</gmd:denominator>

</gmd:MD_RepresentativeFraction>

</gmd:equivalentScale>

</gmd:MD_Resolution>

</gmd:spatialResolution>

<field

name=“distance”

xpath=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance”

or=“distance”

in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*” />

gmd:spatialResolution

gmd:MD_Resolution

gmd:distance

gco:Distance</gco:Distance>

</gmd:distance>

</gmd:MD_Resolution>

</gmd:spatialResolution>

Regards,
Jose García

Vriendelijke groeten / Kind regards,

Jose García


Veenderweg 13
6721 WD Bennekom
The Netherlands
T: +31 (0)318 416664

Please consider the environment before printing this email.


Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San
Francisco, CA to explore cutting-edge tech and listen to tech luminaries
present their vision of the future. This family event has something for
everyone, including kids. Get more information and register today.
http://sdm.link/attshape


GeoNetwork-devel mailing list
GeoNetwork-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geonetwork-devel
GeoNetwork OpenSource is maintained at http://sourceforge.net/projects/geonetwork

Vriendelijke groeten / Kind regards,

Jose García


Veenderweg 13
6721 WD Bennekom
The Netherlands
T: +31 (0)318 416664

Please consider the environment before printing this email.

2016-07-07 13:51 GMT+02:00 Jose Garcia <jose.garcia@anonymised.com>:

Hi Francois

See feedback inline.

Regards,
Jose García

On Thu, Jul 7, 2016 at 1:33 PM, Francois Prunayre <fx.prunayre@anonymised.com>
wrote:

Hi,

2016-07-07 13:16 GMT+02:00 Jose Garcia <jose.garcia@anonymised.com>:

Hi

I want to display 2 fields for gmd:equivalentScale and gmd:distance in
a custom view. The gmd:spatialResolution can be missing in the
metadata, so if possible display them anyway or at least display the button
to add them

According to config-editor.xsd doc:

   - To display a field if exist in the metadata document or providing
   a add button in case it does not exist (specify ``in`` and ``or``
   attribute):
   - Activate the "flat" mode at the tab level to make the form display
   only existing elements

1) The add buttons are rendered, but both using the label defined for
spatialResolution, so it's confusing. Both buttons require to have the
following (see full snippet below), if changed *name* or *or*
attributes, the buttons are not displayed:

<action type="add" name="spatialResolution" or="spatialResolution"

in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification"

Is possible to setup a custom label for the actions?

See
https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1083

Ok, I have an old version of develop and the xsd seem not updated with
that, but the attribute works. That's much better.

2) Also tried to add in the view flatModeExceptions for the following
elements, expecting that then would the fields would be displayed even if
not in the xml and even if no Add buttons are configured, but no success:

      <flatModeExceptions>
        <for name="gmd:spatialResolution"/>
        <for name="gmd:equivalentScale"/>
        <for name="gmd:distance"/>
      </flatModeExceptions>

Not sure if I'm missing something here or what I expect is not correct?

An easier way of doing this could be to use @if instead of @or/@in+flat

https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1011

Just to be sure, you mean that I can use this and that should display the
button also?:

    <action type="add" name="spatialResolution"

if="count(/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance)
= 0">

But this doesn't show the input text if the element is missing in the xml
without requiring any button. Is there're any way to do that? From the
documentation, seem it says that.

Not 100% sure, but if not using a template mode field, then it can't
display an input if the field is not in the XML. Would need some testing...

Francois

Francois

----

This is the snippet for the fields configuration:

<field
name="equivalentScale"

xpath="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:equivalentScale"
or="equivalentScale"
in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*"
/>

<action type="add" name="spatialResolution" or="spatialResolution"

in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification"

if="count(/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:equivalentScale)
= 0">
<template>
  <snippet>
    <gmd:spatialResolution>
      <gmd:MD_Resolution>
        <gmd:equivalentScale>
          <gmd:MD_RepresentativeFraction>
            <gmd:denominator>
              <gco:Integer></gco:Integer>
            </gmd:denominator>
          </gmd:MD_RepresentativeFraction>
        </gmd:equivalentScale>
      </gmd:MD_Resolution>
    </gmd:spatialResolution>
  </snippet>
</template>
</action>

<field
name="distance"

xpath="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance"
or="distance"
in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*"
/>

<action type="add" name="spatialDistance" or="spatialDistance"

in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification"

if="count(/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance)
= 0">
<template>
  <snippet>
    <gmd:spatialResolution>
      <gmd:MD_Resolution>
        <gmd:distance>
          <gco:Distance></gco:Distance>
        </gmd:distance>
      </gmd:MD_Resolution>
    </gmd:spatialResolution>
  </snippet>
</template>
</action>

Regards,
Jose García

--

*Vriendelijke groeten / Kind regards,Jose García
<http://www.geocat.net/&gt;Veenderweg 136721 WD BennekomThe NetherlandsT: +31
(0)318 416664 <+31318416664> <https://www.facebook.com/geocatbv&gt;
<https://twitter.com/geocat_bv&gt;
<https://plus.google.com/u/1/+GeocatNetbv/posts&gt;Please consider the
environment before printing this email.*

------------------------------------------------------------------------------
Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San
Francisco, CA to explore cutting-edge tech and listen to tech luminaries
present their vision of the future. This family event has something for
everyone, including kids. Get more information and register today.
http://sdm.link/attshape
_______________________________________________
GeoNetwork-devel mailing list
GeoNetwork-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geonetwork-devel
GeoNetwork OpenSource is maintained at
http://sourceforge.net/projects/geonetwork

--

*Vriendelijke groeten / Kind regards,Jose García
<http://www.geocat.net/&gt;Veenderweg 136721 WD BennekomThe NetherlandsT: +31
(0)318 416664 <+31318416664> <https://www.facebook.com/geocatbv&gt;
<https://twitter.com/geocat_bv&gt;
<https://plus.google.com/u/1/+GeocatNetbv/posts&gt;Please consider the
environment before printing this email.*

Hi

I have just tried this quickly:

···

But the field is not displayed. In any case, with the button label, it’s ok for now, thanks.

Regards,
Jose García

On Thu, Jul 7, 2016 at 1:54 PM, Francois Prunayre <fx.prunayre@anonymised.com> wrote:

2016-07-07 13:51 GMT+02:00 Jose Garcia <jose.garcia@anonymised.com>:

Hi Francois

See feedback inline.

Regards,
Jose García

Not 100% sure, but if not using a template mode field, then it can’t display an input if the field is not in the XML. Would need some testing…

Francois

On Thu, Jul 7, 2016 at 1:33 PM, Francois Prunayre <fx.prunayre@anonymised.com> wrote:

Hi,

Ok, I have an old version of develop and the xsd seem not updated with that, but the attribute works. That’s much better.

Just to be sure, you mean that I can use this and that should display the button also?:

<action type=“add” name=“spatialResolution”

if=“count(/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance) = 0”>

But this doesn’t show the input text if the element is missing in the xml without requiring any button. Is there’re any way to do that? >From the documentation, seem it says that.

2016-07-07 13:16 GMT+02:00 Jose Garcia <jose.garcia@anonymised.com>:

Hi

I want to display 2 fields for gmd:equivalentScale and gmd:distance in a custom view. The gmd:spatialResolution can be missing in the metadata, so if possible display them anyway or at least display the button to add them

According to config-editor.xsd doc:

  • To display a field if exist in the metadata document or providing a add button in case it does not exist (specify in and or attribute):

  • Activate the “flat” mode at the tab level to make the form display only existing elements

  1. The add buttons are rendered, but both using the label defined for spatialResolution, so it’s confusing. Both buttons require to have the following (see full snippet below), if changed name or or attributes, the buttons are not displayed:

<action type=“add” name=“spatialResolution” or=“spatialResolution”
in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification”

Is possible to setup a custom label for the actions?

See https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1083

  1. Also tried to add in the view flatModeExceptions for the following elements, expecting that then would the fields would be displayed even if not in the xml and even if no Add buttons are configured, but no success:

Not sure if I’m missing something here or what I expect is not correct?

An easier way of doing this could be to use @if instead of @or/@in+flat
https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1011

Vriendelijke groeten / Kind regards,

Jose García


Veenderweg 13
6721 WD Bennekom
The Netherlands
T: +31 (0)318 416664

Please consider the environment before printing this email.

Francois


This is the snippet for the fields configuration:

<field

name=“equivalentScale”

xpath=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:equivalentScale”

or=“equivalentScale”

in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*” />

gmd:spatialResolution

gmd:MD_Resolution

gmd:equivalentScale

gmd:MD_RepresentativeFraction

gmd:denominator

gco:Integer</gco:Integer>

</gmd:denominator>

</gmd:MD_RepresentativeFraction>

</gmd:equivalentScale>

</gmd:MD_Resolution>

</gmd:spatialResolution>

<field

name=“distance”

xpath=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance”

or=“distance”

in=“/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*” />

gmd:spatialResolution

gmd:MD_Resolution

gmd:distance

gco:Distance</gco:Distance>

</gmd:distance>

</gmd:MD_Resolution>

</gmd:spatialResolution>

Regards,
Jose García

Vriendelijke groeten / Kind regards,

Jose García


Veenderweg 13
6721 WD Bennekom
The Netherlands
T: +31 (0)318 416664

Please consider the environment before printing this email.


Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San
Francisco, CA to explore cutting-edge tech and listen to tech luminaries
present their vision of the future. This family event has something for
everyone, including kids. Get more information and register today.
http://sdm.link/attshape


GeoNetwork-devel mailing list
GeoNetwork-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geonetwork-devel
GeoNetwork OpenSource is maintained at http://sourceforge.net/projects/geonetwork

Vriendelijke groeten / Kind regards,

Jose García


Veenderweg 13
6721 WD Bennekom
The Netherlands
T: +31 (0)318 416664

Please consider the environment before printing this email.

2016-07-07 14:02 GMT+02:00 Jose Garcia <jose.garcia@anonymised.com>:

Hi

I have just tried this quickly:

in a template field you need to define key/value with xpath to define which
part of the XML to edit. If none, then no form. This is used to create the
appropriate inputs.

Francois

<field
  name="spatialResolution"
  xpath="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution"
  or="spatialResolution"
  in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/*">
  <template>
    <snippet>
    <gmd:spatialResolution>
      <gmd:MD_Resolution>
        <gmd:distance>
          <gco:Distance></gco:Distance>
        </gmd:distance>
      </gmd:MD_Resolution>
    </gmd:spatialResolution>
    </snippet>
  </template>
</field>

<flatModeExceptions>
  <for name="gmd:spatialResolution"></for>
  <for name="gmd:distance"></for>
</flatModeExceptions>

But the field is not displayed. In any case, with the button label, it's
ok for now, thanks.

Regards,
Jose García

On Thu, Jul 7, 2016 at 1:54 PM, Francois Prunayre <fx.prunayre@anonymised.com>
wrote:

2016-07-07 13:51 GMT+02:00 Jose Garcia <jose.garcia@anonymised.com>:

Hi Francois

See feedback inline.

Regards,
Jose García

On Thu, Jul 7, 2016 at 1:33 PM, Francois Prunayre <fx.prunayre@anonymised.com
> wrote:

Hi,

2016-07-07 13:16 GMT+02:00 Jose Garcia <jose.garcia@anonymised.com>:

Hi

I want to display 2 fields for gmd:equivalentScale and gmd:distance in
a custom view. The gmd:spatialResolution can be missing in the
metadata, so if possible display them anyway or at least display the button
to add them

According to config-editor.xsd doc:

   - To display a field if exist in the metadata document or
   providing a add button in case it does not exist (specify ``in`` and ``or``
   attribute):
   - Activate the "flat" mode at the tab level to make the form
   display only existing elements

1) The add buttons are rendered, but both using the label defined for
spatialResolution, so it's confusing. Both buttons require to have the
following (see full snippet below), if changed *name* or *or*
attributes, the buttons are not displayed:

<action type="add" name="spatialResolution" or="spatialResolution"

in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification"

Is possible to setup a custom label for the actions?

See
https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1083

Ok, I have an old version of develop and the xsd seem not updated with
that, but the attribute works. That's much better.

2) Also tried to add in the view flatModeExceptions for the following
elements, expecting that then would the fields would be displayed even if
not in the xml and even if no Add buttons are configured, but no success:

      <flatModeExceptions>
        <for name="gmd:spatialResolution"/>
        <for name="gmd:equivalentScale"/>
        <for name="gmd:distance"/>
      </flatModeExceptions>

Not sure if I'm missing something here or what I expect is not correct?

An easier way of doing this could be to use @if instead of @or/@in+flat

https://github.com/geonetwork/core-geonetwork/blob/develop/schemas/config-editor.xsd#L1011

Just to be sure, you mean that I can use this and that should display
the button also?:

    <action type="add" name="spatialResolution"

if="count(/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance)
= 0">

But this doesn't show the input text if the element is missing in the
xml without requiring any button. Is there're any way to do that? From the
documentation, seem it says that.

Not 100% sure, but if not using a template mode field, then it can't
display an input if the field is not in the XML. Would need some testing...

Francois

Francois

----

This is the snippet for the fields configuration:

<field
name="equivalentScale"

xpath="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:equivalentScale"
or="equivalentScale"
in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*"
/>

<action type="add" name="spatialResolution" or="spatialResolution"

in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification"

if="count(/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:equivalentScale)
= 0">
<template>
  <snippet>
    <gmd:spatialResolution>
      <gmd:MD_Resolution>
        <gmd:equivalentScale>
          <gmd:MD_RepresentativeFraction>
            <gmd:denominator>
              <gco:Integer></gco:Integer>
            </gmd:denominator>
          </gmd:MD_RepresentativeFraction>
        </gmd:equivalentScale>
      </gmd:MD_Resolution>
    </gmd:spatialResolution>
  </snippet>
</template>
</action>

<field
name="distance"

xpath="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance"
or="distance"
in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/*"
/>

<action type="add" name="spatialDistance" or="spatialDistance"

in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification"

if="count(/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialResolution/gmd:MD_Resolution/gmd:distance)
= 0">
<template>
  <snippet>
    <gmd:spatialResolution>
      <gmd:MD_Resolution>
        <gmd:distance>
          <gco:Distance></gco:Distance>
        </gmd:distance>
      </gmd:MD_Resolution>
    </gmd:spatialResolution>
  </snippet>
</template>
</action>

Regards,
Jose García

--

*Vriendelijke groeten / Kind regards,Jose García
<http://www.geocat.net/&gt;Veenderweg 136721 WD BennekomThe NetherlandsT: +31
(0)318 416664 <+31318416664> <https://www.facebook.com/geocatbv&gt;
<https://twitter.com/geocat_bv&gt;
<https://plus.google.com/u/1/+GeocatNetbv/posts&gt;Please consider the
environment before printing this email.*

------------------------------------------------------------------------------
Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San
Francisco, CA to explore cutting-edge tech and listen to tech
luminaries
present their vision of the future. This family event has something for
everyone, including kids. Get more information and register today.
http://sdm.link/attshape
_______________________________________________
GeoNetwork-devel mailing list
GeoNetwork-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geonetwork-devel
GeoNetwork OpenSource is maintained at
http://sourceforge.net/projects/geonetwork

--

*Vriendelijke groeten / Kind regards,Jose García
<http://www.geocat.net/&gt;Veenderweg 136721 WD BennekomThe NetherlandsT: +31
(0)318 416664 <+31318416664> <https://www.facebook.com/geocatbv&gt;
<https://twitter.com/geocat_bv&gt;
<https://plus.google.com/u/1/+GeocatNetbv/posts&gt;Please consider the
environment before printing this email.*

--

*Vriendelijke groeten / Kind regards,Jose García
<http://www.geocat.net/&gt;Veenderweg 136721 WD BennekomThe NetherlandsT: +31
(0)318 416664 <+31318416664> <https://www.facebook.com/geocatbv&gt;
<https://twitter.com/geocat_bv&gt;
<https://plus.google.com/u/1/+GeocatNetbv/posts&gt;Please consider the
environment before printing this email.*