|
@@ -1,155 +1,70 @@
|
|
|
<template>
|
|
<template>
|
|
|
- <div :class="prefixCls">
|
|
|
|
|
- <a-row :class="`${prefixCls}-top`">
|
|
|
|
|
- <a-col :span="9" :class="`${prefixCls}-col`">
|
|
|
|
|
- <a-row>
|
|
|
|
|
- <a-col :span="8">
|
|
|
|
|
- <div :class="`${prefixCls}-top__avatar`">
|
|
|
|
|
- <img width="70" :src="avatar" />
|
|
|
|
|
- <span>Vben</span>
|
|
|
|
|
- <div>海纳百川,有容乃大</div>
|
|
|
|
|
- </div>
|
|
|
|
|
- </a-col>
|
|
|
|
|
- <a-col :span="16">
|
|
|
|
|
- <div :class="`${prefixCls}-top__detail`">
|
|
|
|
|
- <template v-for="detail in details" :key="detail.title">
|
|
|
|
|
- <p>
|
|
|
|
|
- <Icon :icon="detail.icon" />
|
|
|
|
|
- {{ detail.title }}
|
|
|
|
|
- </p>
|
|
|
|
|
- </template>
|
|
|
|
|
- </div>
|
|
|
|
|
- </a-col>
|
|
|
|
|
- </a-row>
|
|
|
|
|
- </a-col>
|
|
|
|
|
- <a-col :span="7" :class="`${prefixCls}-col`">
|
|
|
|
|
- <CollapseContainer title="标签" :canExpan="false">
|
|
|
|
|
- <template v-for="tag in tags" :key="tag">
|
|
|
|
|
- <Tag class="mb-2">
|
|
|
|
|
- {{ tag }}
|
|
|
|
|
- </Tag>
|
|
|
|
|
- </template>
|
|
|
|
|
- </CollapseContainer>
|
|
|
|
|
- </a-col>
|
|
|
|
|
- <a-col :span="8" :class="`${prefixCls}-col`">
|
|
|
|
|
- <CollapseContainer :class="`${prefixCls}-top__team`" title="团队" :canExpan="false">
|
|
|
|
|
- <div v-for="(team, index) in teams" :key="index" :class="`${prefixCls}-top__team-item`">
|
|
|
|
|
- <Icon :icon="team.icon" :color="team.color" />
|
|
|
|
|
- <span>{{ team.title }}</span>
|
|
|
|
|
- </div>
|
|
|
|
|
- </CollapseContainer>
|
|
|
|
|
- </a-col>
|
|
|
|
|
- </a-row>
|
|
|
|
|
- <div :class="`${prefixCls}-bottom`">
|
|
|
|
|
- <Tabs>
|
|
|
|
|
- <template v-for="item in achieveList" :key="item.key">
|
|
|
|
|
- <TabPane :tab="item.name">
|
|
|
|
|
- <component :is="item.component" />
|
|
|
|
|
- </TabPane>
|
|
|
|
|
- </template>
|
|
|
|
|
- </Tabs>
|
|
|
|
|
- </div>
|
|
|
|
|
- </div>
|
|
|
|
|
|
|
+ <PageWrapper dense contentFullHeight contentClass="flex">
|
|
|
|
|
+ <a-card class="w-1/2 xl:w-1/2">
|
|
|
|
|
+ <List>
|
|
|
|
|
+ <h1>11111</h1>
|
|
|
|
|
+ <ListItem>11111</ListItem>
|
|
|
|
|
+ <ListItem>22222</ListItem>
|
|
|
|
|
+ <ListItem>33333</ListItem>
|
|
|
|
|
+ <ListItem>44444</ListItem>
|
|
|
|
|
+ </List>
|
|
|
|
|
+ </a-card>
|
|
|
|
|
+ <a-card
|
|
|
|
|
+ class="w-1/2 xl:w-1/2"
|
|
|
|
|
+ :active-tab-key="noTitleKey"
|
|
|
|
|
+ :tab-list="tabListNoTitle"
|
|
|
|
|
+ @tabChange="key => onTabChange(key, 'noTitleKey')"
|
|
|
|
|
+ >
|
|
|
|
|
+ <p v-if="noTitleKey === 'basicInformation'">
|
|
|
|
|
+ <basicInformation />
|
|
|
|
|
+ </p>
|
|
|
|
|
+ <p v-if="noTitleKey === 'editPws'">
|
|
|
|
|
+ <editPws />
|
|
|
|
|
+ </p>
|
|
|
|
|
+ <p v-if="noTitleKey === 'socialContact'">
|
|
|
|
|
+ <socialContact />
|
|
|
|
|
+ </p>
|
|
|
|
|
+ </a-card>
|
|
|
|
|
+ </PageWrapper>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
-<script lang="ts">
|
|
|
|
|
- import { Tag, Tabs, Row, Col } from 'ant-design-vue';
|
|
|
|
|
- import { defineComponent, computed } from 'vue';
|
|
|
|
|
- import { CollapseContainer } from '/@/components/Container/index';
|
|
|
|
|
- import Icon from '/@/components/Icon/index';
|
|
|
|
|
- import Article from './Article.vue';
|
|
|
|
|
- import Application from './Application.vue';
|
|
|
|
|
- import Project from './Project.vue';
|
|
|
|
|
|
|
+<script setup lang="ts">
|
|
|
|
|
+ import { ref } from 'vue';
|
|
|
|
|
+ import { List, ListItem } from 'ant-design-vue';
|
|
|
|
|
+ import { PageWrapper } from '/@/components/Page';
|
|
|
|
|
+ // import { userAccountInfo } from '/@/api/sys/userAccountApi';
|
|
|
|
|
+ import basicInformation from './basicInformation.vue';
|
|
|
|
|
+ import editPws from './editPws.vue';
|
|
|
|
|
+ import socialContact from './socialContact.vue';
|
|
|
|
|
+ // onMounted(async () => {
|
|
|
|
|
+ // const res = await userAccountInfo();
|
|
|
|
|
+ // console.log(res);
|
|
|
|
|
+ // });
|
|
|
|
|
|
|
|
- import headerImg from '/@/assets/images/header.png';
|
|
|
|
|
- import { tags, teams, details, achieveList } from './data';
|
|
|
|
|
- import { useUserStore } from '/@/store/modules/user';
|
|
|
|
|
-
|
|
|
|
|
- export default defineComponent({
|
|
|
|
|
- components: {
|
|
|
|
|
- CollapseContainer,
|
|
|
|
|
- Icon,
|
|
|
|
|
- Tag,
|
|
|
|
|
- Tabs,
|
|
|
|
|
- TabPane: Tabs.TabPane,
|
|
|
|
|
- Article,
|
|
|
|
|
- Application,
|
|
|
|
|
- Project,
|
|
|
|
|
- [Row.name]: Row,
|
|
|
|
|
- [Col.name]: Col,
|
|
|
|
|
|
|
+ const key = ref('basicInformation');
|
|
|
|
|
+ const noTitleKey = ref('basicInformation');
|
|
|
|
|
+ // :tab-list="tabListNoTitle"
|
|
|
|
|
+ const tabListNoTitle = [
|
|
|
|
|
+ {
|
|
|
|
|
+ key: 'basicInformation',
|
|
|
|
|
+ tab: '基本资料',
|
|
|
},
|
|
},
|
|
|
- setup() {
|
|
|
|
|
- const userStore = useUserStore();
|
|
|
|
|
- const avatar = computed(() => userStore.getUserInfo.avatar || headerImg);
|
|
|
|
|
- return {
|
|
|
|
|
- prefixCls: 'account-center',
|
|
|
|
|
- avatar,
|
|
|
|
|
- tags,
|
|
|
|
|
- teams,
|
|
|
|
|
- details,
|
|
|
|
|
- achieveList,
|
|
|
|
|
- };
|
|
|
|
|
|
|
+ {
|
|
|
|
|
+ key: 'editPws',
|
|
|
|
|
+ tab: '修改密码',
|
|
|
},
|
|
},
|
|
|
- });
|
|
|
|
|
-</script>
|
|
|
|
|
-<style lang="less" scoped>
|
|
|
|
|
- .account-center {
|
|
|
|
|
- &-col:not(:last-child) {
|
|
|
|
|
- padding: 0 10px;
|
|
|
|
|
-
|
|
|
|
|
- &:not(:last-child) {
|
|
|
|
|
- border-right: 1px dashed rgb(206, 206, 206, 0.5);
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- &-top {
|
|
|
|
|
- padding: 10px;
|
|
|
|
|
- margin: 16px 16px 12px 16px;
|
|
|
|
|
- background-color: @component-background;
|
|
|
|
|
- border-radius: 3px;
|
|
|
|
|
-
|
|
|
|
|
- &__avatar {
|
|
|
|
|
- text-align: center;
|
|
|
|
|
-
|
|
|
|
|
- img {
|
|
|
|
|
- margin: auto;
|
|
|
|
|
- border-radius: 50%;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- span {
|
|
|
|
|
- display: block;
|
|
|
|
|
- font-size: 20px;
|
|
|
|
|
- font-weight: 500;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- div {
|
|
|
|
|
- margin-top: 3px;
|
|
|
|
|
- font-size: 12px;
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- &__detail {
|
|
|
|
|
- padding-left: 20px;
|
|
|
|
|
- margin-top: 15px;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- &__team {
|
|
|
|
|
- &-item {
|
|
|
|
|
- display: inline-block;
|
|
|
|
|
- padding: 4px 24px;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- span {
|
|
|
|
|
- margin-left: 3px;
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ {
|
|
|
|
|
+ key: 'socialContact',
|
|
|
|
|
+ tab: '社交信息',
|
|
|
|
|
+ },
|
|
|
|
|
+ ];
|
|
|
|
|
|
|
|
- &-bottom {
|
|
|
|
|
- padding: 10px;
|
|
|
|
|
- margin: 0 16px 16px 16px;
|
|
|
|
|
- background-color: @component-background;
|
|
|
|
|
- border-radius: 3px;
|
|
|
|
|
|
|
+ const onTabChange = (value, type) => {
|
|
|
|
|
+ if (type === 'key') {
|
|
|
|
|
+ key.value = value;
|
|
|
|
|
+ } else if (type === 'noTitleKey') {
|
|
|
|
|
+ noTitleKey.value = value;
|
|
|
}
|
|
}
|
|
|
- }
|
|
|
|
|
-</style>
|
|
|
|
|
|
|
+ };
|
|
|
|
|
+</script>
|
|
|
|
|
+<style lang="less"></style>
|