考勤页面bug修改
diff --git a/src/main/resources/templates/atte/dtl/index.html b/src/main/resources/templates/atte/dtl/index.html
index 9ce231e..bf675e5 100644
--- a/src/main/resources/templates/atte/dtl/index.html
+++ b/src/main/resources/templates/atte/dtl/index.html
@@ -281,10 +281,7 @@
             deptfor:function (row) {
                 return dept_grpname(row.deptcode);
             },
-            refreshdtl:function (){
-                var _that=this;
-                refreshAtteDtl(_that);
-            }
+
 
         },
         created:function(){
@@ -330,21 +327,7 @@
         }
 
     })
-    function refreshAtteDtl(that){
-        var startdate=class_Formatdate(that.attedtlform.startdate);
-        var enddate=class_Formatdate(that.attedtlform.enddate);
-        if(startdate== '' || enddate=='') {
-            layer.msg("请选择日期", {icon: 2, time: 1000});
-            return;
-        }
-        if(startdate>enddate){
-            layer.msg("开始日期不能大于结束日期!", {icon: 2, time: 1000});
-            return;
-        }
-        layer.confirm('你确定要刷新所选日期的流水吗?', {icon: 3, title:'请确认',offset:'30%'},function (){
 
-        })
-    }
     function dateformatter(time){
         return time.substr(0,4)+'-'+time.substr(4,2)+'-'+time.substr(6,2);
     }
diff --git a/src/main/resources/templates/atte/report/p_index.html b/src/main/resources/templates/atte/report/p_index.html
index 12a5e05..6b3e0d5 100644
--- a/src/main/resources/templates/atte/report/p_index.html
+++ b/src/main/resources/templates/atte/report/p_index.html
@@ -262,10 +262,7 @@
             deptfor:function (row) {
                 return dept_grpname(row.deptcode);
             },
-            refreshdtl:function (){
-                var _that=this;
-                refreshAtteDtl(_that);
-            }
+
 
         },
         created:function(){
@@ -312,30 +309,7 @@
         }
 
     })
-    function refreshAtteDtl(that){
-        var startdate=class_Formatdate(that.preportform.startdate);
-        var enddate=class_Formatdate(that.preportform.enddate);
-        if(startdate== '' || enddate=='') {
-            layer.msg("请选择日期", {icon: 2, time: 1000});
-            return;
-        }
-        if(startdate>enddate){
-            layer.msg("开始日期不能大于结束日期!", {icon: 2, time: 1000});
-            return;
-        }
-        layer.confirm('你确定要刷新所选日期的流水吗?', {icon: 3, title:'请确认',offset:'30%'},function (){
 
-            $.ajax({
-                type:"get",
-                dataType:"json",
-                url:"[[@{/atte/adddtlbyhand?enddate=}]]"+enddate+"&startdate="+startdate,
-                success:function(ret){
-                    layer.msg('保存信息成功!', {icon: 1, time: 1000});
-                    dtl_refreshThisTable();
-                }
-            })
-        })
-    }
     function dateformatter(time){
         return time.substr(0,4)+'-'+time.substr(4,2)+'-'+time.substr(6,2);
     }
diff --git a/src/main/resources/templates/atte/rest/index.html b/src/main/resources/templates/atte/rest/index.html
index ed37bd4..f9b6db6 100644
--- a/src/main/resources/templates/atte/rest/index.html
+++ b/src/main/resources/templates/atte/rest/index.html
@@ -298,10 +298,7 @@
             deptfor:function (row) {
                 return dept_grpname(row.deptcode);
             },
-            refreshdtl:function (){
-                var _that=this;
-                refreshAtteDtl(_that);
-            },
+
             deleteRest:function(row){
                 delRest(row.id);
             }
@@ -344,30 +341,7 @@
         }
 
     })
-    function refreshAtteDtl(that){
-        var startdate=class_Formatdate(that.preportform.startdate);
-        var enddate=class_Formatdate(that.preportform.enddate);
-        if(startdate== '' || enddate=='') {
-            layer.msg("请选择日期", {icon: 2, time: 1000});
-            return;
-        }
-        if(startdate>enddate){
-            layer.msg("开始日期不能大于结束日期!", {icon: 2, time: 1000});
-            return;
-        }
-        layer.confirm('你确定要刷新所选日期的流水吗?', {icon: 3, title:'请确认',offset:'30%'},function (){
 
-            $.ajax({
-                type:"get",
-                dataType:"json",
-                url:"[[@{/atte/adddtlbyhand?enddate=}]]"+enddate+"&startdate="+startdate,
-                success:function(ret){
-                    layer.msg('保存信息成功!', {icon: 1, time: 1000});
-                    dtl_refreshThisTable();
-                }
-            })
-        })
-    }
     function dateformatter(time){
         return time.substr(0,4)+'-'+time.substr(4,2)+'-'+time.substr(6,2);
     }
