新增租户头像功能
This commit is contained in:
parent
719e73aa77
commit
fb6cce17e5
@ -19,13 +19,26 @@ export const columns = [
|
|||||||
label: '租户编码',
|
label: '租户编码',
|
||||||
prop: 'code',
|
prop: 'code',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
label: '租户图片',
|
||||||
|
prop: 'image',
|
||||||
|
render(record) {
|
||||||
|
return h(ElAvatar, {
|
||||||
|
size: 48,
|
||||||
|
src: record.row.image,
|
||||||
|
shape: 'square',
|
||||||
|
fit: 'fill',
|
||||||
|
});
|
||||||
|
},
|
||||||
|
width: 100,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
label: '统一社会信用代码',
|
label: '统一社会信用代码',
|
||||||
prop: 'license',
|
prop: 'license',
|
||||||
width: 160,
|
width: 160,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '用户限额',
|
label: '租户限额',
|
||||||
prop: 'number',
|
prop: 'number',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -2,6 +2,21 @@
|
|||||||
<el-dialog v-model="props.visible" :title="props.tenantId ? '编辑' : '新增'" width="800" :close-on-click-modal="false"
|
<el-dialog v-model="props.visible" :title="props.tenantId ? '编辑' : '新增'" width="800" :close-on-click-modal="false"
|
||||||
:before-close="dialogClose">
|
:before-close="dialogClose">
|
||||||
<el-form ref="formRef" :model="formData" label-width="140px">
|
<el-form ref="formRef" :model="formData" label-width="140px">
|
||||||
|
<div class="flex">
|
||||||
|
<el-form-item
|
||||||
|
label="租户图片"
|
||||||
|
prop="image"
|
||||||
|
:rules="{ required: true,message: '请上传租户图片', trigger: 'change' }"
|
||||||
|
>
|
||||||
|
<UploadImg @changeFileName="(name)=>formData.imageImgName=name"
|
||||||
|
:fileType=" ['image/jpeg', 'image/png', 'image/jpg', 'image/gif']"
|
||||||
|
name="tenant"
|
||||||
|
:fileSize="200"
|
||||||
|
v-model:image-url="formData.image">
|
||||||
|
<template v-slot:tip>支持扩展名: jpg png jpeg;文件大小不超过200M</template>
|
||||||
|
</UploadImg>
|
||||||
|
</el-form-item>
|
||||||
|
</div>
|
||||||
<div class="flex">
|
<div class="flex">
|
||||||
<el-form-item label="名称" prop="name" class="flex-1"
|
<el-form-item label="名称" prop="name" class="flex-1"
|
||||||
:rules="{ required: true, message: '请输入名称', trigger: 'blur' }">
|
:rules="{ required: true, message: '请输入名称', trigger: 'blur' }">
|
||||||
@ -92,6 +107,7 @@ import { getRoleAllList } from '@/api/system/role';
|
|||||||
import { getDeptList } from '@/api/system/dept';
|
import { getDeptList } from '@/api/system/dept';
|
||||||
import { getLevelAllList } from '@/api/system/level';
|
import { getLevelAllList } from '@/api/system/level';
|
||||||
import { getPositionAllList } from '@/api/system/position';
|
import { getPositionAllList } from '@/api/system/position';
|
||||||
|
import UploadImg from "@/components/Upload/Image.vue";
|
||||||
import {buildTree } from "@/utils/auth";
|
import {buildTree } from "@/utils/auth";
|
||||||
import { FormInstance } from "element-plus";
|
import { FormInstance } from "element-plus";
|
||||||
|
|
||||||
@ -115,6 +131,7 @@ const formData = reactive({
|
|||||||
id: 0,
|
id: 0,
|
||||||
code:'',
|
code:'',
|
||||||
name: '',
|
name: '',
|
||||||
|
image:'',
|
||||||
license: "",
|
license: "",
|
||||||
contactUser: "",
|
contactUser: "",
|
||||||
contactMobile: '',
|
contactMobile: '',
|
||||||
|
@ -13,12 +13,12 @@ export const columns = [
|
|||||||
{
|
{
|
||||||
label: '登录账号',
|
label: '登录账号',
|
||||||
prop: 'username',
|
prop: 'username',
|
||||||
width: 100,
|
width: 150,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '用户姓名',
|
label: '用户姓名',
|
||||||
prop: 'realname',
|
prop: 'realname',
|
||||||
width: 100,
|
width: 150,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '头像',
|
label: '头像',
|
||||||
|
Loading…
Reference in New Issue
Block a user