statistics.php 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115
  1. <style>
  2. .addborder{border:1px solid #ccc}
  3. .addheight{height:30px;border-radius:2px;}
  4. .addheight:focus{border-color: #66afe9;box-shadow: 0 1px 1px rgba(0, 0, 0, 0.075) inset, 0 0 8px rgba(102, 175, 233, 0.6);outline: 0 none;}
  5. .ace{position:relative;top:0px !important;left:0px !important;}
  6. label{font-weight:100 !important;}
  7. .diy_select{height:30px;width:230px;position:relative;font-size:12px;background:#fff;color:#000;float:left;border-radius:4px;}
  8. .diy_select:active{box-shadow:0 0 5px #66afe9;border:1px solid #66afe9}
  9. .diy_select_btn,.diy_select_txt{float:left;height:100%;line-height:30px}
  10. .diy_select,.diy_select_list{border:1px solid #ccc;}
  11. .diy_select_txt{width:180px;}
  12. .diy_select_txt,.diy_select_list li{text-indent:10px;overflow:hidden}
  13. .diy_select_btn{width:28px;background:url(/images/arrBottom.png) no-repeat center}
  14. .diy_select_list{position:absolute;top:27px;left:0px;z-index:88888;border-top:none;width:100%;display:none;_top:29px;background: #fff;max-height:300px;overflow-y:scroll;}
  15. .diy_select_list li{list-style:none;height:30px;line-height:30px;cursor:default;_background:#fff;/**padding-left: 10px;**/}
  16. .diy_select_list li.focus{background:#3399FF;color:#fff}
  17. .diy_select label{position:absolute;left:180px;width:160px;top:4px;font-size:15px;}
  18. </style>
  19. <script src="/js/jquery.validate.min.js"></script>
  20. <script type="text/javascript">
  21. jQuery(document).ready(function(){
  22. jQuery("#schoolSubmit").click(function(){
  23. var semester_id = $("#semester_id").val();
  24. var semester_name = $(".diy_select_txt").text();
  25. if(semester_id>0)
  26. {
  27. var data={
  28. semester_id:semester_id
  29. };
  30. $.post("<?php echo Yii::app()->createUrl('export/s_download')?>",data,function(flags){
  31. var m = JSON.parse(flags);
  32. if(m.status==-1)
  33. {
  34. alert('请选择学期');return false;
  35. }
  36. if(m.status==-2)
  37. {
  38. alert('学期不存在');return false;
  39. }
  40. if(m.status==0)
  41. {
  42. alert('文件不存在');return false;
  43. }
  44. if(m.status==1)
  45. {
  46. location.href = m.file_path;return false;
  47. }
  48. });
  49. }else
  50. {
  51. alert('请选择学期');return false ;
  52. }
  53. });
  54. });
  55. </script>
  56. <div class="main-content-inner">
  57. <!-- 导航栏开始-->
  58. <?php include(Yii::app()->basePath.'/views/layouts/view_production_navigation.php');?>
  59. <!-- 导航栏结束-->
  60. <div class="page-content" style="margin-top:15px;">
  61. <div class="row" style="margin:0px;">
  62. <div class="col-xs-12">
  63. <!-- PAGE CONTENT BEGINS -->
  64. <div class="form-horizontal" >
  65. <div class="form-group">
  66. <label class="control-label col-xs-12 col-sm-3 no-padding-right">选择学期:</label>
  67. <div class="col-sm-9">
  68. <div class='diy_select'>
  69. <input type='hidden' id="semester_id" name="semester_id" class='diy_select_input' value="0" />
  70. <div class='diy_select_txt'>选择学期</div>
  71. <div class='diy_select_btn'></div>
  72. <ul class='diy_select_list'>
  73. <?php if($semester){
  74. foreach($semester as $v)
  75. {
  76. ?>
  77. <li val="<?php echo $v->semester_id?>"><?php echo $v->semester_name?></li>
  78. <?php
  79. }
  80. }?>
  81. </ul>
  82. </div>
  83. </div>
  84. </div>
  85. <div class="clearfix form-actions">
  86. <div class="col-md-offset-3 col-md-9">
  87. <button class="btn btn-success btn-sm" type="button" id="schoolSubmit">
  88. <i class="ace-icon fa fa-check bigger-110"></i>
  89. 导出
  90. </button>
  91. </div>
  92. </div>
  93. </div>
  94. <!-- PAGE CONTENT ENDS -->
  95. </div>
  96. </div>
  97. </div>
  98. </div>
  99. <script src="/js/xsgl.js"></script>