correction bug cration actif AUTTRE
This commit is contained in:
@@ -20,15 +20,9 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="control-label col-xs-2" for="doc-text">Texte</label>
|
<label class="control-label col-xs-2" for="texte">Texte</label>
|
||||||
<div class="col-xs-8">
|
<div class="col-xs-8">
|
||||||
<textarea class="form-control" rows="15" cols="40" id="doc-text" name="texte"
|
<textarea class="form-control" rows="15" cols="40" id="texte" name="texte">${texte}</textarea>
|
||||||
data-fv-notempty="true"
|
|
||||||
data-fv-notempty-message="Le texte est obligatoire"
|
|
||||||
data-fv-stringlength="true"
|
|
||||||
data-fv-stringlength-max="30000"
|
|
||||||
data-fv-stringlength-message="30000 caractères maximum">${texte}
|
|
||||||
</textarea>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -64,7 +58,25 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
$('#doc_edit-form').formValidation();
|
$('#doc_edit-form').formValidation({
|
||||||
|
framework: 'bootstrap',
|
||||||
|
message: 'This value is not valid',
|
||||||
|
icon: {
|
||||||
|
valid: 'glyphicon glyphicon-ok',
|
||||||
|
invalid: 'glyphicon glyphicon-remove',
|
||||||
|
validating: 'glyphicon glyphicon-refresh'
|
||||||
|
},
|
||||||
|
fields: {
|
||||||
|
texte: {
|
||||||
|
validators: {
|
||||||
|
stringLength: {
|
||||||
|
max: 30000,
|
||||||
|
message: '30000 caractères maximum'
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
});
|
||||||
$('form input').on('keypress', function(e) {
|
$('form input').on('keypress', function(e) {
|
||||||
return e.which !== 13;
|
return e.which !== 13;
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -117,6 +117,7 @@ def actif2_edit(request):
|
|||||||
actif['cours'] = '0'
|
actif['cours'] = '0'
|
||||||
actif['ter'] = '0'
|
actif['ter'] = '0'
|
||||||
actif['pc_rdt'] = '0'
|
actif['pc_rdt'] = '0'
|
||||||
|
actif['modif_le'] = None
|
||||||
page_title= 'Nouvel actif'
|
page_title= 'Nouvel actif'
|
||||||
else:
|
else:
|
||||||
# lire la fiche du actif
|
# lire la fiche du actif
|
||||||
|
|||||||
Reference in New Issue
Block a user