From 67b129e70011e2f20f235662b0c6aba56d996cda Mon Sep 17 00:00:00 2001
From: chenyc <501753378@qq.com>
Date: 星期一, 18 七月 2022 10:40:06 +0800
Subject: [PATCH] delLOGIN

---
 /dev/null           |  200 --------------------------------------------------
 src/router/index.ts |   19 ----
 2 files changed, 0 insertions(+), 219 deletions(-)

diff --git a/src/router/index.ts b/src/router/index.ts
index ecffb7a..2ba1f62 100644
--- a/src/router/index.ts
+++ b/src/router/index.ts
@@ -7,30 +7,11 @@
     // { path: '/', name: 'Home', component: () => import('@/views/home/index.vue')},
     { path: '/', name: 'test', component: () => import('@/views/home/index.vue')},
     { path: '/test', name: 'Home', component: () => import('@/views/test/index.vue')},
-    { path: '/login', name: 'login', component: () => import('@/views/login/index.vue')},
 ]
 
 const router = createRouter({
     history: createWebHashHistory(),    // history 模式则使用 createWebHistory()
     routes,
 })
-// 路由加载前
-// router.beforeEach(async(to, from, next) => {
-//     // console.log(to, 'to')
-//     const token = Session.get('token')
-//     if (to.path === '/login' && !token) {
-//         next()
-//     }
-//     else {
-//         if (!token||to.path === '/login') {
-//             console.log('如果toke为空,就定位到登录页')
-//             next('/test')
-//             Session.clear()
-//         } else {
-//             next()
-//         }
-        
-//     }
-// })
 
 export default router
