Commit 8835c938 authored by 李苏's avatar 李苏 💬

时间戳调整

parent 575e7461
<template>
<DefaultDialog :app='app'>
<div v-loading="loading" element-loading-text='正在同步请稍后!' slot="form" style="display: flex;padding: 30px;padding-bottom: 60px;" class="flex-center" >
<RelDatetimerangeV2 :form='form' start='startTime' end='endTime' />
<RelDaterangeV2 :form='form' start='startTime' end='endTime' />
</div>
<div slot="reFooter" class="refooter" >
<span slot="footer" class="dialog-footer" >
......@@ -25,20 +25,29 @@
}
},
async mounted() {
this.form.endTime=this.getStartOfToday()
this.form.startTime=this.getStartOfToday() - 7*24*60*60*1000
},
data() {
return {
loading:false,
form:{
startTime:new Date().getTime() - 7*24*60*60*1000,
endTime:new Date().getTime()
startTime:'',
endTime:''
}
}
},
methods: {
getStartOfToday() {
const today = new Date();
// 重置小时、分钟、秒和毫秒为0
today.setHours(0, 0, 0, 0);
return new Date(today).getTime() ;
},
save(){
if(this.form.startTime&&this.form.endTime){
this.$confirm('是否继续该操作?', '提示', {
......@@ -48,7 +57,7 @@
}).then(res=>{
if(this.form.startTime&&this.form.endTime){
this.loading=true
this.$post('jxgl/usbjx/sync/jx',this.form).then(res=>{
this.$post('sync/jx',this.form).then(res=>{
if(res.success){
this.$success('操作成功!')
this.loading=false
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment