Ajout des classifications UNISCIEL

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

Par défaut, ORI-OAI ne propose pas la classification UNISCIEL dans les formulaires LOM. Voici la marche à suivre pour les obtenir :

Création des classifications

Déposer les vocabulaires fournis par UNISCIEL dans: ori-oai-md-editor-svn/WEB-INF/resources/forms/ori-md-editor/common/xml-vocab-local

Déclaration des vocabulaires dans le formulaire LOM

Dans le formulaire LOM que vous souhaitez modifier, déclarez ces nouveaux vocabulaires dans le fichier form.xhtml:

<xforms:instance id="chebocar_taxonomie" src="/fr/service/custom/ori-md-editor/oriGetVocab?vocab=Chebocar-2.0_vdex" xxforms:readonly="true" xxforms:cache="true"/>

<xforms:instance src="/fr/service/custom/ori-md-editor/oriGetVocab?vocab=JaHe-2.0-vdex" xxforms:readonly="true" xxforms:cache="true"/>

<xforms:instance src="/fr/service/custom/ori-md-editor/oriGetVocab?vocab=JaPeSe-2.0_vdex" xxforms:readonly="true" xxforms:cache="true"/>

<xforms:instance src="/fr/service/custom/ori-md-editor/oriGetVocab?vocab=SciencesHommesSocietes-Dewey-vdex-v1.0" xxforms:readonly="true" xxforms:cache="true"/>

<xforms:instance src="/fr/service/custom/ori-md-editor/oriGetVocab?vocab=TaCBaHa-2.0_vdex" xxforms:readonly="true" xxforms:cache="true"/>

<xforms:instance src="/fr/service/custom/ori-md-editor/oriGetVocab?vocab=Thokavi-2.0_vdex" xxforms:readonly="true" xxforms:cache="true"/>

<xforms:instance src="/fr/service/custom/ori-md-editor/oriGetVocab?vocab=Unit-informatique-vdex" xxforms:readonly="true" xxforms:cache="true"/>

Modification du formulaire LOM

Dans le fichier case-classification.xml:

En dessous du bloc «Dewey22e éd» ( bloc commençant par: <xforms:group ref=".[../lom:source/lom:string = 'CDD 22e éd.']">), ajouter ces lignes :

<xforms:group ref=".[starts-with(../lom:source/lom:string, 'Classification Chebocar')]">
<xforms:trigger appearance="minimal">
<xforms:label>
<img src="/forms/ori-md-editor/media/images/list.gif"/>
<span> <xforms:output value="$fr-resources/ori-taxonomy-search-title"/></span>
</xforms:label>
<xforms:action ev:event="DOMActivate">
<!- Remember position of the taxon to edit ->
<xforms:setvalue ref="xxforms:instance('taxonomy-search')/taxon-position" value="count(xxforms:repeat-current()/preceding::lom:taxon) + 1"/>
<!- Open the taxonomy search dialog ->
<xxforms:show dialog="search-chebocar-taxonomy-dialog"/>
</xforms:action>
</xforms:trigger>
<xforms:output value="lom:id">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.1"/>
</xforms:output>
<xforms:group ref="lom:entry">
<xforms:repeat nodeset="lom:string">
<xforms:output value=".">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.2"/>
</xforms:output>
</xforms:repeat>
</xforms:group>
</xforms:group>

<xforms:group ref=".[starts-with(../lom:source/lom:string, 'Classification JaHe')]">
<xforms:trigger appearance="minimal">
<xforms:label>
<img src="/forms/ori-md-editor/media/images/list.gif"/>
<span> <xforms:output value="$fr-resources/ori-taxonomy-search-title"/></span>
</xforms:label>
<xforms:action ev:event="DOMActivate">
<!- Remember position of the taxon to edit ->
<xforms:setvalue ref="xxforms:instance('taxonomy-search')/taxon-position" value="count(xxforms:repeat-current()/preceding::lom:taxon) + 1"/>
<!- Open the taxonomy search dialog ->
<xxforms:show dialog="search-jahe-taxonomy-dialog"/>
</xforms:action>
</xforms:trigger>
<xforms:output value="lom:id">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.1"/>
</xforms:output>
<xforms:group ref="lom:entry">
<xforms:repeat nodeset="lom:string">
<xforms:output value=".">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.2"/>
</xforms:output>
</xforms:repeat>
</xforms:group>
</xforms:group>

