123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291 |
- <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/index'); ?>">素材切割任务</a></span>
- <span class="active">扫描处理任务</span>
- </div>
- <div class="searchArea">
- <form class="task_search" action="<?php echo $this->createUrl('assistTask/scanTask');?>" 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'] ?>">
- <input type="hidden" name="subject_id" value="<?php echo $subjectId?>">
- <div class="submit hbtn">搜索</div>
- </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>
- <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']['surplus'];
- }
- ?>
- </td>
- <td>
- <?php
- if($loop['taskCount']){
- echo $loop['taskCount']['processed'];
- }
- ?>
- </td>
- <?php
- switch ($loop['scan_task']){
- case 0:
- echo '<td> 无</td>';
- break;
- case 1:
- echo '<td class="warning">排队中</td>';
- break;
- case 2:
- echo '<td class="notice">受理中</td>';
- break;
- case 3:
- echo '<td class="theme">已完成</td>';
- break;
- default:
- echo '<td> 无</td>';
- }
- ?>
- <td ><?php echo date('Y-m-d H:i:s',$loop['update_time'])?></td>
- <td><?php echo $loop['operator'] ?></td>
- <td>
- <div class="operator">
- <a href="<?php echo $this->createUrl('assistTask/scanTaskDetail',array('exam_group_id'=>$loop['exam_group_id']));?>" class="theme artical">任务详情</a>
- <a href="#" class="apply" eid="<?php echo $loop['exam_group_id']?>"
- <?php if($loop['operator']=='--'):?>
- class="blue opreator"> 分配操作员
- <?php else:?>
- <a class="blue complete"> 修改操作员
- <?php endif;?>
- </a></div>
- </td>
- </tr>
- <?php ++$i;endforeach;
- else:?>
- <tr><td colspan="12">暂无任务数据</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;text-align: center;width: 100%;padding: 20px 0;">
- <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/scanTask')."?page=".($pages['page']-1).'&'.http_build_query($condition).'">上一页</a></li>';
- }
- for($i=$StartPage;$i<=$EndPage;$i++){
- $url=$this->createUrl('assistTask/scanTask')."?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/scanTask')."?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="close btn-colse">x</i></h2>
- <div class="content">
- <p class="warning">注意:若更改操作员,该次任务的所有任务量统计将计入新的操作员账号下,请谨慎操作!</p>
- <div class="conditionItem">
- <em>选择操作员:</em>
- <select name="user_id" id="user_id" >
- <option value="0">请选择用户</option>
- <?php
- if($users){
- foreach ($users as $user){
- echo '<option value="'.$user['user_id'].'">'.$user['real_name'].'-'.$user['user_name'].'</option>';
- }
- }
- ?>
- </select>
- <input type="hidden" name="exam_group_id" value="0">
- </div>
- </div>
- <div class="btns">
- <input type="hidden" name="exam_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>
- </div>
- <script type="text/javascript">
- $(document).ready(function () {
- //关闭弹窗
- $(".btn-colse").on("click", function () {
- // layer.close(layer.index);
- layer.closeAll();
- $('.hgc_dialog').hide();
- });
- $('.up-form').click(function(){
- var examGroupId= $('input[name=exam_group_id]').val(),
- userId=$('#user_id').val();
- $.ajax({
- url:'<?php echo $this->createUrl('assistTask/applyScan')?>',
- type:'POST',
- dataType:'json',
- data:{exam_group_id:examGroupId,user_id:userId},
- success:function(res){
- if(res.status==1){
- layer.msg('操作成功');
- window.location.reload();
- }else{
- layer.msg('操作失败');
- }
- }
- });
- });
- $('.apply').click(function(){
- var examGroupId=$(this).attr('eid');
- if(examGroupId!=undefined && examGroupId!=''){
- $('input[name=exam_group_id]').val(examGroupId);
- // layer.open({
- // title: false,
- // closeBtn: 0,
- // type: 1,
- //
- // content: $(".port-down-pop")
- // });
- $('.hgc_dialog').show();
- }
- });
- // tips
- $(".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/scanTask')?>?subject_id='+$(this).val();
- });
- $('#scanTask').change(function(){
- var subject=$('input[name=subject_id]').val();
- window.location.href='<?php echo $this->createUrl('assistTask/scanTask')?>?subject_id='+subject+'&scan_task='+$(this).val();
- });
- $(".prompt").mouseover(function(event){
- var tooltipHtml = "<div id='tooltip' class='tooltip'>Hello!</div>";
- $(this).append(tooltipHtml);
- $("#tooltip").css({
- "top": "0px",
- "left": (event.pageX) + "px" //紧跟在内容的后面
- }).show("fast"); //设置提示框的坐标,并显示
- }).mouseout(function(){
- $("#tooltip").remove();
- })
- $('.submit').click(function(){
- $('.task_search').submit();
- });
- });
- </script>
|