去除不必要代码

This commit is contained in:
dqz 2025-03-11 08:58:19 +08:00
parent 1ab653eebe
commit c862472dee
5 changed files with 112 additions and 180 deletions

View File

@ -1,7 +1,7 @@
# 线上环境平台打包路径
VITE_PUBLIC_PATH = ./
VITE_PUBLIC_PATH = /shop-admin/
# 线上环境路由历史模式Hash模式传"hash"、HTML5模式传"h5"、Hash模式带base参数传"hash,base参数"、HTML5模式带base参数传"h5,base参数"
# 预发布环境路由历史模式Hash模式传"hash"、HTML5模式传"h5"、Hash模式带base参数传"hash,base参数"、HTML5模式带base参数传"h5,base参数"
VITE_ROUTER_HISTORY = "hash"
# 是否在打包时使用cdn替换本地库 替换 true 不替换 false
@ -13,4 +13,4 @@ VITE_CDN = false
VITE_COMPRESSION = "none"
# 后端地址
VITE_APP_BASE_API = '/prod-api'
VITE_APP_BASE_API = '/shop-back-end'

View File

@ -1,14 +1,13 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<meta name="renderer" content="webkit" />
<meta
name="viewport"
content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=0"
/>
<title>Agileboot管理系统</title>
<meta name="viewport"
content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=0" />
<title>微商城管理系统</title>
<link rel="icon" href="/favicon.ico" />
<script>
window.process = {};
@ -69,6 +68,7 @@
}
@keyframes load-animation {
0%,
80%,
100% {
@ -84,4 +84,5 @@
</div>
<script type="module" src="/src/main.ts"></script>
</body>
</html>

View File

@ -1,6 +1,6 @@
{
"Version": "4.4.0",
"Title": "Agileboot",
"Title": "微商城后台管理系统",
"FixedHeader": true,
"HiddenSideBar": false,
"MultiTagsCache": false,

View File

@ -158,13 +158,8 @@ onBeforeUnmount(() => {
<img :src="bg" class="wave" />
<div class="absolute flex-c right-5 top-3">
<!-- 主题 -->
<el-switch
v-model="dataTheme"
:active-icon="dayIcon"
:inactive-icon="darkIcon"
inline-prompt
@change="dataThemeChange"
/>
<el-switch v-model="dataTheme" :active-icon="dayIcon" :inactive-icon="darkIcon" inline-prompt
@change="dataThemeChange" />
</div>
<div class="login-container">
<div class="img">
@ -181,63 +176,36 @@ onBeforeUnmount(() => {
</h2>
</Motion>
<el-form
v-if="currentPage === 0"
ref="ruleFormRef"
:model="ruleForm"
:rules="loginRules"
size="large"
>
<el-form v-if="currentPage === 0" ref="ruleFormRef" :model="ruleForm" :rules="loginRules" size="large">
<Motion :delay="100">
<el-form-item
:rules="[
<el-form-item :rules="[
{
required: true,
message: '请输入账号',
trigger: 'blur'
}
]"
prop="username"
>
<el-input
v-model="ruleForm.username"
:prefix-icon="useRenderIcon(User)"
clearable
placeholder="账号"
/>
]" prop="username">
<el-input v-model="ruleForm.username" :prefix-icon="useRenderIcon(User)" clearable placeholder="账号" />
</el-form-item>
</Motion>
<Motion :delay="150">
<el-form-item prop="password">
<el-input
v-model="ruleForm.password"
:prefix-icon="useRenderIcon(Lock)"
clearable
placeholder="密码"
show-password
/>
<el-input v-model="ruleForm.password" :prefix-icon="useRenderIcon(Lock)" clearable placeholder="密码"
show-password />
</el-form-item>
</Motion>
<Motion :delay="200">
<el-form-item v-if="isCaptchaOn" prop="captchaCode">
<el-input
v-model="ruleForm.captchaCode"
:prefix-icon="useRenderIcon('ri:shield-keyhole-line')"
clearable
placeholder="验证码"
>
<el-input v-model="ruleForm.captchaCode" :prefix-icon="useRenderIcon('ri:shield-keyhole-line')"
clearable placeholder="验证码">
<template v-slot:append>
<el-image
:src="captchaCodeBase64"
style="
<el-image :src="captchaCodeBase64" style="
justify-content: center;
width: 120px;
height: 40px;
"
@click="getCaptchaCode"
>
" @click="getCaptchaCode">
<template #error>
<span>Loading</span>
</template>
@ -255,13 +223,8 @@ onBeforeUnmount(() => {
忘记密码
</el-button>
</div>
<el-button
:loading="loading"
class="w-full mt-4"
size="default"
type="primary"
@click="onLogin(ruleFormRef)"
>
<el-button :loading="loading" class="w-full mt-4" size="default" type="primary"
@click="onLogin(ruleFormRef)">
登录
</el-button>
</el-form-item>
@ -270,13 +233,8 @@ onBeforeUnmount(() => {
<Motion :delay="300">
<el-form-item>
<div class="w-full h-[20px] flex justify-between items-center">
<el-button
v-for="(item, index) in operates"
:key="index"
class="w-full mt-4"
size="default"
@click="currentPage = item.page"
>
<el-button v-for="(item, index) in operates" :key="index" class="w-full mt-4" size="default"
@click="currentPage = item.page">
{{ item.title }}
</el-button>
</div>
@ -290,16 +248,9 @@ onBeforeUnmount(() => {
<p class="text-xs text-gray-500">{{ "第三方登录" }}</p>
</el-divider>
<div class="flex w-full justify-evenly">
<span
v-for="(item, index) in thirdParty"
:key="index"
:title="item.title"
>
<IconifyIconOnline
:icon="`ri:${item.icon}-fill`"
class="text-gray-500 cursor-pointer hover:text-blue-400"
width="20"
/>
<span v-for="(item, index) in thirdParty" :key="index" :title="item.title">
<IconifyIconOnline :icon="`ri:${item.icon}-fill`"
class="text-gray-500 cursor-pointer hover:text-blue-400" width="20" />
</span>
</div>
</el-form-item>
@ -309,31 +260,12 @@ onBeforeUnmount(() => {
<!-- 二维码登录 -->
<qrCode v-if="currentPage === 2" v-model:current-page="currentPage" />
<!-- 注册 -->
<register
v-if="currentPage === 3"
v-model:current-page="currentPage"
/>
<register v-if="currentPage === 3" v-model:current-page="currentPage" />
<!-- 忘记密码 -->
<resetPassword
v-if="currentPage === 4"
v-model:current-page="currentPage"
/>
<resetPassword v-if="currentPage === 4" v-model:current-page="currentPage" />
</div>
</div>
</div>
<!-- 底部 -->
<div class="flex items-center justify-center h-full">
<div class="flex flex-col items-center justify-center mb-3">
<span>Copyright © 2018-2023 Agileboot All Rights Reserved. </span>
<el-link
href="https://beian.miit.gov.cn"
rel="external nofollow"
target="_blank"
type="primary"
>闽ICP备2022018106号-2
</el-link>
</div>
</div>
</div>
</template>

View File

@ -5,5 +5,4 @@ defineOptions({
</script>
<template>
<h1>Agileboot前端预览</h1>
</template>