1
0
mirror of https://github.com/fumiama/paper-manager.git synced 2026-06-22 11:30:32 +08:00

edit login page

This commit is contained in:
源文雨
2023-03-13 23:11:09 +08:00
parent 4116f971f7
commit c14eb49661
6 changed files with 50 additions and 31 deletions

View File

@@ -27,7 +27,17 @@
<span class="inline-block mt-4 text-3xl"> {{ t('sys.login.signInTitle') }}</span>
</div>
<div class="mt-5 font-normal text-white dark:text-gray-500 -enter-x">
{{ t('sys.login.signInDesc') }}
{{
t(
'sys.login.signInDesc',
((): string[] => {
let hour: number = new Date().getHours()
if (hour < 10) return ['早']
else if (hour < 19) return ['午']
else return ['晚']
})(),
)
}}
</div>
</div>
</div>

View File

@@ -1,28 +1,37 @@
<template>
<LoginFormTitle v-show="getShow" class="enter-x" />
<Form
<!--<Form
class="p-4 enter-x"
:model="formData"
:rules="getFormRules"
ref="formRef"
v-show="getShow"
@keypress.enter="handleLogin"
>-->
<Form
class="p-4 enter-x"
:rules="getFormRules"
ref="formRef"
v-show="getShow"
@keypress.enter="handleLogin"
>
<FormItem name="account" class="enter-x">
<Input
<Input size="large" :placeholder="t('sys.login.userName')" class="fix-auto-fill" />
<!--<Input
size="large"
v-model:value="formData.account"
:placeholder="t('sys.login.userName')"
class="fix-auto-fill"
/>
/> -->
</FormItem>
<FormItem name="password" class="enter-x">
<InputPassword
<InputPassword size="large" visibilityToggle :placeholder="t('sys.login.password')" />
<!-- <InputPassword
size="large"
visibilityToggle
v-model:value="formData.password"
:placeholder="t('sys.login.password')"
/>
/>-->
</FormItem>
<ARow class="enter-x">
@@ -72,7 +81,7 @@
</Form>
</template>
<script lang="ts" setup>
import { reactive, ref, unref, computed } from 'vue'
import { /*reactive,*/ ref, unref, computed } from 'vue'
import { Checkbox, Form, Input, Row, Col, Button } from 'ant-design-vue'
import LoginFormTitle from './LoginFormTitle.vue'
@@ -101,10 +110,10 @@
const loading = ref(false)
const rememberMe = ref(false)
const formData = reactive({
/*const formData = reactive({
account: 'vben',
password: '123456',
})
})*/
const { validForm } = useFormValid(formRef)