Traduction du calendrier.
Ajout d'information pour la création de conf.
This commit is contained in:
@@ -11,11 +11,9 @@
|
||||
<script type='text/javascript'>
|
||||
|
||||
function init() {
|
||||
//fillTable2();
|
||||
//fillTable();
|
||||
setTimeout("fillTable2()", 500);
|
||||
setTimeout("fillTable()", 500);
|
||||
|
||||
fillTable2();
|
||||
fillTable();
|
||||
dwr.util.setValues({ id:-1, label:null, min:1, max:5 });
|
||||
}
|
||||
|
||||
var peopleCache = { };
|
||||
@@ -84,12 +82,12 @@ function deleteClicked(eleid) {
|
||||
if (confirm("Are you sure you want to delete " + person.label + "?")) {
|
||||
dwr.engine.beginBatch();
|
||||
AddCriteriaJS.deleteCriterion(person);
|
||||
setTimeout("fillTable2()", 500);
|
||||
setTimeout("fillTable()", 500);
|
||||
fillTable2();
|
||||
fillTable();
|
||||
dwr.engine.endBatch();
|
||||
}
|
||||
viewed = -1;
|
||||
dwr.util.setValues({ id:-1, label:null, min:null, max:null });
|
||||
dwr.util.setValues({ id:-1, label:null, min:1, max:5 });
|
||||
}
|
||||
|
||||
function addClicked(eleid) {
|
||||
@@ -97,31 +95,50 @@ function addClicked(eleid) {
|
||||
//person.id = -1;
|
||||
dwr.engine.beginBatch();
|
||||
AddCriteriaJS.setCriterion(person);
|
||||
setTimeout("fillTable2()", 500);
|
||||
setTimeout("fillTable()", 500);
|
||||
fillTable2();
|
||||
fillTable();
|
||||
dwr.engine.endBatch();
|
||||
viewed = -1;
|
||||
dwr.util.setValues({ id:-1, label:null, min:null, max:null });
|
||||
dwr.util.setValues({ id:-1, label:null, min:1, max:5 });
|
||||
}
|
||||
|
||||
function writePerson() {
|
||||
var person = { id:viewed, label:null, min:null, max:null };
|
||||
dwr.util.getValues(person);
|
||||
|
||||
dwr.engine.beginBatch();
|
||||
AddCriteriaJS.setCriterionClick(person);
|
||||
//fillTable2();
|
||||
//fillTable();
|
||||
|
||||
setTimeout("fillTable()", 500);
|
||||
dwr.engine.endBatch();
|
||||
if (person.max <= person.min) {
|
||||
dwr.util.setValues({id:person.id, label:person.label, min:null, max:null });
|
||||
dwr.util.setValues({errorMax:"The max value should'nt be superior to the min value"});
|
||||
}
|
||||
else {
|
||||
dwr.engine.beginBatch();
|
||||
AddCriteriaJS.setCriterionClick(person);
|
||||
fillTable();
|
||||
dwr.engine.endBatch();
|
||||
dwr.util.setValues({ id:-1, label:null, min:1, max:5 });
|
||||
}
|
||||
}
|
||||
|
||||
function clearPerson() {
|
||||
viewed = -1;
|
||||
dwr.util.setValues({ id:-1, label:null, min:null, max:null });
|
||||
dwr.util.setValues({ id:-1, label:null, min:1, max:5 });
|
||||
}
|
||||
|
||||
var CritereManager = Class.create({
|
||||
initialize: function(inputField, inputField2, inputField3){
|
||||
$(inputField).observe("keypress", this.KeyPressHandler.bindAsEventListener(this));
|
||||
$(inputField2).observe("keypress", this.KeyPressHandler.bindAsEventListener(this));
|
||||
$(inputField3).observe("keypress", this.KeyPressHandler.bindAsEventListener(this));
|
||||
},
|
||||
KeyPressHandler: function(event){
|
||||
switch(event.keyCode){
|
||||
case Event.KEY_RETURN:
|
||||
writePerson();
|
||||
event.stop();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
</head>
|
||||
@@ -140,6 +157,7 @@ function clearPerson() {
|
||||
</h4>
|
||||
|
||||
<form:form commandName="formConference" name="monForm">
|
||||
Step (4/5) <br/>
|
||||
|
||||
This step allows you to add criterion which will be used when someone will evaluate an article.<br/>
|
||||
You can add a new criterion using the input form, or add an existing criterion.<br/>
|
||||
@@ -184,16 +202,21 @@ function clearPerson() {
|
||||
<tr>
|
||||
<td>Max:</td>
|
||||
<td><input id="max" type="text"/></td>
|
||||
<td><span id="errorMax"></span></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="right"><small>(ID=<span id="id">-1</span>)</small>
|
||||
<td colspan="2" align="right"><span id="id" style="display: none;">-1</span>
|
||||
<a href="#" onclick="writePerson()">Save</a>
|
||||
<a href="#" onclick="clearPerson()">Clear</a>
|
||||
</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
new CritereManager('label', 'min', 'max');
|
||||
</script>
|
||||
|
||||
<br />
|
||||
<table border="1" id="tableCriterion" style="display: none;">
|
||||
|
||||
Reference in New Issue
Block a user