Просмотр исходного кода

bug:个人统计 当前周期不予显示稽查次数

温红权 8 лет назад
Родитель
Сommit
e9a32d4e3d

+ 69 - 27
VisualInspection/js/statistics/personal_data_statistics.js

@@ -26,6 +26,9 @@ var end_date = $(".div-end input").val() + " 23:00:00";
 $(function() {
     setVisit();
 
+
+
+
     //*************************************数据表格******************************************
     function initAppealPage(start_date, end_date, user_id) {
         initQueryParams();
@@ -111,34 +114,73 @@ $(function() {
 
 
 
-        var data = {
-            "start_date": start_date,
-            "end_date": end_date,
-            "user_id": user_id,
-            "queryType": 0,
-            "score_flag": $(".score-select").val()
-        }
-        if (hasRole(ROLE_STATION_ADMIN) || hasRole(ROLE_STATION) || hasRole(ROLE_JICHA) || roleContains('STATION')) {
-            hide = true;
-        }
 
-        var cols = [
-            { width: 50, text: '序号', flex: true, colClass: 'text-center', field: 'num' },
-            { width: 100, text: '时间段', flex: true, colClass: 'text-center', field: 'check_task_time_name' },
-            { width: 80, text: '扣分人', flex: true, colClass: 'text-center', field: 'checked_name' },
-            { width: 40, text: '扣分数', flex: true, colClass: 'text-center', field: 'score', nullvalue: '0' },
-            { width: 100, text: '考核类型', flex: true, colClass: 'text-center', sort: 'down', field: 'parent_name' },
-            { width: 100, text: '考核项', flex: true, colClass: 'text-center', sort: 'down', field: 'name' },
-            { width: 100, text: '扣分凭证', type: 'imagedd', flex: true, hide: hide, field: 'pics' },
-        ];
-        if (cur_status == 12 || cur_status == 13) {
-            data.check_status_arr = [12, 13];
-        }
-        $('#personal_data_table').mytable({
-            'cols': cols,
-            'url': "/statistics/one/checkedItem/detail/info",
-            'param': data
-        });
+        $.ajax({
+            type: "OPTIONS",
+            url: base_ui_url,
+            complete: function(x) {
+
+                //计算当前周期
+                var now_date_time = moment(new Date(x.getResponseHeader("Date")))
+                var current_start_date = null;
+
+                if (now_date_time.date() >= 26) {
+                    current_start_date = moment(now_date_time.format("YYYY-MM") + "-25 23:00:00Z").subtract(0, "month");
+                } else {
+                    current_start_date = moment(now_date_time.format("YYYY-MM") + "-25 23:00:00Z").subtract(1, "month");
+                }
+                var end_date_time = moment(end_date + "Z");
+
+                if (end_date_time.valueOf() > current_start_date.valueOf()) {
+                    if (hasRole(ROLE_STATION_ADMIN) || hasRole(ROLE_STATION) || roleContains('STATION')) {
+                        $(".score-select").val(1)
+                    }
+                }
+
+                var data = {
+                    "start_date": start_date,
+                    "end_date": end_date,
+                    "user_id": user_id,
+                    "queryType": 0,
+                }
+                if ($(".score-select").val() == "0") {
+                    data["score_flag"] = 0;
+                }
+                if ($(".score-select").val() == "1") {
+                    data["score_flag"] = 1;
+                }
+
+                if (hasRole(ROLE_STATION_ADMIN) || hasRole(ROLE_STATION) || hasRole(ROLE_JICHA) || roleContains('STATION')) {
+                    hide = true;
+                }
+
+                var cols = [
+                    { width: 50, text: '序号', flex: true, colClass: 'text-center', field: 'num' },
+                    { width: 100, text: '时间段', flex: true, colClass: 'text-center', field: 'check_task_time_name' },
+                    { width: 80, text: '扣分人', flex: true, colClass: 'text-center', field: 'checked_name' },
+                    { width: 40, text: '扣分数', flex: true, colClass: 'text-center', field: 'score', nullvalue: '0' },
+                    { width: 100, text: '考核类型', flex: true, colClass: 'text-center', sort: 'down', field: 'parent_name' },
+                    { width: 100, text: '考核项', flex: true, colClass: 'text-center', sort: 'down', field: 'name' },
+                    { width: 100, text: '扣分凭证', type: 'imagedd', flex: true, hide: hide, field: 'pics' },
+                ];
+                if (cur_status == 12 || cur_status == 13) {
+                    data.check_status_arr = [12, 13];
+                }
+                $('#personal_data_table').mytable({
+                    'cols': cols,
+                    'url': "/statistics/one/checkedItem/detail/info",
+                    'param': data
+                });
+
+            }
+        })
+
+
+
+
+
+
+
     }
 
 

+ 1 - 1
VisualInspection/js/statistics/road_manage_statistics.js

@@ -316,7 +316,7 @@ $(function() {
 
             } else {
                 array_year_score.length = 0;
-                x_m_array.length = 0;
+                x_m_array = new Array();
             }
             if (eval("Math.min(" + array_year_score.toString() + ")") == 0)
                 min_year = 0;

+ 1 - 1
VisualInspection/js/statistics/toll_station_statistics.js

@@ -288,7 +288,7 @@
      	                }
      	            } else {
      	                array_year_score.length = 0;
-     	                x_m_array.length = 0;
+     	                x_m_array = new Array();
      	            }
      	            if (eval("Math.min(" + array_year_score.toString() + ")") == 0)
      	                min_year = 0;

+ 1 - 1
VisualInspection/js/statistics/total_company_statistics.js

@@ -287,7 +287,7 @@ $(function() {
                 }
             } else {
                 array_year_score.length = 0;
-                x_m_array.length = 0;
+                x_m_array = new Array();
             }
 
 

+ 270 - 207
VisualInspection/view/mytask/taskDetail.html

@@ -1,6 +1,5 @@
-
 <div class="container-fluid ">
-      <div class="row">
+    <div class="row">
         <h3>考核基本信息</h3>
         <div>
             <table style="width:100%;">
@@ -13,15 +12,15 @@
                 </tr>
             </table>
         </div>
-      </div>
-      <hr>
-      <div class="row">
+    </div>
+    <hr>
+    <div class="row">
         <h3>考核任务流程</h3>
         <div id="flow_div">
         </div>
-      </div>
-      <hr>
-      <div class="row">
+    </div>
+    <hr>
+    <div class="row">
         <h3>考核详细内容</h3>
         <div>
             <div id="score_datatable" data-checkable="true" data-sortable="true"></div>
@@ -39,21 +38,21 @@
                 <tr>
                     <td width="20%">附件:
                         <div class="file-list" id="appeal_file_list">
-                         </div>
+                        </div>
                     </td>
                     <td>
                     </td>
                 </tr>
                 <tr>
                     <td width="20%">复核结果:
-                         <label id="recheck_result"></label>
+                        <label id="recheck_result"></label>
                     </td>
                     <td>
                     </td>
                 </tr>
             </table>
         </div>
-      </div>
+    </div>
     <div class="row" style="margin-top:5px;text-align:center">
         <div>
             <button id="submitBtn" style="display:none" type="button" class="btn btn-warning" onclick="submitCheck()">提交</button>
@@ -72,18 +71,25 @@
     <div class="row">
         <div id="img_container" class="cards cards-borderless col-sm-12">
         </div>
-    </div> 
+    </div>
 </div>
 <div id="appealDetail-div" style="display:none;text-align:center;">
-    <link rel="import" href="/view/appeal_management/appealDetail.html?__inline">   
+    <link rel="import" href="/view/appeal_management/appealDetail.html?__inline">
 </div>
 <div id="chooseCheckman-div" style="display:none;text-align:center;">
-    <link rel="import" href="/view/mytask/chooseCheckman.html?__inline">   
-</div> 
+    <link rel="import" href="/view/mytask/chooseCheckman.html?__inline">
+</div>
 <style>
-    .line{
-        text-align:center;font-size:20px;height:10px;margin:15px 0px;width:100%;background:#516784;overflow:hidden;
+    .line {
+        text-align: center;
+        font-size: 20px;
+        height: 10px;
+        margin: 15px 0px;
+        width: 100%;
+        background: #516784;
+        overflow: hidden;
     }
+    
     .timeline_item_station {
         left: 50%;
         margin-left: 60px;
@@ -112,106 +118,156 @@
         $("#checked_person").html($.checkTask.checked_person_name);
         $("#checked_dept").html($.checkTask.checked_dept_name);
 
-        if($.checkTask.appeal) {
+        if ($.checkTask.appeal) {
             $("#appeal_div").show();
             $("#appeal_time").html($.checkTask.appeal.appeal_time);
-            $("#appeal_reason").html($.checkTask.appeal.appeal_reason);       
+            $("#appeal_reason").html($.checkTask.appeal.appeal_reason);
             $("#appeal_file_list").html(genAppeaFiles($.checkTask.appeal.file_src));
             $("#recheck_result").html($.checkTask.appeal.recheck_result);
-        }else{
+        } else {
             $("#appeal_div").hide();
         }
 
         genFlow();
         queryScores();
     });
-    
+
     //初始化表行按钮
     function initBtns() {
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA+"_2",["#submitBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA+"_3",["#submitBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA+"_7",["#submitBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA+"_12",["#submitAppealBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA+"_13",["#submitAppealBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA+"_17",["#submitAppealBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA_ADMIN+"_4",["#backBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA_ADMIN+"_6",["#backConfirmBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA_ADMIN+"_14",["#backAppealBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_JICHA_ADMIN+"_11",["#assignBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_STATION_ADMIN+"_5",["#confirmBtn","#appealBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_STATION_ADMIN+"_15",["#confirmAppealBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_STATION_AGENT+"_5",["#confirmBtn","#appealBtn"]);
-        $.zui.store.set("task_detail_btn_"+ROLE_STATION_AGENT+"_15",["#confirmAppealBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA + "_2", ["#submitBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA + "_3", ["#submitBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA + "_7", ["#submitBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA + "_12", ["#submitAppealBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA + "_13", ["#submitAppealBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA + "_17", ["#submitAppealBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA_ADMIN + "_4", ["#backBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA_ADMIN + "_6", ["#backConfirmBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA_ADMIN + "_14", ["#backAppealBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_JICHA_ADMIN + "_11", ["#assignBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_STATION_ADMIN + "_5", ["#confirmBtn", "#appealBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_STATION_ADMIN + "_15", ["#confirmAppealBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_STATION_AGENT + "_5", ["#confirmBtn", "#appealBtn"]);
+        $.zui.store.set("task_detail_btn_" + ROLE_STATION_AGENT + "_15", ["#confirmAppealBtn"]);
     }
-    function checkAuth(){
-        initBtns();        
-        showBtn(ROLE_JICHA,$.checkTask.check_status);
-        showBtn(ROLE_JICHA_ADMIN,$.checkTask.check_status);
-        showBtn(ROLE_STATION_ADMIN,$.checkTask.check_status);
-        showBtn(ROLE_STATION_AGENT,$.checkTask.check_status);
+
+    function checkAuth() {
+        initBtns();
+        showBtn(ROLE_JICHA, $.checkTask.check_status);
+        showBtn(ROLE_JICHA_ADMIN, $.checkTask.check_status);
+        showBtn(ROLE_STATION_ADMIN, $.checkTask.check_status);
+        showBtn(ROLE_STATION_AGENT, $.checkTask.check_status);
     }
+
     function showBtn(role, status) {
-        if(hasRole(role)) {
-             var btnArr = $.zui.store.get("task_detail_btn_"+role+"_"+status);
-             if(btnArr) {
-                 for(var i in btnArr) {
-                     $(btnArr[i]).show();
-                 }
-             }
+        if (hasRole(role)) {
+            var btnArr = $.zui.store.get("task_detail_btn_" + role + "_" + status);
+            if (btnArr) {
+                for (var i in btnArr) {
+                    $(btnArr[i]).show();
+                }
+            }
         }
     }
-    function queryScores(){
+
+    function queryScores() {
         // 使用data参数更新数据:
         var data = {
             "task_id": $.checkTask.id
         }
-        
-        var cols = [
-                    {width: 80, text: '序号', type: 'number', flex: true, colClass: 'text-center',field: 'num'},
-                    {width: 60, text: '评分记录', type: 'string', flex: true, sort: 'down',field: 'content'},
-                    {width: 80, text: '分数', type: 'string', flex: true, colClass: '',field: 'check_item_score'},
-                    {width: 80, text: '扣分人', type: 'string', flex: true, colClass: '',field: 'checked_person_name'},
-                    {width: 80, text: '备注', type: 'string', flex: true, colClass: '',field: 'remark'},
-                    {width: 200, text: '图片', type: 'imagedd', flex: true, colClass: '',field: 'pics'}
-                ];
-        if(hasRole(ROLE_JICHA) && ($.checkTask.check_status==2||$.checkTask.check_status==2||$.checkTask.check_status==12
-            ||$.checkTask.check_status==13)) {
-            var oper = {width: 160, text: '操作', type: 'string', flex: true, field: 'id',
-                        oper:[
-                            {func:'showEditScore',text:'修改',icon_class:'icon-edit'},
-                            {func:'deleteScore',text:'删除',icon_class:'icon-remove-circle'}
-                        ]
-                    }
+
+        var cols = [{
+            width: 80,
+            text: '序号',
+            type: 'number',
+            flex: true,
+            colClass: 'text-center',
+            field: 'num'
+        }, {
+            width: 60,
+            text: '评分记录',
+            type: 'string',
+            flex: true,
+            sort: 'down',
+            field: 'content'
+        }, {
+            width: 80,
+            text: '分数',
+            type: 'string',
+            flex: true,
+            colClass: '',
+            field: 'check_item_score'
+        }, {
+            width: 80,
+            text: '扣分人',
+            type: 'string',
+            flex: true,
+            colClass: '',
+            field: 'checked_person_name'
+        }, {
+            width: 80,
+            text: '备注',
+            type: 'string',
+            flex: true,
+            colClass: '',
+            field: 'remark'
+        }, {
+            width: 200,
+            text: '图片',
+            type: 'imagedd',
+            flex: true,
+            colClass: '',
+            field: 'pics'
+        }];
+        if (hasRole(ROLE_JICHA) && ($.checkTask.check_status == 2 || $.checkTask.check_status == 2 || $.checkTask.check_status == 12 ||
+                $.checkTask.check_status == 13)) {
+            var oper = {
+                width: 160,
+                text: '操作',
+                type: 'string',
+                flex: true,
+                field: 'id',
+                oper: [{
+                    func: 'showEditScore',
+                    text: '修改',
+                    icon_class: 'icon-edit'
+                }, {
+                    func: 'deleteScore',
+                    text: '删除',
+                    icon_class: 'icon-remove-circle'
+                }]
+            }
             cols.push(oper);
         }
-        $('#score_datatable').mytable({'cols':cols,
-                                'url':"/score/getScoreList/",
-                                'param':data}
-                                );
+        $('#score_datatable').mytable({
+            'cols': cols,
+            'url': "/score/getScoreList/",
+            'param': data
+        });
         $('a.lightbox-toggle').lightbox();
     }
     var curScoreId;
-    function showEditScore(id){
-        
-        var rowData=getItemByIdFromArr(id,$('#score_datatable').mytable('getTableData'));
+
+    function showEditScore(id) {
+
+        var rowData = getItemByIdFromArr(id, $('#score_datatable').mytable('getTableData'));
         // alert(rowData.pics);
         curScoreId = rowData.id;
-        scoreImageLayer = showPopup4Common('修改图片',updateImg,'600px');
+        scoreImageLayer = showPopup4Common('修改图片', updateImg, '600px');
         showTaskDetailPics(rowData.pics);
     }
 
-    function showTaskDetailPics(pics,divId){
-        var picStr='';
-        if(!divId) divId = '#img_container';
+    function showTaskDetailPics(pics, divId) {
+        var picStr = '';
+        if (!divId) divId = '#img_container';
         $(divId).html(picStr);
-        if(pics){
+        if (pics) {
             var picArr = pics.split(',');
-            for(var i in picArr){
+            for (var i in picArr) {
 
                 var ispic = true;
-                var src =  picArr[i];
+                var src = picArr[i];
                 if (!src.startWith("http"))
-                        src = base_image_server_url + src;
+                    src = base_image_server_url + src;
 
                 var videosrc = src;
                 if (src.indexOf('.avi') != -1) {
@@ -227,108 +283,114 @@
                     ispic = false;
                 }
 
-            
-                var pic = '<div id="img_item_'+i+'" class="col-md-4 col-sm-6 col-lg-3">'
-                    +  '<a href="javascript:void(0)" onclick="removeImg(\'#img_item_'+i+'\')" style="float:right;position:absolute;z-index:100;"><span class="label label-danger"><i class="icon icon-remove-circle"></i> 删除</span></a>'
-                    +(ispic ? '<a class="card lightbox-toggle" data-group="image-group-1" data-lightbox-group="example-3" href="' + src + '" style="position:absolute">' : '<a class="card" onclick="video_paly(\'' + videosrc + '\')" href="javascript:void(0)" style="position:absolute">') 
-                    +      '<img class="pic-class img-thumbnail" style="width:200px;height:150px;" src="'+src+'" alt="">'+ (ispic ? '' : '<i class="icon icon-play-circle" style=" font-size: 30px;position: absolute;top: 40px;left:80px;color: white;"></i>') 
-                    +  '</a>'
-                    +'</div>';
-                picStr+=pic;
+
+                var pic = '<div id="img_item_' + i + '" class="col-md-4 col-sm-6 col-lg-3">' +
+                    '<a href="javascript:void(0)" onclick="removeImg(\'#img_item_' + i + '\')" style="float:right;position:absolute;z-index:100;"><span class="label label-danger"><i class="icon icon-remove-circle"></i> 删除</span></a>' +
+                    (ispic ? '<a class="card lightbox-toggle" data-group="image-group-1" data-lightbox-group="example-3" href="' + src + '" style="position:absolute">' : '<a class="card" onclick="video_paly(\'' + videosrc + '\')" href="javascript:void(0)" style="position:absolute">') +
+                    '<img class="pic-class img-thumbnail" style="width:200px;height:150px;" src="' + src + '" alt="">' + (ispic ? '' : '<i class="icon icon-play-circle" style=" font-size: 30px;position: absolute;top: 40px;left:80px;color: white;"></i>') +
+                    '</a>' +
+                    '</div>';
+                picStr += pic;
             }
             $(divId).html(picStr);
             $('a.lightbox-toggle').lightbox();
         }
     }
-    function updateImg(){
-        
+
+    function updateImg() {
+
         var imgArr = $("#img_container .pic-class");
-        var picsStr="";
-        if(imgArr && imgArr.length>0) {
-            for(var i=0;i<imgArr.length;i++){
-                picsStr+=imgArr[i].src+","
+        var picsStr = "";
+        if (imgArr && imgArr.length > 0) {
+            for (var i = 0; i < imgArr.length; i++) {
+                picsStr += imgArr[i].src + ","
             }
-            picsStr = picsStr.substr(0,picsStr.length-1);
-        }
-        var param= {
-            'id':curScoreId,
-            'pics':picsStr
+            picsStr = picsStr.substr(0, picsStr.length - 1);
         }
-        // alert("dddd");
-        addOrUpdateItem4Common(param,"/score/update",queryScores);
-        curScoreId="";
+        var param = {
+                'id': curScoreId,
+                'pics': picsStr
+            }
+            // alert("dddd");
+        addOrUpdateItem4Common(param, "/score/update", queryScores);
+        curScoreId = "";
     }
-    function deleteScore(id){
-        deleteItem4Common(id,"/score/delete/",queryScores);
+
+    function deleteScore(id) {
+        deleteItem4Common(id, "/score/delete/", queryScores);
     }
-    function genFlow(){
+
+    function genFlow() {
         var data = {
             "id": $.checkTask.id
         };
-        post_common_service("/task/getStatusById/",data,function(data){
-            if(data) {
-                var flowStr="";
-                for(var i in data) {
-                    var str = '<div class="col-sm-2" style="text-align:center;padding:0px;">'
-                                + '<div class="row">'
-                                +  '   <label>'+data[i].update_time+'</label>'
-                                + '</div>'
-                                + '<div class="row">'
-                                +  '   <label>'+data[i].check_status_name+'</label>'
-                                + '</div>'
-                                + '<div class="row line">'
-                                + '    <div class="timeline_item_station"></div>'
-                                + '</div>'
-                                +'</div>';
-                    flowStr+=str;
+        post_common_service("/task/getStatusById/", data, function(data) {
+            if (data) {
+                var flowStr = "";
+                for (var i in data) {
+                    var str = '<div class="col-sm-2" style="text-align:center;padding:0px;">' +
+                        '<div class="row">' +
+                        '   <label>' + data[i].check_status_name + '</label>' +
+                        '</div>' +
+                        '<div class="row">' +
+                        '   <label>' + data[i].update_time + '</label>' +
+                        '</div>' +
+                        '<div class="row line">' +
+                        '    <div class="timeline_item_station"></div>' +
+                        '</div>' +
+                        '</div>';
+                    flowStr += str;
                 }
                 $("#flow_div").html(flowStr);
             }
         })
     }
-    function submitCheck(){
+
+    function submitCheck() {
         var param = {
             "id": $.checkTask.id,
-            "check_status":4
+            "check_status": 4
         }
-        no_return_common_service("/task/taskEnd/",param,function(data){
-             layer.msg("提交成功", {
-                time: 2000//20s后自动关闭
-             });
-           redirectLastPage();
+        no_return_common_service("/task/taskEnd/", param, function(data) {
+            layer.msg("提交成功", {
+                time: 2000 //20s后自动关闭
+            });
+            redirectLastPage();
         });
-        
+
     }
 
-    function submitCheck4Appeal(){
-        var appeal_result=1;
+    function submitCheck4Appeal() {
+        var appeal_result = 1;
         //询问框
         layer.confirm('该申诉是否成功?', {
-            btn: ['成功','失败'] //按钮
-        }, function(){
-            appeal_result=1;
+            btn: ['成功', '失败'] //按钮
+        }, function() {
+            appeal_result = 1;
             submitAppealResult(appeal_result);
-        }, function(){
-            appeal_result=2;
+        }, function() {
+            appeal_result = 2;
             submitAppealResult(appeal_result);
-        });     
+        });
     }
-    function submitAppealResult(appeal_result){
+
+    function submitAppealResult(appeal_result) {
         var param = {
             "id": $.checkTask.id,
             "check_status": 14,
-            "appeal_id":$.checkTask.appeal.id,
-            "appeal_result":appeal_result
+            "appeal_id": $.checkTask.appeal.id,
+            "appeal_result": appeal_result
         }
-        no_return_common_service("/task/update/",param,function(data){
+        no_return_common_service("/task/update/", param, function(data) {
             layer.msg("提交成功", {
-                time: 2000//20s后自动关闭
+                time: 2000 //20s后自动关闭
             });
             redirectLastPage();
         });
     }
     var appealLayer;
-    function showAppeal(){
+
+    function showAppeal() {
         // appealLayer = showPopup4Common('申诉',saveAppeal,'600px','#appealDetail-div');
         layer.open({
             type: 1,
@@ -340,127 +402,128 @@
             content: $('#appealDetail-div'),
             btn: '保存',
             btnAlign: 'c', //按钮居中
-            shade: 0 ,//不显示遮罩
-            yes: function(index){
+            shade: 0, //不显示遮罩
+            yes: function(index) {
                 saveAppeal();
             }
         });
     }
 
-    function confirmCheck(){
+    function confirmCheck() {
         layer.confirm('是否确认该稽查结果?', {
-            btn: ['确认','取消'], //按钮
-            offset:'auto'
-        }, function(){
+            btn: ['确认', '取消'], //按钮
+            offset: 'auto'
+        }, function() {
             var param = {
                 "id": $.checkTask.id,
-                "check_status":6
+                "check_status": 6
             }
-            no_return_common_service("/task/update/",param,function(data){
+            no_return_common_service("/task/update/", param, function(data) {
                 layer.msg("确认成功", {
-                    time: 2000//20s后自动关闭
+                    time: 2000 //20s后自动关闭
                 });
                 redirectLastPage();
             });
-        }, function(index){
+        }, function(index) {
             layer.close(index);
         });
-       
+
     }
 
-    function confirmCheck4Appeal(){
+    function confirmCheck4Appeal() {
         layer.confirm('是否确认该申诉结果?', {
-            btn: ['确认','取消'], //按钮
-            offset:'auto'
-        }, function(){
+            btn: ['确认', '取消'], //按钮
+            offset: 'auto'
+        }, function() {
             var param = {
                 "id": $.checkTask.id,
-                "check_status":16
+                "check_status": 16
             }
-            no_return_common_service("/task/update/",param,function(data){
+            no_return_common_service("/task/update/", param, function(data) {
                 layer.msg("确认成功", {
-                    time: 2000//20s后自动关闭
+                    time: 2000 //20s后自动关闭
                 });
                 redirectLastPage();
             });
-        }, function(index){
+        }, function(index) {
             layer.close(index);
         });
-        
+
     }
 
-    function showAssign(){
-        showPopup4Common('分配稽查员',function(){
+    function showAssign() {
+        showPopup4Common('分配稽查员', function() {
             saveAssign();
-        },'400px','#chooseCheckman-div');
-        setCheckmanSelect('#choseCheckmanList',null,$.checkTask.checkman,
-        function(){
-           $('#choseCheckmanList').chosen({
-                // width:'200px',
-                height:'100px',
-                no_results_text: '没有找到',    // 当检索时没有找到匹配项时显示的提示文本
-                disable_search_threshold: 10, // 10 个以下的选择项则不显示检索框
-                search_contains: true         // 从任意位置开始检索
-            });   
-        });
-       
+        }, '400px', '#chooseCheckman-div');
+        setCheckmanSelect('#choseCheckmanList', null, $.checkTask.checkman,
+            function() {
+                $('#choseCheckmanList').chosen({
+                    // width:'200px',
+                    height: '100px',
+                    no_results_text: '没有找到', // 当检索时没有找到匹配项时显示的提示文本
+                    disable_search_threshold: 10, // 10 个以下的选择项则不显示检索框
+                    search_contains: true // 从任意位置开始检索
+                });
+            });
+
     }
 
-    function saveAssign(){
-         var param = {
+    function saveAssign() {
+        var param = {
             "id": $.checkTask.id,
             "recheckman": $('#choseCheckmanList').val(),
-            "check_status":12
+            "check_status": 12
         }
-        no_return_common_service("/task/update/",param,function(data){
-             layer.msg("分配成功", {
-                time: 2000//20s后自动关闭
-             });
+        no_return_common_service("/task/update/", param, function(data) {
+            layer.msg("分配成功", {
+                time: 2000 //20s后自动关闭
+            });
             redirectLastPage();
         });
     }
 
-    function back2Check(){
+    function back2Check() {
         //退回到待提交页面
         var param = {
             "id": $.checkTask.id,
-            "check_status":3,
-            "check_status_name":"退回"
+            "check_status": 3,
+            "check_status_name": "退回"
         }
-        no_return_common_service("/task/update/",param,function(data){
-             layer.msg("退回成功", {
-                time: 2000//20s后自动关闭
-             });
+        no_return_common_service("/task/update/", param, function(data) {
+            layer.msg("退回成功", {
+                time: 2000 //20s后自动关闭
+            });
             redirectLastPage();
         });
     }
-    function back2Confirm(){
+
+    function back2Confirm() {
         //退回到待提交页面
         var param = {
             "id": $.checkTask.id,
-            "check_status":5,
-            "check_status_name":"退回重新确认"
+            "check_status": 5,
+            "check_status_name": "退回重新确认"
         }
-        no_return_common_service("/task/update/",param,function(data){
-             layer.msg("退回成功", {
-                time: 2000//20s后自动关闭
-             });
+        no_return_common_service("/task/update/", param, function(data) {
+            layer.msg("退回成功", {
+                time: 2000 //20s后自动关闭
+            });
             redirectLastPage();
         });
     }
 
-    function back2AppealCheck(){
+    function back2AppealCheck() {
         //退回到待提交页面
         var param = {
             "id": $.checkTask.id,
-            "check_status":13,
-            "check_status_name":"退回"
+            "check_status": 13,
+            "check_status_name": "退回"
         }
-        no_return_common_service("/task/update/",param,function(data){
-             layer.msg("退回成功", {
-                time: 2000//20s后自动关闭
-             });
+        no_return_common_service("/task/update/", param, function(data) {
+            layer.msg("退回成功", {
+                time: 2000 //20s后自动关闭
+            });
             redirectLastPage();
         });
     }
-    </script>
+</script>

+ 2 - 2
VisualInspection/view/statistics/personal_data_statistics.html

@@ -20,8 +20,8 @@
             <div class="div-end"><input class="form-control" placeholder="请选择考核结束时间"></input>
             </div>
             <div class="div-select">
-                <select class="form-control score-select ">
-                    <option value="">全部</option><option value="1" selected>扣分</option><option value="0">不扣分</option>
+                <select class="form-control score-select" id="score_select">
+                    <option value="2">全部</option><option value="1" selected>扣分</option><option value="0">不扣分</option>
                 </select>
             </div>
             <div class="query div-button"><button>查询</button></div>

+ 2 - 2
VisualInspection_server/src/main/java/com/xintong/visualinspection/mapper/master/StatisticsMapper.xml

@@ -515,10 +515,10 @@
          LEFT JOIN (SELECT ci.* ,cp.name AS parent_name FROM check_item  ci LEFT JOIN check_item cp ON ci.parent_id = cp.id) ci ON ci.id = cs.check_item_id
      		where   t.check_status !=22 and t.id not in <include refid="taskexclouddeleteUser"/>
      		<if test="queryType!=null and queryType==0">
-     			AND (cs.checked_person = #{user_id} OR t.monitor_user_id = #{user_id}  )
+     			AND (t.checked_person = #{user_id} OR t.monitor_user_id = #{user_id}  )
      		</if>
      		<if test="queryType!=null and queryType==1 and user_id!=null and user_id!=''">
-     			AND  cs.checkman = #{user_id}
+     			AND  t.checkman = #{user_id}
      		</if>
      		<if test="start_date !=null and end_date !=null and queryType ==1">
      			AND t.check_time >= #{start_date} AND t.check_time &lt; #{end_date}