<xforms:group ref=".[starts-with(../lom:source/lom:string, 'Classification JaPeSe')]">
<xforms:trigger appearance="minimal">
<xforms:label>
<img src="/forms/ori-md-editor/media/images/list.gif"/>
<span> <xforms:output value="$fr-resources/ori-taxonomy-search-title"/></span>
</xforms:label>
<xforms:action ev:event="DOMActivate">
<!- Remember position of the taxon to edit ->
<xforms:setvalue ref="xxforms:instance('taxonomy-search')/taxon-position" value="count(xxforms:repeat-current()/preceding::lom:taxon) + 1"/>
<!- Open the taxonomy search dialog ->
<xxforms:show dialog="search-japese-taxonomy-dialog"/>
</xforms:action>
</xforms:trigger>
<xforms:output value="lom:id">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.1"/>
</xforms:output>
<xforms:group ref="lom:entry">
<xforms:repeat nodeset="lom:string">
<xforms:output value=".">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.2"/>
</xforms:output>
</xforms:repeat>
</xforms:group>
</xforms:group>

<xforms:group ref=".[starts-with(../lom:source/lom:string, 'Classification SciencesHommesSocietes')]">
<xforms:trigger appearance="minimal">
<xforms:label>
<img src="/forms/ori-md-editor/media/images/list.gif"/>
<span> <xforms:output value="$fr-resources/ori-taxonomy-search-title"/></span>
</xforms:label>
<xforms:action ev:event="DOMActivate">
<!- Remember position of the taxon to edit ->
<xforms:setvalue ref="xxforms:instance('taxonomy-search')/taxon-position" value="count(xxforms:repeat-current()/preceding::lom:taxon) + 1"/>
<!- Open the taxonomy search dialog ->
<xxforms:show dialog="search-SciencesHommesSocietes-taxonomy-dialog"/>
</xforms:action>
</xforms:trigger>
<xforms:output value="lom:id">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.1"/>
</xforms:output>
<xforms:group ref="lom:entry">
<xforms:repeat nodeset="lom:string">
<xforms:output value=".">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.2"/>
</xforms:output>
</xforms:repeat>
</xforms:group>
</xforms:group>

<xforms:group ref=".[starts-with(../lom:source/lom:string, 'Classification TaCBaHa')]">
<xforms:trigger appearance="minimal">
<xforms:label>
<img src="/forms/ori-md-editor/media/images/list.gif"/>
<span> <xforms:output value="$fr-resources/ori-taxonomy-search-title"/></span>
</xforms:label>
<xforms:action ev:event="DOMActivate">
<!- Remember position of the taxon to edit ->
<xforms:setvalue ref="xxforms:instance('taxonomy-search')/taxon-position" value="count(xxforms:repeat-current()/preceding::lom:taxon) + 1"/>
<!- Open the taxonomy search dialog ->
<xxforms:show dialog="search-tacbaha-taxonomy-dialog"/>
</xforms:action>
</xforms:trigger>
<xforms:output value="lom:id">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.1"/>
</xforms:output>
<xforms:group ref="lom:entry">
<xforms:repeat nodeset="lom:string">
<xforms:output value=".">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.2"/>
</xforms:output>
</xforms:repeat>
</xforms:group>
</xforms:group>

<xforms:group ref=".[starts-with(../lom:source/lom:string, 'Classification Thokavi')]">
<xforms:trigger appearance="minimal">
<xforms:label>
<img src="/forms/ori-md-editor/media/images/list.gif"/>
<span> <xforms:output value="$fr-resources/ori-taxonomy-search-title"/></span>
</xforms:label>
<xforms:action ev:event="DOMActivate">
<!- Remember position of the taxon to edit ->
<xforms:setvalue ref="xxforms:instance('taxonomy-search')/taxon-position" value="count(xxforms:repeat-current()/preceding::lom:taxon) + 1"/>
<!- Open the taxonomy search dialog ->
<xxforms:show dialog="search-thokavi-taxonomy-dialog"/>
</xforms:action>
</xforms:trigger>
<xforms:output value="lom:id">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.1"/>
</xforms:output>
<xforms:group ref="lom:entry">
<xforms:repeat nodeset="lom:string">
<xforms:output value=".">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.2"/>
</xforms:output>
</xforms:repeat>
</xforms:group>
</xforms:group>

