jack-PC\jack %!s(int64=8) %!d(string=hai) anos
pai
achega
001c3e22e2

+ 81 - 0
VisualInspection/css/other_check/other_check.css

@@ -0,0 +1,81 @@
+
+.div-month{
+    width:80px;
+    height:32px;
+    float:left;
+    margin-left: 20px;
+    line-height: 50px;
+}
+.div-roadManage{
+    width:140px;
+    height:50px;
+    float:left;
+    margin-left: 20px;
+    line-height: 50px;
+}
+.div-station{
+    width:120px;
+    height:50px;
+    float:left;
+    margin-left: 20px;
+    line-height: 50px;
+}
+.div-roadManage select{
+    width:140px;
+    height:30px;
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    font-size: 14px;
+}
+.div-station select{
+    width:110px;
+    height:30px;
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    font-size: 14px;
+}
+.div-month select{
+    width:80px;
+    height:30px;
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    font-size: 14px;
+}
+.div-month input{
+    width:80px;
+    height:30px;
+    /*margin-top: 9px;*/
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    font-size: 14px;
+}
+
+.div-select {
+    width: 130px;
+    height: 32px;
+    float: left;
+    line-height: 50px;
+}
+
+.div-select select {
+    width: 130px;
+    height: 30px;
+    border: 1px solid #ccc;
+    border-radius: 4px;
+}
+
+.div-month2{
+    width:130px;
+    height:32px;
+    float:left;
+    line-height: 50px;
+}
+
+.div-month2 input{
+    width:130px;
+    height:32px;
+    /*margin-top: 9px;*/
+    border: 1px solid #ccc;
+    border-radius: 4px;
+    font-size: 14px;
+}

+ 1 - 0
VisualInspection/js/lib/treeSelect.css

@@ -7,6 +7,7 @@
     border-top-width: 0;
     z-index: 101;
     background: white;
