Commit 661af077 by 张辉

添加loading

parent cc2923d4
Showing with 5 additions and 2 deletions
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
<script> <script>
import { Header } from "@/components"; import { Header } from "@/components";
import { Icon } from "vant"; import { Icon,Toast } from "vant";
import { mapGetters, mapActions } from "vuex"; import { mapGetters, mapActions } from "vuex";
import dayjs from "dayjs"; import dayjs from "dayjs";
import setBarHeight from "../../assets/js/setBarHeight.js"; import setBarHeight from "../../assets/js/setBarHeight.js";
...@@ -80,12 +80,14 @@ export default { ...@@ -80,12 +80,14 @@ export default {
} }
}, },
getData() { getData() {
Toast.loading({ duration: 0, message: "加载中..." });
this.loadReceiptDetail({ this.loadReceiptDetail({
accountId: this.currentPerId, accountId: this.currentPerId,
type: this.type, type: this.type,
}).then( }).then(
(data) => { (data) => {
this.data = data; this.data = data;
Toast.clear();
}, },
(err) => { (err) => {
console.log(err); console.log(err);
...@@ -204,7 +206,7 @@ export default { ...@@ -204,7 +206,7 @@ export default {
.empty_data{ .empty_data{
color:#c2c2c2; color:#c2c2c2;
margin:100px auto; margin:100px auto;
width: 120px; width: 135px;
} }
} }
</style> </style>
\ No newline at end of file
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 sign in to comment