优化下单页面

This commit is contained in:
TOP糯米 2023-04-02 18:08:05 +08:00
parent 3d1729dad0
commit 9f75725b3d
1 changed files with 10 additions and 2 deletions

View File

@ -70,7 +70,7 @@ import AppLayout from "@/components/layout/layout";
import ServicePreviewItem from "@/components/service/preview-item";
import WidgetTips from "@/components/widgets/tips";
import ServiceInsurance from "@/components/service/insurance";
import { mapState } from "vuex";
import { mapGetters, mapState } from "vuex";
export default {
name: "order-create",
data() {
@ -98,8 +98,12 @@ export default {
...mapState({
insurancePrice: (state) => state.service.insurancePrice,
}),
...mapGetters({
isLogin: "user/isLogin",
}),
},
onLoad(e) {
this.serviceList = [];
this.pageConfig = getApp().globalData.pageConfig;
this.$store.dispatch("service/insurancePrice");
if (!e.orderData) {
@ -126,7 +130,11 @@ export default {
});
});
},
onShow() {},
onShow() {
if (!this.isLogin) {
this.$store.commit("user/showLoginModal", true);
}
},
onReady() {},
onReachBottom() {},
onPullDownRefresh() {},