// const Login = () =>
//     import ('../views/Login.vue')


// const Home = () =>
//     import ('../views/Home.vue')


// const Register = () =>
//     import ('../views/Register.vue')


// const ChangePassword = () =>
//     import ('../views/ChangePassword.vue')


// const Main = () =>
//     import ('../views/Main.vue')


// const EditWorkList = () =>
//     import ('../components/EditWorkList.vue')

// const WorkList = () =>
//     import ('../components/Worklist.vue')

// import Login from '../views/Login.vue';
// import Home from '../views/Home.vue';
// import Register from '../views/Register.vue';
// import ChangePassword from '../views/ChangePassword.vue';
// import Main from '../views/Main.vue';

// import EditWorkList from '../components/EditWorkList.vue';
// import WorkList from '../components/Worklist.vue';

// import AppVersion from '../views/AppVersion.vue';

// const routes = [{
//         path: '/',
//         component: () =>
//             import ('../views/Home.vue'),
//         name: 'Home'
//     },
//     {
//         path: '/appversion',
//         component: AppVersion,
//         name: 'AppVersion'
//     },
//     {
//         path: '/signin',
//         component: () =>
//             import ('../views/Login.vue'),
//         name: 'signin'
//     },
//     {
//         path: '/signup',
//         component: () =>
//             import ('../views/Register.vue'),
//         name: 'signup'
//     },
//     {
//         path: '/changePassword',
//         component: () =>
//             import ('../views/ChangePassword.vue'),
//         name: 'changePassword'
//     }, {
//         path: '/main',
//         component: () =>
//             import ('../views/Main.vue'),
//         name: 'main',
//         children: [{
//             path: "worklist",
//             name: "worklist",
//             components: {
//                 default: () =>
//                     import ('../components/Worklist.vue'),
//                 edit_worklist: () =>
//                     import ('../components/EditWorkList.vue')
//             }
//         }]
//     }
// ];

// export default routes;










import Login from '../views/Login.vue';
import Home from '../views/Home.vue';
// import Register from '../views/Register.vue';
import ChangePassword from '../views/ChangePassword.vue';
import Main from '../views/Main.vue';

import EditWorkList from '../components/EditWorkList.vue';
import RegisterPatient from '../components/RegisterPatient.vue';
// import WorkList from '../components/Worklist.vue';
// import HisLink from '../components/HisLink.vue';
import DeviceMap from '../components/DeviceMap.vue';
import Client from '../components/Client.vue';

import Users from '../components/Users.vue';
import UserSetting from '../components/UserSetting.vue';

import AppVersion from '../views/AppVersion.vue';

const routes = [{
        path: '/',
        component: Home,
        name: 'Home'
    },
    {
        path: '/appversion',
        component: AppVersion,
        name: 'AppVersion'
    },
    {
        path: '/signin',
        component: Login,
        name: 'signin'
    },
    // {
    //     path: '/signup',
    //     component: Register,
    //     name: 'signup'
    // },
    {
        path: '/changePassword',
        component: ChangePassword,
        name: 'changePassword'
    }, {
        path: '/main',
        component: Main,
        name: 'main',
        children: [{
            path: "worklist",
            name: "worklist",
            components: {
                // default: WorkList,
                default: () =>
                    import ('../components/Worklist.vue'),
                register_patient: RegisterPatient
                    // edit_worklist: WorkList
            }
        }, {
            path: "hislink",
            name: "hislink",
            // component: HisLink
            component: () =>
                import ('../components/HisLink.vue')
        }, {
            path: "devicemap",
            name: "devicemap",
            component: DeviceMap
        }, {
            path: "client",
            name: "client",
            component: Client
        }, {
            path: "users",
            name: "users",
            component: Users
        }, {
            path: "usersetting",
            name: "usersetting",
            component: UserSetting
        }]
    }
];

export default routes;