Disable values by educational path ( ELP )


From Ametys 4.9

Some values of the model of a ELP may be overloaded depending on the educational path.

For example, a ELP carries an "ECTS Credits" data which is a default value, but a different value can be given depending on the educational path in the event of sharing of this ELP .

If you want to prohibit local values according to the educational path, follow these steps:

Attribute

The kernel provides a number of overloadable attributes per educational path:

  • ECTS
  • MCC / Coefficient
  • MCC / Evaluations

You have to decide which one you don't want to be overloaded.

Data

Before continuing, it is very important to ensure that no data of the type in question has been entered into the current catalog: otherwise inconsistencies and strange behavior will appear.

Here is a request JCR allowing to find the ELP with a local ECTS credit value.

//element(*, ametys:courseContent)[ametys:catalog='2013-2017']/ametys:ectsByEducationalPath/*[1]

Here is a request JCR allowing to find the ELP with a local value of MCC coefficient.

//element(*, ametys:courseContent)[ametys:catalog='2013-2017']/ametys:mccCoefficientByEducationalPath/*[1]

Here are some requests JCR allowing to find the ELP with local assessment values in the initial or catch-up session.

//element(*, ametys:courseContent)[ametys:catalog='2013-2017']/ametys:mccSession1/*[ametys:common='false']
//element(*, ametys:courseContent)[ametys:catalog='2013-2017']/ametys:mccSession2/*[ametys:common='false']

Modification

Data must be hidden from grid and form editing.

Grid Edit

This step allows you to remove columns from the grid assessment entry.

You need to work on the file " cms/WEB-INF/param/search/mcc- xml " like this:

  • To withdraw ECTS by educational path:
    1. Commenter le libellé de <item ref="ects"> 
    2. Commenter la section <item ref="ectsByEducationalPath">
  • To remove the MCC coefficient by educational path:
    1. Commenter le libellé de <item ref="mccCoefficient"> 
    2. Commenter la section <item ref="mccCoefficientByEducationalPath">
  • To remove assessments by educational path:
    1. Commenter les sections <item ref="common"> ET <item ref="path">
      dans mccSession1 ET mccSession2

If you don't have a " cms/WEB-INF/param/search/mcc- xml " file, you need to create it by copying the contents of the core version you are using.
For example, you can find plugin ODF xml ametys
Be very careful to select the correct branch or tag from the drop-down list which points to "master" by default.

Modification in form

This step allows you to remove fields from the modification of a ELP in a form.

You need to work on the file " plugins /WEB-INF/param/content-types/_override ametys xml ".

In this file, work on the "default-edition" view in "override" mode to remove the desired fields:

<?xml version="1.0" encoding="UTF-8" ?>
<content-type>
   <view name="default-edition" override="true">
      <!-- Ligne pour retirer les ECTSpar chemin pédagogique-->
       <remove-item ref="ectsByEducationalPath" />

      <!-- Ligne pour retirer les coefficient MCCpar chemin pédagogique-->
       <remove-item ref="mcc/mccCoefficientByEducationalPath" />
        
      <!-- Lignes pour retirer les évaluations par chemin pédagogique -->
       <remove-item ref="mcc/mccSession1/path" />
       <remove-item ref="mcc/mccSession1/common" />
       <remove-item ref="mcc/mccSession2/path" />
       <remove-item ref="mcc/mccSession2/common" />
    </view>
</content-type>
Back to top