\ No newline at end of file
diff --git a/src/views/login/component/account.vue b/src/views/login/component/account.vue
deleted file mode 100644
index 2d3dbbb..0000000
--- a/src/views/login/component/account.vue
+++ /dev/null
@@ -1,169 +0,0 @@
-<template>
-	<el-form class="login-content-form" ref="ruleFormRef">
-		<el-form-item class="form-input">
-			<el-input type="text" placeholder="请输入用户名" :prefix-icon="Avatar" v-model="ruleForm.userName" clearable autocomplete="off">
-			</el-input>
-		</el-form-item>
-		<el-form-item class="form-input form-item-bottom">
-			<el-input
-				:type="isShowPassword ? 'text' : 'password'"
-				placeholder="请输入密码"
-				v-model="ruleForm.password"
-				autocomplete="off"
-				:prefix-icon="GoodsFilled"
-			>
-			</el-input>
-		</el-form-item>
-		<el-form-item>
-			<div class="login-footer">
-				<div>
-					<span style="vertical-align: middle;margin-right:10px">
-						<el-checkbox v-model="rememberPassword"></el-checkbox>
-					</span>
-					<span>自动登录</span>
-				</div>
-			</div>
-		</el-form-item>
-		<el-form-item>
-			<el-button type="primary" class="login-content-submit" round @click="onSignIn" :loading="loading.signIn">
-				<span>立即登录</span>
-			</el-button>
-		</el-form-item>
-	</el-form>
-	
-</template>
-
-<script lang="ts">
-import { toRefs, reactive, defineComponent, computed, getCurrentInstance } from 'vue';
-import { useRoute, useRouter } from 'vue-router';
-import { Session } from '@/utils/storage'
-import { Avatar, GoodsFilled } from '@element-plus/icons-vue'
-import { ElMessage } from 'element-plus';
-
-import {signIn,getuserinfo} from '@/api/user/index';
-export default defineComponent({
-	name: 'loginAccount',
-	setup() {
-		const { proxy } = getCurrentInstance() as any;
-		const route = useRoute();
-		const router = useRouter();
-		const state = reactive({
-			isShowClients2:false,
-			// 记住密码
-			rememberPassword: false,
-			isShowClients:false,
-			isShowPassword: false,
-			user:{},
-			clientCode:'',
-			CilentOptions:[],
-			ruleForm: {
-				userName: '',
-				password: '',
-				code: '1234',
-			},
-			
-			seconds:60,
-			loading: {
-				signIn: false,
-			},
-		});
-		// 登录
-		const onSignIn = async () => {
-			state.loading.signIn = true;
-			if(state.ruleForm.userName===""||state.ruleForm.password===""){
-				ElMessage.error('登录名和密码不能为空')
-				state.loading.signIn = false;
-				return
-			}
-			const signInRes = await signIn(`user_no=${state.ruleForm.userName}&user_password=${state.ruleForm.password}`)
-			// 缓存token游览器
-			Session.set('token', signInRes.data);
-			const userinfoRes = await getuserinfo()
-			const userRet=userinfoRes.data
-			// 模拟数据
-			state.loading.signIn = false;
-			// 跳转到首页
-			router.push('/');
-			
-		};
-		
-		
-		
-		
-		
-		return {
-			onSignIn,
-			GoodsFilled,
-			Avatar,
-			...toRefs(state),
-		};
-	},
-});
-</script>
-
-<style scoped lang="scss">
-.el-input__icon {
-	color: rgb(32, 80, 240);
-}
-.login-content-form {
-	margin-top: 20px;
-	.login-footer {
-		display: flex;
-		justify-content: space-between;
-		font-weight: 400;
-		color: #AAAAAA;
-	}
-	.login-content-password {
-		display: inline-block;
-		width: 25px;
-		cursor: pointer;
-		&:hover {
-			color: #909399;
-		}
-	}
-	.form-input {
-		::v-deep .el-input__inner {
-			border: none !important;
-			border-bottom: 1px solid #EBEBEB !important;
-			padding: 0 50px;
-			font-weight: 500;
-		}
-	}
-	::v-deep .form-item-bottom.el-form-item {
-		margin-bottom: 0 !important;
-	}
-	.login-content-code {
-		display: flex;
-		align-items: center;
-		justify-content: space-around;
-		.login-content-code-img {
-			width: 100%;
-			height: 40px;
-			line-height: 40px;
-			background-color: #ffffff;
-			border: 1px solid rgb(220, 223, 230);
-			color: #333;
-			font-size: 16px;
-			font-weight: 700;
-			letter-spacing: 5px;
-			text-indent: 5px;
-			text-align: center;
-			cursor: pointer;
-			transition: all ease 0.2s;
-			border-radius: 4px;
-			user-select: none;
-			&:hover {
-				border-color: #c0c4cc;
-				transition: all ease 0.2s;
-			}
-		}
-	}
-	.login-content-submit {
-		width: 100%;
-		letter-spacing: 2px;
-		margin-top: 15px;
-		font-weight: 500;
-		color: #FFFFFF;
-	}
-}
-</style>
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
deleted file mode 100644
index f4065ca..0000000
--- a/src/views/login/index.vue
+++ /dev/null
@@ -1,200 +0,0 @@
-<template>
-	<div class="login-container">
-		<div class="login-logo">
-			<span>岱特智能科技</span>
-		</div>
-		<div class="login-content" :class="{ 'login-content-mobile': tabsActiveName === 'mobile' }">
-			<el-row :gutter="0">
-				<el-col :xs="0" :sm="12" :md="12" :lg="12" :xl="12">
-					<div class="login-content-image">
-						<div></div>
-					</div>
-				</el-col>
-				<el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12">
-					<div class="login-content-main">
-						<div class="login-content-title">
-							<div class="login-content-logo"></div>
-							<div class="login-title">胜透血液透析管理平台</div>
-							<div class="login-welcome">WELCOME欢迎登陆</div>
-						</div>
-						<div>
-							<Account />
-						</div>
-					</div>
-				</el-col>
-			</el-row>
-		</div>
-		<div class="login-copyright">
-			<div class="mb5 login-copyright-company"></div>
-			<div class="login-copyright-msg"></div>
-		</div>
-	</div>
-</template>
-
-<script lang="ts">
-import { toRefs, reactive, computed } from 'vue';
-import Account from '@/views/login/component/account.vue';
-export default {
-	name: 'loginIndex',
-	components: { Account },
-	setup() {
-		const state = reactive({
-			tabsActiveName: 'account',
-			isTabPaneShow: true,
-			isScan: false,
-		});
-		return {
-			...toRefs(state),
-		};
-	},
-	
-};
-</script>
-
-<style scoped lang="scss">
-.login-container {
-	width: 100%;
-	height: 100%;
-	background: url('@/assets/imgs/login/login-background.jpg') no-repeat;
-	background-size: 100% 100%;
-	.login-logo {
-		position: absolute;
-		top: 30px;
-		left: 50%;
-		height: 50px;
-		display: flex;
-		align-items: center;
-		font-size: 20px;
-		color: var(--color-primary);
-		letter-spacing: 2px;
-		width: 90%;
-		transform: translateX(-50%);
-	}
-	.login-content {
-		width: 848px;
-		// padding: 20px;
-		position: absolute;
-		top: 50%;
-		left: 50%;
-		transform: translate(-50%, -50%) translate3d(0, 0, 0);
-		background-color: rgba(255, 255, 255, 0.99);
-		// border: 5px solid var(--color-primary-light-8);
-		border-radius: 10px;
-		transition: height 0.2s linear;
-		// height: 480px;
-		overflow: hidden;
-		z-index: 1;
-		.login-content-image {
-			padding: 40px 20px;
-			width: 100%;
-			height: 100%;
-			background-color: #F1F7FF
-		}
-		.login-content-image div {
-			width: 100%;
-			height: 100%;
-			background: url('@/assets/imgs/login/login.jpg') no-repeat;
-			background-size: 100% 100%;
-		}
-		.login-content-main {
-			margin: 75px 50px;
-			// margin: 0 auto;
-			// width: 80%;
-			.login-content-title {
-				color: #333;
-				font-weight: 500;
-			font-size: 22px;
-				text-align: left;
-				// letter-spacing: 4px;
-				// margin: 15px 0 30px;
-				white-space: nowrap;
-				z-index: 5;
-				// position: relative;
-				// transition: all 0.3s ease;
-				.login-content-logo {
-					text-align: left;
-					width: 40px;
-					height: 30px;
-					background: url('@/assets/imgs/login/favicon.svg') no-repeat;
-					display: inline-block;
-					vertical-align: middle;
-				}
-				.login-title {
-					display: inline-block;
-					width: 224px;
-					height: 30px;
-					font-size: 21px;
-					font-family: PingFangSC-Medium, PingFang SC;
-					font-weight: 500;
-					color: #232426;
-					line-height: 30px;
-					letter-spacing: 1px;
-					vertical-align: middle;
-				}
-				.login-welcome {
-					width: 149px;
-					height: 20px;
-					font-size: 14px;
-					font-family: PingFangSC-Medium, PingFang SC;
-					font-weight: 500;
-					color: #AAAAAA;
-					line-height: 20px;
-				}
-			}
-		}
-		.login-content-main-sacn {
-			// position: absolute;
-			// top: 0;
-			// right: 0;
-			// width: 50px;
-			// height: 50px;
-			overflow: hidden;
-			cursor: pointer;
-			transition: all ease 0.3s;
-			&-delta {
-				position: absolute;
-				width: 35px;
-				height: 70px;
-				z-index: 2;
-				top: 2px;
-				right: 21px;
-				background: var(--el-color-white);
-				transform: rotate(-45deg);
-			}
-			&:hover {
-				opacity: 1;
-				transition: all ease 0.3s;
-				color: var(--color-primary);
-			}
-			i {
-				width: 47px;
-				height: 50px;
-				display: inline-block;
-				font-size: 48px;
-				position: absolute;
-				right: 2px;
-				top: -1px;
-			}
-		}
-	}
-	.login-content-mobile {
-		height: 418px;
-	}
-	.login-copyright {
-		position: absolute;
-		left: 50%;
-		transform: translateX(-50%);
-		bottom: 30px;
-		text-align: center;
-		color: var(--color-whites);
-		font-size: 12px;
-		opacity: 0.8;
-		.login-copyright-company {
-			white-space: nowrap;
-		}
-		.login-copyright-msg {
-			@extend .login-copyright-company;
-		}
-	}
-}
-</style>

--
Gitblit v1.8.0