<xforms:group ref=".[starts-with(../lom:source/lom:string, 'Classification Unit-informatique')]">
<xforms:trigger appearance="minimal">
<xforms:label>
<img src="/forms/ori-md-editor/media/images/list.gif"/>
<span> <xforms:output value="$fr-resources/ori-taxonomy-search-title"/></span>
</xforms:label>
<xforms:action ev:event="DOMActivate">
<!- Remember position of the taxon to edit ->
<xforms:setvalue ref="xxforms:instance('taxonomy-search')/taxon-position" value="count(xxforms:repeat-current()/preceding::lom:taxon) + 1"/>
<!- Open the taxonomy search dialog ->
<xxforms:show dialog="search-unit-informatique-taxonomy-dialog"/>
</xforms:action>
</xforms:trigger>
<xforms:output value="lom:id">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.1"/>
</xforms:output>
<xforms:group ref="lom:entry">
<xforms:repeat nodeset="lom:string">
<xforms:output value=".">
<widget:labels instance="i18n_lom" termIdentifier="9.2.2.2"/>
</xforms:output>
</xforms:repeat>
</xforms:group>
</xforms:group>

Remplacez la ligne commençant par: <xforms:group ref=".[not(../lom:source/lom:string = ('Classification UNIT', 'CDD 22e éd.',

Par celle-ci:

<xforms:group ref=".[not(../lom:source/lom:string = ('Classification UNIT', 'CDD 22e éd.', 'Classification Chebocar v2.0', 'Classification JaHe v2.0', 'Classification JaPeSe v2.0', 'Classification SciencesHommesSocietes v1.0', 'Classification TaCBaHa v2.0', 'Classification Thokavi v2.0', 'Classification Unit-informatique')) and not(starts-with(../lom:source/lom:string, 'Universités Numériques Thématiques'))]">

Création des boites de dialogue

En regardant les lignes précédemment ajoutées, vous vous rendrez compte que l’on fait appel aux vocabulaires mais aussi à des fenêtres de dialogue. Télécharger ce fichier et mettez-les à la racine du votre formulaire.

Il faut à présent les déclarer dans le fichier form.xhtml pour pouvoir les utiliser.

En bas de ce fichier, après la ligne: <xi:include href="oxf:/forms/ori-md-editor/lom-full/form/dialog-dewey-search.xml"/>

Ajoutez ceci:

<xi:include href="oxf:/forms/ori-md-editor/votre_formulaire/form/dialog-chebocar-taxonomy-search.xml"/>

<xi:include href="oxf:/forms/ori-md-editor/votre_formulaire/form/dialog-jahe-taxonomy-search.xml"/>

<xi:include href="oxf:/forms/ori-md-editor/votre_formulaire/form/dialog-japese-taxonomy-search.xml"/>

<xi:include href="oxf:/forms/ori-md-editor/votre_formulaire/form/dialog-SciencesHommesSocietes-taxonomy-search.xml"/>

<xi:include href="oxf:/forms/ori-md-editor/votre_formulaire/form/dialog-tacbaha-taxonomy-search.xml"/>

<xi:include href="oxf:/forms/ori-md-editor/votre_formulaire/form/dialog-thokavi-taxonomy-search.xml"/>

<xi:include href="oxf:/forms/ori-md-editor/votre_formulaire/form/dialog-unit-informatique-taxonomy-search.xml"/>

Prise en compte des modifications

  • Eteindre le tomcat du md-editor
  • Ant all-md-editor depuis le répertoire quick-install

Démarrer le tomcat du md-editor

  • No labels