import { createRouter,createWebHashHistory } from "vue-router";

const routes = [
    {
    path:"/",
    name:"index",
    component:()=>import("@/page/index/index.vue")
    },
    {
        path:"/index_service",
        name:"index_service",
        component:()=>import("@/page/index/service_people/index_service.vue")
        },
    {
        path:"/institution",
        name:"institution",
        component:()=>import("@/page/index/institution_index.vue")
    },
    {
        path:"/institutionDetail",
        name:"institutionDetail",
        component:()=>import("@/page/index/institution_detail.vue")
    },
    {
        path:"/serviceDetail",
        name:"serviceDetail",
        component:()=>import("@/page/index/service_detail.vue")
    },
    {
        path:"/found",
        name:"found",
        component:()=>import("@/page/found/found.vue")
    },
    {
    path:"/publish",
    name:"publish",
    component:()=>import("@/page/publish/publish.vue")
    },
    {
        path:"/mine",
        name:"mine",
        component:()=>import("@/page/mine/mine.vue")
    },   
    {
        path:"/addressList",
        name:"addressList",
        component:()=>import("@/page/mine/addressList.vue")
    },  
    {
        path:"/addressAdit",
        name:"addressAdit",
        component:()=>import("@/page/mine/addressAdit.vue")
    },  
    {
            path:"/login",
            name:"login",
            component:()=>import("@/page/login.vue")
    },   
    {
        path:"/register",
        name:"register",
        component:()=>import("@/page/register.vue")
        },   
        {
            path:"/forgot-password",
            name:"forgot-password",
            component:()=>import("@/page/register.vue")
            },   
            {
                path:"/orders",
                name:"orders",
                component:()=>import("@/page/mine/orders.vue"),
                props: (route) => ({ status: route.query.status }),
            },   
        

];

const router = createRouter({
    history:createWebHashHistory(),
    routes,
});

export default router;