Rev 1929 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1929 | Rev 1930 | ||
---|---|---|---|
Line 278... | Line 278... | ||
278 | $scope.checkUnit = function(document,collection) |
278 | $scope.checkUnit = function(document,collection) |
279 | { |
279 | { |
280 | if(document.checked) |
280 | if(document.checked) |
281 | { |
281 | { |
282 | var docContainer = |
282 | var docContainer = |
283 | { |
283 | { |
284 | "document" : document, |
284 | "document" : document, |
285 | "collection" : collection |
285 | "collection" : collection |
286 | } |
286 | } |
287 | $scope.checkedDocuments.push(docContainer); |
287 | $scope.checkedDocuments.push(docContainer); |
288 | } |
288 | } |
289 | else |
289 | else |
290 | { |
290 | { |
291 | angular.forEach($scope.checkedDocuments, function(documentContainer, key) |
291 | angular.forEach($scope.checkedDocuments, function(documentContainer, key) |
Line 366... | Line 366... | ||
366 | return false; |
366 | return false; |
367 | } |
367 | } |
368 | $scope.addUc = function(semestre) |
368 | $scope.addUc = function(semestre) |
369 | { |
369 | { |
370 | semestre.ucs.push( |
370 | semestre.ucs.push( |
371 | { |
371 | { |
372 | "@class" : "<%=UnitsLearningResultUc.class.getName()%>", |
372 | "@class" : "<%=UnitsLearningResultUc.class.getName()%>", |
373 | manual : true, |
373 | manual : true, |
374 | periodo : semestre.semestre, |
374 | periodo : semestre.semestre, |
375 | alunosInscritos: 0, |
375 | alunosInscritos: 0, |
376 | aprovados: 0, |
376 | aprovados: 0, |
377 | aprovados1013: 0, |
377 | aprovados1013: 0, |
378 | aprovados1013Percent: 0, |
378 | aprovados1013Percent: 0, |
379 | aprovados1416: 0, |
379 | aprovados1416: 0, |
380 | aprovados1416Percent: 0, |
380 | aprovados1416Percent: 0, |
381 | aprovados1720: 0, |
381 | aprovados1720: 0, |
382 | aprovados1720Percent: 0, |
382 | aprovados1720Percent: 0, |
383 | aprovadosPercent: 0, |
383 | aprovadosPercent: 0, |
384 | cumprimentoProgramaPercent: 0, |
384 | cumprimentoProgramaPercent: 0, |
385 | reprovados: 0, |
385 | reprovados: 0, |
386 | reprovadosPercent: 0, |
386 | reprovadosPercent: 0, |
387 | semElementos: 0, |
387 | semElementos: 0, |
388 | semElementosPercent: 0, |
388 | semElementosPercent: 0, |
389 | sigesCode : 0 |
389 | sigesCode : 0 |
390 | } |
390 | } |
391 | ); |
391 | ); |
392 | } |
392 | } |
393 | $scope.addAno = function(comp) |
393 | $scope.addAno = function(comp) |
394 | { |
394 | { |
395 | if(!comp.years) |
395 | if(!comp.years) |
396 | comp.years = []; |
396 | comp.years = []; |
397 | comp.years.push( |
397 | comp.years.push( |
398 | { |
398 | { |
399 | ano : 1, |
399 | ano : 1, |
400 | "@class" : "<%=UnitsLearningResultYear.class.getName()%>", |
400 | "@class" : "<%=UnitsLearningResultYear.class.getName()%>", |
401 | manual : true, |
401 | manual : true, |
402 | "alunosInscritos": 0, |
402 | "alunosInscritos": 0, |
403 | "aprovados": 0, |
403 | "aprovados": 0, |
404 | "aprovados1013": 0, |
404 | "aprovados1013": 0, |
405 | "aprovados1013Percent": 0, |
405 | "aprovados1013Percent": 0, |
406 | "aprovados1416": 0, |
406 | "aprovados1416": 0, |
407 | "aprovados1416Percent": 0, |
407 | "aprovados1416Percent": 0, |
408 | "aprovados1720": 0, |
408 | "aprovados1720": 0, |
409 | "aprovados1720Percent": 0, |
409 | "aprovados1720Percent": 0, |
410 | "aprovadosPercent": 0, |
410 | "aprovadosPercent": 0, |
411 | "cumprimentoProgramaPercent": 0, |
411 | "cumprimentoProgramaPercent": 0, |
412 | "reprovados": 0, |
412 | "reprovados": 0, |
413 | "reprovadosPercent": 0, |
413 | "reprovadosPercent": 0, |
414 | "semElementos": 0, |
414 | "semElementos": 0, |
415 | "semElementosPercent": 0, |
415 | "semElementosPercent": 0, |
416 | semesters : [ |
416 | semesters : [ |
417 | { |
417 | { |
418 | "@class" : "<%=UnitsLearningResultSemester.class.getName()%>", |
418 | "@class" : "<%=UnitsLearningResultSemester.class.getName()%>", |
419 | manual : true, |
419 | manual : true, |
420 | semestre : "S1", |
420 | semestre : "S1", |
421 | alunosInscritos: 0, |
421 | alunosInscritos: 0, |
422 | aprovados: 0, |
422 | aprovados: 0, |
423 | aprovados1013: 0, |
423 | aprovados1013: 0, |
424 | aprovados1013Percent: 0, |
424 | aprovados1013Percent: 0, |
425 | aprovados1416: 0, |
425 | aprovados1416: 0, |
426 | aprovados1416Percent: 0, |
426 | aprovados1416Percent: 0, |
427 | aprovados1720: 0, |
427 | aprovados1720: 0, |
428 | aprovados1720Percent: 0, |
428 | aprovados1720Percent: 0, |
429 | aprovadosPercent: 0, |
429 | aprovadosPercent: 0, |
430 | cumprimentoProgramaPercent: 0, |
430 | cumprimentoProgramaPercent: 0, |
431 | reprovados: 0, |
431 | reprovados: 0, |
432 | reprovadosPercent: 0, |
432 | reprovadosPercent: 0, |
433 | semElementos: 0, |
433 | semElementos: 0, |
434 | semElementosPercent: 0, |
434 | semElementosPercent: 0, |
435 | ucs : [] |
435 | ucs : [] |
436 | }, |
436 | }, |
437 | { |
437 | { |
438 | "@class" : "<%=UnitsLearningResultSemester.class.getName()%>", |
438 | "@class" : "<%=UnitsLearningResultSemester.class.getName()%>", |
439 | manual : true, |
439 | manual : true, |
440 | semestre: "S2", |
440 | semestre: "S2", |
441 | alunosInscritos: 0, |
441 | alunosInscritos: 0, |
442 | aprovados: 0, |
442 | aprovados: 0, |
443 | aprovados1013: 0, |
443 | aprovados1013: 0, |
444 | aprovados1013Percent: 0, |
444 | aprovados1013Percent: 0, |
445 | aprovados1416: 0, |
445 | aprovados1416: 0, |
446 | aprovados1416Percent: 0, |
446 | aprovados1416Percent: 0, |
447 | aprovados1720: 0, |
447 | aprovados1720: 0, |
448 | aprovados1720Percent: 0, |
448 | aprovados1720Percent: 0, |
449 | aprovadosPercent: 0, |
449 | aprovadosPercent: 0, |
450 | cumprimentoProgramaPercent: 0, |
450 | cumprimentoProgramaPercent: 0, |
451 | reprovados: 0, |
451 | reprovados: 0, |
452 | reprovadosPercent: 0, |
452 | reprovadosPercent: 0, |
453 | semElementos: 0, |
453 | semElementos: 0, |
454 | semElementosPercent: 0, |
454 | semElementosPercent: 0, |
455 | ucs : [] |
455 | ucs : [] |
456 | } |
456 | } |
457 | ] |
457 | ] |
458 | } |
458 | } |
459 | ); |
459 | ); |
460 | } |
460 | } |
461 | 461 | ||
462 | }, |
462 | }, |
463 | templateUrl: function(elem,attrs) { |
463 | templateUrl: function(elem,attrs) { |
Line 626... | Line 626... | ||
626 | { |
626 | { |
627 | $scope.generateChart = function(comp) |
627 | $scope.generateChart = function(comp) |
628 | { |
628 | { |
629 | 629 | ||
630 | widgetCallWithActionParameters( |
630 | widgetCallWithActionParameters( |
631 | "<%=request.getContextPath()%>/user/courseReport.do", |
631 | "<%=request.getContextPath()%>/user/courseReport.do", |
632 | "generateGlobalLearningResultsChartImg", |
632 | "generateGlobalLearningResultsChartImg", |
633 | { |
633 | { |
634 | "courseReportDocument" : BacoJS.stringifyOrdered(angular.element($("#courseReportApp")).scope().report) |
634 | "courseReportDocument" : BacoJS.stringifyOrdered(angular.element($("#courseReportApp")).scope().report) |
635 | }, |
635 | }, |
636 | "#courseReportApp", |
636 | "#courseReportApp", |
637 | function(repositoryFile4JsonView) |
637 | function(repositoryFile4JsonView) |
638 | { |
638 | { |
639 | comp.image = repositoryFile4JsonView; |
639 | comp.image = repositoryFile4JsonView; |
640 | comp.imageUrl = "<%=request.getContextPath()%>/repositoryStream/" + comp.image.identifier + "?" + new Date().getTime(); |
640 | comp.imageUrl = "<%=request.getContextPath()%>/repositoryStream/" + comp.image.identifier + "?" + new Date().getTime(); |
641 | angular.element($("#courseReportApp")).scope().$apply(); |
641 | angular.element($("#courseReportApp")).scope().$apply(); |
642 | }, |
642 | }, |
643 | function(){} |
643 | function(){} |
644 | ); |
644 | ); |
645 | } |
645 | } |
646 | 646 | ||
647 | 647 | ||
648 | }, |
648 | }, |
649 | templateUrl: function(elem,attrs) { |
649 | templateUrl: function(elem,attrs) { |
650 | return "globallearningresultschartimg"; |
650 | return "chartcomponenttemplate"; |
651 | } |
651 | } |
652 | } |
652 | } |
653 | }); |
653 | }); |
654 | </script> |
654 | </script> |
655 | <script type="text/ng-template" id="globallearningresultschartimg"> |
655 | <script type="text/ng-template" id="chartcomponenttemplate"> |
656 | <div class="imageComponent component"> |
656 | <div class="imageComponent component"> |
657 | 657 | ||
658 | <div class="componentBody"> |
658 | <div class="componentBody"> |
659 | <div class="form-group clearfix"> |
659 | <div class="form-group clearfix"> |
660 | <label class="col-md-2 control-label">Legenda</label> |
660 | <label class="col-md-2 control-label">Legenda</label> |
Line 698... | Line 698... | ||
698 | { |
698 | { |
699 | $scope.generateChart = function(comp) |
699 | $scope.generateChart = function(comp) |
700 | { |
700 | { |
701 | 701 | ||
702 | widgetCallWithActionParameters( |
702 | widgetCallWithActionParameters( |
703 | "<%=request.getContextPath()%>/user/courseReport.do", |
703 | "<%=request.getContextPath()%>/user/courseReport.do", |
704 | "generateGlobalLearningResultsChartYearImg", |
704 | "generateGlobalLearningResultsChartYearImg", |
705 | { |
705 | { |
706 | "courseReportDocument" : BacoJS.stringifyOrdered(angular.element($("#courseReportApp")).scope().report) |
706 | "courseReportDocument" : BacoJS.stringifyOrdered(angular.element($("#courseReportApp")).scope().report) |
707 | }, |
707 | }, |
708 | "#courseReportApp", |
708 | "#courseReportApp", |
709 | function(repositoryFile4JsonView) |
709 | function(repositoryFile4JsonView) |
710 | { |
710 | { |
711 | comp.image = repositoryFile4JsonView; |
711 | comp.image = repositoryFile4JsonView; |
712 | comp.imageUrl = "<%=request.getContextPath()%>/repositoryStream/" + comp.image.identifier + "?" + new Date().getTime(); |
712 | comp.imageUrl = "<%=request.getContextPath()%>/repositoryStream/" + comp.image.identifier + "?" + new Date().getTime(); |
713 | angular.element($("#courseReportApp")).scope().$apply(); |
713 | angular.element($("#courseReportApp")).scope().$apply(); |
714 | }, |
714 | }, |
715 | function(){} |
715 | function(){} |
716 | ); |
716 | ); |
717 | } |
717 | } |
718 | 718 | ||
719 | 719 | ||
720 | }, |
720 | }, |
721 | templateUrl: function(elem,attrs) { |
721 | templateUrl: function(elem,attrs) { |
722 | return "globallearningresultschartimg"; |
722 | return "chartcomponenttemplate"; |
723 | } |
723 | } |
724 | } |
724 | } |
725 | }); |
725 | }); |
726 | </script> |
726 | </script> |
727 | <script type="text/ng-template" id="globallearninglesultschartyearimg"> |
- | |
728 | <div class="imageComponent component"> |
- | |
729 | - | ||
730 | <div class="componentBody"> |
- | |
731 | <div class="form-group clearfix"> |
- | |
732 | <label class="col-md-2 control-label">Legenda</label> |
- | |
733 | <div class="col-md-10"> |
- | |
734 | <input type="text" class="form-control" rows="10" ng-model="comp.title"> |
- | |
735 | </div> |
- | |
736 | </div> |
- | |
737 | <div class="form-group clearfix"> |
- | |
738 | <div class="col-md-2 control-label"> |
- | |
739 | <button class="btn btn-default" ng-click="generateChart(comp)">Refrescar/Gerar Gráfico</button> |
- | |
740 | </div> |
- | |
741 | <div class="col-md-10"> |
- | |
742 | <label ng-if="comp.image.identifier"> Limites do PDF </label> |
- | |
743 | <div ng-if="comp.image.identifier" style="text-align: center; width: 595px; border: 1px solid black; padding: 45px"> |
- | |
744 | <center> |
- | |
745 | <div style="width: 200px;height: 200px; max-width: 500px; max-height: 750px" resizable on-resize="resize($evt, $ui, comp)"> |
- | |
746 | <img ng-if="comp.imageUrl" style="width: 100%;height: 100%" ng-src="{{comp.imageUrl}}"> |
- | |
747 | <img ng-if="!comp.imageUrl" style="width: 100%;height: 100%" ng-src="{{'<%=request.getContextPath()%>/repositoryStream/' + comp.image.identifier}}"> |
- | |
748 | </div> |
- | |
749 | (Se desejar altere o tamanho da imagem arrastando no canto inferior direito) |
- | |
750 | </center> |
- | |
751 | </div> |
- | |
752 | </div> |
- | |
753 | </div> |
- | |
754 | </div> |
- | |
755 | </div> |
- | |
756 | </script> |
- | |
757 | 727 | ||
758 | 728 | ||
759 | <script type="text/ng-template" id="pt_estgp_estgweb_services_courses_coursereport_documentmodel_learningresults_components_LearningResultsChartSem"> |
729 | <script type="text/ng-template" id="pt_estgp_estgweb_services_courses_coursereport_documentmodel_learningresults_components_LearningResultsChartSem"> |
760 | <learningresultschartsem> |
730 | <learningresultschartsem> |
761 | </learningresultschartsem> |
731 | </learningresultschartsem> |
Line 790... | Line 760... | ||
790 | } |
760 | } |
791 | 761 | ||
792 | 762 | ||
793 | }, |
763 | }, |
794 | templateUrl: function(elem,attrs) { |
764 | templateUrl: function(elem,attrs) { |
795 | return "learningresultschartsem"; |
765 | return "chartcomponenttemplate"; |
796 | } |
766 | } |
797 | } |
767 | } |
798 | }); |
768 | }); |
799 | </script> |
769 | </script> |
800 | <script type="text/ng-template" id="learningresultschartsem"> |
- | |
801 | <div class="imageComponent component"> |
- | |
802 | - | ||
803 | <div class="componentBody"> |
- | |
804 | <div class="form-group clearfix"> |
- | |
805 | <label class="col-md-2 control-label">Legenda</label> |
- | |
806 | <div class="col-md-10"> |
- | |
807 | <input type="text" class="form-control" rows="10" ng-model="comp.title"> |
- | |
808 | </div> |
- | |
809 | </div> |
- | |
810 | <div class="form-group clearfix"> |
- | |
811 | <div class="col-md-2 control-label"> |
- | |
812 | <button class="btn btn-default" ng-click="generateChart(comp)">Refrescar/Gerar Gráfico</button> |
- | |
813 | </div> |
- | |
814 | <div class="col-md-10"> |
- | |
815 | <label ng-if="comp.image.identifier"> Limites do PDF </label> |
- | |
816 | <div ng-if="comp.image.identifier" style="text-align: center; width: 595px; border: 1px solid black; padding: 45px"> |
- | |
817 | <center> |
- | |
818 | <div style="width: 200px;height: 200px; max-width: 500px; max-height: 750px" resizable on-resize="resize($evt, $ui, comp)"> |
- | |
819 | <img ng-if="comp.imageUrl" style="width: 100%;height: 100%" ng-src="{{comp.imageUrl}}"> |
- | |
820 | <img ng-if="!comp.imageUrl" style="width: 100%;height: 100%" ng-src="{{'<%=request.getContextPath()%>/repositoryStream/' + comp.image.identifier}}"> |
- | |
821 | </div> |
- | |
822 | (Se desejar altere o tamanho da imagem arrastando no canto inferior direito) |
- | |
823 | </center> |
- | |
824 | </div> |
- | |
825 | </div> |
- | |
826 | </div> |
- | |
827 | </div> |
- | |
828 | </div> |
- | |
829 | </script> |
- | |
830 | 770 |