fix: 修复eslint检测问题和生产打包问题
Former-commit-id: dbba543597dd24d5c8b61287590cdc43db22874a
This commit is contained in:
@@ -112,7 +112,7 @@ export function getDictItemDetail(id: number): AxiosPromise<DictItemFormData> {
|
||||
*
|
||||
* @param data
|
||||
*/
|
||||
export function addDictItem(data: DictFormData) {
|
||||
export function addDictItem(data: any) {
|
||||
return request({
|
||||
url: '/youlai-admin/api/v2/dict/items',
|
||||
method: 'post',
|
||||
@@ -126,7 +126,7 @@ export function addDictItem(data: DictFormData) {
|
||||
* @param id
|
||||
* @param data
|
||||
*/
|
||||
export function updateDictItem(id: number, data: DictFormData) {
|
||||
export function updateDictItem(id: number, data: any) {
|
||||
return request({
|
||||
url: '/youlai-admin/api/v2/dict/items/' + id,
|
||||
method: 'put',
|
||||
|
||||
@@ -1,13 +1,7 @@
|
||||
<template>
|
||||
<div class="login-container">
|
||||
<el-form
|
||||
ref="loginFormRef"
|
||||
:model="loginForm"
|
||||
:rules="loginRules"
|
||||
class="login-form"
|
||||
auto-complete="on"
|
||||
label-position="left"
|
||||
>
|
||||
<el-form ref="loginFormRef" :model="loginForm" :rules="loginRules" class="login-form" auto-complete="on"
|
||||
label-position="left">
|
||||
<div class="title-container">
|
||||
<h3 class="title">{{ $t("login.title") }}</h3>
|
||||
<lang-select class="set-language" />
|
||||
@@ -17,43 +11,20 @@
|
||||
<span class="svg-container">
|
||||
<svg-icon icon-class="user" />
|
||||
</span>
|
||||
<el-input
|
||||
ref="username"
|
||||
v-model="loginForm.username"
|
||||
:placeholder="$t('login.username')"
|
||||
name="username"
|
||||
type="text"
|
||||
tabindex="1"
|
||||
auto-complete="on"
|
||||
/>
|
||||
<el-input ref="username" v-model="loginForm.username" :placeholder="$t('login.username')" name="username"
|
||||
type="text" tabindex="1" auto-complete="on" />
|
||||
</el-form-item>
|
||||
|
||||
<el-tooltip
|
||||
:disabled="capslockTooltipDisabled"
|
||||
content="Caps lock is On"
|
||||
placement="right"
|
||||
>
|
||||
<el-tooltip :disabled="capslockTooltipDisabled" content="Caps lock is On" placement="right">
|
||||
<el-form-item prop="password">
|
||||
<span class="svg-container">
|
||||
<svg-icon icon-class="password" />
|
||||
</span>
|
||||
<el-input
|
||||
ref="passwordRef"
|
||||
:key="passwordType"
|
||||
v-model="loginForm.password"
|
||||
:type="passwordType"
|
||||
placeholder="Password"
|
||||
name="password"
|
||||
tabindex="2"
|
||||
auto-complete="on"
|
||||
@keyup="checkCapslock"
|
||||
@blur="capslockTooltipDisabled = true"
|
||||
@keyup.enter="handleLogin"
|
||||
/>
|
||||
<el-input ref="passwordRef" :key="passwordType" v-model="loginForm.password" :type="passwordType"
|
||||
placeholder="Password" name="password" tabindex="2" auto-complete="on" @keyup="checkCapslock"
|
||||
@blur="capslockTooltipDisabled = true" @keyup.enter="handleLogin" />
|
||||
<span class="show-pwd" @click="showPwd">
|
||||
<svg-icon
|
||||
:icon-class="passwordType === 'password' ? 'eye' : 'eye-open'"
|
||||
/>
|
||||
<svg-icon :icon-class="passwordType === 'password' ? 'eye' : 'eye-open'" />
|
||||
</span>
|
||||
</el-form-item>
|
||||
</el-tooltip>
|
||||
@@ -63,36 +34,20 @@
|
||||
<span class="svg-container">
|
||||
<svg-icon icon-class="validCode" />
|
||||
</span>
|
||||
<el-input
|
||||
v-model="loginForm.code"
|
||||
auto-complete="off"
|
||||
:placeholder="$t('login.code')"
|
||||
style="width: 65%"
|
||||
@keyup.enter="handleLogin"
|
||||
/>
|
||||
<el-input v-model="loginForm.code" auto-complete="off" :placeholder="$t('login.code')" style="width: 65%"
|
||||
@keyup.enter="handleLogin" />
|
||||
|
||||
<div class="captcha">
|
||||
<img
|
||||
:src="captchaBase64"
|
||||
@click="handleCaptchaGenerate"
|
||||
height="38px"
|
||||
/>
|
||||
<img :src="captchaBase64" @click="handleCaptchaGenerate" height="38px" />
|
||||
</div>
|
||||
</el-form-item>
|
||||
|
||||
<el-button
|
||||
size="default"
|
||||
:loading="loading"
|
||||
type="primary"
|
||||
style="width: 100%; margin-bottom: 30px"
|
||||
@click.prevent="handleLogin"
|
||||
>{{ $t("login.login") }}
|
||||
<el-button size="default" :loading="loading" type="primary" style="width: 100%; margin-bottom: 30px"
|
||||
@click.prevent="handleLogin">{{ $t("login.login") }}
|
||||
</el-button>
|
||||
|
||||
<div class="tips">
|
||||
<span style="margin-right: 20px"
|
||||
>{{ $t("login.username") }}: admin</span
|
||||
>
|
||||
<span style="margin-right: 20px">{{ $t("login.username") }}: admin</span>
|
||||
<span> {{ $t("login.password") }}: 123456</span>
|
||||
</div>
|
||||
</el-form>
|
||||
@@ -128,6 +83,7 @@ const loginFormRef = ref(ElForm);
|
||||
const passwordRef = ref(ElInput);
|
||||
|
||||
const state = reactive({
|
||||
redirect: "",
|
||||
loginForm: {
|
||||
username: "admin",
|
||||
password: "123456",
|
||||
@@ -206,7 +162,7 @@ function handleLogin() {
|
||||
|
||||
// 获取验证码
|
||||
function handleCaptchaGenerate() {
|
||||
getCaptcha().then(({data}) => {
|
||||
getCaptcha().then(({ data }) => {
|
||||
const { img, uuid } = data;
|
||||
state.captchaBase64 = "data:image/gif;base64," + img;
|
||||
state.loginForm.uuid = uuid;
|
||||
@@ -306,6 +262,7 @@ $cursor: #fff;
|
||||
border-color: var(--el-input-hover-border, var(--el-border-color-hover));
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
|
||||
@@ -27,7 +27,6 @@ import { CaretRight } from '@element-plus/icons-vue';
|
||||
// API 引用
|
||||
import { listCascadeCategories } from "@/api/pms/category";
|
||||
import { computed } from "@vue/reactivity";
|
||||
import { GoodsDetail } from "@/types";
|
||||
|
||||
const emit = defineEmits(['next', "update:modelValue"])
|
||||
const props = defineProps({
|
||||
|
||||
@@ -28,12 +28,6 @@ import { useRoute } from "vue-router";
|
||||
import { GoodsDetail } from "@/types";
|
||||
|
||||
const route = useRoute();
|
||||
const props = defineProps({
|
||||
goodsId: {
|
||||
type: String,
|
||||
default: () => ''
|
||||
}
|
||||
})
|
||||
|
||||
const state = reactive({
|
||||
loaded: false,
|
||||
|
||||
@@ -132,7 +132,7 @@ const state = reactive({
|
||||
dictCode: props.dictCode,
|
||||
dictName: props.dictName,
|
||||
status: 1,
|
||||
sort: 1,
|
||||
sort: 1
|
||||
} as DictItemFormData,
|
||||
rules: {
|
||||
name: [{ required: true, message: "请输入字典项名称", trigger: "blur" }],
|
||||
|
||||
Reference in New Issue
Block a user