123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998 |
- <script src="/js/xsgl.js"></script>
- <script type="text/javascript">
- function in_array(search, array){
- for(var i in array){
- if(array[i]==search){
- return true;
- }
- }
- return false;
- }
- testFlag = "<?php echo $this->testFlag;?>";
- customTplsIds = new Array();
- var i = 0;
- <?php foreach(Yii::app()->params["custom_tpls_ids"] as $tplId){?>
- customTplsIds[i] = "<?php echo $tplId;?>";
- i++;
- <?php }?>
- jQuery(document).ready(function(){
- // 打印答案解析
- $(".answerAnalysis").click(function(){
- var element = this;
- layer.msg('您确定下载答案解析嘛?', {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- var wpCode = jQuery(element).attr("examId");
- if (!wpCode) {
- layer.msg('周周练id有误!');return false;
- }
- jQuery.post(
- '<?php echo $this->createUrl('print/createtempelate');?>',
- {"eid":wpCode},
- function(data){
- var obj = JSON.parse(data);
- if (obj.success == 1) {
- /*alert(obj.message);
- alert(obj);*/
- evaluationClient.printDAJX(JSON.stringify(obj.object));
- } else {
- layer.msg(obj.message);
- }
- }
- );
- }
- });
- });
- jQuery(".needToSendLabelTask").click(function(){
- layer.msg("请先发送标注任务");
- });
- jQuery(".sendLabelTask").click(function(){
- var examId = jQuery(this).attr("examId");
- var examName = jQuery(this).attr("examName");
- var subjectId = jQuery(this).attr("subjectId");
- var createTime = jQuery(this).attr("createTime");
- layer.msg('您确定发送试题标注任务吗?', {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- jQuery.post(
- "<?php echo $this->createUrl("print/sendlabeltask");?>",
- {"examId": examId, "examName": examName, "createTime": createTime},
- function(data){
- data = JSON.parse(data);
- if(data.success == 1){
- layer.msg(data.message);
- setTimeout(function(){location.reload();}, 1300);
- }
- else{
- layer.msg(data.message);
- }
- }
- );
- }
- });
- });
- jQuery(".enterStudentsList1").click(function(){
- layer.msg("请先发送标注任务");
- });
- jQuery(".paperType").click(function(){
- if(testFlag != 1)
- return false;
- var examId = jQuery(this).attr("examId");
- var tpl_index = jQuery(this).attr("tpl_index");
- if(in_array(jQuery(this).attr("tpl_index"), customTplsIds)){
- if(in_array(jQuery(this).attr("tpl_index"), [10,1011,11])){
- var style = "width:200px;color:gray;";
- var state = "disabled";
- }else{
- var style = "width:200px;";
- var state = "enabled";
- }
- }
- else{
- var style = "width:200px;color:gray;";
- var state = "disabled";
- }
- html = ""+
- '<div style="padding:10px 30px">'+
- '<div style="margin:5px 0; float: left">选择纸张:</div>'+
- '<div style="float: left"><select id="paperSize" style="'+style+'" '+state+' >'+
- '<option value="A3" ';
- if(jQuery(this).attr("paper_size")=='A3'){ html=html+'selected';}
- html=html+'>A3</option>'+
- '<option value="A4" ';
- if(jQuery(this).attr("paper_size")=='A4'){ html=html+'selected';}
- html=html+'>A4</option>'+
- '<option value="8K" ';
- if(jQuery(this).attr("paper_size")=='8K'){ html=html+'selected';}
- html=html+'>8K</option>'+
- '<option value="16K" ';
- if(jQuery(this).attr("paper_size")=='16K'){ html=html+'selected';}
- html=html+'>16K</option>'+
- '</select></div>'+
- '<div style="padding-top:10px;clear: left"></div>'+
- '<div style="margin:5px 0; float: left">阅卷方式:</div>'+
- '<div style="float: left"><select id="mark_type" style="width:200px">'+
- '<option value="0" ';
- if(jQuery(this).attr("mark_type")=='0'){ html=html+'selected';}
- html=html+'>线下阅卷</option>'+
- '<option value="1" ';
- if(jQuery(this).attr("mark_type")=='1'){ html=html+'selected';}
- html=html+'>在线阅卷(题)</option> <option value="3" ';
- if(jQuery(this).attr("mark_type")=='3'){ html=html+'selected';}
- html=html+'>班级混合阅卷</option> <option value="4" ';
- if(jQuery(this).attr("mark_type")=='4'){ html=html+'selected';}
- html=html+'>班级单独阅卷</option> '+
- '</select></div>'+
- '<div class="row" style="margin:30px auto;"><button id="confirm" class="label-primary-s bth-s" style="padding:4px 12px;margin:20px 0 0 15px">确定</button>'+
- '<button id="cancel" class="label-primary-s bth-s" style="border:gray;background:gray;padding:4px 12px;margin:20px 0 0 25px">取消</button></div>'+
- '</div>'+
- '</div>'+
- "";
- layer.open({
- type: 1,
- area: ['350px', '220px'],
- title: "更改试卷",
- content: html,
- success: function(index, layerObj){
- jQuery("#cancel").on("click", function(){
- layer.closeAll();
- });
- jQuery("#confirm").on("click", function(){
- var paperSize = jQuery("#paperSize").val();
- var mark_type = jQuery("#mark_type").val();
- jQuery.post(
- "<?php echo $this->createUrl("print/setpapersize");?>",
- {"examId": examId, "paperSize": paperSize,"mark_type":mark_type,"tpl_index":tpl_index},
- function(data){
- data = JSON.parse(data);
- layer.msg(data.message);
- if(data.success == 1){
- setTimeout(function(){location.reload();}, 1300);
- }
- }
- );
- layer.closeAll();
- });
- },
- end: function(){
- }
- });
- });
- // 根据年级筛选班级
- jQuery("#grade").change(function(){
- var grade = $(this).val();
- if (!grade) return false;
- jQuery.post(
- '<?php echo $this->createUrl("print/getGradeClass");?>',{"grade": grade},function(data){
- data = JSON.parse(data);
- if(data.success == 1){
- var classObj = $("#class");
- var html = "<option value=''>全部班级</option>";
- classObj.empty();
- $.each(data.message,function(i,n){
- html += "<option value='"+n.class_id+"'>" + n.class_name + "</option>";
- });
- classObj.append(html);
- }
- }
- );
- });
- });
- </script>
- <style>
- /*切换选择*/
- .tab-con{
- position: relative;
- height: 30px;
- width: 200px;
- background: #F2F2F2;
- border: 1px solid #01B677;
- border-radius: 15px;
- }
- .has-sel{
- background: #01B677;
- color: #fff;
- width: 50%;
- height: 30px;
- border-top-left-radius: 15px;
- border-bottom-left-radius: 15px;
- text-align: center;
- line-height: 30px;
- }
- .sel-opt{
- width: 50%;
- position: relative;
- color: #01B677;
- line-height: 30px;
- text-indent: 6px;
- cursor: pointer;
- }
- .sel-opt:after{
- content: '';
- border-left: 6px solid transparent;
- border-right: 6px solid transparent;
- border-top: 8px solid #01B677;
- position: absolute;
- right: 12px;
- top: 12px;
- }
- // .sel-opt select{
- // width: 100%;
- // height: 30px;
- // background: #F2F2F2;
- // color: #01B677;
- // text-indent: 6px;
- // font-size: inherit;
- // border-top-right-radius: 15px;
- // border-bottom-right-radius: 15px;
- // cursor: pointer;
- // }
- // .sel-opt select option{
- // position: relative;
- // }
- .points{
- position: absolute;
- top: -2px;
- right: 0;
- width: 10px;
- height: 10px;
- background: #F01516;
- border-radius: 50%;
- }
- .sel-cons{
- border: 1px solid #01B677;
- width: 50%;
- position: absolute;
- right: 0;
- top: 30px;
- text-indent: 10px;
- display: none;
- }
- .sc-lis{
- line-height: 30px;
- cursor: pointer;
- }
- .sc-lis span{
- position: relative;
- }
- .sc-lis .points{
- top: 2px;
- right: -16px;
- }
- .click-sc:focus {
- color: #fff;
- }
- .click-sc:hover {
- color: #fff;
- }
- .create-third{
- position: absolute;
- right: 6px;
- top: 10px;
- }
- .dn{display: none}
- </style>
- <style>
- *{margin: 0;padding: 0;}
- .loading-pop{position: fixed;left: 0;top: 0;bottom: 0;right: 0;background: rgba(0,0,0,0.5);z-index: 200;}
- .loading-pop-msg{color: #fff;position: absolute;left: 50%;top: 50%;transform: translate(-50%,-50%);font-size: 22px;letter-spacing: 4px;}
- a:hover, a:focus {
- color: #23527c;
- text-decoration: none;
- }
- @font-face {font-family: "iconfont";
- src: url('/fonts/pdf/iconfont.eot?t=1484561666180'); /* IE9*/
- src: url('/fonts/pdf/iconfont.eot?t=1484561666180#iefix') format('embedded-opentype'), /* IE6-IE8 */
- url('/fonts/pdf/iconfont.woff?t=1484561666180') format('woff'), /* chrome, firefox */
- url('/fonts/pdf/iconfont.ttf?t=1484561666180') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
- url('/fonts/pdf/iconfont.svg?t=1484561666180#iconfont') format('svg'); /* iOS 4.1- */
- }
- .iconfont {
- font-family:"iconfont" !important;
- font-size:16px;
- font-style:normal;
- -webkit-font-smoothing: antialiased;
- -moz-osx-font-smoothing: grayscale;
- }
- /*切换选择*/
- .tab-con{
- position: relative;
- height: 30px;
- width: 200px;
- background: #F2F2F2;
- border: 1px solid #01B677;
- border-radius: 15px;
- }
- .has-sel{
- background: #01B677;
- color: #fff;
- width: 50%;
- height: 30px;
- border-top-left-radius: 15px;
- border-bottom-left-radius: 15px;
- text-align: center;
- line-height: 30px;
- }
- .sel-opt{
- width: 50%;
- position: relative;
- color: #01B677;
- line-height: 30px;
- text-indent: 6px;
- cursor: pointer;
- }
- .sel-opt:after{
- content: '';
- border-left: 6px solid transparent;
- border-right: 6px solid transparent;
- border-top: 8px solid #01B677;
- position: absolute;
- right: 12px;
- top: 12px;
- }
- // .sel-opt select{
- // width: 100%;
- // height: 30px;
- // background: #F2F2F2;
- // color: #01B677;
- // text-indent: 6px;
- // font-size: inherit;
- // border-top-right-radius: 15px;
- // border-bottom-right-radius: 15px;
- // cursor: pointer;
- // }
- // .sel-opt select option{
- // position: relative;
- // }
- .points{
- position: absolute;
- top: -2px;
- right: 0;
- width: 10px;
- height: 10px;
- background: #F01516;
- border-radius: 50%;
- }
- .sel-cons{
- border: 1px solid #01B677;
- width: 50%;
- position: absolute;
- right: 0;
- top: 30px;
- text-indent: 10px;
- display: none;
- }
- .sc-lis{
- line-height: 30px;
- cursor: pointer;
- }
- .sc-lis span{
- position: relative;
- }
- .sc-lis .points{
- top: 2px;
- right: -16px;
- }
- .icon-pdf:before { content: "\e618"; }}
- .fl{float:left;}
- /* 往期教师讲案按钮 */
- .history-teacher-exolaincase-btn{cursor: pointer;background: rgb(21,174,104);color: #fff;width: 130px;height: 28px;margin-left: 20px;text-indent: 10px;}
- .history-teacher-exolaincase-btn img,.history-teacher-exolaincase-btn span{ color: #fff;vertical-align: middle;line-height: 28px;font-size: 12px;}
- .dtw-top-right-btns{float: right;padding-right:10px;}
- .dtw-top-left-cons{float: left;padding-left: 12px;}
- .tabs a{
- margin:5px 10px;
- padding:0 10px;
- line-height: 24px;
- background: #15ae68;
- color: #fff;
- }
- .tabs a.active{
- background: green;
- }
- </style>
- <link rel="stylesheet" href="/fonts/fpdf/iconfont.css" />
- <link rel="stylesheet" href="/fonts/shangchuan/iconfont.css" />
- <div class="main-content-inner">
- <ul class="clearfix main-content-inner-ul">
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("print/index",array('type'=>'wp'));?>"' class="button button_normal button_group button_arrow " data-button="red">打印试卷</button>
- <img src="/images/line.jpg" style="height:45px;" />
- </li>
- <li class="pull-left">
- <!--<button onclick='ccc()' class="button button_normal button_group button_arrow <?php if($printType == 'wtb'){echo 'button_active';}?>" data-button="red">下载错题本</button>-->
- <button onclick='location.href="<?php echo $this->createUrl("print/sub_index",array('type'=>'wtb'));?>"' class="button button_normal button_group button_arrow " data-button="red">下载错题本</button>
- <img src="/images/line.jpg" style="height:45px;" />
- </li>
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("print/sub_index",array('type'=>'isp'));?>"' class="button button_normal button_group button_arrow " data-button="red">下载个性化学习方案</button>
- <img src="/images/line.jpg" style="height:45px;" />
- </li>
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("print/sub_index",array('type'=>'studytrend'));?>"' class="button button_normal button_group button_arrow " data-button="red">下载个性化学习宝</button>
- <img src="/images/line.jpg" style="height:45px;" />
- </li>
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("print/student_product");?>"' class="button button_normal button_group button_arrow " data-button="red">阶段复习个性化学习宝</button>
- <img src="/images/line.jpg" style="height:45px;" />
- </li>
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("third/index");?>"' class="button button_normal button_group button_arrow button_active" data-button="red">第三方试卷</button>
- <img src="/images/line.jpg" style="height:45px;" />
- </li>
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("export/index");?>"' class="button button_normal button_group button_arrow <?php if($printType == ''){echo 'button_active';}?>" data-button="red">导出报告</button>
- <img src="/images/line.jpg" style="height:45px;" />
- </li>
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("upload/index");?>"' class="button button_normal button_group button_arrow" data-button="red">上传试卷</button>
- <img src="/images/line.jpg" style="height:45px;" />
- </li>
- <?php if(isset(Yii::app()->session['testFlag'])&&(Yii::app()->session['testFlag']==1)){
- ?>
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("print/restore");?>"' class="button button_normal button_group button_arrow" data-button="red">还原考试</button>
- <img src="/images/line.jpg" style="height:45px;" />
- </li>
- <?php
- }?>
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("record/importscore"); ?>"'
- class="button button_normal button_group button_arrow " data-button="red">导入成绩
- </button>
- <img src="/images/line.jpg" style="height:45px;"/>
- </li>
- <li class="pull-left">
- <button onclick='location.href="<?php echo $this->createUrl("cylet/index");?>"' class="button button_normal button_group button_arrow" data-button="red">全学科统考</button>
- </li>
- </ul>
- <div class="tabs clearfix">
- <a href="javascript:;" class="fl <?php if(isset($_GET['_tab'])){if($_GET['_tab'] ==0){echo 'active';}}else{echo 'active';}?>" id="_third_shijuan">全学科</a>
- <a href="javascript:;" class="fl <?php if(isset($_GET['_tab'])){if($_GET['_tab'] ==1){echo 'active';}}?>" id="_baogao">导出报告</a>
- <div class="tab-con clearfix pull-right" style="margin:8px 11px 0 0">
- <div class="has-sel fl"><?php echo isset(Yii::app()->params["subjectId"][Yii::app()->session['session_duoxueke_subject_id']])?Yii::app()->params["subjectId"][Yii::app()->session['session_duoxueke_subject_id']]:'数学'?></div>
- <div class="sel-opt fl">
- 切换学科
- <?php if($subject){?>
- <div class="points"></div>
- <?php }?>
- </div>
- <div class="sel-cons" style="z-index:6;background-color: #fff;">
- <div class="sc-lis" val="3"><span>数学<?php if($subject && isset($subject[3]) && !empty($subject[3])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="8"><span>英语<?php if($subject && isset($subject[8]) && !empty($subject[8])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="9"><span>语文<?php if($subject && isset($subject[9]) && !empty($subject[9])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="12"><span>物理<?php if($subject && isset($subject[12]) && !empty($subject[12])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="13"><span>化学<?php if($subject && isset($subject[13]) && !empty($subject[13])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="14"><span>生物<?php if($subject && isset($subject[14]) && !empty($subject[14])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="15"><span>政治<?php if($subject && isset($subject[15]) && !empty($subject[15])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="16"><span>历史<?php if($subject && isset($subject[16]) && !empty($subject[16])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="17"><span>地理<?php if($subject && isset($subject[17]) && !empty($subject[17])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="18"><span>理综<?php if($subject && isset($subject[18]) && !empty($subject[18])){?><div class="points"></div><?php }?></span></div>
- <div class="sc-lis" val="19"><span>文综<?php if($subject && isset($subject[19]) && !empty($subject[19])){?><div class="points"></div><?php }?></span></div>
- </div>
- </div>
- </div>
- <div class="third_shijuan <?php if(isset($_GET['_tab'])){if(isset($_GET['_tab']) && $_GET['_tab']==1){echo 'dn';}}?>">
- <div class="page-content">
- <div class="row" style="margin:0px;">
- <div class="col-xs-12">
- <!-- PAGE CONTENT BEGINS -->
- <div id="dynamic-table_wrapper" class="dataTables_wrapper form-inline no-footer">
- <div class="row">
- <form method="get" id="form1" action="<?php echo $this->createUrl("third/index");?>">
- <div class="col-xs-12">
- <div class="dataTables_length margin-zy">
- <input type="hidden" name="type" value="<?php echo $printType;?>" />
- <input type="hidden" name="_tab" value="<?php if(isset($_GET['_tab'])){echo $_GET['_tab'];}else{echo 0;}?>" />
- <input type="checkbox" name="display" style="margin: -1px 2px 0 0;display:inline-block;vertical-align: middle;width:15px;height:15px;" value="1" <?php if($display === '1') echo "checked";?>>显示隐藏试卷
- <?php if(in_array(Yii::app()->session['session_duoxueke_subject_id'],array(3,6)))
- {
- ?> <select class="form-control" id="labelled" name="labelled">
- <option value="">标注状态</option>
- <option value="0" <?php if($labelled === '0') echo "selected";?> >未发送</option>
- <option value="2" <?php if($labelled == 2) echo "selected";?> >已发送</option>
- <option value="1" <?php if($labelled == 1) echo "selected";?>>已标注</option>
- </select><?php } ?>
- <input type="text" class="form-control input-sm" placeholder="请输入打印任务名称" name="name" value="<?php echo $printName;?>">
- <button class="label-primary-s bth-s" id="search" style="padding:4px 12px;">搜索</button>
- </div>
- </div>
- </form>
- <button onclick='location.href="<?php if(in_array(Yii::app()->session['session_duoxueke_subject_id'],array(3,6))){echo $this->createUrl("third/thirdview");}else{echo $this->createUrl("third/thirdview_duo");}?>"' class="label-primary-s bth-s create-third" data-button="red">创建试卷</button>
- </div>
- <table id="dynamic-table" class="table table-striped table-bordered table-hover dataTable no-footer DTTT_selectable" style="font-size:12px">
- <thead>
- <tr>
- <th>名称</th>
- <th>创建日期</th>
- <th>是否创建答题卡</th>
- <th>选择题量</th>
- <th>填空题量</th>
- <th>解答题量</th>
- <!-- <th>选做题量</th>-->
- <?php if(in_array(Yii::app()->session['session_duoxueke_subject_id'],array(3,6)))
- {
- ?> <th >状态</th><?php } ?>
- <th >操作</th>
- </tr>
- </thead>
- <tbody>
- <?php if(!empty($printList)):foreach($printList as $cl):?>
- <tr>
- <td style="max-width:260px">
- <?php
- if($cl['is_new']==0)
- {
- echo "<span style='color: #ff0000;font-weight: bold;'>【New】</span>";
- }
- ?>
- <?php if( isset(Yii::app()->session['testFlag'])&&(Yii::app()->session['testFlag']==1)){
- ?>
- <a href="<?php echo Yii::app()->createUrl('paper/index',array('eid'=>$cl['exam_id'],'is_third'=>1))?>"><?php echo $cl['exam_name'];?></a>
- <?php }else{
- ?>
- <a href="<?php echo Yii::app()->createUrl('paper/index',array('eid'=>$cl['exam_id'],'is_third'=>1,'tag'=>1))?>"><?php echo $cl['exam_name'];?></a>
- <?php
- }?>
- <!-- <a href="<?php /*echo Yii::app()->createUrl('paper/index',array('eid'=>$cl['exam_id']))*/?>"><?php /*echo $cl['print_name'];*/?></a>-->
- </td>
- <td><?php if(!empty($cl['create_time'])){ echo date('Y-m-d',$cl['create_time']);}?></td>
- <td><?php if(isset($exam_sheets[$cl['exam_group_id']]) && !empty($exam_sheets[$cl['exam_group_id']])){ echo '已创建';}else{echo "未创建";}?></td>
- <td><?php if(isset($sheet_rs[$cl['exam_group_id']]) && !empty($sheet_rs[$cl['exam_group_id']])){
- echo $sheet_rs[$cl['exam_group_id']]->ke_topic_num;
- }else{echo 0;}?></td>
- <td><?php if(isset($sheet_rs[$cl['exam_group_id']]) && !empty($sheet_rs[$cl['exam_group_id']])){
- echo $sheet_rs[$cl['exam_group_id']]->tian_topic_num;
- }else{echo 0;}?></td>
- <td><?php if(isset($sheet_rs[$cl['exam_group_id']]) && !empty($sheet_rs[$cl['exam_group_id']])){
- echo $sheet_rs[$cl['exam_group_id']]->zu_topic_num;
- }else{echo 0;}?></td>
- <!-- <td><?php /*if(isset($sheet_rs[$cl['exam_group_id']]) && !empty($sheet_rs[$cl['exam_group_id']])){
- echo $sheet_rs[$cl['exam_group_id']]->xuan_topic_num;
- }else{echo 0;}*/?></td>-->
- <?php if(in_array(Yii::app()->session['session_duoxueke_subject_id'],array(3,6)))
- {
- ?>
- <td>
- <?php if($cl['is_answersheet']==1){if($cl["is_labelled"] == 1){
- echo "<span style='color:green;font-weight:normal;'>已标注</span>";
- }else if($cl["is_labelled"] == 2 ){
- echo "<span style='color:orange;font-weight:normal;'>已发送</span>";
- }
- if($cl["is_labelled"] == 0 && $cl['tw_status']==2){?>
- <span class="iconfont click-sc addbx sendLabelTask" examId="<?php echo $cl["exam_id"];?>" examName="<?php echo $cl["exam_name"];?>" subjectId="<?php echo $cl["subject_id"];?>" createTime="<?php echo $cl["examDate"];?>" aria-hidden="true" title="发送试题标注"></span>
- <?php }}else{if($cl['tw_status']==2){echo "<span style='color:orange;font-weight:normal;'>解析成功</span>";}elseif($cl['tw_status']==3){echo "<span style='color:orange;font-weight:normal;cursor:pointer' onclick=showError('".$cl['wrong_reason']."')>解析失败</span>";}elseif($cl['word_path']){echo "<span style='color:orange;font-weight:normal;'>等待解析</span>";}else{echo "<span style='color:orange;font-weight:normal;'>上传试卷</span>";}}?>
- </td>
- <?php } ?>
- <td style="width:265px;">
- <span class="iconfont click-sc addbx" aria-hidden="true" title="选择学生" onclick="javascript:location.href='<?php echo $this->createUrl('third/exam_list',array('exam_group_id'=>$cl['exam_group_id']));?>'"></span>
- <?php if(in_array(Yii::app()->session['session_duoxueke_subject_id'],array(3,6)))
- {
- ?>
- <a class="iconfont click-sc addbx create_sheet" aria-hidden="true" title="<?php if(isset($exam_sheets[$cl['exam_group_id']]) && !empty($exam_sheets[$cl['exam_group_id']])){ echo '修改答题卡';}else{echo "创建答题卡";}?>" exam_group_id="<?php echo $cl['exam_group_id']?>" sheet_id ="<?php if(isset($exam_sheets[$cl['exam_group_id']]) && !empty($exam_sheets[$cl['exam_group_id']])){ echo $exam_sheets[$cl['exam_group_id']];}else{echo 0;}?>"></a>
- <!-- <span class="iconfont click-sc addbx" aria-hidden="true" title="创建客观题答案" onclick="javascript:location.href='<?php /*echo $this->createUrl('third/exam_answer',array('exam_group_id'=>$cl['exam_group_id']));*/?>'">答</span>-->
- <span class="iconfont click-sc addbx" aria-hidden="true" title="扫描答题卡" onclick="createTemplate('<?php echo $cl['exam_group_id'];?>')">扫</span>
- <span class="iconfont click-sc addbx" aria-hidden="true" title="上传试卷" onclick="uploadTemplate('<?php echo $cl['exam_group_id'];?>','<?php echo $cl['exam_name'];?>')"></span>
- <?php
- }else{
- ?>
- <a class="iconfont click-sc addbx create_sheet_subject" aria-hidden="true" title="<?php if(isset($exam_sheets[$cl['exam_group_id']]) && !empty($exam_sheets[$cl['exam_group_id']])){ echo '修改答题卡';}else{echo "创建答题卡";}?>" exam_group_id="<?php echo $cl['exam_group_id']?>" sheet_id ="<?php if(isset($exam_sheets[$cl['exam_group_id']]) && !empty($exam_sheets[$cl['exam_group_id']])){ echo $exam_sheets[$cl['exam_group_id']];}else{echo 0;}?>"></a>
- <!-- <span class="iconfont click-sc addbx" aria-hidden="true" title="创建客观题答案" onclick="javascript:location.href='<?php /*echo $this->createUrl('third/exam_answer',array('exam_group_id'=>$cl['exam_group_id']));*/?>'">答</span>-->
- <span class="iconfont click-sc addbx" aria-hidden="true" title="扫描答题卡" onclick="createTemplateSubject('<?php echo $cl['exam_group_id'];?>',<?php echo Yii::app()->session['session_duoxueke_subject_id']?>)">扫</span>
- <?php
- }?>
- <?php if($cl['is_display'] == 1):?>
- <span class="iconfont click-sc click-tc addbx" aria-hidden="true" title="恢复试卷" onclick="oprateExam('<?php echo $cl['exam_group_id'];?>',0)"></span>
- <?php else:?>
- <span class="iconfont click-sc click-delete addbx" aria-hidden="true" title="隐藏试卷" onclick="oprateExam('<?php echo $cl['exam_group_id'];?>',1)"></span>
- <?php endif;?>
- </td>
- </tr>
- <?php endforeach;else:?>
- <tr><td colspan="8">暂无数据!</td></tr>
- <?php endif;?>
- </tbody>
- </table>
- <?php if(!empty($page_total)):?>
- <div class="row">
- <div class="col-xs-6">
-
- </div>
- <div class="col-xs-6">
- <div class="dataTables_paginate paging_simple_numbers">
- <?php
- $this->widget('CLinkPager', array(
- 'header' => '',
- 'firstPageLabel'=> '首页',
- 'lastPageLabel' => '末页',
- 'prevPageLabel' => '上一页',
- 'nextPageLabel' => '下一页',
- 'pages' => $pages,
- 'maxButtonCount'=> 5,
- ));
- echo '共:'.$page_total.'条';
- ?>
- </div>
- </div>
- </div>
- <?php endif;?>
- </div>
- <!--上传模板弹窗-->
- <!-- PAGE CONTENT ENDS -->
- </div>
- </div>
- </div>
- </div>
- <div class="baogao <?php if(!isset($_GET['_tab'])){echo 'dn';}else{if(isset($_GET['_tab']) && $_GET['_tab']==0){echo 'dn';}}?>">
- <div class="page-content" >
- <div class="row" style="margin:0px;">
- <div class="col-xs-12">
- <!-- PAGE CONTENT BEGINS -->
- <div id="dynamic-table_wrapper" class="dataTables_wrapper form-inline no-footer">
- <div class="row">
- <form method="get" action="<?php echo $this->createUrl('third/index'); ?>" style="padding-left: 0px;">
- <input type="hidden" name="_tab" value="<?php if(isset($_GET['_tab'])){echo $_GET['_tab'];}else{echo 0;}?>" />
- <div class="dtw-top-left-cons">
- <div class="dataTables_length margin-zy">
- <div class='diy_select1' style="display: inline;margin-right: 5px;border: 1px solid #c9ccd2;">
- <input type='hidden' id="grade_id" name="grade_id" class='diy_select_input1' value="<?php if (empty($grade_id)) {
- echo 0;
- } else {
- echo $grade_id;
- } ?>"/>
- <div class='diy_select_txt1'><?php
- if (empty($grade_id)) {
- echo '请选择年级';
- } else {
- switch ($grade_id) {
- case 1:echo '高一';
- break;
- case 2:echo '高二';
- break;
- case 3:echo '高三';
- break;
- }
- }
- ?></div>
- <div class='diy_select_btn1'></div>
- <ul class='diy_select_list1'>
- <li val="0" >请选择年级</li>
- <li val="1">高一</li>
- <li val="2">高二</li>
- <li val="3">高三</li>
- </ul>
- </div>
- <div class='diy_select'>
- <input type='hidden' id="class_id" name="class_id" class='diy_select_input' value="<?php if (empty($grade_id) || empty($grade_class) || empty($class_id)) {
- echo 0;
- } else {
- echo $class_id;
- } ?>"/>
- <div class='diy_select_txt'><?php if (empty($grade_id) || empty($class_id) || empty($grade_class)) {
- echo '请选择班级';
- } else {
- if (isset($grade_class[$class_id]) && !empty($grade_class[$class_id])) {
- echo $grade_class[$class_id]['class_name'];
- }
- } ?></div>
- <div class='diy_select_btn'></div>
- <ul class='diy_select_list'>
- <li val="0">请选择班级</li>
- <?php if (empty($grade_id) || empty($grade_class)) {
- echo '';
- } else {
- foreach ($grade_class as $v) {
- ?>
- <li val="<?php echo $v['class_id'] ?>"><?php echo $v['class_name'] ?></li>
- <?php }
- } ?>
- </ul>
- </div>
- <input type="text" class="form-control input-sm" placeholder="请输入报告名称!" name="realname1" value="<?php if (!empty($realname1)) {
- echo $realname;
- } ?>">
- <!--<button class="btn btn-minier btn-primary">搜索</button>-->
- <button class="label-primary-s bth-s" id="search" style="padding:4px 12px;">搜索</button>
- </div>
- </div>
- </form>
- <?php if ((isset(Yii::app()->session['session_duoxueke_subject_id']) && Yii::app()->session['session_duoxueke_subject_id'] == 3) || (isset(Yii::app()->session['session_duoxueke_subject_id']) && Yii::app()->session['session_duoxueke_subject_id'] == 6)) { ?>
- <div class="dtw-top-right-btns mt15" >
- <?php if ($past_sem_exist):?>
- <div class="history-teacher-exolaincase-btn fl">
- <img src="/images/download.png" alt="" class="" href="">
- <a href="<?php echo Yii::app()->createUrl('export/pastacdemicrs');?>"><span>往期教师讲案</span></a>
- </div>
- <?php endif;?>
- <div id="dynamic-table_filter" class="dataTables_filter position_g fl" >
- <a class="btn btn-success btn-sm" href="<?php echo Yii::app()->createUrl('export/statistics') ?>">
- <i class="fa fa-plus " style="font-style: normal;"></i> 校长专用分析报告
- </a>
- </div>
- </div>
- <?php }?>
- </div>
- <table id="dynamic-table" class="table table-striped table-bordered table-hover dataTable no-footer DTTT_selectable">
- <thead>
- <tr>
- <th width="50%">名称</th>
- <th width="10%">班级</th>
- <?php if(in_array(Yii::app()->session['session_duoxueke_subject_id'],array(3,6))){
- ?>
- <th width="10">错题文档</th>
- <?php
- }?>
- <th width="30%">操作</th>
- </tr>
- </thead>
- <tbody>
- <?php if (!empty($printList1)):foreach ($printList1 as $cl): ?>
- <tr>
- <td><?php echo $cl['print_name']; ?></td>
- <td><?php echo $cl['class_name']; ?></td>
- <?php if(in_array(Yii::app()->session['session_duoxueke_subject_id'],array(3,6))){
- ?>
- <td><span style="color: #15ae68;font-weight: bold">
- <?php if ($cl['is_topwb_html'] == 0 || $cl['is_topwb_html'] == 90) {
- echo '未生成';
- } elseif ($cl['is_topwb_html'] == 1 && $cl['is_topwb_pdf'] == 0) {
- echo "正在生成中";
- } elseif ($cl['is_topwb_pdf'] == 1) {
- echo '已生成';
- } elseif ($cl['is_topwb_pdf'] == 9){
- echo '已删除';
- };
- ?>
- </span>
- </td>
- <?php
- }?>
- <td>
- <?php if ($this->schoolManager->classExamHasPaperRs($cl['exam_id'], $cl['class_id'])): ?>
- <!-- <a class="green" style="margin-left:4px;" href="<?php /*echo $this->createUrl("export/excel?examId={$cl['exam_id']}&classId={$cl['class_id']}&type=word&is_outer=0"); */?>">
- <span class="fa fa-file-word-o click-sc addbx" style="padding:0.5px 9px" aria-hidden="true" title="导出Word(精简)"></span>
- </a>-->
- <a class="green setEduce" style="margin-left:4px;" href="#" exam_id ="<?php echo $cl['exam_id']?>" file_type="word">
- <span class="fa fa-file-word-o click-sc addbx" style="padding:0.5px 9px" aria-hidden="true" title="导出Word"></span>
- </a>
- <a class="green setEduce" style="margin-left:4px" href="#" exam_id ="<?php echo $cl['exam_id']?>" file_type="excel">
- <span class="fa fa-file-excel-o click-sc addbx" style="padding:0.5px 9px" aria-hidden="true" title="导出Excel"></span>
- </a>
- <?php if(in_array(Yii::app()->session['session_duoxueke_subject_id'],array(3,6))){
- ?>
- <?php if ($cl['is_topwb_pdf'] == 1) { ?>
- <a class="green" style="margin-left:4px" href="<?php echo Yii::app()->createUrl('export/download', array('exam_id' => $cl['exam_id'])); ?>">
- <span class="fa fa-file-pdf-o click-sc addbx" style="padding:0.5px 9px" aria-hidden="true" title="下载错题前十"></span>
- </a>
- <?php } ?>
- <a class="green" style="margin-left:4px" onclick="downpdf('<?php echo $cl['exam_id'] ?>', '<?php echo $cl['class_id'] ?>')" href="javascript:void(0);">
- <span class="fa fa-file-pdf-o click-sc addbx" style="padding:0.5px 9px" aria-hidden="true" title="下载教师讲案"></span>
- </a>
- <?php if(isset(Yii::app()->session['testFlag'])&&(Yii::app()->session['testFlag']==1)){ ?>
- <?php if($cl['is_academicr_pdf']=='1'&&$cl['academicr_pdf_path']!=""){ ?>
- <span class="iconfont click-sc addbx" aria-hidden="true" title="重新生成教师讲案" onclick="reloadAcademicr('<?php echo $cl['exam_id']; ?>',1,this)"></span>
- <?php } ?>
- <span class="iconfont click-sc addbx" aria-hidden="true" title="重新生成错题前十" onclick="reloadAcademicr('<?php echo $cl['exam_id']; ?>',2,this)"></span>
- <?php } }?>
- <?php else: ?>
- <a style="margin-left:10px">
- <span class="iconfont click-sc addbx" aria-hidden="true" title="数据异常"></span>
- </a>
- <?php endif; ?>
- </td>
- </tr>
- <?php endforeach;
- else: ?>
- <tr><td colspan="4">暂无数据!</td></tr>
- <?php endif; ?>
- </tbody>
- </table>
- <?php if (!empty($page_total1)): ?>
- <div class="row" style="padding-top:10px;">
- <div class="col-xs-7">
-
- </div>
- <div class="col-xs-5" style="font-size: 16px">
- <div class="dataTables_paginate paging_simple_numbers" style="vertical-align:sub;">
- <?php
- $this->widget('CLinkPager', array(
- 'header' => '',
- 'firstPageLabel' => '首页',
- 'lastPageLabel' => '末页',
- 'prevPageLabel' => '上一页',
- 'nextPageLabel' => '下一页',
- 'pages' => $pages1,
- 'maxButtonCount' => 5,
- ));
- echo '<span style="vertical-align:middle;">共:' . $page_total1 . '条</span>';
- ?>
- </div>
- </div>
- </div>
- <?php endif; ?>
- </div>
- <!-- PAGE CONTENT ENDS -->
- </div>
- </div>
- </div>
- </div>
- </div>
- <div class="loading-pop" style="display:none;">
- <div class="loading-pop-msg">正在生成中,请稍候···</div>
- </div>
- <style>
- *{padding:0px;margin:0px;font-family:微软雅黑}
- ul,li,ol{list-style-type:none;}
- .clearfix:after{clear:both;overflow:hidden;content:"";display:block;}
- input ,button{outline:none;}
- .position-r{position:relative}
- .fl{float:left;}
- .fr{float:right;}
- .mt5{margin-top:5px;}
- .mt10{margin-top:10px;}
- .mt20{margin-top:20px;}
- .ml15{margin-left:15px;}
- .mr15{margin-right:15px;}
- .font_bold{font-weight:bold;}
- .choseImg{cursor:pointer;}
- .ttd{background:url(/images/back-d.png) center repeat;width:100%;height:100%;position:fixed;top:0px;z-index:999}
- .s-state{width:380px;background:#fff;margin:12% auto 0 auto;}
- .hint_size{height:45px;width:90%;color:#333;line-height:45px;margin:0px auto;border-bottom:1px solid #ccc;}
- .mistake_character{text-align:left;color:#606060;font-size:14px;padding:0px 0px 28px 0px;width:90%;margin:0px auto;}
- .roger{width:100px;height:35px;border:1px solid #15ae68;background:#15ae68;color:#fff;font-size:16px;cursor:pointer;}
- .rogergb{background:#ccc;border:1px solid #ccc;}
- .allTeacher{width:164px;height:30px;border:1px solid #ccc;border-radius:6px;margin-top:10px;}
- button.wordBtn{background:#50d2c2;color:#fff;width:120px;height:30px;border:1px solid #50d2c2;cursor:pointer;border-radius:4px;margin-left: 15px;}
- </style>
- <div class="ttd" style="display: none;">
- <div class="s-state clearfix posirela">
- <div class="hint_size clearfix">
- <span class="fl ml15">下载的学情分析报告是否需要下列数据</span>
- </div>
- <div class="mistake_character clearfix" style="padding-top: 10px; padding-bottom: 0;">
- <label class="ml15 fl" style="line-height:37px"><input type="checkbox" name="student_card" style="margin-right: 5px;margin-top: 0; vertical-align: middle; width: 17px;height: 17px;">系统准考证号</label>
- </div>
- <div class="mistake_character clearfix" style="padding-top: 0; padding-bottom: 0px;">
- <label class="ml15 fl" style="line-height:37px"><input type="checkbox" name="school_student_card" style="margin-right: 5px;margin-top: 0; vertical-align: middle; width: 17px;height: 17px;">学校准考证号</label>
- </div>
- <div class="mistake_character clearfix" style="padding-top: 0; padding-bottom: 10px;">
- <label class="ml15 fl" style="line-height:37px"><input type="checkbox" name="is_outer" style="margin-right: 5px;margin-top: 0; vertical-align: middle;width: 17px;height: 17px;">是否只显示在籍生</label>
- </div>
- <div class="mistake_character clearfix">
- <div class="clearfix" style="width:300px;margin:0px auto;">
- <input type="hidden" name="exam_id" value="0">
- <input type="hidden" name="file_type" value="">
- <p class="fl"><button class="roger shut" id="btnSubmit">确定</button></p>
- <p class="fr"><button class="roger shut rogergb" id="btnClose">取消</button></p>
- </div>
- </div>
- </div>
- </div>
- <script type="text/javascript">
- function reloadAcademicr(examId,type,obj){
- $.get("<?php echo $this->createUrl("export/reload_academicr") ?>", {examId: examId, type: type}, function(data) {
- var m = JSON.parse(data);
- if (m.status == 0)
- {
- alert('重置成功');
- $(obj).hide()
- }
- });
- }
- function downpdf(examId, classId) {
- $(".loading-pop").show();
- $.get("<?php echo $this->createUrl("export/academicr") ?>", {examId: examId, classId: classId}, function(data) {
- var m = JSON.parse(data);
- if (m.status == 0)
- {
- if (m.is_create == 1) {
- setTimeout(function() {
- $(".loading-pop").hide();
- }, 500);
- } else {
- $(".loading-pop").hide();
- }
- location.href="<?php echo $this->createUrl("export/down_load")?>?examId="+examId;
- } else
- {
- setTimeout(function() {
- $(".loading-pop").hide();
- }, 500);
- layer.msg(m.error)
- // alert(m.error);
- }
- });
- }
- $(document).ready(function() {
- /*var str = '<div class="points"></div>';
- $(".sc-lis").each(function(){
- if($(this).find(".points").length>0){
- $(".sel-opt").append(str);
- }
- });*/
- $("#btnClose").click(function(){
- $(this).parents(".ttd").fadeOut();
- });
- $(".shut").click(function(){
- $("body").css({height :"100%",overflow:"auto"});
- });
- $(".setEduce").click(function(){
- var tp = $(".ttd");
- var lq = $(window).height();
- $("#btnSubmit").removeAttr('disabled');
- $("input[name=exam_id]").val($(this).attr('exam_id'));
- $("input[name=file_type]").val($(this).attr('file_type'));
- tp.fadeIn();
- $("body").css({height : lq+"px",overflow:"hidden"});
- });
- $(".sel-opt,.sel-cons").mouseover(function(){
- $(".sel-cons").show();
- }).mouseout(function(){
- $(".sel-cons").hide();
- });
- $(".sc-lis").click(function(){
- var data = {
- subjectId : $(this).attr('val')
- };
- $.post("<?php echo Yii::app()->createUrl('third/setSubjectId')?>",data,function(flags){
- if(flags)
- {
- var url = "/index.php/third/index?_tab="+$("input[name=_tab]").val();
- location.href = url;
- }else
- {
- alert('网络异常');
- }
- });
- $('.has-sel').text($(this).text());
- $(".sel-cons").hide();
- });
- $("body").delegate("#btnSubmit","click",function(){
- var student_card = 0;
- var is_outer = 0;
- var school_student_card = 0;
- var exam_id = "";
- var file_type = "";
- exam_id = $("input[name=exam_id]").val();
- file_type = $("input[name=file_type]").val();
- if(!exam_id || !file_type)
- {
- layer.msg('参数有误!');return false;
- }
- if($("input[name=student_card]").is(':checked'))
- {
- student_card = 1;
- }
- if($("input[name=school_student_card]").is(':checked'))
- {
- school_student_card = 1;
- }
- if($("input[name=is_outer]").is(':checked'))
- {
- is_outer = 1;
- }
- var data ={
- exam_id:''+exam_id+'',
- file_type:file_type,
- student_card:student_card,
- school_student_card:school_student_card,
- is_outer:is_outer
- };
- $("#btnSubmit").attr('disabled','disabled');
- $.post("<?php echo Yii::app()->createUrl('export/ajax_down') ?>", data, function(flags) {
- var m = JSON.parse(flags);
- if(m.status)
- {
- $("#btnClose").parents(".ttd").fadeOut();
- location.href = m.result;
- }else
- {
- layer.msg(m.result);
- $(this).parents(".ttd").fadeOut();
- return false;
- }
- })
- })
- });
- function ccc() {
- layer.msg('敬请期待!', {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index) {
- layer.close(index);
- return false;
- }
- });
- }
- $(function() {
- $(".diy_select1").click(function() {
- var grade = $(".diy_select1 input[class=diy_select_input1]").val();
- if (grade == 0)
- {
- $(".diy_select input[class=diy_select_input]").val(0);
- $(".diy_select_txt").text("请选择班级");
- $(".diy_select_list li").text("请选择班级");
- $(".diy_select_list li").attr("val", 0);
- }
- $.post("<?php echo $this->createUrl('classes/getclass'); ?>", {grade_id: grade}, function(data) {
- var m = JSON.parse(data);
- if (m.status == 0)
- {
- $(".diy_select input[class=diy_select_input]").val(0);
- $(".diy_select_txt").text("请选择班级");
- $(".diy_select_list").empty();
- var html = '<li val="0">请选择班级</li>';
- $(".diy_select_list").html(html);
- } else {
- $(".diy_select input[class=diy_select_input]").val(0);
- $(".diy_select_txt").text("请选择班级");
- $(".diy_select_list").empty();
- var html = '<li val="0">请选择班级</li>';
- $.each(m.result, function(i, n) {
- html += '<li val="' + n.class_id + '">' + n.class_name + '</li>';
- });
- $(".diy_select_list").html(html);
- }
- });
- });
- });
- </script>
- <script src="/js/jquery.ajaxfileupload.js"></script>
- <script type="text/javascript">
- $(document).ready(function(){
- $("#_third_shijuan").click(function(){
- $(this).addClass('active');
- $("#_baogao").removeClass('active');
- $(".baogao").hide();
- $(".third_shijuan").show();
- $("input[name=_tab]").val(0);
- });
- $("#_baogao").click(function(){
- $(this).addClass('active');
- $("#_third_shijuan").removeClass('active');
- $(".third_shijuan").hide();
- $(".baogao").show();
- $("input[name=_tab]").val(1);
- });
- $(".ruanyun").click(function(){
- var exam_id = $(this).attr('exam_id');
- layer.msg("确定发送吗?学生是否全部上传成绩", {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- $.ajax({
- url: "<?php echo $this->createUrl('print/send_ruanyun_pdf');?>",
- type: "POST",
- dataType: "json",
- data:{ examId: exam_id
- },
- success: function (data){
- if(data.status == 1){
- layer.msg('发送成功',{
- icon: 1
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }else if(data.status == 2){
- layer.msg('发送失败,未上传成绩',{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }else{
- layer.msg('发送失败',{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- },
- error: function (data, status, e){ //服务器响应失败处理函数
- layer.msg('返回失败!',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- });
- }
- });
- });
- $(".create_sheet").click(function(){
- var exam_group_id = $(this).attr("exam_group_id");
- var sheet_id = $(this).attr("sheet_id");
-
- if(exam_group_id>0){
- $.post("<?php echo Yii::app()->createUrl('third/set_new')?>",{exam_group_id:exam_group_id});
- $.post("<?php echo Yii::app()->createUrl('third/verify_exam_rs')?>",{exam_group_id:exam_group_id},function(rs){
- var m = JSON.parse(rs);
- if(m.status==1)
- {
- layer.msg('已上传成绩,无法修改!',{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- if(m.status==3)
- {
- layer.msg('已发送标注,无法修改!',{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- if(m.status==2)
- {
- layer.msg('非法考试!',{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- if(m.status==0)
- {
- evaluationClient.createAnswerSheet(sheet_id+","+exam_group_id);
- }
- });
- }
- });
- $(".create_sheet_subject").click(function(){
- var exam_group_id = $(this).attr("exam_group_id");
- var sheet_id = $(this).attr("sheet_id");
- if(exam_group_id>0){
- $.post("<?php echo Yii::app()->createUrl('third/set_new')?>",{exam_group_id:exam_group_id});
- $.post("<?php echo Yii::app()->createUrl('third/verify_exam_rs')?>",{exam_group_id:exam_group_id},function(rs){
- var m = JSON.parse(rs);
- if(m.status==1)
- {
- layer.msg('已上传成绩,无法修改!',{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- if(m.status==3)
- {
- layer.msg('已发送标注,无法修改!',{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- if(m.status==2)
- {
- layer.msg('非法考试!',{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- if(m.status==0)
- {
- evaluationClient.createAnswerSheet(sheet_id+","+exam_group_id+",<?php echo Yii::app()->session['session_duoxueke_subject_id']?>");
- }
- });
- }
- });
- });
- function showError(str)
- {
- layer.msg(str,{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- function objToJson(obj){
- var json = "{ ";
- for(var item in obj){
- json += "'"+item+"':'"+obj[item]+"',";
- }
- json += " }";
- return json;
- }
- function ccc(){
- layer.msg('敬请期待!', {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- return false;
- }
- });
- }
- function delExam(odj){
- if (!odj) return false;
- var classId = odj.getAttribute("w_class_id");
- var examId = odj.getAttribute("w_exam_id");
- if (!classId || !examId) return false;
- var msg = '您确定要删除此班的考试吗?';
- layer.msg(msg, {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- $.ajax({
- url: "<?php echo $this->createUrl('print/delexam');?>",
- type: "POST",
- dataType: "json",
- data: {
- examId: examId,
- classId:classId
- },
- success: function (data){
- if(data.status == 1){
- layer.msg('删除成功',{
- icon: 1
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }else{
- layer.msg('删除失败',{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- },
- error: function (data, status, e){ //服务器响应失败处理函数
- layer.msg('返回失败!',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- });
- }
- });
- }
- // 确认上传成绩
- function uploadConfirm(classId, examId,className,is_uploaded_count,students_count) {
- //if (confirm('您确定已上传成绩了吗?')) {
- msg = "<div style='text-align:left;'>("+className+")已上传(<span style=' font-size:20px;color:#15ae68 ;font-weight: bold'>"+is_uploaded_count+"</span>)份试卷,还有(<span style='font-size:20px;color: red;font-weight: bold'>"+(students_count-is_uploaded_count)+"</span>)份试卷未上传!是否确认本班级试卷都已上传?<br/><br/><span style='color: red'>请注意!试卷上传确认后将不能再次上传本班的试卷!!!</span></div>";
- layer.msg(msg, {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index, layerObj){
- layer.close(index);
- $.ajax({
- url: "<?php echo $this->createUrl('print/uploadConfirm');?>",
- type: "POST",
- data: {
- classId: classId,
- examId: examId
- },
- beforeSend:function(){
- // 发送请求显示打印中
- layer.msg('确认中...', {time: 20000});
- },
- dataType: "JSON",
- success: function(data) {
- if (data.status == 1) {
- layer.msg('确认成功!');
- setTimeout(function(){location.reload();}, 1300);
- } else {
- layer.msg(data.error);
- }
- },
- complete:function(){
- },
- error:function(){
- }
- });
- }
- });
- //}
- }
- // 打印错题本
- function printBook(cid,eid,type){
- if (!cid || !eid || !type) {
- layer.msg("打印参数有误");return;
- }
- var message = '';
- var objUrl = '';
- if (type == 1) {
- message = "您确定要下载该班级纠错本吗?";
- objUrl = "<?php echo $this->createUrl('print/downloadwrongtopic');?>";
- divTitle = "下载错题本";
- improveName = "错题本";
- } else if (type == 2){
- message = "您确定要下载该班级个性化学习方案吗?";
- objUrl = "<?php echo $this->createUrl('print/downloadraisescheme');?>";
- divTitle = "下载个性化学习方案";
- improveName = "个性化学习方案";
- }else if (type == 3){
- message = "您确定要下载该班级个性化学习宝吗?";
- objUrl = "<?php echo $this->createUrl('print/downloadraisescheme');?>";
- divTitle = "下载个性化学习宝";
- improveName = "个性化学习宝";
- }
- else{
- layer.msg("打印参数有误");return;
- }
- html = ""+
- '<div style="padding:20px 30px 0px 30px">'+
- '<div style="padding:8px 0;">请复制下方链接下载'+improveName+'。</div>'+
- '<div id="downloadUrl" style="white-space:nowrap;overflow:hidden;text-overflow:ellipsis;width:455px;"></div>'+
- '<div class="row" style="margin:30px auto 0px auto;text-align:center"><button id="confirm" class="label-primary-s bth-s" style="padding:4px 12px;margin:5px 0 10px 15px;background:gray;border-color:gray;">关闭</button>'+
- '</div>'+
- '</div>'+
- "";
- layer.msg(message, {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- msgIndex = layer.msg("下载中请稍后...", {"time": 3600000});
- // 更试卷打印时间
- $.post("<?php echo $this->createUrl('print/updatepaperprinttime');?>", {cid: cid, eid: eid,type:type } );
- /*if(type == 1)
- location.href = objUrl+"/cid/"+cid+"/eid/"+eid;
- else
- location.href = objUrl+"/cid/"+cid+"/eid/"+eid+"/type/"+type;*/
- startTime = (new Date()).getTime();
- showTip = true;
- tipShowed = false;
- toPromptTime = 3000;
- window.interval = setInterval(function(){
- execTime = (new Date()).getTime() - startTime;
- if(execTime > toPromptTime && showTip && !tipShowed){
- // msgIndex = layer.msg("该文件较大,请耐心等待...", {"time": 3600000});
- // tipShowed = true;
- }
- }, 1000);
- jQuery.get(
- "<?php echo $this->createUrl("print/getImproveFile");?>",
- {"examId": eid, "classId": cid, "type": type},
- function(data){
- data = JSON.parse(data);
- if(data.success == 1||data.success == 2){
- layer.open({
- type: 1,
- area: ['550px', '220px'],
- title: divTitle,
- content: html,
- success: function(index, layerObj){
- clearInterval(window.interval);
- msgIndex = layer.msg(data.limitinfo, {"time": 3000});
- clearInterval(window.interval);
- layer.close(msgIndex);
- jQuery("#downloadUrl").html('下载地址:<span style=""><input id="url" type="text" size="40" readonly value="'+data.downloadPath+'" /></span><button id="copy" class="label-primary-s bth-s" style="padding:4px 12px;margin:5px 0 10px 15px;">全选</button>');
- jQuery("#confirm, #cancel").on("click", function(){
- layer.close(layerObj);
- });
- jQuery("#copy").on("click", function(){
- jQuery("#url").select();
- });
- },
- end: function(){
- }
- });
- }
- else if(data.success == 0){
- clearInterval(window.interval);
- msgIndex = layer.msg(data.message, {"time": 3000});
- }
- }
- );
- }
- });
- }
- // 上传试卷模板
- function uploadTemplate(eid,name){
- if (!eid) {
- layer.msg('操作失败!');
- return false;
- }
- forCheckUrl = "<?php echo $this->createUrl('third/checkanswercard');?>";
- $.post(forCheckUrl,{eid:eid},function(data){
- var obj = JSON.parse(data);
- if(obj.success==1)
- {
- var html ='<div class="layer_notice" style="padding:5px;">';
- html +='<table class="table table-striped table-bordered table-hover ">';
- html +='<thead class="thin-border-bottom">';
- html +='<tr>';
- html +='<th>试卷名称</th>';
- html +='<th>操作</th>';
- html +='</tr>';
- html +='</thead>';
- html +='<tbody class="content_tbody">';
- html +='<td>'+name+'</td><td><input type="file" name="word_file" id="word_file" /></td></tr>';
- html +='</tbody>';
- html +='</table>';
- html +='<span style="width:582px;display:inline-block;text-align:center;">';
- html +='<button class="btn btn-success btn-sm" onclick="uploadWord()"><i class="ace-icon fa fa-check bigger-110"></i>确定</button>';
- html +='</span>';
- html +='<input type="hidden" id="mpEGid" value="'+eid+'">';
- html +='</div>';
- layer.open({
- type: 1,
- skin: 'layui-layer-rim', //加上边框
- area: ['600px', '300px'], //宽高
- content: html
- });
- }else
- {
- layer.msg(obj.message,{
- icon: 5
- }, function(){
- layer.closeAll();
- location.reload();
- });
- //layer.msg(obj.message);
- }
- });
- }
- function uploadWord() {
- var paramEid = $('#mpEGid').val();
- if (!paramEid) {
- layer.msg('没找到考试ID!');
- return false;
- }
- var obj_file = $("#word_file").val();
- if (!obj_file) {
- layer.msg('请选择上传文件');
- return false;
- }
- var extStart = obj_file.lastIndexOf('.');
- var extName = obj_file.substring(extStart,obj_file.length).toLowerCase();
- if (extName != ".docx" && extName != ".dotx" && extName != ".dotm") {
- layer.msg('模板格式有误,请上传dotx格式word!');
- return false;
- }
- $.ajaxFileUpload({
- url: "<?php echo $this->createUrl('third/uploadTpl');?>", //用于文件上传的服务器端请求地址
- secureuri: false, //是否需要安全协议,一般设置为false
- fileElementId: 'word_file', //文件上传域的ID
- dataType: 'text', //返回值类型 一般设置为json
- data:{"eid":paramEid},
- success: function (data, status){
- var obj = JSON.parse(data);
- if (obj.success == 1) {
- layer.msg(obj.message,{
- icon: 1,
- }, function(){
- layer.closeAll();
- location.reload();
- });
- $("#alreadUpload").html('<span style="color:red;">已上传</span>');
- } else {
- layer.msg(obj.message,{
- icon: 1,
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- },
- error: function (data, status, e){ //服务器响应失败处理函数
- layer.msg('返回失败!',{
- icon: 1,
- }, function(){
- layer.closeAll();
- location.reload();
- });
- }
- });
- return false;
- }
- // 搜索事件
- $("#search").click(function(){
- $("#form1").submit();
- });
- function print(cid,eid,tid,fg){
- if (!cid || !eid) return false;
- var msg = '';
- if (tid == 0) {
- if (fg == 1) {
- msg = '打印答题卡';
- } else {
- msg = '您确定要打印该试卷嘛?';
- }
- } else if (tid == 1) {
- msg = '您确定要打印该错题本嘛?';
- } else if (tid == 2) {
- msg = '您确定要打印该个性化学习宝吗?';
- }
- layer.msg(msg, {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- ajaxPrint(cid, eid, tid);
- }
- });
- }
- function ajaxPrint(cid, eid, tid) {
- $.ajax({
- url:"<?php echo $this->createUrl('print/ajaxupdate');?>",
- type:"post",
- data:{cid:cid,eid:eid,tid:tid},
- dataType: "json",
- beforeSend:function(){
- // 发送请求显示打印中
- layer.msg('打印中', {icon: 16,time: 20000});
- },
- success:function(obj){
- var index = layer.msg();
- layer.close(index);
- if (obj.success == 1) {
- if (tid == 0) {//console.log(JSON.stringify(obj.message));
- evaluationClient.printPaper(JSON.stringify(obj.message));
- //alert('提交打印试卷成功!');
- } else if (tid == 1) {
- evaluationClient.printCTB(JSON.stringify(obj.message));
- //alert('提交打印错题本成功!');
- } else if (tid == 2) {
- evaluationClient.printTFFA(JSON.stringify(obj.message));
- //alert('提交打印提分册成功!');
- } else {
- layer.msg('操作错误!');
- }
- location.reload();
- } else {//alert(obj.message);
- layer.msg(obj.message);
- }
- },
- complete:function(){
- //layer.msg('打印失败!');
- //var index = layer.msg();
- //layer.close(index);
- },
- error:function(){
- //var index = layer.msg();
- //layer.close(index);
- }
- });
- }
- // 生成试卷模板
- function createTemplate (exam_group_id){
- if (!exam_group_id) {
- layer.msg('未找到试卷ID');
- }
- var data={
- exam_group_id:exam_group_id
- }
- $.post("<?php echo Yii::app()->createUrl("third/paper")?>",data,function(rs){
- var m = JSON.parse(rs);
- if(m.status==1)
- {
- evaluationClient.loadThirdParty(exam_group_id);
- }else {
- layer.msg('尚未创建答题卡,请创建');
- }
- });
- }
- // 生成试卷模板
- function createTemplateSubject (exam_group_id,subject){
- if (!exam_group_id||!subject) {
- layer.msg('未找到试卷ID');
- }
- var data={
- exam_group_id:exam_group_id
- }
- $.post("<?php echo Yii::app()->createUrl("third/paper")?>",data,function(rs){
- var m = JSON.parse(rs);
- if(m.status==1)
- {
- evaluationClient.loadThirdParty(exam_group_id+','+subject);
- }else {
- layer.msg('尚未创建答题卡,请创建');
- }
- });
- }
- function wb_html(odj){
- if (!odj) return false;
- var classId = odj.getAttribute("w_class_id");
- var examId = odj.getAttribute("w_exam_id");
- if (!classId || !examId) return false;
- var msg = '您确定要生成该班级的错题本吗?';
- layer.msg(msg, {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- $.ajax({
- url: "<?php echo $this->createUrl('client/wbhtml');?>",
- type: "POST",
- dataType: "json",
- data: {
- examId: examId,
- classId:classId
- },
- success: function (data){
- if(data > 0){
- layer.msg('操作成功,重新生成错题本',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }else if(data==0){
- layer.msg('操作失败,此班无错题本',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- else{
- layer.msg('操作失败,重新生成错题本',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- },
- error: function (data, status, e){ //服务器响应失败处理函数
- layer.msg('返回失败!',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- });
- }
- });
- }
- function isp2_html(odj){
- if (!odj) return false;
- var classId = odj.getAttribute("w_class_id");
- var examId = odj.getAttribute("w_exam_id");
- if (!classId || !examId) return false;
- var msg = '您确定要生成该班级的二步提分方案吗?';
- layer.msg(msg, {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- $.ajax({
- url: "<?php echo $this->createUrl('client/isp2html');?>",
- type: "POST",
- dataType: "json",
- data: {
- examId: examId,
- classId:classId
- },
- success: function (data){
- if(data > 0){
- layer.msg('操作成功,重新生成提分方案',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }else if(data==0){
- layer.msg('操作失败,此班无提分方案',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- else{
- layer.msg('操作失败,重新生成提分方案',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- },
- error: function (data, status, e){ //服务器响应失败处理函数
- layer.msg('返回失败!',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- });
- }
- });
- }
- function isp3_html(odj){
- if (!odj) return false;
- var classId = odj.getAttribute("w_class_id");
- var examId = odj.getAttribute("w_exam_id");
- if (!classId || !examId) return false;
- var msg = '您确定要生成该班级的个性化学习宝吗?';
- layer.msg(msg, {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- $.ajax({
- url: "<?php echo $this->createUrl('client/isp3html');?>",
- type: "POST",
- dataType: "json",
- data: {
- examId: examId,
- classId:classId
- },
- success: function (data){
- if(data > 0){
- layer.msg('操作成功,重新生成提分方案',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }else if(data==0){
- layer.msg('操作失败,此班无提分方案',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- else{
- layer.msg('操作失败,重新生成提分方案',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- },
- error: function (data, status, e){ //服务器响应失败处理函数
- layer.msg('返回失败!',{
- icon: 1
- }, function(){
- layer.closeAll();
- });
- }
- });
- }
- });
- }
- // 隐藏试卷
- function oprateExam(examGroupId,flag){
- if (examGroupId) {
- layer.msg('未找到周周练id',{
- icon: 5
- }, function(){
- layer.closeAll();
- });
- }
- var msg = '您确定要隐藏该试卷吗?';
- if (flag == 0) {
- msg = '您确定要恢复该试卷吗?';
- }
- layer.msg(msg, {
- time: 0,
- btn: ['确定', '取消'],
- yes: function(index){
- layer.close(index);
- $.post('<?php echo $this->createUrl("third/oprateexam");?>',{exam_group_id:examGroupId,flag:flag},function(data){
- var obj = JSON.parse(data);
- if (obj.success == 1) {
- location.reload();
- } else {
- layer.msg(obj.message,{
- icon: 5
- }, function(){
- layer.closeAll();
- });
- // layer.msg(obj.message);
- }
- });
- }
- });
- }
- </script>
|