后端个人加字段,个人设置提交

temp
tengxi 1 year ago
parent dbc20379eb
commit 7fa223db42

@ -1,6 +1,8 @@
<script lang="ts" setup> <script lang="ts" setup>
import { reactive, ref } from 'vue' import {onMounted, reactive, ref, toRefs, getCurrentInstanc, getCurrentInstance} from 'vue'
import type { UnwrapRef } from 'vue' import type { UnwrapRef } from 'vue'
// let {proxy}=getCurrentInstanc
import { import {
FieldTimeOutlined, FieldTimeOutlined,
LeftOutlined, ManOutlined, LeftOutlined, ManOutlined,
@ -9,10 +11,16 @@ import {
WomanOutlined, WomanOutlined,
} from '@ant-design/icons-vue' } from '@ant-design/icons-vue'
import { getUserProfileApi, updateUserProfileApi, uploadAvatarApi } from '@/api/base/profile'
import { exportLoginLog, getLoginLogPage } from '@/api/system/loginLog'
import { deleteNotice, getNoticePage } from '@/api/system/notice'
// //
const sex = ref<string>('保密')// const sex = ref<string>('保密')//
const message = ref<string>('全部信息')// const message = ref<string>('全部信息')//
interface FormState { interface FormState {
@ -51,6 +59,8 @@ const state = reactive({
// //
const current = ref(6)// const current = ref(6)//
// //
const isVisible = ref(true) const isVisible = ref(true)
const isVisible2 = ref(false) const isVisible2 = ref(false)
@ -135,6 +145,53 @@ const tabledata = [
time:'2023-08-22 22:31', time:'2023-08-22 22:31',
}, },
] ]
// const userInfo = ref(null);
// onMounted( async () => {
// let result = await getUserProfileApi()
// userInfo.value = result;
// })
let userInfo = reactive({
})
onMounted( async () => {
userInfo = await getUserProfileApi()
console.log(userInfo)
})
let loginlog = reactive({
})
onMounted( async () => {
loginlog = await getLoginLogPage()
// console.log(loginlog)
console.log(loginlog.list)
// console.log(loginlog.list.createTime)
// var date =new Date(loginlog.list.createTime)
// var time1 =loginlog.list.createTime
// console.log(time1)
})
// let Notice = reactive({
// })
// onMounted( async () => {
// loginlog = await getNoticePage()
// console.log(Notice.list)
// })
// const {username} = toRefs(userInfo)
// onMounted(async () => {
// const data = await getUserProfileApi()
// console.log(data);
// })
// let { proxy }: any = getCurrentInstance ()
// let classifylist=reactive ({
// data: [],
// })
// //
// onMounted( async () => {
// let { data: res } = await getUserProfileApi();
// console.log(res)
// })
</script> </script>
<template> <template>
@ -150,22 +207,23 @@ const tabledata = [
<p> <p>
<span></span> <span></span>
基本资料 基本资料
<!-- {{userInfo}} -->
</p> </p>
</div> </div>
<p class="pleft"> <p class="pleft">
基本信息 基本信息
</p> </p>
<div class="datumbox"> <div class="datumbox">
<div class="form"> <div class="form" :data="list">
<a-form :model="formState" :label-col="labelCol" :wrapper-col="wrapperCol"> <a-form :model="FormState" :label-col="labelCol" :wrapper-col="wrapperCol">
<a-form-item label="登录账号:"> <a-form-item label="登录账号:">
<a-input v-model:value="value" placeholder="输入内容" /> <a-input v-model:value="userInfo.username" placeholder="输入内容" />
</a-form-item> </a-form-item>
<a-form-item label="姓名:"> <a-form-item label="姓名:">
<a-input v-model:value="value" placeholder="输入内容" /> <a-input v-model:value="userInfo.nickname" placeholder="输入内容" />
</a-form-item> </a-form-item>
<a-form-item label="所属部门:"> <a-form-item label="所属部门:">
<a-input v-model:value="value" placeholder="输入内容" /> <a-input v-model:value="userInfo.dept.name" placeholder="输入内容" />
</a-form-item> </a-form-item>
<a-form-item label="员工职务:"> <a-form-item label="员工职务:">
<a-input v-model:value="value" placeholder="输入内容" /> <a-input v-model:value="value" placeholder="输入内容" />
@ -356,17 +414,19 @@ const tabledata = [
<p> <p>
<span></span> <span></span>
登录记录 登录记录
<!-- {{loginlog}}-->
</p> </p>
</div> </div>
<!-- 日期 --> <!-- 日期 -->
<div <div
v-for="(item, index) in 5" :key="index" v-for="(item, index) in loginlog.list" :key="index"
> >
<div class="date"> <div class="date">
{{ `2023-08-22` }} {{item.logType}}
{{ `日期2023-08-22` }}
</div> </div>
<div <div
v-for="(item, index) in 5" v-for="(item, index) in loginlog.list"
:key="index" class="recordbox" :key="index" class="recordbox"
> >
<div class="recordleft"> <div class="recordleft">
@ -374,14 +434,18 @@ const tabledata = [
<WindowsFilled /> <WindowsFilled />
</div> </div>
<div class="recordmessage"> <div class="recordmessage">
<div class="usersId"> <div class="usersId">
{{ `kang-pc` }} {{item.username}}
<!-- {{ `kang-pc` }}-->
</div> </div>
{{ `上海市长宁区 14.127.100.242` }} {{item.userIp}}
<!-- {{ `上海市长宁区 14.127.100.242` }}-->
</div> </div>
</div> </div>
<div class="recordright"> <div class="recordright">
<span><FieldTimeOutlined /></span>{{ `2023-08-22 12:00` }} <span><FieldTimeOutlined /></span>
<!-- {{ `2023-08-22 12:00` }}-->
{{item.createTime}}
</div> </div>
</div> </div>
</div> </div>
@ -399,6 +463,7 @@ const tabledata = [
<p> <p>
<span></span> <span></span>
系统通知 系统通知
</p> </p>
</div> </div>
<div class="messagetitle"> <div class="messagetitle">
@ -432,7 +497,7 @@ const tabledata = [
<div class="table"> <div class="table">
<a-table :columns="tablecolumns" :data-source="tabledata" :total="500"> <a-table :columns="tablecolumns" :data-source="tabledata" :total="500">
<template #headerCell="{ column }"> <template #headerCell="{ column }">
<template v-if="column.key === 'title'"> <template v-if="column.key === 'title'" >
<span> <span>
通知标题 通知标题
</span> </span>
@ -535,7 +600,7 @@ const tabledata = [
</div> </div>
<div class="firmtopbot"> <div class="firmtopbot">
<p class="fontcss"> <p class="fontcss">
部门{{ `再生资源事业部<采购部` }} 部门{{ `再生资源事业部 采购部` }}
</p> </p>
<p class="fontcss"> <p class="fontcss">
业务线{{ `废铁、废铝` }} 业务线{{ `废铁、废铝` }}

@ -8,6 +8,7 @@ import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank; import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern; import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size; import javax.validation.constraints.Size;
import java.time.LocalDateTime;
import java.util.Set; import java.util.Set;
/** /**
@ -51,4 +52,31 @@ public class UserBaseVO {
@Schema(description = "用户头像", example = "https://www.iocoder.cn/xxx.png") @Schema(description = "用户头像", example = "https://www.iocoder.cn/xxx.png")
private String avatar; private String avatar;
@Schema(description = "员工工号", example = "123")
private String jobNumber;
@Schema(description = "微信账号", example = "123")
private String wechatAccount;
@Schema(description = "出生日期", example = "123")
private LocalDateTime birthDatetime;
@Schema(description = "籍贯", example = "123")
private String nativePlace;
@Schema(description = "学历", example = "123")
private String education;
@Schema(description = "专业", example = "123")
private String speciality;
@Schema(description = "毕业院校", example = "123")
private String graduationInstitution;
@Schema(description = "毕业时间", example = "123")
private LocalDateTime institutionDatatime;
@Schema(description = "个人简介", example = "123")
private String personalProfile;
} }

@ -96,6 +96,42 @@ public class AdminUserDO extends TenantBaseDO {
* *
*/ */
private LocalDateTime loginDate; private LocalDateTime loginDate;
/**
*
*/
private String jobNumber;
/**
*
*/
private String wechatAccount;
/**
*
*/
private LocalDateTime birthDatetime;
/**
*
*/
private String nativePlace;
/**
*
*/
private String education;
/**
*
*/
private String speciality;
/**
*
*/
private String graduationInstitution;
/**
*
*/
private LocalDateTime institutionDatatime;
/**
*
*/
private String personalProfile;
private Long defaultEnterpriseId; private Long defaultEnterpriseId;

Loading…
Cancel
Save