/**
 * meta 参数说明
 * form:表单路由，存在或ture,也要后台配置，前端校验
 * mode:功能入口路由，存在或ture,也要后台配置，前端校验
 */
const routesCommon = [
	/***公共***/
	{
		path: '/common',
		component: () => import('../views/Layout.vue'),
		children: [
			//消息
			{
				path: 'notice',
				component: () => import('../views/Layout.vue'),
				children: [
					//消息列表
					{
						path: '',
						name: 'CommonNotice',
						component: () => import('../views/Common/Notice/Home.vue'),
						meta: {
							requireAuth: false,
							role: [],
							title: '消息列表',
						}
					},
					//消息详情
					{
						path: 'info',
						name: 'CommonNoticeInfo',
						component: () => import('../views/Common/Notice/Info.vue'),
						meta: {
							requireAuth: false,
							role: [],
							title: '消息详情',
						}
					},
					//发送通知
					{
						path: 'send',
						name: 'CommonNoticeSend',
						component: () => import('../views/Common/Notice/Send.vue'),
						meta: {
							requireAuth: true,
							role: [],
							title: '发送通知',
							mode: true
						}
					},
				]
			},
			//健康
			{
				path: 'health',
				component: () => import('../views/Layout.vue'),
				children: [
					//健康证
					{
						path: 'cert',
						name: 'CommonHealthCert',
						component: () => import('../views/Common/Health/Cert.vue'),
						meta: {
							requireAuth: true,
							role: [],
							title: '健康证',
							mode: true
						}
					},
					//测温记录
					{
						path: 'temperatureRecord',
						name: 'CommonHealthTemperatureRecord',
						component: () => import('../views/Common/Health/TemperatureRecord.vue'),
						meta: {
							requireAuth: true,
							role: [],
							title: '测温记录',
							mode: true
						}
					},
					//测温详情
					{
						path: 'temperatureInfo',
						name: 'CommonHealthTemperatureInfo',
						component: () => import('@/views/Common/Health/TemperatureInfo.vue'),
						meta: {
							requireAuth: true,
							role: [],
							title: '测温详情',
						}
					},

				]
			},
			//设备
			{
				path: 'device',
				component: () => import('../views/Layout.vue'),
				children: [
					//设备列表
					{
						path: 'list',
						name: 'CommonDeviceList',
						component: () => import('@/views/Common/Device/List.vue'),
						meta: {
							requireAuth: true,
							role: [],
							title: '设备列表',
							mode: true
						}
					},
					//手机开门
					{
						path: 'openDoor',
						name: 'CommonDeviceOpenDoor',
						component: () => import('../views/Common/Device/OpenDoor.vue'),
						meta: {
							requireAuth: true,
							role: [],
							title: '手机开门',
							mode: true
						}
					},
					//手表绑定列表
					{
						path: 'liveBindList',
						name: 'CommonDeviceLiveBindList',
						component: () => import('../views/Common/Device/LiveBindList.vue'),
						meta: {
							requireAuth: true,
							role: [],
							title: '手表绑定列表',
							mode: true
						}
					},
					//手表绑定列表
					{
						path: 'liveBindListAdmin',
						name: 'CommonDeviceLiveBindListAdmin',
						component: () => import('../views/Common/Device/LiveBindListAdmin.vue'),
						meta: {
							requireAuth: true,
							role: [],
							title: '手表绑定列表(高管)',
							mode: true
						}
					},
					//手表绑定详情
					{
						path: 'liveBindInfo',
						name: 'CommonDeviceLiveBindInfo',
						component: () => import('../views/Common/Device/LiveBindInfo.vue'),
						meta: {
							requireAuth: false,
							role: [],
							title: '手表绑定详情',
						}
					},
				],
			},

		],
	}
]

export default routesCommon
