Commit 5f2b411c authored by EXT Ait Ammar Adam's avatar EXT Ait Ammar Adam
Browse files

Prendre les deux premieres lignes dans regex

parent b77cc074
......@@ -7,7 +7,7 @@
<script type="text/javascript" src="closure-library/closure/goog/base.js"></script>
<link type="text/css" rel="stylesheet" href="media/blockly.css">
<link type="text/css" rel="stylesheet" href="closure-library/closure/goog/css/dialog.css">
<script type="text/javascript" src="blockly-b7ab676f-6394-4ede-9328-f2ea1a2f2fb1.js"></script>
<script type="text/javascript" src="blockly-83330fc4-b12c-49c7-a14c-c26e5ad3351b.js"></script>
<style>
html, body {
background-color: #fff;
......
5B61915C4586CCD4755C8800F126AB71.cache.js
locale default
user.agent safari
76ABD4C8BE9F7C90E5E65A249E3B71B7.cache.js
locale default
user.agent gecko1_8
B616572CAC86E8984B4EEBFBE62A47B4.cache.js
56BBE5B300CE00F8AB0ABBD401CBDF2A.cache.js
locale fr_FR
user.agent gecko1_8
D3DC641A0075F7D0842C782F2C981E32.cache.js
5D702697F2D6F1EDD1B2851EE3BF5464.cache.js
locale default
user.agent safari
6BAD5F2F461DED68DA7DE56340857173.cache.js
locale fr_FR
user.agent safari
E01E2C8A9420BD373707C992CE33F499.cache.js
locale default
user.agent gecko1_8
Devmode:devmode.js
\ No newline at end of file
......@@ -656,6 +656,11 @@ public final class YaBlocksEditor extends FileEditor
// Composant QCM
else if (component.getName().contains("QCM")) {
// Mise à jour de la chaine générique avec le nom d'activité suivante
if (JemBlocksMethods.blocsExist(blocksContent, JemBlocksRegex.TVB)) {
alert("Trouve");
reloadBlocks(JemBlocksMethods.updateBlock(blocksContent, JemBlocksRegex.TVB,""));
}
String updatedOpenQuestionBlocs = JemBlocksMethods.tellNextActivity(this.getForm().getName(),JemBlocksStrings.QCM_COMPONENT);
String qcmBlock = JemBlocksMethods.addNewBlocks(this, updatedOpenQuestionBlocs);
this.reloadBlocks(qcmBlock);
......
......@@ -268,11 +268,18 @@ public final class AddFormCommand extends ChainableCommand {
YaBlocksEditor thisBlocksEditor = (YaBlocksEditor)blocksEditor;
// Mettre à jour le texte brut INITIAL_FORM avec le nom de l'activité en cours
String blocksWithUpdatedFormName = JemBlocksMethods.updateBlock(INITIAL_FORM, CURRENT_FORM, defaultFormName);
blocksWithUpdatedFormName = JemBlocksMethods.tellNextActivity(defaultFormName, blocksWithUpdatedFormName);
if (defaultFormName.equals("Activite_1"))
// Remettre le score à 0 (remplacer dans les blocs "valeur de départ" par 0)
blocksWithUpdatedFormName = JemBlocksMethods.updateBlock(blocksWithUpdatedFormName,JemBlocksRegex.SCORE_START_VALUE,SCORE_NULL);
thisBlocksEditor.reloadBlocks(blocksWithUpdatedFormName);
String blockTVB = JemBlocksMethods.addNewBlocks(thisBlocksEditor, TVB);
blockTVB = JemBlocksMethods.tellNextActivity(defaultFormName,blockTVB);
thisBlocksEditor.reloadBlocks(blockTVB);
}
} else {
// The form editor and/or blocks editor is still not there. Try again later.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment