Uploaded image for project: 'Offre de formation'
  1. Offre de formation
  2. ODF-1033

Error when using enumeration without values

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • 2.6.5
    • None
    • None
    • None

      In file Widgets.i18.js, if enumeratedValues is null, it causes an error

      For example

      <cms:metadata name="internshipDurationPeriod" type="string" multiple="true">
      			<label i18n="true">plugin.odf-ujm:PLUGINS_ODF_PROGRAM_DURATION_PERIOD_INTERNSHIP</label>
      			<description i18n="true">plugin.odf-ujm:PLUGINS_ODF_PROGRAM_DURATION_PERIOD_INTERNSHIP_DESC</description>		
      				<custom-enumerator class="org.ametys.odf.enumeration.StaticODFEnumerator">
      					<constant>INTERNSHIP_DURATION_PERIOD</constant>
      				</custom-enumerator>
      			<restrict-to>
      				<right read-write-direction="write" id="ODF_Program_Stages_Rights"/>
      			</restrict-to>
      		</cms:metadata>	
      

      In this example, the tag enumeration is missing, this is a mistake that cause a JS error which is not easy to debug.

            quentin Quentin Glinel-Mortreuil (Inactive)
            fravetier Frederic Ravetier (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: