120 lines
4.6 KiB
XML
120 lines
4.6 KiB
XML
<metal:block use-macro="main_template">
|
|
<div metal:fill-slot="content">
|
|
|
|
<div class="alert alert-danger" tal:condition="message" tal:content="message" />
|
|
|
|
<form id="balance-form" action="${url}" method="post" class="form-horizontal">
|
|
<h3 class="text-primary">1. Générer la Balance Clients</h3>
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-4">Société</label>
|
|
<div class="col-xs-8">
|
|
<p class="form-control-static"><b>CERRA</b></p>
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-4" for="cat">Catégorie</label>
|
|
<div class="col-xs-3">
|
|
<select class="form-control" id="cat" name="cat">
|
|
<div tal:repeat="item permis">
|
|
<option value="${item.CAT}" tal:attributes="selected cat==item.CAT and 'selected' or None">${item.CAT}</option>
|
|
</div>
|
|
</select>
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-4" for="date_debut">Période du </label>
|
|
<div class="col-xs-6">
|
|
<div class="input-group date" id="date_debut">
|
|
<input class="form-control" type="text" name="date_debut" value="${layout.date2dmy(date_debut)}"
|
|
data-fv-date="true"
|
|
data-fv-date-format="DD-MM-YYYY"
|
|
data-fv-date-message="La date n'est pas valide" />
|
|
<span class="input-group-addon add-on">
|
|
<span class="glyphicon glyphicon-calendar"></span>
|
|
</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-4" for="date_fin">au</label>
|
|
<div class="col-xs-6">
|
|
<div class="input-group date" id="date_fin">
|
|
<input class="form-control" type="text" name="date_fin" value="${layout.date2dmy(date_fin)}"
|
|
data-fv-date="true"
|
|
data-fv-date-format="DD-MM-YYYY"
|
|
data-fv-date-message="La date n'est pas valide" />
|
|
<span class="input-group-addon add-on">
|
|
<span class="glyphicon glyphicon-calendar"></span>
|
|
</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<div class="col-xs-8 col-xs-offset-4">
|
|
<button id="extractButton" class="btn btn-lg btn-primary" type="submit" name="form.submitted">
|
|
<span class="glyphicon glyphicon-export"></span> Générer Balance</button>
|
|
<a href="/parametres" class="btn btn-lg btn-default" role="button">
|
|
<span class="glyphicon glyphicon-chevron-left"></span> Annuler</a>
|
|
</div>
|
|
</div>
|
|
<br />
|
|
<h3 class="text-primary">2. Imprimer la Balance Clients</h3>
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-4">Critères de sélection</label>
|
|
<div class="col-xs-8">
|
|
<p class="form-control-static">${balance_criteres}</p>
|
|
</div>
|
|
<label class="control-label col-xs-4">Générée le</label>
|
|
<div class="col-xs-8">
|
|
<p class="form-control-static">${generer_debut}</p>
|
|
</div>
|
|
<label class="control-label col-xs-4">Terminée le</label>
|
|
<div class="col-xs-8">
|
|
<p class="form-control-static">${generer_fin}</p>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="form-group" tal:condition="balance_fin">
|
|
<div class="col-xs-8 col-xs-offset-4">
|
|
<a href="/balance_print" class="btn btn-lg btn-success" role="button">
|
|
<span class="glyphicon glyphicon-chevron-print"></span> Imprimer Balance</a>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
<br />
|
|
<br />
|
|
<br />
|
|
<br />
|
|
<br />
|
|
<br />
|
|
</div><!-- content -->
|
|
|
|
<div metal:fill-slot="additional_scripts">
|
|
<script>
|
|
$(document).ready(function() {
|
|
$('#balance-form').formValidation();
|
|
$('#date_debut').datetimepicker({
|
|
format: 'DD-MM-YYYY',
|
|
allowInputToggle: true,
|
|
}).on('dp.change', function(e) {
|
|
// Revalidate the date field
|
|
$('#balance-form').formValidation('revalidateField', 'date_debut');
|
|
});
|
|
$('#date_fin').datetimepicker({
|
|
format: 'DD-MM-YYYY',
|
|
allowInputToggle: true,
|
|
}).on('dp.change', function(e) {
|
|
// Revalidate the date field
|
|
$('#balance-form').formValidation('revalidateField', 'date_fin');
|
|
});
|
|
});
|
|
$('#extractButton').on('click', function(){
|
|
$('i.gly-spin').removeClass('gly-spin');
|
|
$('i').addClass('gly-spin');
|
|
});
|
|
</script>
|
|
</div>
|
|
</metal:block>
|
|
|
|
|