运费模板 品牌 计量单位 支持刷新功能

master
15386982806 2024-01-05 15:10:48 +08:00
parent 560199944d
commit 77e7d095a7
4 changed files with 27 additions and 1 deletions

View File

@ -3,6 +3,7 @@
<Card> <Card>
<Row class="operation"> <Row class="operation">
<Button @click="add" type="primary">添加</Button> <Button @click="add" type="primary">添加</Button>
<Button @click="refresh"></Button>
<Button @click="delAll"></Button> <Button @click="delAll"></Button>
</Row> </Row>
<Table <Table
@ -284,6 +285,15 @@ export default {
}, },
}); });
}, },
//
refresh() {
this.loading = true;
setTimeout(() => {
this.getDataList();
this.loading = false;
this.$Message.success("刷新成功");
}, 500);
},
// //
delAll() { delAll() {
if (this.selectCount <= 0) { if (this.selectCount <= 0) {

View File

@ -10,6 +10,7 @@
</Form> </Form>
<Row class="operation padding-row"> <Row class="operation padding-row">
<Button @click="add" type="primary">添加</Button> <Button @click="add" type="primary">添加</Button>
<Button @click="refresh"></Button>
</Row> </Row>
<Table :loading="loading" border :columns="columns" :data="data" ref="table"></Table> <Table :loading="loading" border :columns="columns" :data="data" ref="table"></Table>
<Row type="flex" justify="end" class="mt_10"> <Row type="flex" justify="end" class="mt_10">
@ -314,6 +315,15 @@ export default {
delete this.form.id; delete this.form.id;
this.modalVisible = true; this.modalVisible = true;
}, },
//
refresh() {
this.loading = true;
setTimeout(() => {
this.getDataList();
this.loading = false;
this.$Message.success("刷新成功");
}, 500);
},
// //
edit(v) { edit(v) {
this.modalType = 1; this.modalType = 1;

View File

@ -140,8 +140,10 @@ export default {
this.loading = true; this.loading = true;
let that = this; let that = this;
setTimeout(function () { setTimeout(function () {
that.init();
that.$Message.success("刷新成功");
that.loading = false; that.loading = false;
}, 1000); }, 500);
}, },
// //
addChildren(v) { addChildren(v) {
@ -261,4 +263,7 @@ export default {
min-height: 100vh; min-height: 100vh;
height: auto; height: auto;
} }
.operation {
margin-bottom: 10px;
}
</style> </style>

View File

@ -294,6 +294,7 @@ export default {
this.operation = "INFO"; this.operation = "INFO";
this.currentTab = "INFO"; this.currentTab = "INFO";
this.getData(); this.getData();
this.$Message.success("刷新成功");
}, },
// //
getData() { getData() {