+    max-height: 200px;
 }
 
 .treeSelect-input {

+ 567 - 0
VisualInspection/js/other_check/other_check.js

@@ -0,0 +1,567 @@
+var file_src="";
+var imgs_src = [];
+var idUpdate;
+var check_id;
+var check_type;
+var check_item_tree = null;
+var edittype = "add";
+var al_data = []; 
+    // 页面初始化
+    function init(){
+        $(document).delegate("#editImage img","mouseenter",function(){
+            var myself = $(this);
+            var xx = $("<i class='icon-remove' img_src='"+$(this).attr('img_src')+"'></i>");
+            xx.css({ "position": "absolute", "display": "" });
+            $(this).parent().append(xx);
+            $(".icon-remove").click(function () {
+                myself.hide();
+                imgs_src.push($(this).attr("img_src"));
+            });
+         })
+          $(document).delegate("#editImage div","mouseleave",function(){
+           $(".icon-remove").hide();
+         })
+         // 初始化上传
+        refreshUploader();
+        setVisit();
+         $.jeDate("#month_date", {
+            isinitVal: true,
+            format: 'YYYY/MM' // 分隔符可以任意定义,该例子表示只显示年月
+        });
+        $.jeDate("#month_date2", {
+            isinitVal: true,
+            format: 'YYYY-MM-DD hh:mm' ,
+            zIndex:300000000000// 分隔符可以任意定义,该例子表示只显示年月日
+        });
+        var road_manager;
+        if (roleContains("STATION")) {
+            road_manager = getCurrentUser().road_manager_id;
+        }
+        if (roleContains("ROAD_MANAGER")) {
+            road_manager = getCurrentUser().organid;
+        }
+        setRoadManagerSelect("#first", road_manager);
+        setSecond();
+
+        // 收费站下拉框
+        var dept;
+        if (roleContains("STATION")) {
+            dept = getCurrentUser().organid;
+        }
+        var roadManager2;
+        if (roleContains("ROAD_MANAGER")) {
+            roadManager2 = getCurrentUser().organid;
+        }
+        var feeList = $.zui.store.get("cache_fee_station_list");
+        if (roadManager2) feeList = cache_road_manager_fee_list_map.get(roadManager2);
+        setFeeSelectValueNoAll(feeList, "#select-dept", dept);
+        setPersonal();
+        var zTreeObj;
+        var zNodes = [];
+        check_item_tree = $.fn.zTree.init($("#check_rule_tree2"), {}, zNodes);
+
+        getCheckItems();
+
+        $("#check_item_select input").on("click", function() {
+            //debugger;
+            var nodedata;
+            if($("#check_item_select input") != undefined && $("#check_item_select input") != ""){
+                nodedata = check_item_tree.getNodeByParam("name",$("#check_item_select input").val(), null);
+            }
+            $("#add_btn").data("tree_flag",1);
+            loadData(nodedata);
+            $("#add_btn").data("tree_flag",0);
+        })
+        queryTable();
+    }
+     //关闭弹窗
+    $("#close-layer").click(function(){
+        layer.closeAll();
+    })
+    //条件查询
+    $("#conditional_query").click(function(){
+        queryTable();
+    })
+    //保存修改或添加
+    $("#save-check").click(function(){
+        var dept_id = $("#select-dept").val();
+        var user_id = $("#select-personal").val();
+        var check_item_id = dept_selectinput!=null?dept_selectinput.value:null ;
+        var remark = $("#remark").val();
+        var check_score = $("#check_score").val();
+        var check_time = $("#month_date2").val();
+        var check_num = $("#check_num").val();
+        if(idUpdate){
+            if($("#editImage").attr("file_src") != ''){
+                var src  = $("#editImage").attr("file_src").split(",");
+                var flag = 1;
+                for(var i= 0 ;i<src.length;i++){
+                for(var j= 0 ;j<imgs_src.length;j++){
+                        if(src[i] == imgs_src[j]){
+                            flag = 0;
+                            break;
+                        }
+                }
+                if(flag == 1){
+                        file_src += src[i] + ",";
+                }
+                }
+            }
+        }
+        var file_ids = (file_src.substring(file_src.length-1)==',')?file_src.substring(0,file_src.length-1):file_src;
+
+        var check_time_name = timeStamp2String(new Date(),"yyyy/MM");
+        if(dept_id == null || dept_id == undefined ||dept_id == ""){
+            layer.msg('请选择部门');
+            return;
+        }else if(user_id == null || user_id == undefined ||user_id == ""){
+            layer.msg('请选择人员');
+            return;
+        }else if(check_item_id == null || check_item_id == undefined ||check_item_id == ""){
+            layer.msg('请选择扣分类别');
+            return;
+        }else if(check_score == null || check_score == undefined ||check_score == ""){
+            layer.msg('请选择扣分值');
+            return;
+        }
+        
+        data = {
+            "id":check_id,
+            "dept_id":dept_id,
+            "user_id":user_id,
+            "check_item_id":check_item_id,
+            "check_type":check_type,
+            "remark":remark,
+            "check_score":check_score,
+            "file_ids":file_ids,
+            "check_time":check_time,
+            "check_time_name":check_time_name,
+            "check_num":check_num
+        }
+        if(idUpdate){
+            post_common_service("checkOther/update", data, function(data){
+                file_src = "";
+                imgs_src = [];
+                layer.closeAll();
+                queryTable();
+            }, function(){
+
+            });
+        }else{
+            post_common_service("checkOther/add", data, function(data){
+                file_src = "";
+                imgs_src = [];
+                layer.closeAll();
+                queryTable();
+            }, function(){
+
+            });
+        }
+    })
+    //添加稽查记录
+    $("#add_btn").click(function(){
+        idUpdate = false;
+        edittype = "add";
+        check_id=null;
+        $("#select-dept").val("");
+        $("#select-personal").val("");
+        $(".treeSelect-input").val("");
+        $("#remark").val("");
+        $("#check_score").val("");
+        $("#month_date2").val(timeStamp2String(new Date(),"yyyy-MM-dd HH:mm"));
+        $("#check_num").val(1);
+        $("#editImage").empty();
+        layerUpdateTeam('form-div','稽查记录新增','550px');
+        $("#save-check").html("保存");
+        $("#check_item_select input").on("click", function() {
+            //debugger;
+            var nodedata;
+            $("#add_btn").data("tree_flag",1);
+            loadData(nodedata);
+            $("#add_btn").data("tree_flag",0);
+        })
+    })
+function queryTable(){
+    $(".datatable").empty();
+    var data = {
+        "check_time_name":$("#month_date").val(),
+        "dept_id":$("#second").val(),
+        "check_type":check_type
+    }
+    var cols = [
+                    {width: 30, text: '序号', flex: false, colClass: 'text-center',field:'num'},
+                    {width: 50, text: '时间', flex: false,colClass: '',field:'check_time'},
+                    {width: 50, text: '部门', flex: false,colClass: '',field:'organname'},
+                    {width: 50, text: '人员', flex: false,colClass: '',field:'username'},
+                    {width: 50, text: '扣分类型', flex: false,colClass: '',field:'check_item_name'},
+                    {width: 50, text: '扣分值', flex: false,colClass: '',field:'check_score'},
+                    {width: 120, text: '附件', type: 'imagedd',flex: false,colClass: '',field:'file_ids'},
+                    {width: 50, text: '扣分描述', flex: false,colClass: '',field:'remark'},
+                    {width: 50, text: '操作',  flex: false, colClass: '',field:'id',oper:[
+                        {func:'updateCheckTeam',text:'修改',icon_class:'icon-edit'},{func:'deleteCheckTeam',text:'删除',icon_class:'icon-remove-circle'}
+                    ]},
+                ] ;
+    
+    $('.datatable').mytable({'cols':cols,
+                            'url':"checkOther/getCheckByDeptId",
+                            'param':data}
+                            );
+}
+function deleteCheckTeam(id){
+        deleteItem4Common(id,"checkOther/delete",queryTable);
+    }
+function updateCheckTeam(id){
+    check_id = id;
+    data = {
+        "id":id
+    }
+    post_common_service("checkOther/getCheckById", data, function(data){
+        $("#select-dept").val(data.dept_id);
+        $("#select-personal").val(data.user_id);
+        $("#check_item_select input").val(data.check_item_name);
+        $("#remark").val(data.remark);
+        $("#check_score").val(data.check_score);
+        var time = data.check_time;
+        $("#month_date2").val(data.check_time);
+        $("#check_num").val(data.check_num);
+        $("#editImage").empty();
+        if(data.file_ids !=null && data.file_ids != ""){
+            var ids = data.file_ids.split(",");
+            var str = "";
+            for(i=0;i<ids.length;i++){
+                str += ids[i] + ",";
+                $("#editImage").append("<div style='float:left;width:60px;'><img  img_src='"+ids[i]+"' class='pic-class  img-thumbnail' style='width:50px;height:50px;' alt='' src='http://file_release_yanhai.jsxt.jsjtyxt.com/"+ids[i]+"' ></div>");
+            }
+                $("#editImage").attr("file_src",(str.substring(str.length-1)==',')?str.substring(0,str.length-1):str);
+        }
+        
+        idUpdate = true;
+        edittype = "edit";
+        layerUpdateTeam('form-div','稽查记录修改','550px');
+        $("#save-check").html("修改");
+        $("#check_item_select input").on("click", function() {
+            //debugger;
+            var nodedata;
+            if($("#check_item_select input") != undefined && $("#check_item_select input") != ""){
+                nodedata = check_item_tree.getNodeByParam("name",$("#check_item_select input").val(), null);
+            }
+            $("#add_btn").data("tree_flag",1);
+            loadData(nodedata);
+            $("#add_btn").data("tree_flag",0);
+        })
+    }, function(){
+
+    });
+    
+}
+function refreshUploader(){
+    // 文件上传
+    $('#uploaderExample').uploader({
+        autoUpload: true,  // 当选择文件后立即自动进行上传操作  
+        unique_names:true,  // 生成唯一名称
+        url: base_image_server_url +'fileServer/file/upload',  // 文件上传提交地址
+        filters:{
+            mime_types: [
+                {title: '图片', extensions: 'jpg,gif,png'},
+                {title: '图标', extensions: 'ico'},
+                {title: '视频', extensions: 'mp4,avi'},
+                {title: '文档', extensions: 'doc,docx'}
+            ],
+            // 不允许上传重复文件
+            prevent_duplicates: true
+        },
+        fileTemplate :'<div class="file"><div class="file-progress-bar"></div><div class="file-wrapper"><div class="file-icon"><i class="icon icon-file-o"></i></div><div class="content"></div><div class="actions"><div class="file-status" data-toggle="tooltip"><i class="icon"></i> <span class="text"></span></div><a data-toggle="tooltip" class="btn btn-link btn-download-file" target="_blank"><i class="icon icon-download-alt"></i></a><button type="button" data-toggle="tooltip" class="btn btn-link btn-reset-file" title="Repeat"><i class="icon icon-repeat"></i></button><button type="button" data-toggle="tooltip" class="btn btn-link btn-rename-file" title="Rename"><i class="icon icon-pencil"></i></button><button type="button" data-toggle="tooltip" title="Remove" class="btn btn-link btn-delete-file"><i class="icon icon-trash text-danger"></i></button></div></div></div>', // 设置模板
+        onFileUploaded: function(file, responseObject){
+            var datas = eval('('+responseObject.response+')');
+            file_src += datas.result_data.path+",";
+            //$(".file").append("<div style='float:left;width:60px;'><img  img_src='"+datas.result_data.path+"' class='pic-class  img-thumbnail' style='width:50px;height:50px;' alt='' src='http://file_release_yanhai.jsxt.jsjtyxt.com/"+datas.result_data.path+"' ></div>");
+        },
+        onInit:function(){
+            $("#file-list").empty();
+        },
+        onFilesRemoved:function(files) {
+            // alert(files);
+        }
+    });
+}
+ function setVisit() {
+        if (roleContains("STATION")) {
+            $("#first").attr("disabled", "disabled");
+            $("#second").attr("disabled", "disabled");
+        }
+        if (roleContains("ROAD_MANAGER")) {
+            $("#first").attr("disabled", "disabled");
+        }
+    }
+     /**
+     * 根据道管中心获取收费站列表(下拉框)
+     */
+    $(".div-roadManage select").change(function() {
+        setSecond();
+        flag = true;
+    });
+
+    function setSecond() {
+        var select_road = $(".div-roadManage select").val();
+        var feeList = $.zui.store.get("cache_fee_station_list");
+        if (select_road) feeList = cache_road_manager_fee_list_map.get(select_road);
+
+        var dept;
+        if (roleContains("STATION")) {
+            dept = getCurrentUser().organid;
+        }
+        refreshFee(feeList, dept);
+    }
+    function refreshFee(data, selectId) {
+        var sec = document.getElementById('second');
+        var tempStr = ''
+        if (data.length != 0) {
+            for (var i = 0; i < data.length; i++) {
+                if (data[i].deptid == selectId)
+                    tempStr += "<option value=" + data[i].deptid + " selected>" + data[i].name + "</option>";
+                else
+                    tempStr += "<option value=" + data[i].deptid + ">" + data[i].name + "</option>";
+                // }
+                sec.innerHTML = tempStr;
+            }
+        } else {
+            sec.innerHTML = '';
+        }
+    }
+
+     /**
+     * 部门人员下拉框
+     */
+    function setPersonal() {
+        var select_road = $("#select-dept").val();
+        var sec = document.getElementById('select-personal');
+        var tempStr = ''
+        var param = {
+            "organid": select_road
+        }
+        post_common_service("user/getFsUserList", param, function(data) {
+            if (data.length != 0) {
+                var userId;
+                if (hasRole("ROLE_STATION")) {
+                    userId = getCurrentUser().id;
+                }
+                for (var i = 0; i < data.length; i++) {
+                    for (var j = 33; j <= 53; j++) {
+                        if (select_road == j) {
+                            if (data[i].id == userId) {
+                                tempStr += "<option value=" + data[i].id + " selected='selected'>" + data[i].truename + "</option>";
+                            } else {
+                                tempStr += "<option value=" + data[i].id + ">" + data[i].truename + "</option>";
+                            }
+                        }
+                    }
+                    sec.innerHTML = tempStr;
+                }
+            } else {
+                sec.innerHTML = '';
+            }
+        }, function(error) {
+            return "";
+        });
+    }
+    // 部门改变后 重新生成人员下拉框
+    $("#select-dept").change(function() {
+        setPersonal();
+    });
+
+    
+    function layerUpdateTeam(domId,title,area){
+        var uploader = $('#uploaderExample').data('zui.uploader');
+        uploader.destroy();
+        refreshUploader();
+        $(".file-list").empty();
+        file_src = "";
+        imgs_src = [];
+        layer.open({
+            type: 1,
+            title: false,
+            closeBtn: 1,
+            title:title,
+            shadeClose: true,
+            skin: 'yourclass',
+            area:area,
+            content: $("#"+domId)
+        });
+    }
+
+    // 增加和编辑框
+    var dept_selectinput;
+
+    function loadData(nodedata) {
+        var pnode = nodedata;
+        if(pnode != null){
+            dept_selectinput = new TreeSelect({
+                element: '#check_item_select',
+                data: all_data,
+                valueKey: "id",
+                placeholder: "请选择扣分类别",
+                selectvalue: pnode.id
+            });
+        }else{
+            if($("#add_btn").data("tree_flag")==1){
+                dept_selectinput = new TreeSelect({
+                    element: '#check_item_select',
+                    data: all_data,
+                    valueKey: "id",
+                    placeholder: "请选择扣分类别"
+                });
+            }else{
+               
+            }
+        }
+    }
+
+    function getCheckItems() {
+     function zTreeOnRename(event, treeId, treeNode, isCancel) {
+         alert(treeNode.tId + ", " + treeNode.name);
+     }
+
+     function zTreeOnRemove(event, treeId, treeNode) {
+         alert(treeNode.tId + ", " + treeNode.name);
+     }
+
+
+     function getTreeData(c_obj,id){
+        if(c_obj.id == id){
+            return c_obj ;
+        }else{
+            if(c_obj.subCheckItem!=null){
+                for(var i=0;i<c_obj.subCheckItem.length;i++){
+                    var tmp = getTreeData(c_obj.subCheckItem[i],id);
+                    if(tmp != null){
+                        return tmp ;
+                    }
+                }
+            }
+            return null;
+        }
+     }
+
+     var seq = 0 ;
+
+     function getTree(obj,rowObj){
+        var userdata = {};
+        userdata["checked"] = false;
+        if(obj.score != null){
+            userdata["data"] = [++seq, obj.name, (obj.score!=null?obj.score:""), '<a href="javascript:void(0)" onclick="modify_check_item('+ obj.id +')"  ><i class="icon icon-edit"></i> 修改</a><a href="javascript:void(0)" onclick="delete_check_item('+ obj.id +')" ><i class="icon icon-remove-circle"></i> 删除</a>'];
+            rowObj.push(userdata);
+        }
+
+        if(obj.subCheckItem!=null){
+            for(var i=0; i<obj.subCheckItem.length;i++ ){
+                getTree(obj.subCheckItem[i],rowObj);
+            }
+        }
+        return rowObj;
+     }
+
+     function zTreeOnClick(event, treeId, treeNode) {
+
+        var rowdata = [];
+
+        seq = 0 ;
+
+        for(var i=0;i<z_cache.length;i++){
+            var treeObj = getTreeData(z_cache[i],treeNode.id) ;
+            if( treeObj != null){
+               rowdata = getTree(treeObj,rowdata);
+               break ;
+            }
+        }
+
+        // 使用data参数更新数据:
+        $('.datatable').datatable('load', {
+            cols: cols,
+            rows: rowdata
+        });
+     };
+
+     var setting = {
+         data: {
+             simpleData: {
+                 enable: true,
+                 idKey: "id",
+                 pIdKey: "pId",
+                 rootPId: null
+             }
+         },
+         view: { //表示tree的显示状态
+             selectMulti: false //表示禁止多选
+         },
+         check: { //表示tree的节点在点击时的相关设置
+             enable: false, //是否显示radio/checkbox
+             chkStyle: "checkbox", //值为checkbox或者radio表示
+             checkboxType: { p: "", s: "" }, //表示父子节点的联动效果
+             radioType: "level" //设置tree的分组
+         },
+         callback: {
+             onRename: zTreeOnRename,
+             //  beforeDrop: zTreeBeforeDrop,
+             onRemove: zTreeOnRemove,
+             onClick: zTreeOnClick
+         },
+         edit: {
+             enable: true,
+             drag: {
+                 autoExpandTrigger: true,
+                 isMove: true,
+                 prev: false,
+                 next: true,
+                 inner: true,
+                 autoOpenTime: 0
+             },
+             showRenameBtn: false,
+             showRemoveBtn: false
+         }
+     };
+
+     post_common_service("/checkItem/getAll","",function(data){
+        all_data = [];
+        z_cache = data ;
+         for (var i = 0; i < data.length; i++) {
+             var m = data[i];
+             var zdataItem = {};
+             zdataItem["id"] = m.id;
+             zdataItem["value"] = m.id;
+             zdataItem["pId"] = null;
+             zdataItem["score"] = m.score ;
+             zdataItem["name"] = m.name;
+             zdataItem["open"] = true;
+             zdataItem["children"] = addobj(m);
+              zdataItem.open = true ;
+             all_data.push(zdataItem);
+         }
+         check_item_tree = $.fn.zTree.init($("#check_rule_tree2"), setting, all_data)
+     },function(error){})
+ }
+
+ function addobj(data) {
+    var zdata = [];
+    if (typeof(data.subCheckItem) != "undefinde" && data.subCheckItem != null &&
+        data.subCheckItem.length > 0) {
+        for (var i = 0; i < data.subCheckItem.length; i++) {
+            var m = data.subCheckItem[i];
+            var zdataItem = {};
+            //   if(m.score != null){
+            //      continue;
+            //   }
+            zdataItem["id"] = m.id;
+            zdataItem["value"] = m.id;
+            zdataItem["pId"] = data.id;
+            zdataItem["score"] = m.score;
+            zdataItem["icon"] = "";
+            zdataItem["name"] = m.name;
+            zdataItem["children"] = addobj(m);
+            zdataItem.open = false;
+            zdata.push(zdataItem);
+        }
+        return zdata;
+    } else {
+        return [];
+    }
+}

+ 134 - 0
VisualInspection/view/other_check/data_platform_check.html

@@ -0,0 +1,134 @@
+<link rel="stylesheet" type="text/css" href="/css/other_check/other_check.css">
+<script src="/js/other_check/other_check.js?_inline"></script>
+<!--  start -->
+<div class="container-fluid ">
+        <div class="row">
+             <div>
+                <div class="div-month">
+                    <input id="month_date" class="form-control form-date" type="text" placeholder="请选择" style="height:30px;">
+                 </div>
+                 <div class="div-roadManage">
+                    <select class="form-control" id="first"></select>
+                </div>
+                <div class="div-station">
+                    <select class="form-control" id="second"></select>
+                </div>
+
+               <div class="col-xs-3">
+                    <div class="input-group">
+                        <button class="btn btn-primary " type="button" id="conditional_query">查询</button>
+                    </div>
+                </div>
+
+                 <div style="float:right;margin-right:30px;">
+                    <button class="btn btn-primary" type="button" id="add_btn"><i class="icon icon-plus-sign"></i> 增加稽查记录</button>
+                </div>
+            </div>
+        </div>
+        <hr>
+        <div class="row">
+            <!-- 使用一个div来显示数据表格 -->
+            <div class="datatable" data-checkable="true" data-sortable="true"></div>
+        </div>
+        <div class="">
+            
+
+        </div>
+
+</div>
+<!--  end -->          
+<div style="display:none;" id="form-div">
+    <div class="layer-content" style="width:100%;height:100%;">
+        <div style="width:350px;overflow:hidden;zoom:1;margin:auto;">
+            <div style="width:100%;margin-top:20px;overflow:hidden;zoom:1;">
+                <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                    <div style="width:80px;float:left;">
+                        <span style="line-height:32px;">选择人员</span>
+                    </div>
+                    <div style="width:260px;float:left;">
+                        <div class="div-select"><select class="form-control" id="select-dept"></select></button>
+                        </div>
+                        <div class="div-select"><select class="form-control" id="select-personal"></select></button>
+                        </div>
+                    </div>
+                </div>
+            <div style="width:100%;margin-top:10px;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分类别</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div id="check_item_select" style="position: relative;">
+                        <input class="form-control" id="check_item_id">
+                    </div>
+                     <div class="form-group check_item_group">
+                        <!--<label for="exampleInputPassword4" class="col-sm-2">分类:</label>-->
+                        <div class="col-md-6 col-sm-10">
+                            <div id="check_item_select"></div>
+
+                        </div>
+                    </div>
+                </div>
+                <div class="panel-body" style="display:none;">
+                    <ul id="check_rule_tree2" class="ztree">
+
+                    </ul>
+                </div>
+            </div>
+             <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分描述</span>
+                </div>
+                <div style="width:260px;float:left;">
+                   <input class="form-control" id="remark">
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分值</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <input class="form-control" id="check_score" onkeypress="return kkpager.keypress_gopage(event);">
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">附件上传</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div class="col-md-10">
+                        <div id="uploaderExample" class="uploader">
+                            <div id="editImage" file_src="" style="overflow:hidden;zoom:1;"></div>
+                            <div class="file-list" data-drag-placeholder="请拖拽文件到此处"></div>
+                            <button type="button" class="btn btn-primary  uploader-btn-browse" style="float:left;"><i class="icon icon-cloud-upload"></i> 选择文件</button>
+                        </div>
+                    </div>
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">稽查时间</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div class="div-month2">
+                        <input id="month_date2" class="form-control form-date" type="text" placeholder="请选择" style="height:32px;">
+                    </div>
+                    <select class="form-control" style="width:130px;" id="check_num">
+                        <option value="1">第一次检查</option>
+                        <option value="2">第二次检查</option>
+                        <option value="3">第三次检查</option>
+                    </select>
+                </div>
+            </div>
+        </div>
+    </div>
+    <div class="operation" style="width:100%;overflow:hidden;zoom:1;border-top:1px solid #ddd;margin-top:20px;padding:10px 10px 10px 10px;">
+        <button class="btn btn-primary" type="button"  style="float:right;" id="save-check"> 保存</button>
+        <button class="btn btn-primary" type="button" style="float:right;background-color:#fff;color:#333;margin-right:20px;" id="close-layer"> 关闭</button>
+    </div>
+</div>
+<script>
+    $(document).ready(function() {
+        check_type = 4;
+        init();
+    });
+</script>

+ 134 - 0
VisualInspection/view/other_check/onsite_check.html

@@ -0,0 +1,134 @@
+<link rel="stylesheet" type="text/css" href="/css/other_check/other_check.css">
+<script src="/js/other_check/other_check.js?_inline"></script>
+<!--  start -->
+<div class="container-fluid ">
+        <div class="row">
+             <div>
+                <div class="div-month">
+                    <input id="month_date" class="form-control form-date" type="text" placeholder="请选择" style="height:30px;">
+                 </div>
+                 <div class="div-roadManage">
+                    <select class="form-control" id="first"></select>
+                </div>
+                <div class="div-station">
+                    <select class="form-control" id="second"></select>
+                </div>
+
+               <div class="col-xs-3">
+                    <div class="input-group">
+                        <button class="btn btn-primary " type="button" id="conditional_query">查询</button>
+                    </div>
+                </div>
+
+                 <div style="float:right;margin-right:30px;">
+                    <button class="btn btn-primary" type="button" id="add_btn"><i class="icon icon-plus-sign"></i> 增加稽查记录</button>
+                </div>
+            </div>
+        </div>
+        <hr>
+        <div class="row">
+            <!-- 使用一个div来显示数据表格 -->
+            <div class="datatable" data-checkable="true" data-sortable="true"></div>
+        </div>
+        <div class="">
+            
+
+        </div>
+
+</div>
+<!--  end -->          
+<div style="display:none;" id="form-div">
+    <div class="layer-content" style="width:100%;height:100%;">
+        <div style="width:350px;overflow:hidden;zoom:1;margin:auto;">
+            <div style="width:100%;margin-top:20px;overflow:hidden;zoom:1;">
+                <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                    <div style="width:80px;float:left;">
+                        <span style="line-height:32px;">选择人员</span>
+                    </div>
+                    <div style="width:260px;float:left;">
+                        <div class="div-select"><select class="form-control" id="select-dept"></select></button>
+                        </div>
+                        <div class="div-select"><select class="form-control" id="select-personal"></select></button>
+                        </div>
+                    </div>
+                </div>
+            <div style="width:100%;margin-top:10px;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分类别</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div id="check_item_select" style="position: relative;">
+                        <input class="form-control" id="check_item_id">
+                    </div>
+                     <div class="form-group check_item_group">
+                        <!--<label for="exampleInputPassword4" class="col-sm-2">分类:</label>-->
+                        <div class="col-md-6 col-sm-10">
+                            <div id="check_item_select"></div>
+
+                        </div>
+                    </div>
+                </div>
+                <div class="panel-body" style="display:none;">
+                    <ul id="check_rule_tree2" class="ztree">
+
+                    </ul>
+                </div>
+            </div>
+             <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分描述</span>
+                </div>
+                <div style="width:260px;float:left;">
+                   <input class="form-control" id="remark">
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分值</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <input class="form-control" id="check_score" onkeypress="return kkpager.keypress_gopage(event);">
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">附件上传</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div class="col-md-10">
+                        <div id="uploaderExample" class="uploader">
+                            <div id="editImage" file_src="" style="overflow:hidden;zoom:1;"></div>
+                            <div class="file-list" data-drag-placeholder="请拖拽文件到此处"></div>
+                            <button type="button" class="btn btn-primary  uploader-btn-browse" style="float:left;"><i class="icon icon-cloud-upload"></i> 选择文件</button>
+                        </div>
+                    </div>
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">稽查时间</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div class="div-month2">
+                        <input id="month_date2" class="form-control form-date" type="text" placeholder="请选择" style="height:32px;">
+                    </div>
+                    <select class="form-control" style="width:130px;" id="check_num">
+                        <option value="1">第一次检查</option>
+                        <option value="2">第二次检查</option>
+                        <option value="3">第三次检查</option>
+                    </select>
+                </div>
+            </div>
+        </div>
+    </div>
+    <div class="operation" style="width:100%;overflow:hidden;zoom:1;border-top:1px solid #ddd;margin-top:20px;padding:10px 10px 10px 10px;">
+        <button class="btn btn-primary" type="button"  style="float:right;" id="save-check"> 保存</button>
+        <button class="btn btn-primary" type="button" style="float:right;background-color:#fff;color:#333;margin-right:20px;" id="close-layer"> 关闭</button>
+    </div>
+</div>
+<script>
+    $(document).ready(function() {
+        check_type = 3;
+        init();
+    });
+</script>

+ 134 - 0
VisualInspection/view/other_check/special_check.html

@@ -0,0 +1,134 @@
+<link rel="stylesheet" type="text/css" href="/css/other_check/other_check.css">
+<script src="/js/other_check/other_check.js?_inline"></script>
+<!--  start -->
+<div class="container-fluid ">
+        <div class="row">
+             <div>
+                <div class="div-month">
+                    <input id="month_date" class="form-control form-date" type="text" placeholder="请选择" style="height:30px;">
+                 </div>
+                 <div class="div-roadManage">
+                    <select class="form-control" id="first"></select>
+                </div>
+                <div class="div-station">
+                    <select class="form-control" id="second"></select>
+                </div>
+
+               <div class="col-xs-3">
+                    <div class="input-group">
+                        <button class="btn btn-primary " type="button" id="conditional_query">查询</button>
+                    </div>
+                </div>
+
+                 <div style="float:right;margin-right:30px;">
+                    <button class="btn btn-primary" type="button" id="add_btn"><i class="icon icon-plus-sign"></i> 增加稽查记录</button>
+                </div>
+            </div>
+        </div>
+        <hr>
+        <div class="row">
+            <!-- 使用一个div来显示数据表格 -->
+            <div class="datatable" data-checkable="true" data-sortable="true"></div>
+        </div>
+        <div class="">
+            
+
+        </div>
+
+</div>
+<!--  end -->          
+<div style="display:none;" id="form-div">
+    <div class="layer-content" style="width:100%;height:100%;">
+        <div style="width:350px;overflow:hidden;zoom:1;margin:auto;">
+            <div style="width:100%;margin-top:20px;overflow:hidden;zoom:1;">
+                <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                    <div style="width:80px;float:left;">
+                        <span style="line-height:32px;">选择人员</span>
+                    </div>
+                    <div style="width:260px;float:left;">
+                        <div class="div-select"><select class="form-control" id="select-dept"></select></button>
+                        </div>
+                        <div class="div-select"><select class="form-control" id="select-personal"></select></button>
+                        </div>
+                    </div>
+                </div>
+            <div style="width:100%;margin-top:10px;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分类别</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div id="check_item_select" style="position: relative;">
+                        <input class="form-control" id="check_item_id">
+                    </div>
+                     <div class="form-group check_item_group">
+                        <!--<label for="exampleInputPassword4" class="col-sm-2">分类:</label>-->
+                        <div class="col-md-6 col-sm-10">
+                            <div id="check_item_select"></div>
+
+                        </div>
+                    </div>
+                </div>
+                <div class="panel-body" style="display:none;">
+                    <ul id="check_rule_tree2" class="ztree">
+
+                    </ul>
+                </div>
+            </div>
+             <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分描述</span>
+                </div>
+                <div style="width:260px;float:left;">
+                   <input class="form-control" id="remark">
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分值</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <input class="form-control" id="check_score" onkeypress="return kkpager.keypress_gopage(event);">
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">附件上传</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div class="col-md-10">
+                        <div id="uploaderExample" class="uploader">
+                            <div id="editImage" file_src="" style="overflow:hidden;zoom:1;"></div>
+                            <div class="file-list" data-drag-placeholder="请拖拽文件到此处"></div>
+                            <button type="button" class="btn btn-primary  uploader-btn-browse" style="float:left;"><i class="icon icon-cloud-upload"></i> 选择文件</button>
+                        </div>
+                    </div>
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">稽查时间</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div class="div-month2">
+                        <input id="month_date2" class="form-control form-date" type="text" placeholder="请选择" style="height:32px;">
+                    </div>
+                    <select class="form-control" style="width:130px;" id="check_num">
+                        <option value="1">第一次检查</option>
+                        <option value="2">第二次检查</option>
+                        <option value="3">第三次检查</option>
+                    </select>
+                </div>
+            </div>
+        </div>
+    </div>
+    <div class="operation" style="width:100%;overflow:hidden;zoom:1;border-top:1px solid #ddd;margin-top:20px;padding:10px 10px 10px 10px;">
+        <button class="btn btn-primary" type="button"  style="float:right;" id="save-check"> 保存</button>
+        <button class="btn btn-primary" type="button" style="float:right;background-color:#fff;color:#333;margin-right:20px;" id="close-layer"> 关闭</button>
+    </div>
+</div>
+<script>
+    $(document).ready(function() {
+        check_type = 2;
+        init();
+    });
+</script>

+ 135 - 0
VisualInspection/view/other_check/third_unannounced_check.html

@@ -0,0 +1,135 @@
+<link rel="stylesheet" type="text/css" href="/css/other_check/other_check.css">
+<script src="/js/other_check/other_check.js?_inline"></script>
+<!--  start -->
+<div class="container-fluid ">
+        <div class="row">
+             <div>
+                <div class="div-month">
+                    <input id="month_date" class="form-control form-date" type="text" placeholder="请选择" style="height:30px;">
+                 </div>
+                 <div class="div-roadManage">
+                    <select class="form-control" id="first"></select>
+                </div>
+                <div class="div-station">
+                    <select class="form-control" id="second"></select>
+                </div>
+
+               <div class="col-xs-3">
+                    <div class="input-group">
+                        <button class="btn btn-primary " type="button" id="conditional_query">查询</button>
+                    </div>
+                </div>
+
+                 <div style="float:right;margin-right:30px;">
+                    <button class="btn btn-primary" type="button" id="add_btn"><i class="icon icon-plus-sign"></i> 增加稽查记录</button>
+                </div>
+            </div>
+        </div>
+        <hr>
+        <div class="row">
+            <!-- 使用一个div来显示数据表格 -->
+            <div class="datatable" data-checkable="true" data-sortable="true"></div>
+        </div>
+        <div class="">
+            
+
+        </div>
+
+</div>
+<!--  end -->          
+<div style="display:none;" id="form-div">
+    <div class="layer-content" style="width:100%;height:100%;">
+        <div style="width:350px;overflow:hidden;zoom:1;margin:auto;">
+            <div style="width:100%;margin-top:20px;overflow:hidden;zoom:1;">
+                <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                    <div style="width:80px;float:left;">
+                        <span style="line-height:32px;">选择人员</span>
+                    </div>
+                    <div style="width:260px;float:left;">
+                        <div class="div-select"><select class="form-control" id="select-dept"></select></button>
+                        </div>
+                        <div class="div-select"><select class="form-control" id="select-personal"></select></button>
+                        </div>
+                    </div>
+                </div>
+            <div style="width:100%;margin-top:10px;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分类别</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div id="check_item_select" style="position: relative;">
+                        <input class="form-control" id="check_item_id">
+                    </div>
+                     <div class="form-group check_item_group">
+                        <!--<label for="exampleInputPassword4" class="col-sm-2">分类:</label>-->
+                        <div class="col-md-6 col-sm-10">
+                            <div id="check_item_select"></div>
+
+                        </div>
+                    </div>
+                </div>
+                <div class="panel-body" style="display:none;">
+                    <ul id="check_rule_tree2" class="ztree">
+
+                    </ul>
+                </div>
+            </div>
+             <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分描述</span>
+                </div>
+                <div style="width:260px;float:left;">
+                   <input class="form-control" id="remark">
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">扣分值</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <input class="form-control" id="check_score" onkeypress="return kkpager.keypress_gopage(event);">
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">附件上传</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div class="col-md-10">
+                        <div id="uploaderExample" class="uploader">
+                            <div id="editImage" file_src="" style="overflow:hidden;zoom:1;"></div>
+                            <div class="file-list" data-drag-placeholder="请拖拽文件到此处"></div>
+                            <button type="button" class="btn btn-primary  uploader-btn-browse" style="float:left;"><i class="icon icon-cloud-upload"></i> 选择文件</button>
+                        </div>
+                    </div>
+                </div>
+            </div>
+            <div style="width:100%;margin-top:10px;overflow:hidden;zoom:1;">
+                <div style="width:80px;float:left;">
+                    <span style="line-height:32px;">稽查时间</span>
+                </div>
+                <div style="width:260px;float:left;">
+                    <div class="div-month2">
+                        <input id="month_date2" class="form-control form-date" type="text" placeholder="请选择" style="height:32px;">
+                    </div>
+                    <select class="form-control" style="width:130px;" id="check_num">
+                        <option value="1">第一次检查</option>
+                        <option value="2">第二次检查</option>
+                        <option value="3">第三次检查</option>
+                    </select>
+                </div>
+            </div>
+        </div>
+    </div>
+    <div class="operation" style="width:100%;overflow:hidden;zoom:1;border-top:1px solid #ddd;margin-top:20px;padding:10px 10px 10px 10px;">
+        <button class="btn btn-primary" type="button"  style="float:right;" id="save-check"> 保存</button>
+        <button class="btn btn-primary" type="button" style="float:right;background-color:#fff;color:#333;margin-right:20px;" id="close-layer"> 关闭</button>
+    </div>
+</div>
+<script>
+    $(document).ready(function() {
+        check_type = 1;
+        init();
+    });
+</script>
+

+ 53 - 0
VisualInspection_server/src/main/java/com/xintong/visualinspection/bean/CheckOther.java

@@ -0,0 +1,53 @@
+package com.xintong.visualinspection.bean;
+
+import java.util.Date;
+
+import org.springframework.format.annotation.DateTimeFormat;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+@Data
+@EqualsAndHashCode(callSuper = false)
+public class CheckOther {
+	//编号
+    private Long id;
+    // 部门id
+    private Long dept_id;
+    // 稽查人员id
+    private Long user_id;
+    // 稽查人id
+    private Long check_person_id;
+    // 扣分值
+    private Long check_score;
+    // 考核项id
+    private Long check_item_id;
+    // 扣分描述
+    private String remark;
+    // 稽查类型 页面1,2,3,4
+    private Integer check_type;
+    // 附件ids
+    private String file_ids;
+    //稽查时间
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm") 
+    @JsonFormat(pattern="yyyy-MM-dd HH:mm",timezone = "GMT+8") 
+    private Date check_time;
+    // 稽查次数
+    private Integer check_num;
+    //稽查月份名称 年/月
+    private String check_time_name;
+    // 删除标记
+    private Integer delete_flag;
+    // 更新时间
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") 
+    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")  
+    private Date update_time;
+    // 部门名称
+    private String organname;
+    // 人员名称
+    private String username;
+    // 扣分类型名
+    private String check_item_name;
+}

+ 82 - 0
VisualInspection_server/src/main/java/com/xintong/visualinspection/controller/CheckOtherController.java

@@ -0,0 +1,82 @@
+package com.xintong.visualinspection.controller;
+
+import java.util.List;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.validation.Valid;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import com.github.pagehelper.PageHelper;
+import com.github.pagehelper.PageInfo;
+import com.xintong.system.err.BusinessException;
+import com.xintong.visualinspection.bean.CheckAppeal;
+import com.xintong.visualinspection.bean.CheckOther;
+import com.xintong.visualinspection.bean.Task;
+import com.xintong.visualinspection.bean.Team;
+import com.xintong.visualinspection.bean.User;
+import com.xintong.visualinspection.service.CheckOtherService;
+import com.xintong.visualinspection.util.Constants;
+
+/**
+ * 文件名:CheckItemController 版本信息:日期:2017/3/30 Copyright 江苏省交通规划设计院 Corporation
+ * 2017 版权所有.
+ */
+@RestController
+@RequestMapping("/checkOther")
+public class CheckOtherController extends BaseController {
+
+	@Autowired
+	private CheckOtherService checkOtherService;
+
+	/**添加其他稽查查记录
+	 * @param request
+	 * @param checkOther
+	 * @return
+	 */
+	@RequestMapping(value = "/add")
+	public String add(HttpServletRequest request, @Valid @RequestBody CheckOther checkOther) {
+		checkOtherService.insert(checkOther);
+		return super.returnSuccessResult("添加成功");
+	}
+	/**根据id删除稽查记录
+	 * @param checkOther
+	 * @return
+	 */
+	@RequestMapping(value = "/delete")
+    public String delete(@RequestBody CheckOther checkOther){
+    	checkOtherService.delete(checkOther.getId());
+    	return super.returnSuccessResult("删除成功");
+    }
+	@RequestMapping(value = "/update")
+    public String update(@RequestBody CheckOther checkOther){
+    	checkOtherService.update(checkOther);
+    	return super.returnSuccessResult("修改成功");
+    }
+	/**根据id获取稽查记录
+	 * @param checkOther
+	 * @return
+	 */
+	@RequestMapping(value = "/getCheckById")
+    public String getCheckById(@RequestBody CheckOther checkOther){
+    	CheckOther check =checkOtherService.getCheckById(checkOther.getId());
+    	return super.returnSuccessResult(check);
+    }
+	
+	/**根据dept_id 获取稽查记录
+	 * @param checkOther
+	 * @param page
+	 * @param size
+	 * @return
+	 */
+	@RequestMapping(value = "/getCheckByDeptId/{page}/{size}")
+    public String getCheckByDeptId(@RequestBody CheckOther checkOther,@PathVariable Integer page,@PathVariable Integer size){
+    	PageHelper.startPage(page, size);
+    	List<CheckOther> checkOtherList = checkOtherService.getCheckByDeptId(checkOther);
+    	return super.returnSuccessResult(new PageInfo(checkOtherList));
+    }
+}

+ 43 - 0
VisualInspection_server/src/main/java/com/xintong/visualinspection/dao/master/CheckOtherDao.java

@@ -0,0 +1,43 @@
+package com.xintong.visualinspection.dao.master;
+
+import java.util.List;
+
+import org.apache.ibatis.annotations.Mapper;
+
+import com.xintong.visualinspection.bean.CheckAppeal;
+import com.xintong.visualinspection.bean.CheckOther;
+
+/**
+ * 文件名:CheckOtherDao
+ * 版本信息:日期:2017/8/11 Copyright 江苏省交通规划设计院 Corporation 2017 版权所有.
+ */
+@Mapper
+public interface CheckOtherDao  {
+
+	/**添加稽查记录
+	 * @param checkOther
+	 */
+	void insert(CheckOther checkOther);
+
+	/**根据条件查询稽查记录
+	 * @param checkOther
+	 * @return
+	 */
+	List<CheckOther> getCheckByDeptId(CheckOther checkOther);
+
+	/**根据id删除稽查记录
+	 * @param id
+	 */
+	void delete(Long id);
+
+	/**根据id获取稽查记录
+	 * @param id
+	 */
+	CheckOther getCheckById(Long id);
+
+	/**根据id修改稽查记录
+	 * @param id
+	 */
+	void update(CheckOther checkOther);
+    
+}

+ 60 - 0
VisualInspection_server/src/main/java/com/xintong/visualinspection/mapper/master/CheckOtherMapper.xml

@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.xintong.visualinspection.dao.master.CheckOtherDao">
+
+	<insert id="insert" parameterType="com.xintong.visualinspection.bean.CheckOther">
+		INSERT INTO
+		other_check
+		(dept_id,user_id,check_person_id,check_score,check_item_id,remark,check_type,file_ids,check_num,check_time,check_time_name,update_time)
+		VALUES
+		(#{dept_id},#{user_id},#{check_person_id},#{check_score},#{check_item_id},#{remark},#{check_type},#{file_ids},#{check_num},#{check_time},#{check_time_name},now())
+	</insert>
+	
+	<select id="getCheckByDeptId" parameterType="com.xintong.visualinspection.bean.CheckOther"
+	resultType="com.xintong.visualinspection.bean.CheckOther" >
+       SELECT
+		o.id,o.dept_id,o.user_id,o.check_person_id,o.check_score,o.check_item_id,o.remark,o.check_type,o.file_ids,o.check_num,o.check_time,
+		o.check_time_name,o.delete_flag,o.update_time , t.ORGANNAME organname,u.TRUENAME  username,c.name check_item_name
+		FROM
+			(SELECT * FROM other_check
+			where 1=1 and check_type = #{check_type}
+	        <if test="check_time_name != null and check_time_name != ''">AND check_time_name = #{check_time_name}</if>
+			 <if test="dept_id != null">AND dept_id = #{dept_id}</if>
+			)o
+		LEFT JOIN t_sys_organ t ON o.dept_id = t.id
+		LEFT JOIN t_sys_users u ON o.user_id = u.id
+		LEFT JOIN check_item c ON o.check_item_id = c.id
+    </select>
+    <select id="getCheckById" parameterType="java.lang.Long" resultType="com.xintong.visualinspection.bean.CheckOther" >
+        SELECT o.id,o.dept_id,o.user_id,o.check_person_id,o.check_score,o.check_item_id,o.remark,o.check_type,o.file_ids,o.check_num,o.check_time,
+		o.check_time_name,o.delete_flag,o.update_time,c.name check_item_name
+        FROM other_check o
+        LEFT JOIN check_item c ON o.check_item_id = c.id
+        WHERE o.id = #{id}
+    </select>
+    
+    <update id="update" parameterType="com.xintong.visualinspection.bean.CheckOther" >
+        UPDATE
+        other_check
+        SET
+        <if test="dept_id != null">dept_id = #{dept_id}</if>
+        <if test="check_person_id != null">,check_person_id = #{check_person_id}</if>
+        <if test="check_type != null">,check_type = #{check_type}</if>
+        <if test="check_type != null">,check_type = #{check_type}</if>
+        <if test="check_item_id != null">,check_item_id = #{check_item_id}</if>
+        <if test="remark != null and remark !='' " >,remark = #{remark}</if>
+        <if test="check_score != null">,check_score = #{check_score}</if>
+        <if test="file_ids != null">,file_ids = #{file_ids}</if>
+        <if test="check_time != null">,check_time = #{check_time}</if>
+        <if test="check_num != null">,check_num = #{check_num}</if>
+        WHERE
+        id = #{id}
+    </update>
+
+    <delete id="delete" parameterType="java.lang.Long" >
+        DELETE FROM
+        other_check
+        WHERE
+        id =#{id}
+    </delete>
+</mapper>

+ 32 - 0
VisualInspection_server/src/main/java/com/xintong/visualinspection/service/CheckOtherService.java

@@ -0,0 +1,32 @@
+package com.xintong.visualinspection.service;
+
+import java.util.List;
+
+import com.xintong.visualinspection.bean.CheckOther;
+
+public interface CheckOtherService {
+
+	/**添加稽查记录
+	 * @param checkOther
+	 */
+	void insert(CheckOther checkOther);
+	/**根据id删除稽查记录
+	 * @param checkOther
+	 */
+	void delete(Long id);
+
+	/**根据部门id获取稽查记录
+	 * @param checkOther
+	 * @return
+	 */
+	List<CheckOther> getCheckByDeptId(CheckOther checkOther);
+	/**根据id获取稽查记录
+	 * @param id
+	 */
+	CheckOther getCheckById(Long id);
+	/**根据id修改稽查记录
+	 * @param id
+	 */
+	void update(CheckOther checkOther);
+
+}

+ 47 - 0
VisualInspection_server/src/main/java/com/xintong/visualinspection/service/impl/CheckOtherServiceImpl.java

@@ -0,0 +1,47 @@
+package com.xintong.visualinspection.service.impl;
+
+import java.util.List;
+
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import com.xintong.visualinspection.bean.CheckOther;
+import com.xintong.visualinspection.dao.master.CheckOtherDao;
+import com.xintong.visualinspection.service.BaseService;
+import com.xintong.visualinspection.service.CheckOtherService;
+
+/**
+ * 文件名:CheckOtherServiceImpl
+ * 版本信息:日期:2017/8/11 Copyright 江苏省交通规划设计院 Corporation 2017 版权所有.
+ */
+@Service
+public class CheckOtherServiceImpl  extends BaseService implements CheckOtherService{
+
+	private static final org.slf4j.Logger logger = LoggerFactory.getLogger(CheckOtherServiceImpl.class);
+
+	@Autowired
+	private CheckOtherDao checkOtherDao;
+	@Override
+	public void insert(CheckOther checkOther) {
+		checkOtherDao.insert(checkOther);
+	}
+	@Override
+	public List<CheckOther> getCheckByDeptId(CheckOther checkOther) {
+		List<CheckOther> checkOtherList = checkOtherDao.getCheckByDeptId(checkOther);
+		return checkOtherList;
+	}
+	@Override
+	public void delete(Long id) {
+		checkOtherDao.delete(id);
+	}
+	@Override
+	public CheckOther getCheckById(Long id) {
+		CheckOther checkOther = checkOtherDao.getCheckById(id);
+		return checkOther;
+	}
+	@Override
+	public void update(CheckOther checkOther) {
+		checkOtherDao.update(checkOther);
+	}
+}