Revisión 407
Añadido por Manu Mora Gordillo hace más de 12 años
controlies/trunk/applications/controlies/views/reports/laptops.html | ||
---|---|---|
<script>
|
||
$(function() {
|
||
$("#tabsSearch").tabs().css("font-size","13px");
|
||
$("#buttonReport").button({ icons: { primary: "ui-icon-document"}});
|
||
$("#buttonReport")
|
||
.button({ icons: { primary: "ui-icon-document"}})
|
||
.click( function(){ report(); });
|
||
|
||
getGroups();
|
||
showFields();
|
||
})
|
||
|
||
function getGroups(){
|
||
jQuery.post("call/json/getClassrooms",
|
||
jQuery.get("call/json/getClassrooms",
|
||
function(data){
|
||
jQuery.each(data.classrooms, function(i,item){
|
||
jQuery("#classroom").append("<option value='"+item+"'>"+item+"</option>");
|
||
... | ... | |
}
|
||
);
|
||
}
|
||
|
||
function restartStyle(){
|
||
jQuery('#messageReport').html("");
|
||
}
|
||
|
||
function report(){
|
||
restartStyle();
|
||
jQuery.ajax({url:"report",data:jQuery("#form_authorization").serialize()})
|
||
.done(function ( data ){
|
||
switch(data){
|
||
case 'noPeople':{
|
||
alert("no hay gente");
|
||
jQuery('#messageReport').html("No se han encontrado datos").effect("highlight", {"color":"yellow"}, 1000);
|
||
break
|
||
}
|
||
default: eval(data);
|
||
... | ... | |
}
|
||
|
||
function hideAllFields(){
|
||
restartStyle();
|
||
jQuery("#form_authorization #searchTD").hide();
|
||
jQuery("#form_authorization #classroomsTD").hide();
|
||
}
|
||
... | ... | |
</td>
|
||
</tr>
|
||
<tr>
|
||
<td colspan="4" style="text-align:center;"><br><br>
|
||
<button id="buttonReport" onClick="javascript:report();">Generar informe</button>
|
||
<td colspan="4" style="text-align:center;">
|
||
<br><div id="messageReport" style="text-align:center; font-weight:bold; color:red; padding:3px; "></div>
|
||
<button type="button" id="buttonReport">Generar informe</button>
|
||
</td>
|
||
</tr>
|
||
</table>
|
Exportar a: Unified diff
Mensaje de aviso - Informes portátiles