diff --git a/src/main/resources/templates/atte/timedtl/index.html b/src/main/resources/templates/atte/timedtl/index.html
index c8a86b6..25cec89 100644
--- a/src/main/resources/templates/atte/timedtl/index.html
+++ b/src/main/resources/templates/atte/timedtl/index.html
@@ -8,14 +8,14 @@
     </div>
     <div class="layui-card-body" >
         <div id="timedtlapp">
-            <el-form :inline="true" ref="attedtlform" :model="attedtlform" data-parsley-validate class="form-horizontal form-label-left">
+            <el-form :inline="true" ref="timedtlform" :model="timedtlform" data-parsley-validate class="form-horizontal form-label-left">
                 <div class="col-md-4">
                     <div class="form-group">
                         <label class="control-label col-md-4 col-sm-12 col-xs-12" style="font-size: 14px;">开始日期:</span>
                         </label>
                         <div class="col-md-8 col-sm-12 col-xs-12">
                             <el-date-picker style="width: 100%"
-                                    v-model="attedtlform.startdate" type="date"
+                                    v-model="timedtlform.startdate" type="date"
                                     placeholder="选择日期" :editable="false"  value-format="yyyyMMdd">
                             </el-date-picker>
                         </div>
@@ -27,7 +27,7 @@
                         </label>
                         <div class="col-md-8 col-sm-12 col-xs-12">
                             <el-date-picker style="width: 100%"
-                                    v-model="attedtlform.enddate" type="date"
+                                    v-model="timedtlform.enddate" type="date"
                                     placeholder="选择日期" :editable="false"  value-format="yyyyMMdd">
                             </el-date-picker>
                         </div>
@@ -38,7 +38,7 @@
                         <label class="control-label col-md-4 col-sm-12 col-xs-12" style="font-size: 14px;">卡号:</span>
                         </label>
                         <div class="col-md-8 col-sm-12 col-xs-12">
-                            <el-input v-model="attedtlform.cardno" placeholder="输入%模糊查询"></el-input>
+                            <el-input v-model="timedtlform.cardno" placeholder="输入%模糊查询"></el-input>
                         </div>
                     </div>
                 </div>
@@ -48,7 +48,7 @@
                         <label class="control-label col-md-4 col-sm-12 col-xs-12" style="font-size: 14px;">姓名:</span>
                         </label>
                         <div class="col-md-8 col-sm-12 col-xs-12">
-                            <el-input v-model="attedtlform.custname" ></el-input>
+                            <el-input v-model="timedtlform.custname" ></el-input>
                         </div>
                     </div>
                 </div>
@@ -57,7 +57,7 @@
                         <label class="control-label col-md-4 col-sm-12 col-xs-12" style="font-size: 14px;">人员类别:</span>
                         </label>
                         <div class="col-md-8 col-sm-12 col-xs-12">
-                            <el-select v-model="attedtlform.custtypeid" style="width:100%;" clearable filterable placeholder="请选择">
+                            <el-select v-model="timedtlform.custtypeid" style="width:100%;" clearable filterable placeholder="请选择">
                                 <el-option
                                         v-for="custtypeid in typegrplist"
                                         :key="custtypeid.value"
@@ -240,7 +240,7 @@
             currentRow: null,
             stategrplist:[{value:0,label:'未打卡'},{value:1,label:'正常'},{value:2,label:'迟到早退'},
                 {value:11,label:'事假'},{value:12,label:'病假'},{value:13,label:'年假'},{value:14,label:'调休'},{value:15,label:'其他'},],
