chore: 💄 更新logo样式,登录二维码

This commit is contained in:
H0nGzA1
2023-03-20 21:23:51 +08:00
parent 0c3fa62a27
commit 7199e30131
7 changed files with 3047 additions and 272 deletions

View File

@@ -1,6 +1,6 @@
MIT License
Copyright (c) 2023 dvadmin,hugedream
Copyright (c) 2023 DVAdmin,hugedream
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

File diff suppressed because it is too large Load Diff

Before

Width:  |  Height:  |  Size: 4.1 KiB

After

Width:  |  Height:  |  Size: 212 KiB

View File

@@ -2,7 +2,7 @@
<div class="layout-footer pb15">
<div class="layout-footer-warp">
<div> Powered by Django-Vue3-Admin </div>
<div class="mt5">Copyright dvadmin团队</div>
<div class="mt5">Copyright DVAdmin团队</div>
</div>
</div>
</template>

View File

@@ -1,7 +1,7 @@
<template>
<div class="layout-logo" v-if="setShowLogo" @click="onThemeConfigChange">
<img :src="logoMini" class="layout-logo-medium-img" />
<span>{{ themeConfig.globalTitle }}</span>
<span style="font-size: x-large">{{ themeConfig.globalTitle }}</span>
</div>
<div class="layout-logo-size" v-else @click="onThemeConfigChange">
<img :src="logoMini" class="layout-logo-size-img" />
@@ -52,7 +52,7 @@ const onThemeConfigChange = () => {
}
}
&-medium-img {
width: 20px;
width: 40px;
margin-right: 5px;
}
}
@@ -63,7 +63,7 @@ const onThemeConfigChange = () => {
cursor: pointer;
animation: logoAnimation 0.3s ease-in-out;
&-img {
width: 20px;
width: 40px;
margin: auto;
}
&:hover {

View File

@@ -137,9 +137,9 @@ export const useThemeConfig = defineStore('themeConfig', {
* 全局网站标题 / 副标题
*/
// 网站主标题(菜单导航、浏览器当前网页标题)
globalTitle: 'dvadmin',
globalTitle: 'DVAdmin',
// 网站副标题(登录页顶部文字)
globalViceTitle: 'dvadmin',
globalViceTitle: 'DVAdmin',
// 网站副标题(登录页顶部文字)
globalViceTitleMsg: '企业级快速开发平台',
// 默认初始语言,可选值"<zh-cn|en|zh-tw>",默认 zh-cn

View File

@@ -1,220 +1,225 @@
import * as api from "./api";
import { dict, PageQuery, AddReq, DelReq, EditReq, CrudExpose, CrudOptions, } from "@fast-crud/fast-crud";
import { request } from "/@/utils/service";
import { dictionary } from "/@/utils/dictionary";
import * as api from './api';
import { dict, PageQuery, AddReq, DelReq, EditReq, CrudExpose, CrudOptions } from '@fast-crud/fast-crud';
import { verifyPhone } from '/@/utils/toolsValidate';
import { request } from '/@/utils/service';
import { dictionary } from '/@/utils/dictionary';
interface CreateCrudOptionsTypes {
crudOptions: CrudOptions;
crudOptions: CrudOptions;
}
export const createCrudOptions = function ({ crudExpose }: { crudExpose: CrudExpose }): CreateCrudOptionsTypes {
const pageRequest = async (query: PageQuery) => {
return await api.GetList(query);
};
const editRequest = async ({ form, row }: EditReq) => {
form.id = row.id;
return await api.UpdateObj(form);
};
const delRequest = async ({ row }: DelReq) => {
return await api.DelObj(row.id);
};
const addRequest = async ({ form }: AddReq) => {
return await api.AddObj(form);
};
const pageRequest = async (query: PageQuery) => {
return await api.GetList(query);
};
const editRequest = async ({ form, row }: EditReq) => {
form.id = row.id;
return await api.UpdateObj(form);
};
const delRequest = async ({ row }: DelReq) => {
return await api.DelObj(row.id);
};
const addRequest = async ({ form }: AddReq) => {
return await api.AddObj(form);
};
/**
* 懒加载
* @param row
* @returns {Promise<unknown>}
*/
const loadContentMethod = (tree: any, treeNode: any, resolve: any) => {
api.GetList({ parent: tree.id }).then((res: any) => {
resolve(res.data);
});
};
/**
* 懒加载
* @param row
* @returns {Promise<unknown>}
*/
const loadContentMethod = (tree: any, treeNode: any, resolve: any) => {
api.GetList({ parent: tree.id }).then((res: any) => {
resolve(res.data);
});
};
return {
crudOptions: {
request: {
pageRequest,
addRequest,
editRequest,
delRequest
},
pagination: {
show: false,
},
table: {
rowKey: 'id',
lazy: true,
load: loadContentMethod,
treeProps: { children: 'children', hasChildren: 'hasChild' },
},
rowHandle:{
fiexd:'right',
width:310,
buttons:{
addChildren:{
text: "添加子级",
type:"warning",
click(context){
const rowId =context.row.id
crudExpose.openAdd({ row: { parent: rowId } })
}
}
}
},
columns: {
_index: {
title: '序号',
form: { show: false },
column: {
type: 'index',
align: 'center',
width: '70px',
columnSetDisabled: true, //禁止在列设置中选择
},
},
search: {
title: '关键词',
column: {
show: false
},
search: {
show: true,
component: {
props: {
clearable: true
},
placeholder: '请输入关键词'
}
},
form: {
show: false,
component: {
props: {
clearable: true
}
}
},
},
name: {
title: '部门名称',
sortable: true,
treeNode: true, // 设置为树形列
search: {
disabled: false,
component: {
props: {
clearable: true
}
}
},
width: 180,
type: 'input',
form: {
rules: [
// 表单校验规则
{ required: true, message: '部门名称必填项' }
],
component: {
span: 12,
props: {
clearable: true
},
placeholder: '请输入部门名称'
},
}
},
key: {
title: '部门标识',
sortable: true,
form: {
component: {
props: {
clearable: true
},
placeholder: '请输入标识字符'
},
}
},
owner: {
title: '负责人',
sortable: true,
form: {
component: {
span: 12,
props: {
clearable: true
},
placeholder: '请输入负责人'
}
}
},
phone: {
title: '联系电话',
sortable: true,
form: {
component: {
span: 12,
props: {
clearable: true
},
placeholder: '请输入联系电话'
}
}
},
email: {
title: '邮箱',
sortable: true,
form: {
component: {
span: 12,
props: {
clearable: true
},
placeholder: '请输入邮箱'
},
rules: [
{
type: 'email',
message: '请输入正确的邮箱地址',
trigger: ['blur', 'change']
}
]
}
},
sort: {
title: '排序',
sortable: true,
width: 80,
type: 'number',
form: {
value: 1,
component: {
span: 12,
placeholder: '请选择序号'
}
}
},
status: {
title: '状态',
sortable: true,
search: {
disabled: false
},
type: 'dict-radio',
dict: dict({
data: dictionary('button_status_bool')
}),
form: {
value: true,
component: {
span: 12,
placeholder: '请选择状态'
}
}
}
}
},
}
}
return {
crudOptions: {
request: {
pageRequest,
addRequest,
editRequest,
delRequest,
},
pagination: {
show: false,
},
table: {
rowKey: 'id',
lazy: true,
load: loadContentMethod,
treeProps: { children: 'children', hasChildren: 'hasChild' },
},
rowHandle: {
fiexd: 'right',
width: 310,
buttons: {
addChildren: {
text: '添加子级',
type: 'warning',
click(context) {
const rowId = context.row.id;
crudExpose.openAdd({ row: { parent: rowId } });
},
},
},
},
columns: {
_index: {
title: '序号',
form: { show: false },
column: {
type: 'index',
align: 'center',
width: '70px',
columnSetDisabled: true, //禁止在列设置中选择
},
},
search: {
title: '关键词',
column: {
show: false,
},
search: {
show: true,
component: {
props: {
clearable: true,
},
placeholder: '请输入关键词',
},
},
form: {
show: false,
component: {
props: {
clearable: true,
},
},
},
},
name: {
title: '部门名称',
sortable: true,
treeNode: true, // 设置为树形列
search: {
disabled: false,
component: {
props: {
clearable: true,
},
},
},
width: 180,
type: 'input',
form: {
rules: [
// 表单校验规则
{ required: true, message: '部门名称必填项' },
],
component: {
span: 12,
props: {
clearable: true,
},
placeholder: '请输入部门名称',
},
},
},
key: {
title: '部门标识',
sortable: true,
form: {
component: {
props: {
clearable: true,
},
placeholder: '请输入标识字符',
},
},
},
owner: {
title: '负责人',
sortable: true,
form: {
component: {
span: 12,
props: {
clearable: true,
},
placeholder: '请输入负责人',
},
},
},
phone: {
title: '联系电话',
sortable: true,
form: {
rules: [
{ required: true, message: '请输入联系电话' },
{ validator: verifyPhone, trigger: 'change' },
],
component: {
span: 12,
props: {
clearable: true,
},
placeholder: '请输入联系电话',
},
},
},
email: {
title: '邮箱',
sortable: true,
form: {
component: {
span: 12,
props: {
clearable: true,
},
placeholder: '请输入邮箱',
},
rules: [
{
type: 'email',
message: '请输入正确的邮箱地址',
trigger: ['blur', 'change'],
},
],
},
},
sort: {
title: '排序',
sortable: true,
width: 80,
type: 'number',
form: {
value: 1,
component: {
span: 12,
placeholder: '请选择序号',
},
},
},
status: {
title: '状态',
sortable: true,
search: {
disabled: false,
},
type: 'dict-radio',
dict: dict({
data: dictionary('button_status_bool'),
}),
form: {
value: true,
component: {
span: 12,
placeholder: '请选择状态',
},
},
},
},
},
};
};

View File

@@ -17,7 +17,7 @@ export default defineComponent({
const initQrcode = () => {
(qrcodeRef.value as HTMLElement).innerHTML = '';
new QRCode(qrcodeRef.value, {
text: `https://jq.qq.com/?_wv=1027&k=8keWoTap`,
text: `https://jq.qq.com/?_wv=1027&k=hUu2GeU1`,
width: 260,
height: 260,
colorDark: '#000000',