123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287 |
- <link rel="stylesheet" href="/css/assist/taskPage.css">
- <script src="/js/assist/drag.js" type="text/javascript"></script>
- <div class="hgc_taskPage">
- <div class="hgc_totalHeader">
- <span><a href="<?php echo $this->createUrl('assistTask/myTask'); ?>">素材切割任务</a></span>
- <span class="active">扫描处理任务</span>
- </div>
- <div class="searchArea">
- <form class="task_search" action="<?php echo $this->createUrl('assistTask/myScanTask');?>" method="get" >
- <div class="searchLeft">
- <div class="conditionItem">
- <em>任务状态:</em>
- <select name="scan_task" id="scanTask">
- <option value="0">全部</option>
- <option value="1" <?php if($condition['scan_task']==1) echo 'selected'?>>排队中</option>
- <option value="2" <?php if($condition['scan_task']==2) echo 'selected'?>>受理中</option>
- <option value="3" <?php if($condition['scan_task']==3) echo 'selected'?>>已完成 </option>
- </select>
- </div>
- <div class="conditionItem">
- <input type="text" placeholder="请输入考试名称/学校名称/学管姓名的等关键字搜索" name="search_name" value="<?php echo $condition['search_name'] ?>">
- <div class="submit hbtn">搜索</div>
- <input type="hidden" name="subject_id" value="<?php echo $subjectId?>">
- </div>
- </div>
- </form>
- <div class="conditionItem last">
- <em>学科:</em>
- <select name="subject_id" id="selectId">
- <option value="0">全部</option>
- <?php
- if(isset($subjects)){
- foreach ($subjects as $key => $subject){
- if($key==$subjectId){
- echo '<option value="'.$key.'" selected>'.$subject.'</option>';
- }else{
- echo '<option value="'.$key.'">'.$subject.'</option>';
- }
- }
- }
- ?>
- </select>
- </div>
- </div>
- <div class="tableBox">
- <table class="hgc_table" border="1" cellspacing="0">
- <thead>
- <tr>
- <th>考试名称</th>
- <th>学科</th>
- <th>学校名称</th>
- <th>学管姓名</th>
- <th>学管手机号</th>
- <th>任务类别</th>
- <th>个人完成量</th>
- <th>剩余待处理</th>
- <th>任务状态</th>
- <th>任务更新时间</th>
- <th>操作</th>
- </tr>
- </thead>
- <tbody>
- <?php $i = 1; if ($dataList):foreach ($dataList as $loop): ?>
- <tr>
- <td><p class="examName" title="<?php echo $loop['exam_name'] ?>"><?php echo $loop['exam_name'] ?></p></td>
- <td><?php echo Yii::app()->params['subjectId'][$loop['subject_id']] ?></td>
- <td><?php echo $loop['school_name'] ?></td>
-
- <td><?php echo $loop['coach_name'] ?></td>
- <td><?php echo $loop['coach_mobile'] ?></td>
- <td>
- <?php
- if($loop['taskType']){
- echo implode(',',$loop['taskType']);
- }
- ?>
- </td>
- <td>
- <?php
- if($loop['taskCount']){
- echo $loop['taskCount']['processed'];
- }
- ?>
- </td>
- <td>
- <?php
- if($loop['taskCount']){
- echo $loop['taskCount']['surplus'];
- }
- ?>
- </td>
- <?php
- if($loop['scan_task']==2){
- echo '<td class="notice">受理中</td>';
- }elseif($loop['scan_task']==3){
- echo '<td class="theme">已完成</td>';
- }elseif($loop['scan_task']==4){
- echo '<td class="theme">已完成</td>';
- }else{
- echo '<td ></td>';
- }
- ?>
- <td><?php echo date('Y-m-d H:i:s',$loop['update_time'])?></td>
- <td>
- <div class="operator">
- <?php if($loop['scan_task']==3 || $loop['scan_task']==4){
- ?>
- <a href="<?php echo $this->createUrl('assistTask/scanTaskDetail',array('exam_group_id'=>$loop['exam_group_id']))?>" class="theme">查看详情</a>
- <?php
- }else{
- ?>
- <a href="<?php echo $this->createUrl('assistTask/scanTaskDetail',array('exam_group_id'=>$loop['exam_group_id']))?>" class="theme artical"> 查看并处理</a>
- <a href="#" class="complete blue" eid="<?php echo $loop['exam_group_id']?>">完成并提交</a>
- <?php
- }?>
- </div>
- </td>
- </tr>
- <?php ++$i;endforeach; else:?>
- <tr><td colspan="12">
- <?php
- if(isset($isNoLimit)){
- echo '用户无权限';
- }else{
- echo '暂无任务数据';
- }
- ?>
- </td></tr>
- <?php endif; ?>
- </tbody>
- </table>
- <div class="dataTables_paginate paging_simple_numbers" >
- <?php
- if(isset($pages['totalPage']) && $pages['totalPage']>1){
- $StartPage=$pages['page']-5;
- $EndPage=$pages['page']+5;
- if($StartPage<1){
- $StartPage=1;
- }
- if($EndPage>$pages['totalPage']){
- $EndPage=$pages['totalPage'];
- }
- ?>
- <div class="row" style="padding-top:10px;margin:0 auto;">
- <div class="col-xs-5" style="font-size: 16px">
- <div class="dataTables_paginate paging_simple_numbers" style="vertical-align:sub;">
- <ul id="yw0" class="yiiPager">
- <?php
- if($pages['page']>1){
- echo '<li class="previous"><a href="'.$this->createUrl('assistTask/myScanTask')."?page=".($pages['page']-1).'&'.http_build_query($condition).'">上一页</a></li>';
- }
- for($i=$StartPage;$i<=$EndPage;$i++){
- $url=$this->createUrl('assistTask/myScanTask')."?page=".$i.'&'.http_build_query($condition);
- if($pages['page']==$i){
- echo '<li class="page selected"><a href="#">'.$i.'</a></li>';
- }else{
- echo '<li class="page"><a href="'.$url.'">'.$i.'</a></li>';
- }
- }
- if($pages['page']<$pages['totalPage']){
- echo '<li class="previous"><a href="'.$this->createUrl('assistTask/myScanTask')."?page=".($pages['page']+1).'&'.http_build_query($condition).'">下一页</a></li>';
- }
- ?>
- </ul>
- 共:<?php echo $pages['total']?>条
- </div>
- </div>
- </div>
- <?php } ?>
- </div>
- </div>
- <div class="hgc_dialog" style="display: none">
- <div class="hgc_dialogContent">
- <h2>任务完成 <i class="btn-colse">x</i></h2>
- <div class="content">
- <div class="conditionItem">
- <p class="mgt">
- 本次考试扫描异常您已处理<span class="complete_count"></span>份,剩余<span class="surplus"></span>份未处理,确认提交任务吗?
- </p>
- </div>
- <p class="notice" style="text-align: center;font-size: 16px;padding: 10px 0;">注:提交后将不可撤回</p>
- </div>
- <div class="btns">
- <input type="hidden" name="exam_group_id" value="0">
- <input type="hidden" name="file_type" value="">
- <div class="hbtn up-form" id="btnSubmit">确定</div>
- <div class="hbtn btn-colse" id="btnClose">取消</div>
- </div>
- </div>
- </div>
- <script type="text/javascript">
- $(document).ready(function () {
- //关闭弹窗
- $(".btn-colse").on("click", function () {
- $('.hgc_dialog').hide();
- });
- $('.complete').click(function(){
- var examGroupId=$(this).attr('eid');
- if(examGroupId!=0){
- $.ajax({
- url:'<?php echo $this->createUrl('assistTask/getScanDetail')?>',
- type:'POST',
- dataType:'json',
- data:{exam_group_id:examGroupId},
- success:function(res){
- if(res.status==1){
- $('.complete_count').html(res.data['count']['complete']);
- $('.surplus').html(res.data['count']['surplus']);
- $('input[name=exam_group_id]').val(examGroupId);
- $('.hgc_dialog').show();
- }
- }
- });
- }
- });
- //完成提交
- $('.up-form').click(function(){
- var examGroupId=$('input[name=exam_group_id]').val();
-
- if(examGroupId!=0){
- $.ajax({
- url:'<?php echo $this->createUrl('assistTask/scanTaskComplete')?>',
- type:'POST',
- dataType:'json',
- data:{exam_group_id:examGroupId},
- success:function(res){
- if(res.status==1){
- layer.msg('提交成功');
- window.location.reload()
- }else{
- if(res.msg!=undefined){
- layer.msg(res.msg);
- }else{
- layer.msg('提交失败');
- }
- }
- }
- })
- }
- });
- $(".open-tips").on("mouseenter", function () {
- var tips_text = $(this).attr("tipstext");
- layer.tips(tips_text, this, {
- tips: [1, '#14AE68'] //还可配置颜色
- });
- });
- $('#selectId').change(function(){
- window.location.href='<?php echo $this->createUrl('assistTask/myScanTask')?>?subject_id='+$(this).val();
- });
- $('#scanTask').change(function(){
- var subject=$('input[name=subject_id]').val();
- window.location.href='<?php echo $this->createUrl('assistTask/myScanTask')?>?subject_id='+subject+'&scan_task='+$(this).val();
- });
- $('.submit').click(function(){
- $('.task_search').submit();
- });
- });
- </script>
|