-            attedtlform:{
+            timedtlform:{
                 startdate:Date.now(),
                 enddate:Date.now(),
                 cardno:'',
@@ -248,6 +248,7 @@
                 custtypeid:'',
                 deptcode:''
             },
+            refreshflag:'1',
             timegrplist:[],
             typegrplist:[],
             deptlist:[],
@@ -273,11 +274,11 @@
         methods: {
             handleSizeChange:function(val) {
                 this.pageSize=val;
-                attedtl_commonQuery(this,this.currPage,val);
+                timedtl_commonQuery(this,this.currPage,val);
             },
             currPageChange:function(val) {
                 this.currPage=val;
-                attedtl_commonQuery(this,this.currPage,this.pageSize);
+                timedtl_commonQuery(this,this.currPage,this.pageSize);
             },
             currRowChange:function(val) {
                 this.currentRow = val;
@@ -310,7 +311,7 @@
             query:function () {
                 this.pagesize=10;
                 this.currPage=1;
-                attedtl_commonQuery(this,this.currPage,this.pageSize);
+                timedtl_commonQuery(this,this.currPage,this.pageSize);
             },
             resetForm:function(formName) {
                 this.$refs[formName].resetFields();
@@ -346,8 +347,8 @@
         created:function(){
             var _self=this;
             var token=$("meta[name='_csrf_token']").attr("value");
-            var startdate=class_Formatdate(_self.attedtlform.startdate);
-            var enddate=class_Formatdate(_self.attedtlform.enddate);
+            var startdate=class_Formatdate(_self.timedtlform.startdate);
+            var enddate=class_Formatdate(_self.timedtlform.enddate);
             $.ajax({
                 type:"post",
                 dataType:"json",
@@ -358,7 +359,7 @@
                     'Content-Type': 'application/json',
                     'X-CSRF-TOKEN':token,
                 },
-                data:JSON.stringify(_self.attedtlform),
+                data:JSON.stringify(_self.timedtlform),
                 success:function(ret){
                     // //console.log(ret);
                    _self.totSize=ret.PageResult.totalCount;
@@ -396,8 +397,9 @@
 
     })
     function refreshAtteDtl(that){
-        var startdate=class_Formatdate(that.attedtlform.startdate);
-        var enddate=class_Formatdate(that.attedtlform.enddate);
+
+        var startdate=class_Formatdate(that.timedtlform.startdate);
+        var enddate=class_Formatdate(that.timedtlform.enddate);
         if(startdate== '' || enddate=='') {
             layer.msg("请选择日期", {icon: 2, time: 1000});
             return;
@@ -407,14 +409,19 @@
             return;
         }
         layer.confirm('你确定要刷新所选日期的流水吗?', {icon: 3, title:'请确认',offset:'30%'},function (){
-
+            if(that.refreshflag == '0'){
+                layer.msg('请稍等!', {icon: 1, time: 1000});
+                return ;
+            }
+            that.refreshflag='0';
             $.ajax({
                 type:"get",
                 dataType:"json",
                 url:"[[@{/atte/adddtlbyhand?enddate=}]]"+enddate+"&startdate="+startdate,
                 success:function(ret){
                     layer.msg('保存信息成功!', {icon: 1, time: 1000});
-                    dtl_refreshThisTable();
+                    that.refreshflag='1';
+                    timedtl_refreshThisTable();
                 }
             })
         })
@@ -486,11 +493,11 @@
 
         return formated;
     }
-    function attedtl_commonQuery(_self,pageno,pagesize) {
+    function timedtl_commonQuery(_self,pageno,pagesize) {
 
         var token=$("meta[name='_csrf_token']").attr("value");
-        var startdate=class_Formatdate(_self.attedtlform.startdate);
-        var enddate=class_Formatdate(_self.attedtlform.enddate);
+        var startdate=class_Formatdate(_self.timedtlform.startdate);
+        var enddate=class_Formatdate(_self.timedtlform.enddate);
         $.ajax({
             type:"post",
             dataType:"json",
@@ -501,7 +508,7 @@
                 'Content-Type': 'application/json',
                 'X-CSRF-TOKEN':token,
             },
-            data:JSON.stringify(_self.attedtlform),
+            data:JSON.stringify(_self.timedtlform),
             success:function(ret){
                 _self.totSize=ret.PageResult.totalCount;
                 _self.tableData=ret.PageResult.list;
@@ -549,7 +556,7 @@
                     } else {
                         layer.msg('保存信息成功!', {icon: 1, time: 1000});
                         _that.dialogFormVisible = false;
-                        dtl_refreshThisTable();
+                        timedtl_refreshThisTable();
                         _that.$refs[formName].resetFields();
                     }
                 }
@@ -557,8 +564,8 @@
 
     }
 
-    function dtl_refreshThisTable(){
-        attedtl_commonQuery(timedtl_vue,timedtl_vue.currPage,timedtl_vue.pageSize);
+    function timedtl_refreshThisTable(){
+        timedtl_commonQuery(timedtl_vue,timedtl_vue.currPage,timedtl_vue.pageSize);
     };