feat: 修改404页面

pull/117/head
zhengkunwang223 2023-02-03 11:17:31 +08:00 committed by zhengkunwang223
parent a99ea07086
commit 8c599d7b75
11 changed files with 68 additions and 75 deletions

View File

@ -14,7 +14,8 @@ import (
) )
func Init() { func Init() {
stdout, err := cmd.Exec("grep '^BASE_DIR=' /usr/bin/1pctl | cut -d'=' -f2") //stdout, err := cmd.Exec("grep '^BASE_DIR=' /usr/bin/1pctl | cut -d'=' -f2")
stdout, err := cmd.Exec("grep '^BASE_DIR=' /Users/wangzhengkun/Downloads/1pctl | cut -d'=' -f2")
if err != nil { if err != nil {
panic(err) panic(err)
} }

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.6 KiB

View File

@ -0,0 +1,17 @@
<svg width="250" height="250" viewBox="0 0 250 250" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_802_165199)">
<path d="M249.172 92.9244C249.172 90.7152 247.382 88.9243 245.172 88.9243H55.1377C52.9286 88.9243 51.1377 90.7152 51.1377 92.9243V229.034C51.1377 231.243 52.9286 233.034 55.1377 233.034H245.172C247.381 233.034 249.172 231.243 249.172 229.034L249.172 92.9244Z" fill="#EFF2F4"/>
<path d="M233 68.019C233 65.8099 231.209 64.019 229 64.019H38.9653C36.7562 64.019 34.9653 65.8099 34.9653 68.019V204.128C34.9653 206.338 36.7562 208.128 38.9653 208.128H229C231.209 208.128 233 206.338 233 204.128V68.019Z" fill="#D6DAE1"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M152.048 82.2305H88.6361V74.2305H152.048V82.2305ZM231.798 99.2336H35.8599V91.2336H231.798V99.2336Z" fill="white"/>
<path d="M87.8191 167.68L62.8885 174.655L59.7402 163.399L76.3791 126.791L88.3067 123.454L96.7762 153.726L102.959 151.997L105.928 162.613L99.7466 164.343L102.322 173.55L90.3947 176.886L87.8191 167.68ZM84.8487 157.063L80.515 141.574L71.6783 160.748L84.8487 157.063ZM117.588 156.854C116.834 147.162 118.045 140.243 121.222 136.101C124.423 131.955 129.594 129.604 136.736 129.049C140.168 128.782 143.019 128.992 145.288 129.678C147.556 130.341 149.44 131.303 150.938 132.563C152.433 133.799 153.635 135.141 154.54 136.587C155.467 138.008 156.251 139.696 156.894 141.652C158.141 145.382 158.924 149.31 159.246 153.437C159.966 162.69 158.927 169.583 156.131 174.117C153.335 178.651 148.11 181.215 140.458 181.811C136.167 182.144 132.648 181.73 129.897 180.568C127.148 179.405 124.823 177.568 122.925 175.056C121.549 173.273 120.388 170.787 119.439 167.593C118.512 164.376 117.895 160.797 117.588 156.854ZM131.644 155.796C132.149 162.288 133.063 166.685 134.385 168.985C135.728 171.261 137.49 172.313 139.67 172.143C141.108 172.031 142.309 171.437 143.275 170.358C144.263 169.255 144.915 167.594 145.232 165.376C145.572 163.157 145.564 159.74 145.204 155.126C144.678 148.354 143.744 143.854 142.404 141.626C141.086 139.372 139.279 138.335 136.982 138.513C134.641 138.695 133.041 140.021 132.183 142.491C131.324 144.937 131.144 149.372 131.644 155.796ZM194.748 162.33L169.064 159.09L170.528 147.493L200.063 120.204L212.351 121.753L208.417 152.941L214.786 153.744L213.406 164.682L207.037 163.879L205.84 173.364L193.552 171.813L194.748 162.33ZM196.129 151.391L198.141 135.433L182.56 149.679L196.129 151.391Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M3.28383 18.1852C3.28383 18.1847 3.28384 18.1844 4.28374 18.1986C5.28364 18.2128 5.28363 18.2131 5.28362 18.2136L5.11981 29.7394C5.01992 36.7579 4.88407 46.2865 4.74024 56.3273C4.45261 76.4078 4.13305 98.5381 4.0054 106.735C3.86666 116.908 6.40507 122.677 9.65955 125.312C12.8429 127.889 17.0116 127.69 20.8188 125.212L21.9098 126.888C17.5859 129.703 12.4347 130.131 8.40114 126.866C4.43883 123.658 1.86345 117.116 2.0056 106.706C2.13322 98.5121 2.45279 76.3806 2.74045 56.2987C2.88427 46.2579 3.02012 36.7293 3.12001 29.711L3.28383 18.1852Z" fill="#231815"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M20.4399 93.1866C20.4399 93.1863 20.4399 93.1861 21.4394 93.2192C22.4388 93.2523 22.4388 93.2524 22.4388 93.2527L22.4251 93.6773C22.4162 93.9554 22.4033 94.3641 22.3873 94.8866C22.3553 95.9316 22.3108 97.4314 22.2609 99.2502C22.1611 102.888 22.0398 107.801 21.9536 112.902C21.8674 118.005 21.8164 123.29 21.8569 127.675C21.8979 132.102 22.0328 135.504 22.2945 136.914L22.295 136.917C22.683 139.038 23.73 140.465 25.0424 141.334C26.3721 142.213 28.0347 142.558 29.6827 142.382C32.9991 142.03 35.9607 139.647 35.9607 135.793H37.9607C37.9607 140.912 33.9675 143.938 29.8943 144.371C27.8474 144.589 25.7064 144.171 23.9387 143.002C22.1537 141.82 20.8095 139.911 20.3276 137.277C20.0275 135.656 19.8974 132.059 19.857 127.693C19.8162 123.283 19.8675 117.978 19.9539 112.868C20.0402 107.758 20.1617 102.838 20.2616 99.1954C20.3116 97.3742 20.3562 95.8722 20.3882 94.8254C20.4043 94.302 20.4172 93.8923 20.4261 93.6135L20.4399 93.1866Z" fill="#231815"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M36.5228 98.2076C36.5228 98.2073 36.5228 98.2072 37.5225 98.2316C38.5222 98.2561 38.5222 98.2562 38.5222 98.2565L38.4876 99.7049C38.4657 100.632 38.4347 101.963 38.3984 103.581C38.3257 106.817 38.2314 111.198 38.1451 115.781C37.972 124.968 37.8325 134.908 37.9586 138.106C38.1494 142.952 42.3455 145.702 46.4836 145.179C48.5277 144.92 50.5409 143.853 51.9986 141.805C53.4606 139.75 54.4133 136.635 54.1668 132.217L56.1637 132.106C56.4287 136.855 55.4158 140.452 53.6281 142.964C51.836 145.482 49.3154 146.837 46.7345 147.163C41.6227 147.81 36.2044 144.385 35.9602 138.185C35.8311 134.913 35.9731 124.896 36.1454 115.744C36.2318 111.157 36.3261 106.773 36.3989 103.536C36.4353 101.917 36.4662 100.585 36.4881 99.6577L36.5228 98.2076Z" fill="#231815"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M76.724 42.5859V16H74.724V44.6782L75.7846 44.6133L75.7871 44.6132L75.7992 44.6125L75.8529 44.6098C75.9018 44.6074 75.9762 44.6041 76.0747 44.6007C76.2718 44.5938 76.5649 44.5862 76.9416 44.5842C77.6951 44.5801 78.7813 44.598 80.0994 44.6864C82.7398 44.8636 86.2893 45.3227 89.9515 46.4442C97.2773 48.6877 104.893 53.5143 106.83 63.9209L108.797 63.5549C106.669 52.1255 98.2398 46.8908 90.5372 44.5319C86.6851 43.3522 82.9745 42.8749 80.2333 42.6909C78.8606 42.5988 77.7256 42.5799 76.9307 42.5842C76.859 42.5846 76.7901 42.5852 76.724 42.5859ZM79.2776 63.6387C80.4582 63.1571 81.7621 63.0666 83.1686 63.4052L82.7004 65.3497C81.6649 65.1004 80.7921 65.1809 80.0329 65.4906C79.2623 65.8049 78.5415 66.3833 77.8713 67.232C76.5132 68.9516 75.4764 71.6353 74.7118 74.8526C73.1894 81.2595 72.85 89.3143 72.8119 94.6327C72.7865 98.1769 73.088 102.35 73.4103 106.81C73.569 109.007 73.7328 111.274 73.865 113.57C74.2615 120.455 74.3676 127.55 73.096 133.397C71.7529 139.573 66.9813 142.489 62.4228 142.055C57.8459 141.62 53.7493 137.84 53.6807 131.303L53.6807 131.293C53.6807 128.728 53.7766 119.892 53.8724 111.707C53.9203 107.613 53.9683 103.678 54.0042 100.767L54.0641 95.9699C54.0641 95.9697 54.0641 95.9685 55.064 95.9812C56.064 95.9939 56.064 95.994 56.064 95.9943L56.0041 100.792C55.9681 103.703 55.9202 107.637 55.8723 111.731C55.7765 119.918 55.6808 128.731 55.6807 131.287C55.7413 136.867 59.1227 139.732 62.6121 140.064C66.1208 140.398 70.0047 138.2 71.1416 132.972C72.35 127.416 72.2644 120.562 71.8683 113.685C71.7407 111.468 71.58 109.243 71.4228 107.064C71.0971 102.553 70.786 98.2414 70.8119 94.6184C70.8503 89.2751 71.1883 81.0299 72.766 74.3902C73.5516 71.0843 74.6705 68.058 76.3017 65.9925C77.1261 64.9486 78.1084 64.1156 79.2776 63.6387Z" fill="#231815"/>
</g>
<defs>
<clipPath id="clip0_802_165199">
<rect width="250" height="250" fill="white"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.9 KiB

View File

@ -1,18 +0,0 @@
<template>
<div class="not-container">
<img src="@/assets/images/403.png" class="not-img" alt="403" />
<div class="not-detail">
<h2>403</h2>
<h4>抱歉您无权访问该页面~🙅🙅</h4>
<!-- <el-button type="primary" @click="tabStore.goHome()"
>返回首页</el-button
> -->
</div>
</div>
</template>
<script setup lang="ts" name="403"></script>
<style scoped lang="scss">
@import './index.scss';
</style>

View File

@ -1,12 +1,9 @@
<template> <template>
<div class="not-container"> <div class="not-container">
<img src="@/assets/images/404.png" class="not-img" alt="404" /> <img src="@/assets/images/404.svg" class="not-img" alt="404" />
<div class="not-detail"> <div class="not-detail">
<h2>404</h2> <h2>404</h2>
<h4>抱歉您访问的页面不存在~🤷🤷</h4> <h4>{{ $t('commons.msg.notFound') }}</h4>
<!-- <el-button type="primary" @click="tabStore.goHome()"
>返回首页</el-button -->
<!-- > -->
</div> </div>
</div> </div>
</template> </template>
@ -14,5 +11,34 @@
<script setup lang="ts" name="404"></script> <script setup lang="ts" name="404"></script>
<style scoped lang="scss"> <style scoped lang="scss">
@import './index.scss'; .not-container {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
.not-img {
margin-top: 300px;
}
.not-detail {
margin-top: 300px;
display: flex;
flex-direction: column;
h2,
h4 {
padding: 0;
margin: 0;
}
h2 {
font-size: 60px;
color: #434e59;
}
h4 {
margin: 30px 0 20px;
font-size: 19px;
font-weight: normal;
color: #848587;
}
}
}
</style> </style>

View File

@ -1,18 +0,0 @@
<template>
<div class="not-container">
<img src="@/assets/images/500.png" class="not-img" alt="500" />
<div class="not-detail">
<h2>500</h2>
<h4>抱歉您的网络不见了~🤦🤦</h4>
<!-- <el-button type="primary" @click="tabStore.goHome()"
>返回首页</el-button -->
>
</div>
</div>
</template>
<script setup lang="ts" name="500"></script>
<style scoped lang="scss">
@import './index.scss';
</style>

View File

@ -1,32 +0,0 @@
.not-container {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
.not-img {
margin-right: 120px;
}
.not-detail {
display: flex;
flex-direction: column;
h2,
h4 {
padding: 0;
margin: 0;
}
h2 {
font-size: 60px;
color: #434e59;
}
h4 {
margin: 30px 0 20px;
font-size: 19px;
font-weight: normal;
color: #848587;
}
.el-button {
width: 100px;
}
}
}

View File

@ -89,6 +89,7 @@ export default {
copyfailed: '', copyfailed: '',
backupSuccess: '', backupSuccess: '',
restoreSuccess: '', restoreSuccess: '',
notFound: '访',
}, },
login: { login: {
firstLogin: '', firstLogin: '',

View File

@ -19,6 +19,22 @@
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item :label="$t('setting.theme')" :rules="Rules.requiredSelect" prop="theme">
<el-radio-group
@change="onSave(panelFormRef, 'Theme', form.theme)"
v-model="form.theme"
>
<el-radio-button label="light">
<el-icon><Sunny /></el-icon>
{{ $t('setting.light') }}
</el-radio-button>
<el-radio-button label="dark">
<el-icon><Moon /></el-icon>
{{ $t('setting.dark') }}
</el-radio-button>
</el-radio-group>
</el-form-item>
<el-form-item :label="$t('setting.title')" :rules="Rules.requiredInput" prop="panelName"> <el-form-item :label="$t('setting.title')" :rules="Rules.requiredInput" prop="panelName">
<el-input clearable v-model="form.panelName"> <el-input clearable v-model="form.panelName">
<template #append> <template #append>