完成数据备份页面
This commit is contained in:
parent
4738f5744d
commit
3c74876d9f
|
@ -5,35 +5,12 @@
|
|||
<div class="table-page-search-wrapper">
|
||||
<a-form layout="inline" @keyup.enter.native="searchQuery">
|
||||
<a-row :gutter="24">
|
||||
<a-col :md="5" :sm="5">
|
||||
<a-form-item label="任务名称">
|
||||
<a-input placeholder="请输入" v-model="queryParam.databaseName"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :md="5" :sm="5">
|
||||
<a-form-item label="数据库">
|
||||
<a-select placeholder="请选择" option-filter-prop="children" size="small" v-model="queryParam.schemaName">
|
||||
<a-select-option v-for="d in allSchemaName" :key="d">
|
||||
{{ d }}
|
||||
</a-select-option>
|
||||
</a-select>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :md="5" :sm="5">
|
||||
<a-form-item label="调度开始时间">
|
||||
<a-date-picker v-model="queryParam.startTime" @change="onChangeStartTime" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :md="5" :sm="5">
|
||||
<a-form-item label="调度结束时间">
|
||||
<a-date-picker v-model="queryParam.endtime" @change="onChangeEndTime" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
||||
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
|
||||
<a-col :md="4" :sm="4">
|
||||
<a-button type="primary" style="left: 10px" @click="loadData" icon="search">查询</a-button>
|
||||
<a-button type="primary" @click="searchReset" icon="reload"
|
||||
style="margin-left: 8px;left: 10px">重置</a-button>
|
||||
<a-button type="primary" style="left: 10px" @click="backup" icon="plus">一键备份</a-button>
|
||||
<a-button type="primary" @click="searchReset" icon="plus"
|
||||
style="margin-left: 8px;left: 10px">添加</a-button>
|
||||
</a-col>
|
||||
</span>
|
||||
|
||||
|
@ -78,19 +55,7 @@
|
|||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
shipModelPageList,
|
||||
shipModeldeleteById
|
||||
} from '@/api/ship'
|
||||
import { getAction } from '@/api/manage'
|
||||
import {
|
||||
taskCreate,
|
||||
taskUpdateById,
|
||||
taskQueryById,
|
||||
taskPageList,
|
||||
taskDistributeTask,
|
||||
taskDeleteById
|
||||
} from '@/api/task'
|
||||
import { getAction, deleteAction, putAction, postAction } from '@/api/manage'
|
||||
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
||||
import JEllipsis from "@/components/jeecg/JEllipsis";
|
||||
|
||||
|
@ -108,22 +73,12 @@ export default {
|
|||
return {
|
||||
description: '数据库备份',
|
||||
dataSource: [
|
||||
{
|
||||
id: "1",
|
||||
name: "第一次备份",
|
||||
dataBaseName: 'test',
|
||||
startTime: "2024-03-06 10:30:26",
|
||||
endTime: "2024-03-06 15:30:26",
|
||||
larmder: '',
|
||||
Status: 2,
|
||||
endisStatus: 1
|
||||
}
|
||||
],
|
||||
schemaName: "",
|
||||
allSchemaName: [],
|
||||
queryParam: {
|
||||
pageNum: 1,
|
||||
pageSize: 20
|
||||
pageSize: 10
|
||||
},
|
||||
columns: [
|
||||
{
|
||||
|
@ -212,7 +167,14 @@ export default {
|
|||
});
|
||||
},
|
||||
loadData() {
|
||||
|
||||
getAction("/idcDataBackup/list?pageNo=1&pageSize=10").then((res) => {
|
||||
if (res.success) {
|
||||
console.log(res)
|
||||
this.dataSource = res.result;
|
||||
} else {
|
||||
this.$message.warning(res.message);
|
||||
}
|
||||
});
|
||||
},
|
||||
handleDelete: function (id) {
|
||||
var that = this;
|
||||
|
@ -240,9 +202,14 @@ export default {
|
|||
}
|
||||
});
|
||||
},
|
||||
handleAdd() {
|
||||
this.$refs.modalForm.add();
|
||||
this.$refs.modalForm.title = "新增";
|
||||
backup() {
|
||||
postAction("/idcDataBackup/dmExportByUserName?userName=data_conn_original",{}).then(res => {
|
||||
if (res.success) {
|
||||
that.$message.success(res.message);
|
||||
} else {
|
||||
that.$message.warning(res.message);
|
||||
}
|
||||
})
|
||||
},
|
||||
onChangeStartTime(date, dateString) {
|
||||
console.log(date, dateString);
|
||||
|
|
Loading…
Reference in New Issue
Block a user