0523065a9277e0d11b82cd19e0684b86361b1f06..ce9ff4af4cf7ccc87d3ef94a849942baf112b811
2025-04-07 杨磊
Merge branch 'master' of http://182.92.203.7:2001/r/wyyDatabase
ce9ff4 对比 | 目录
2025-04-07 杨磊
首页
cd9bda 对比 | 目录
2025-04-07 zhongshujie
学术成果checkbox
5fc2fd 对比 | 目录
9个文件已修改
8个文件已添加
11895 ■■■■■ 已修改文件
package-lock.json 30 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
package.json 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/achievements/sort-bottom.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/achievements/sort-top.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/directory/bottomIcon.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/directory/noChartIcon.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/directory/noListIcon.png 补丁 | 查看 | 原始文档 | blame | 历史
src/components/form/form.vue 83 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/layout/index.vue 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/router/index.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/achievements/index.vue 637 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/chronology/floatingWindow.vue 81 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/chronology/index.vue 1003 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/directory/index.vue 277 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/home/components/searchBox.vue 109 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/home/index.vue 191 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
yarn.lock 9478 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
package-lock.json
@@ -1,5 +1,5 @@
{
  "name": "wyyDataBase",
  "name": "website",
  "version": "0.1.0",
  "lockfileVersion": 3,
  "requires": true,
@@ -10,6 +10,7 @@
      "dependencies": {
        "axios": "^0.27.2",
        "core-js": "^3.8.3",
        "echarts": "^5.6.0",
        "element-china-area-data": "^6.1.0",
        "element-ui": "^2.15.10",
        "moment": "^2.29.4",
@@ -5155,6 +5156,20 @@
      "engines": {
        "node": ">=6.0.0"
      }
    },
    "node_modules/echarts": {
      "version": "5.6.0",
      "resolved": "https://registry.npmmirror.com/echarts/-/echarts-5.6.0.tgz",
      "integrity": "sha512-oTbVTsXfKuEhxftHqL5xprgLoc0k7uScAwtryCgWF6hPYFLRwOUHiFmHGCBKP5NPFNkDVopOieyUqYGH8Fa3kA==",
      "dependencies": {
        "tslib": "2.3.0",
        "zrender": "5.6.1"
      }
    },
    "node_modules/echarts/node_modules/tslib": {
      "version": "2.3.0",
      "resolved": "https://registry.npmmirror.com/tslib/-/tslib-2.3.0.tgz",
      "integrity": "sha512-N82ooyxVNm6h1riLCoyS9e3fuJ3AMG2zIZs2Gd1ATcSFjSA23Q0fzjjZeh0jbJvWVDZ0cJT8yaNNaaXHzueNjg=="
    },
    "node_modules/ee-first": {
      "version": "1.1.1",
@@ -12404,6 +12419,19 @@
      "resolved": "https://registry.npmmirror.com/yallist/-/yallist-2.1.2.tgz",
      "integrity": "sha512-ncTzHV7NvsQZkYe1DW7cbDLm0YpzHmZF5r/iyP3ZnQtMiJ+pjzisCiMNI+Sj+xQF5pXhSHxSB3uDbsBTzY/c2A==",
      "dev": true
    },
    "node_modules/zrender": {
      "version": "5.6.1",
      "resolved": "https://registry.npmmirror.com/zrender/-/zrender-5.6.1.tgz",
      "integrity": "sha512-OFXkDJKcrlx5su2XbzJvj/34Q3m6PvyCZkVPHGYpcCJ52ek4U/ymZyfuV1nKE23AyBJ51E/6Yr0mhZ7xGTO4ag==",
      "dependencies": {
        "tslib": "2.3.0"
      }
    },
    "node_modules/zrender/node_modules/tslib": {
      "version": "2.3.0",
      "resolved": "https://registry.npmmirror.com/tslib/-/tslib-2.3.0.tgz",
      "integrity": "sha512-N82ooyxVNm6h1riLCoyS9e3fuJ3AMG2zIZs2Gd1ATcSFjSA23Q0fzjjZeh0jbJvWVDZ0cJT8yaNNaaXHzueNjg=="
    }
  }
}
package.json
@@ -10,6 +10,7 @@
  "dependencies": {
    "axios": "^0.27.2",
    "core-js": "^3.8.3",
    "echarts": "^5.6.0",
    "element-china-area-data": "^6.1.0",
    "element-ui": "^2.15.10",
    "moment": "^2.29.4",
src/assets/images/achievements/sort-bottom.png
src/assets/images/achievements/sort-top.png
src/assets/images/directory/bottomIcon.png
src/assets/images/directory/noChartIcon.png
src/assets/images/directory/noListIcon.png
src/components/form/form.vue
New file
@@ -0,0 +1,83 @@
<template >
  <div>
    <el-form
      size="mini"
      :inline="true"
      style="padding: 0px 10px;
      "
      :model="from"
      class="row demo-form-inline col-xs-12"
    >
      <el-row :gutter="10">
        <el-form-item
          style="width: 33%"
          v-for="(item, i) in from.from"
          :key="i"
          :label="item.label"
        >
          <el-input
            v-if="item.type === 'input'"
            v-model="item.value"
            :placeholder="item.label"
          ></el-input>
        </el-form-item>
        <!-- 其他表单项省略 -->
        <!-- <el-form-item style="display:block; "> -->
        <div class="flex flex-center Formbtn">
          <el-button
            size="mini"
            @click="handleSubmit"
            >搜索</el-button
          >
          <el-button  size="mini" @click="handleReset"
            >重置</el-button
          >
        </div>
        <!-- </el-form-item> -->
      </el-row>
    </el-form>
  </div>
</template>
<script>
export default {
  props: ["from"],
  mounted(){
  },
  methods: {
    handleSubmit() {
      this.$message({
        message: "查询成功",
        type: "success",
      });
      const result = this.from.from.reduce((obj, item) => {
        obj[item.name] = item.value;
        return obj;
      }, {});
      // 提交逻辑
      this.$emit("submit", result); // 发送 submit 事件,并将表单数据作为参数传递给父组件
    },
    handleReset() {
      this.from.from.forEach((item) => {
        item.value = "";
      });
      // 重置逻辑
      this.$emit('reset') // 发送 reset 事件给父组件
    },
  },
};
</script>
<style scoped>
.el-form--inline .el-form-item {
  margin-right: 0;
}
::v-deep .el-form-item__content {
  width: 80%;
}
::v-deep .el-form-item__content div {
  width: 100%;
}
</style>
src/layout/index.vue
@@ -69,10 +69,8 @@
<style lang="less" scoped>
.homeLayoutBox {
  width: 100%;
  height: 100%;
  display: flex;
  // background-image: url("@/assets/images/homeBg.png");
  // background-repeat: no-repeat;
  // background-size: 100% 95%;
@@ -92,6 +90,7 @@
    background: #937950;
    display: flex;
    flex-direction: column;
    font-family: Alimama DongFangDaKai;
    .leftMenuTitle {
      width: 100%;
src/router/index.js
@@ -16,7 +16,7 @@
    name: "HomeLayout",
    component: HomeLayout,
    redirect: {
      name: "honor",
      name: "chronology",
    },
    children: [
      // 在主框架内
src/views/achievements/index.vue
@@ -3,42 +3,374 @@
    <div class="page-header">
      <p>王永炎院士学术成果</p>
    </div>
    <!-- 搜索框 -->
    <ul class="page-input">
      <li class="input-main">
        <el-input placeholder="请输入内容" v-model="input3" class="input-with-select" suffix="搜索">
          <el-select v-model="select" slot="prepend" placeholder="请选择">
            <el-option label="餐厅名" value="1"></el-option>
            <el-option label="订单号" value="2"></el-option>
            <el-option label="用户电话" value="3"></el-option>
          </el-select>
          <el-button slot="append" >搜索</el-button>
        </el-input>
      </li>
      <li class="input-txt" @click="isDisplay = !isDisplay">
        高级检索
        <img v-if="isDisplay" src="../../assets/images/achievements/top-Icon.png" alt="">
        <img v-else src="../../assets/images/achievements/bottom-Icon.png" alt="">
      </li>
    </ul>
    <!-- 高级搜索 -->
    <div v-if="isDisplay">
      123
    </div>
    <div class="page-main">
      <!-- 搜索框 -->
      <ul class="page-input">
        <li class="input-main">
          <el-input placeholder="请输入内容" v-model="input3" class="input-with-select" suffix="搜索">
            <el-select v-model="select" slot="prepend" placeholder="请选择">
              <el-option v-for="(item, index) in optionlist" :key="index" :label="item.lable"
                :value="item.lable"></el-option>
            </el-select>
            <el-button slot="append">搜索</el-button>
          </el-input>
        </li>
        <li class="input-txt" @click="isDisplay = !isDisplay">
          高级检索
          <img :src="[isDisplay ? topIcon : bottomIcon]" alt="">
        </li>
      </ul>
      <!-- 高级搜索 -->
      <div v-if="isDisplay" class="page-search">
        <MyForm class="myfrom" @submit="
          (data) => {
            CurrentPage = 1;
            onSubmit(data);
          }
        " @reset="resetForm" :from="from" />
      </div>
      <!-- 搜索结果 -->
      <div class="page-content">
        <div class="content-left">
          <!-- 类型 -->
          <ul>
            <li class="left-title">
              <span>{{ category.title }}</span>
              <p @click="category.isDisplay = !category.isDisplay">
                <img :src="[category.isDisplay ? topIcon : bottomIcon]" alt="">
              </p>
            </li>
            <li class="left-main" v-if="category.isDisplay">
              <div class="category-main" v-for="(item, index) in category.list" :key="index">
                <el-checkbox class="el-checkbox" v-model="item.checked" :title="item.name">{{ item.name }}</el-checkbox>
                <span class="">{{ item.num }}</span>
              </div>
            </li>
          </ul>
          <!-- 年度 -->
          <ul>
            <li class="left-title">
              <div>
                <span>{{ annual.title }}</span>
                <span>
                  时间
                  <img class="sort-Icon" :src="[isDisplay ? sortTop : sortBottom]" alt="">
                </span>
                <span>文献量
                  <img class="sort-Icon" :src="[isDisplay ? sortBottom : sortTop]" alt="">
                </span>
              </div>
              <p @click="annual.isDisplay = !annual.isDisplay">
                <img :src="[annual.isDisplay ? topIcon : bottomIcon]" alt="">
              </p>
            </li>
            <li class="left-main" v-if="annual.isDisplay">
              <div class="annual-main" v-for="(item, index) in annual.list" :key="index">
                <el-checkbox class="el-checkbox" v-model="item.checked" :title="item.years">{{ item.years }}</el-checkbox>
                <span class="">{{ item.num }}</span>
              </div>
              <p class="annual-footer" v-if="annual.list && annual.list.length > 5">展开</p>
            </li>
          </ul>
          <!-- 文献来源 -->
          <ul>
            <li class="left-title">
              <div>
                <span>{{ sources.title }}</span>
                <span>
                  文献量
                  <img class="sort-Icon" :src="[isDisplay ? sortBottom : sortTop]" alt="">
                </span>
              </div>
              <p @click="sources.isDisplay = !sources.isDisplay">
                <img :src="[sources.isDisplay ? topIcon : bottomIcon]" alt="">
              </p>
            </li>
            <li class="left-main" v-if="sources.isDisplay">
              <div class="sources-main" v-for="(item, index) in sources.list" :key="index">
                <el-checkbox class="el-checkbox" :title="item.name" v-model="item.checked">{{ item.name }}</el-checkbox>
                <span class="">{{ item.num }}</span>
              </div>
              <p class="sources-footer" v-if="sources.list && sources.list.length > 5">展开</p>
            </li>
          </ul>
          <!-- 学科 -->
          <ul>
            <li class="left-title">
              <span>{{ subject.title }}</span>
              <p @click="subject.isDisplay = !subject.isDisplay">
                <img :src="[subject.isDisplay ? topIcon : bottomIcon]" alt="">
              </p>
            </li>
            <li class="left-main" v-if="subject.isDisplay">
              <div class="category-main" v-for="(item, index) in subject.list" :key="index">
                <el-checkbox class="el-checkbox" v-model="item.checked" :title="item.name">{{ item.name }}</el-checkbox>
                <span class="">{{ item.num }}</span>
              </div>
            </li>
          </ul>
        </div>
        <div class="content-right">
        </div>
      </div>
    </div>
  </div>
</template>
<script>
import MyForm from '@/components/form/form.vue'
/* eslint-disable vue/no-unused-components */
export default {
  name: 'achievements',
  components: {
    MyForm
  },
  data() {
    return {
      topIcon: require("@/assets/images/achievements/top-Icon.png"),
      bottomIcon: require("@/assets/images/achievements/bottom-Icon.png"),
      sortTop: require("@/assets/images/achievements/sort-top.png"),
      sortBottom: require("@/assets/images/achievements/sort-bottom.png"),
      isDisplay: false,
      input3: '',
      select: '',
      checked: [],
      optionlist: [
        {
          lable: "标题"
        },
        {
          lable: "作者"
        },
        {
          lable: "年份"
        },
        {
          lable: "关键词"
        },
        {
          lable: "摘要"
        },
        {
          lable: "来源"
        },
      ],
      // 当前页
      CurrentPage: 1,
      // 高级搜索
      from: {
        from: [
          {
            type: "input",
            label: "标 题",
            name: "title",
            value: ""
          },
          {
            type: "input",
            label: "作 者",
            name: "author",
            value: ""
          },
          {
            type: "input",
            label: "年 份",
            name: "year",
            value: ""
          },
          {
            type: "input",
            label: "关键词",
            name: "keyword",
            value: ""
          },
          {
            type: "input",
            label: "摘 要",
            name: "abstract",
            value: ""
          },
          {
            type: "input",
            label: "来 源",
            name: "source",
            value: ""
          },
        ]
      },
      // 类型
      category: {
        title: "类型",
        isDisplay: true,
        id: "",
        index: "",
        list: [
          {
            name: "期刊",
            num: 190,
            check: false
          },
          {
            name: "图书",
            num: 190,
            check: false
          },
          {
            name: "视频",
            num: 190,
            check: false
          },
          {
            name: "音频",
            num: 190,
            check: false
          },
        ]
      },
      // 年度
      annual: {
        title: "年度",
        isDisplay: true,
        id: "",
        index: "",
        list: [
          {
            years: "2025",
            num: 20,
            check: false
          },
          {
            years: "2025",
            num: 20,
            check: false
          },
          {
            years: "2025",
            num: 20,
            check: false
          },
          {
            years: "2025",
            num: 20,
            check: false
          },
          {
            years: "2025",
            num: 20,
            check: false
          },
          {
            years: "2025",
            num: 20,
            check: false
          },
          {
            years: "2025",
            num: 20,
            check: false
          },
        ],
      },
      // 文献来源
      sources: {
        title: "文献来源",
        isDisplay: true,
        id: "",
        index: "",
        list: [
          {
            name: "北京中医药大学大学学报",
            num: 190,
            check: false
          },
          {
            name: "北京中医药大学大学学报",
            num: 190,
            check: false
          },
          {
            name: "北京中医药大学大学学报",
            num: 190,
            check: false
          },
          {
            name: "北京中医药大学大学学报",
            num: 190,
            check: false
          },
          {
            name: "北京中医药大学大学学报",
            num: 190,
            check: false
          },
          {
            name: "北京中医药大学大学学报",
            num: 190,
            check: false
          },
        ]
      },
      // 学科
      subject: {
        title: "学科",
        isDisplay: true,
        id: "",
        index: "",
        list: [
          {
            name: "医学",
            num: 190,
            check: false
          },
          {
            name: "医学",
            num: 190,
            check: false
          },
          {
            name: "医学",
            num: 190,
            check: false
          },
          {
            name: "医学",
            num: 190,
            check: false
          },
          {
            name: "医学",
            num: 190,
            check: false
          },
        ]
      },
      // 查询结果
      resultList:[
        {
            name:"中药闸柜的历史传承与新时代发展思考",
            sources:"北京中医药大学学报",
            time:"2025-02-24 09:21",
            title:"摘要: 中药闸柜是传统中药调剂的高级管理人员,在'前店后厂式'中药房发挥重要作用和关键职能。传承中药闸柜的宝贵学术经验与优秀文化对厘清中药学学科发展脉络、规范中药调剂技术操作、促进老药工技艺'活态传承'具有重要科学价值和现实意义。面向新时代、开启新思维,本文对老字号中药铺的兴起和中药闸柜进行考证,分析中药闸柜的岗位责任、传承路径及未来发展,提出高素质中药闸柜人才培养策略,旨在培养符合当代社会需求的中药行业复合型创新人才。",
            keyword:""
        }
      ]
    }
  },
  methods: {
  methods: {
    async onSubmit(val) {
    },
    //重置搜索结果
    resetForm() {
      // this.onSearch("");
    },
  }
}
</script>
@@ -68,45 +400,252 @@
  }
}
.page-input {
.page-main {
  width: 1330px;
  margin: 0 auto;
  display: flex;
  background-color: #fff;
}
.input-main {
  padding: 15px 0;
  text-align: center;
  width: 90%;
  border-right: 2px solid #E4DACE;
  .input-with-select{
    width: 50%;
.page-input {
  width: 100%;
  display: flex;
  background-color: #fefbf5;
  border: 1px solid #E4DACE;
  .input-main {
    padding: 15px 0;
    text-align: center;
    width: 90%;
    border-right: 2px solid #E4DACE;
    .input-with-select {
      width: 50%;
    }
  }
  .input-txt {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 10%;
    padding: 15px 0;
    font-family: Source Han Sans;
    font-size: 14px;
    font-weight: bold;
    color: #6F5A3A;
    cursor: pointer;
    img {
      width: 10px;
      height: auto;
      margin-left: 5px;
    }
  }
}
.input-txt {
.page-search {
  width: 100%;
  background-color: #fefbf5;
  border-bottom: 1px solid #E4DACE;
  border-left: 1px solid #E4DACE;
  border-right: 1px solid #E4DACE;
  padding: 13px 0px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 10%;
  padding: 15px 0;
  font-family: Source Han Sans;
  font-size: 14px;
  font-weight: bold;
  color: #6F5A3A;
  cursor: pointer;
  img {
    width: 10px;
    height: auto;
    margin-left: 5px;
  .myfrom {
    width: 80%;
    ::v-deep .flex-center {
      height: 80% !important;
    }
    ::v-deep .Formbtn {
      width: 100% !important;
      display: flex;
      justify-content: center;
      align-items: center;
      .el-button {
        width: 68px !important;
        height: 32px !important;
        font-size: 14px;
        background-color: transparent;
        color: #937950;
        border: 1px solid #6F5A3A;
        &:hover {
          background-color: #6F5A3A;
          color: #FFFDF8;
        }
      }
    }
  }
}
.page-content {
  width: 100%;
  margin-top: 20px;
  background-color: #fefbf5;
  border: 1px solid #E4DACE;
  display: flex;
  .content-left {
    width: 19.5%;
    border-right: 1px solid #E4DACE;
    border-bottom: 1px solid #E4DACE;
  }
  .left-title {
    padding: 7px 7px 9px 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #E4DACE;
    span {
      margin-right: 20px;
      font-family: Source Han Sans;
      font-size: 14px;
      font-weight: bold;
    }
    .sort-Icon {
      cursor: pointer;
      height: 12px;
      width: auto;
    }
    img {
      cursor: pointer;
      height: 4px;
      width: auto;
    }
  }
  .left-main {
    border-bottom: 1px solid #E4DACE;
    padding: 10px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
  }
  .category-main {
    width: 50%;
    margin-bottom: 10px;
    span {
      font-family: Source Han Sans;
      font-size: 12px;
      color: #8F7A5A;
    }
  }
  .annual-main {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    span {
      font-family: Source Han Sans;
      font-size: 12px;
      color: #8F7A5A;
    }
  }
  .annual-footer {
    cursor: pointer;
    width: 100%;
    text-align: center;
    font-family: Source Han Sans;
    font-size: 12px;
    font-weight: 350;
    color: #937950;
  }
  .sources-main {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    span {
      font-family: Source Han Sans;
      font-size: 12px;
      color: #8F7A5A;
    }
  }
  .el-checkbox {
    width: 70%;
  }
  /* 设置鼠标经过对勾框,对勾框边框的颜色 */
  ::v-deep .el-checkbox .el-checkbox__inner:hover {
    border-color: #D1D1D1;
  }
  /* 设置checkbox获得焦点后,对勾框的边框颜色 */
  ::v-deep .el-checkbox .el-checkbox__input.is-focus .el-checkbox__inner {
    border-color: #D1D1D1;
  }
  ::v-deep .el-checkbox .el-checkbox__input.is-checked+.el-checkbox__label {
    color: #2C2C2C;
  }
  ::v-deep .el-checkbox .el-checkbox__input.is-checked .el-checkbox__inner,
  ::v-deep .el-checkbox .el-checkbox__input.is-indeterminate .el-checkbox__inner {
    border-color: #8F7A5A;
    background-color: #8F7A5A;
  }
  ::v-deep .el-checkbox__label {
    color: #2C2C2C;
    width: 100%;
    font-family: Source Han Sans;
    font-size: 12px;
    font-weight: bold;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    /* 超出部分显示省略号 */
    vertical-align: middle;
  }
  .sources-footer {
    cursor: pointer;
    width: 100%;
    text-align: center;
    font-family: Source Han Sans;
    font-size: 12px;
    font-weight: 350;
    color: #937950;
  }
  .content-right{
    width: 80.5%;
    padding: 14px 20px 20px 14px;
  }
}
el-input__suffix {
right: 22px;
color: #999;
  right: 22px;
  color: #999;
}
</style>
src/views/chronology/floatingWindow.vue
New file
@@ -0,0 +1,81 @@
<template>
  <div class="dialogBox">
    <div class="journalBox">
      <div class="title">复方剂量配比多目标优化的ED-NM-MO三联法</div>
      <div class="subtitle">
        <div class="source">中国中医基础医学杂志</div>
        <div class="journalInformation">2005 3月 第40卷 第4期</div>
      </div>
      <div class="contentBox">
        <p>王睿 中国科学院大连化学物理研究所</p>
        <p>王睿 中国科学院大连化学物理研究所</p>
        <p>王睿 中国科学院大连化学物理研究所</p>
        <p>王睿 中国科学院大连化学物理研究所</p>
        <p>王睿 中国科学院大连化学物理研究所</p>
      </div>
      <div class="abstract">
        摘要:
        针对复方多药物(多部位多组分多成分)、多靶点多药效指标、非线性的特征,提出复方剂量配比优化的ED-NM-MO三联法,该方法具有良好的非线性拟合能力,可以适应复方的非线性特征,又可以实现同时针对多个药效指标的多目标优化,适合复方的多靶点特征,是一种适应复方特点的优化方法。
      </div>
      <div class="keyword">
        关键词: 复方剂量配比优化; 复方数学特征; 多药效指标; 非线性;
        试验设计-非线性建模-多目标优化的三联法
      </div>
    </div>
    <div class="imageBox"></div>
    <div class="BookBox"></div>
    <div class="videoBox"></div>
    <div class="audioBox"></div>
  </div>
</template>
<script>
export default {
  name: "floatingWindow",
  props: {
    info: {
      type: Object,
      default: () => {},
    },
  },
};
</script>
<style scoped>
.dialogBox {
  width: 400px;
  height: 100%;
  background-color: #fdf8f0;
  position: relative;
  padding: 15px;
  z-index: 20;
  box-sizing: border-box;
}
.title {
  font-size: 16px;
  line-height: 22px;
  font-weight: 600;
}
.subtitle {
  display: flex;
  justify-content: space-between;
}
.subtitle {
  margin-top: 20px;
}
.abstract {
  margin-top: 10px;
  white-space: pre-line;
  line-height: 18px;
}
.keyword {
  margin-top: 10px;
  white-space: pre-line;
  line-height: 18px;
}
.contentBox {
  margin-top: 10px;
  line-height: 18px;
}
</style>
src/views/chronology/index.vue
@@ -1,9 +1,1006 @@
<template>
  <div>年谱</div>
  <div class="page">
    <div class="page-header">
      <p>王永炎院士年谱</p>
    </div>
    <div class="pageBox">
      <div class="tagBox">
        <div class="tagItem">
          <div style="background-color: #87a7b9" class="item-tag"></div>
          <div>期刊</div>
        </div>
        <div class="tagItem">
          <div style="background-color: #c48787" class="item-tag"></div>
          <div>图书</div>
        </div>
        <div class="tagItem">
          <div style="background-color: #6f8f5a" class="item-tag"></div>
          <div>视频</div>
        </div>
        <div class="tagItem">
          <div style="background-color: #b9a587" class="item-tag"></div>
          <div>音频</div>
        </div>
        <div class="tagItem">
          <div style="background-color: #8d77b3" class="item-tag"></div>
          <div>报纸</div>
        </div>
        <div class="tagItem">
          <div style="background-color: #009f9f" class="item-tag"></div>
          <div>其他</div>
        </div>
      </div>
      <div class="contentBox">
        <div class="chartsBox">
          <div
            class="chartsItemBox"
            v-for="(item, index) in contentList"
            :key="index"
          >
            <div class="chartsItem">
              <div class="item-grad">
                <div
                  class="gradchild"
                  v-for="(citem, cindex) in item.list"
                  :style="{ background: citem.color }"
                  @mouseover="showDetail(index, cindex, 1)"
                  :key="cindex"
                >
                  <div class="detailDialog" v-if="citem.showDetail">
                    <!-- <div class="dialogContent" @click="gotoDetail(citem)"> -->
                      <floatingWindow :info="citem" />
                    <!-- </div> -->
                  </div>
                </div>
              </div>
              <div class="item-circle"></div>
              <div class="item-text">
                <div class="">
                  {{ item.year }}
                </div>
                <div style="margin-top: 10px">
                  {{ item.name }}
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>
<script>
export default {};
import echarts from "@/assets/js/echarts.min.js";
import floatingWindow from "./floatingWindow.vue";
export default {
  components: {
    floatingWindow,
  },
  data() {
    return {
      contentList: [
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1938",
              id: "1",
            },
          ],
          name: "出生",
          year: "1938",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "2",
            },
          ],
          name: "一岁",
          year: "1939",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "2",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              id: "3",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              id: "4",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              id: "5",
            },
          ],
          name: "3岁",
          year: "1941",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#6F8F5A",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "2",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              id: "3",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              id: "4",
            },
            {
              color: "#B9A587",
              showDetail: false,
              name: "王永炎",
              id: "5",
            },
          ],
          name: "4岁",
          year: "1941",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
        {
          list: [
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#87A7B9",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
            {
              color: "#CB9D9D",
              showDetail: false,
              name: "王永炎",
              year: "1937",
              id: "1",
            },
          ],
          name: "5岁",
          year: "1942",
        },
      ],
    };
  },
  methods: {
    gotoDetail(item) {},
    showDetail(index, cindex, type) {
      for (let i = 0; i < this.contentList.length; i++) {
        const item = this.contentList[i];
        for (let j = 0; j < item.list.length; j++) {
          const citem = item.list[j];
          this.$set(citem, "showDetail", false);
        }
      }
      if (type == 1) {
        this.contentList[index].list[cindex].showDetail = true;
      } else {
        this.contentList[index].list[cindex].showDetail = false;
      }
    },
  },
};
</script>
<style></style>
<style lang="less" scoped>
.page {
  width: 100%;
  height: 100%;
  box-sizing: border-box;
  background-color: #e9e1d4;
  display: flex;
  flex-direction: column;
  overflow: auto;
}
.pageBox {
  flex: 1;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  .tagBox {
    display: flex;
    margin-top: 20px;
    .item-tag {
      width: 20px;
      height: 20px;
      margin-right: 10px;
    }
    .tagItem {
      display: flex;
      line-height: 20px;
      margin-left: 30px;
    }
  }
  .contentBox {
    flex: 1;
    padding-bottom: 100px;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: end;
    overflow: auto;
    .chartsBox {
      white-space: nowrap;
      padding: 0 80px;
      width: calc(100vw - 400px);
      padding-bottom: 100px;
    }
    // &::-webkit-scrollbar {
    //   width: 0 !important;
    //   height: 0 !important;
    // }
    /* 对于WebKit浏览器和Blink引擎(如Chrome, Opera) */
    ::-webkit-scrollbar {
      width: 16px; /* 滚动条的宽度 */
      height: 16px; /* 滚动条的高度 */
    }
    ::-webkit-scrollbar-track {
      background: #ebe5d6; /* 滚动条轨道的颜色 */
    }
    ::-webkit-scrollbar-thumb {
      background: #b9a587; /* 滚动条滑块的颜色 */
      border-radius: 16px; /* 滚动条滑块的圆角 */
    }
    ::-webkit-scrollbar-thumb:hover {
      background: #b9a587; /* 鼠标悬停在滚动条滑块上的颜色 */
    }
  }
}
.page-header {
  height: 102px;
  width: 100%;
  text-align: left;
  margin-bottom: 8px;
  border-bottom: 2px solid #937950;
  p {
    padding: 35px 0 34px 0;
    font-family: Alimama DongFangDaKai;
    font-size: 30px;
    text-indent: 1em;
    border-bottom: 1px solid #937950;
  }
}
.chartsItemBox {
  display: inline-block;
  width: 105px;
  height: 100%;
  position: relative;
  margin-right: 30px;
}
.chartsItem {
  width: 100%;
  height: 100%;
}
.item-grad {
  width: 80px;
  display: flex;
  flex-wrap: wrap-reverse;
}
.gradchild {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  margin-right: 2px;
  cursor: pointer;
  position: relative;
}
.item-circle {
  width: 100%;
  height: 20px;
  margin-top: 20px;
  position: relative;
}
.item-circle::after {
  content: "";
  position: absolute;
  top: 9px;
  display: block;
  width: 135px;
  height: 2px;
  background-color: #b9a587;
  z-index: 1;
}
.item-circle::before {
  content: "";
  display: block;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1px solid #b9a587;
  position: absolute;
  top: 0;
  left: 50%;
  margin-left: -9px;
  z-index: 99;
  background: #fff;
}
.item-text {
  margin-top: 16px;
  font-size: 18px;
  color: #b9a587;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.detailDialog {
  position: absolute;
  // left: -54px;
  // bottom: 50px;
  top: -550%;
  width: 400px;
  z-index: 9999;
  cursor: pointer;
  background: #fff;
  border: 2px solid #CBBEAA;
  box-shadow: 2px 2px 4px 1px rgba(0, 0, 0, 0.5);
}
.detailDialog .dialogContent {
  width: 100%;
  height: 100%;
  background-color: #fff;
  position: relative;
  padding: 15px;
  z-index: 20;
  box-sizing: border-box;
}
</style>
src/views/directory/index.vue
@@ -5,97 +5,42 @@
    </div>
    <div class="page-main-title">
      <p @click="changeTab('chart')" :class="[activeTabs == 'chart' ? 'active-tab' : '']">
        <img src="../../assets/images/directory/chartIcon.png" alt="">
        <img :src="[activeTabs == 'chart' ? chartIcon : noChartIcon]" alt="">
        <span>图表显示</span>
      </p>
      <p @click="changeTab('list')" :class="[activeTabs == 'list' ? 'active-tab' : '']">
        <img src="../../assets/images/directory/listIcon.png" alt="">
        <img :src="[activeTabs == 'list' ? listIcon : noListIcon]" alt="">
        <span>列表显示</span>
      </p>
    </div>
    <!-- 图表显示 -->
    <div class="charts-main" v-if="activeTabs == 'chart'">
      <!-- <div class="pageBox">
        <div class="main" v-loading="loading" element-loading-text="加载中..."
          element-loading-background="rgba(255,255,255,.5)">
          <div class="main-content">
            <div class="detailBox">
              <div class="legendBox">
                <div class="legendItem">
                  <div class="lengend-color"></div>
                  <div class="lengend-text">生</div>
                </div>
                <div class="legendItem">
                  <div class="lengend-color"></div>
                  <div class="lengend-text">旦</div>
                </div>
                <div class="legendItem">
                  <div class="lengend-color"></div>
                  <div class="lengend-text">净</div>
                </div>
                <div class="legendItem">
                  <div class="lengend-color"></div>
                  <div class="lengend-text">末</div>
                </div>
                <div class="legendItem">
                  <div class="lengend-color"></div>
                  <div class="lengend-text">丑</div>
                </div>
                <div class="legendItem">
                  <div class="lengend-color"></div>
                  <div class="lengend-text">未知</div>
                </div>
              </div>
              <div class="echartsBox">
                <div class="clickBox" id="clickBox">
                  <div class="clickBoxContent">
                    <div class="imgBox" style="width: 300px; height: 150px">
                      <img :src="detailData.img" />
                    </div>
                    <div class="title">{{ detailData.title }}</div>
                    <div class="subTitle">{{ detailData.subTitle }}</div>
                    <div class="desc">{{ detailData.desc }}</div>
                    <div class="btnBox">
                      <div @click="gotoDetail()" class="detailBtn">了解更多</div>
                      <img class="closeBtn" @click.stop="closeDetail()"
                        src="@/assets/images/chronology/icon_close.svg" />
                    </div>
                  </div>
                </div>
                <div class="echarts" style="width: 100%; height: 100%"></div>
              </div>
              <div class="toponymBox">
                <div class="imgBox" style="width: 280px; height: 280px">
                  <img :src="toponymData.img" />
                </div>
                <div class="">戏院:{{ toponymData.toponymName || "-" }}</div>
                <div class="">农历:{{ toponymData.chineseTime || "-" }}</div>
              </div>
            </div>
          </div>
        </div>
      </div> -->
      <div class="radial-tree-container">
        <div ref="chart" style="width: 100%; height: 600px"></div>
      </div>
    </div>
    <!-- 列表显示 -->
    <div class="page-main" v-if="activeTabs == 'list'">
      <div v-for="(item, index) in universityList" :key="index">
        <div class="table-title" v-if="item.studentList && item.studentList.length > 0">
        <div
          class="table-title"
          v-if="item.studentList && item.studentList.length > 0"
        >
          <div class="table-title-left">
            <p class="table-title-name">{{ item.name }}</p>
            <p class="table-title-degree">{{ item.degree }}</p>
            <p class="table-title-number">{{ item.studentList.length }}人</p>
          </div>
          <div class="table-title-right" @click="item.isShow = !item.isShow"><img
              src="../../assets/images/directory/topIcon.png" alt=""></div>
              :src="[item.isShow ? topIcon : bottomIcon]" alt=""></div>
        </div>
        <table cellpadding="100" v-if="item.studentList && item.studentList.length > 0 && item.isShow">
        <table
          cellpadding="100"
          v-if="item.studentList && item.studentList.length > 0 && item.isShow"
        >
          <tr class="table-heading">
            <th>
              姓名
            </th>
            <th>
              性别
            </th>
            <th>姓名</th>
            <th>性别</th>
            <th>学习时间</th>
            <th>工作单位(到二级单位全称)</th>
            <th>职务</th>
@@ -120,10 +65,17 @@
</template>
<script>
import echarts from "@/assets/js/echarts.min.js";
import * as echarts from "echarts";
import axios from "axios";
export default {
  data() {
    return {
      chartIcon: require("@/assets/images/directory/chartIcon.png"),
      noChartIcon: require("@/assets/images/directory/noChartIcon.png"),
      listIcon: require("@/assets/images/directory/listIcon.png"),
      noListIcon: require("@/assets/images/directory/noListIcon.png"),
      topIcon: require("@/assets/images/directory/topIcon.png"),
      bottomIcon: require("@/assets/images/directory/bottomIcon.png"),
      activeTabs: "chart",
      universityList: [
        {
@@ -155,7 +107,7 @@
              position: "原院长",
              title: "主任医师、教授",
            },
          ]
          ],
        },
        {
          name: "北京中医药大学",
@@ -186,7 +138,7 @@
              position: "原院长",
              title: "主任医师、教授",
            },
          ]
          ],
        },
        {
          name: "北京中医药大学",
@@ -217,14 +169,13 @@
              position: "原院长",
              title: "主任医师、教授",
            },
          ]
          ],
        },
        {
          name: "北京中医药大学",
          degree: "硕士",
          isShow: "true",
          studentList: [
          ]
          studentList: [],
        },
        {
          name: "北京中医药大学",
@@ -255,14 +206,13 @@
              position: "原院长",
              title: "主任医师、教授",
            },
          ]
          ],
        },
        {
          name: "北京中医药大学",
          degree: "硕士",
          isShow: "true",
          studentList: [
          ]
          studentList: [],
        },
        {
          name: "北京中医药大学",
@@ -293,23 +243,157 @@
              position: "原院长",
              title: "主任医师、教授",
            },
          ]
          ],
        },
      ]
    }
      ],
      chart: null,
      chartData: {
        name: "Root",
        children: [
          {
            name: "Node 1",
            children: [
              { name: "Leaf 1-1" },
              { name: "Leaf 1-2" },
              { name: "Leaf 1-3" },
            ],
          },
          {
            name: "Node 2",
            children: [
              {
                name: "Node 2-1",
                children: [{ name: "Leaf 2-1-1" }, { name: "Leaf 2-1-2" }],
              },
              { name: "Leaf 2-2" },
            ],
          },
          {
            name: "Node 3",
            children: [{ name: "Leaf 3-1" }, { name: "Leaf 3-2" }],
          },
        ],
      },
    };
  },
  mounted() {
    this.initChart();
    window.addEventListener("resize", this.handleResize);
  },
  beforeDestroy() {
    window.removeEventListener("resize", this.handleResize);
    if (this.chart) {
      this.chart.dispose();
    }
  },
  methods: {
    changeTab(key) {
      this.activeTabs = key
      this.activeTabs = key;
      console.log(this.activeTabs, "activeTabs");
      // if (key == "chart") {
    },
    initChart() {
      this.chart = echarts.init(this.$refs.chart);
      // } else if (key == 'list') {
      const option = {
        tooltip: {
          trigger: "item",
          triggerOn: "mousemove",
          formatter: (params) => {
            const data = params.data;
            return `
              <div style="
                padding: 10px;
                background: #fff;
                border-radius: 5px;
                box-shadow: 0 2px 10px rgba(0,0,0,0.1);
                max-width: 300px;
              ">
                <div style="
                  border-bottom: 1px solid #eee;
                  padding-bottom: 5px;
                  margin-bottom: 5px;
                ">
                  <span style="
                    font-size: 16px;
                    color: #333;
                    font-weight: bold;
                  ">${data.name}</span>
                  ${
                    data.customInfo
                      ? `<span style="
                    background: #ffeb3b;
                    padding: 2px 5px;
                    border-radius: 3px;
                    margin-left: 8px;
                    font-size: 12px;
                  ">${data.customInfo}</span>`
                      : ""
                  }
                </div>
                <div style="margin-top: 8px;">
                  <div>节点值: <span style="color: #4f8ff7;">${
                    data.value || 0
                  }</span></div>
                  <div>描述: ${data.description || "暂无描述"}</div>
                </div>
              </div>
            `;
          },
        },
        series: [
          {
            type: "tree",
            data: [this.chartData],
            layout: "radial",
            symbol: "emptyCircle",
            symbolSize: 7,
            initialTreeDepth: -1, // 展开所有节点
            animationDurationUpdate: 750,
            emphasis: {
              focus: "descendant",
            },
            label: {
              position: "left",
              verticalAlign: "middle",
              align: "right",
              fontSize: 12,
              rotate: 0,
            },
            leaves: {
              label: {
                position: "right",
                verticalAlign: "middle",
                align: "left",
              },
            },
            expandAndCollapse: true,
            lineStyle: {
              color: "#ccc",
              width: 1,
            },
            itemStyle: {
              color: "#4f8ff7",
              borderColor: "#4f8ff7",
            },
            roam: true,
            center: ["10%", "15%"], // 微调垂直居中
            radius: "60%", // 增大半径占比
            nodePadding: 20,
          },
        ],
      };
      // }
    }
  }
      this.chart.setOption(option);
    },
    handleResize() {
      if (this.chart) {
        this.chart.resize();
      }
    },
  },
};
</script>
@@ -344,13 +428,13 @@
  justify-content: center;
  cursor: pointer;
  margin-bottom: 75px;
  color: #9E9E9E;
  color: #9e9e9e;
  p {
    display: flex;
    align-items: center;
    padding: 15.5px 20px;
    border-bottom: 2px solid #9E9E9E;
    border-bottom: 2px solid #9e9e9e;
  }
  img {
@@ -370,8 +454,6 @@
  color: #937950 !important;
  border-bottom: 2px solid #937950 !important;
}
.page-main {
  width: 1313px;
@@ -409,16 +491,17 @@
    /* 移除最后一行的下边框 */
  }
}
.charts-main {
  // background-color: #000;
}
.table-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 28px;
  background-color: #D8CBB6;
  background-color: #d8cbb6;
  margin-bottom: 4px;
  margin-top: 2px;
  .table-title-left {
    display: flex;
@@ -446,7 +529,6 @@
    font-weight: bold;
  }
  .table-title-right {
    cursor: pointer;
  }
@@ -455,6 +537,5 @@
    width: 20px;
    height: auto;
  }
}
</style>
src/views/home/components/searchBox.vue
New file
@@ -0,0 +1,109 @@
<template>
  <div class="search-container">
    <el-select
      v-model="selectedType"
      slot="prepend"
      placeholder="请选择"
      class="type-select"
    >
      <el-option
        v-for="item in options"
        :key="item.value"
        :label="item.label"
        :value="item.value"
      />
    </el-select>
    <div class="inputBox">
      <input type="text" v-model="searchText" class="search-input" />
      <div class="searchBtn">搜索</div>
    </div>
  </div>
</template>
<script>
export default {
  name: "SearchBox",
  data() {
    return {
      searchText: "", // 输入框内容
      selectedType: "", // 下拉框选中值
      options: [
        // 下拉选项
        { value: "all", label: "全部" },
        { value: "name", label: "名称" },
        { value: "id", label: "ID" },
        { value: "code", label: "编码" },
      ],
    };
  },
  methods: {
    // 搜索处理
    handleSearch() {
      this.$emit("search", {
        text: this.searchText,
        type: this.selectedType,
      });
    },
  },
};
</script>
<style scoped>
/* 组合样式 */
.search-container {
  max-width: 800px;
  margin: 20px 0;
  display: flex;
}
/* 输入框样式 */
.search-input {
}
.inputBox {
  border: 1px solid #B9A587;
  height: 38px;
  width: 400px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 13px;
  padding-right: 5px;
  border-radius: 5px;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  padding-left: 10px;
}
.searchBtn {
  width: 70px;
  height: 30px;
  background-color: #937950;
  margin-left: 10px;
  cursor: pointer;
  font-size: 14px;
  text-align: center;
  line-height: 30px;
  color: #fff;
}
/* 下拉框样式 */
.type-select {
  width: 120px;
}
/* 调整间距 */
.el-select /deep/ .el-input__inner {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
  border: 1px solid #B9A587;
  border-right: none;
}
.el-input-group__prepend {
  padding: 0;
  border: none;
}
</style>
src/views/home/index.vue
@@ -1,12 +1,100 @@
<template>
  <div class="home">
    <div class="profilePhoto">
    <div class="headerBox">
      <div class="title">
        <p>王永炎院士</p>
        <p>学术思想传承多维度数据库</p>
      </div>
      <div class="searchBox">
        <SearchBox />
      </div>
    </div>
    <div class="menuBox">
      <div class="menuList">
        <div
          class="menu"
          v-for="item in menuList"
          :key="item.id"
          @click="$router.push(item.path)"
        >
          <div class="menuIcon"><i class="el-icon-platform-eleme"></i></div>
          <div class="menuTitle">{{ item.title }}</div>
          <div class="menuSubTitle">{{ item.subTitle }}</div>
          <div class="menuLine"><i class="el-icon-right"></i></div>
        </div>
      </div>
    </div>
    <div class="personalProfile">
      <div class="textInfo">
        <p>
          <i style="font-size: 18px">王永炎(1938.09.29 - ) </i>
          <i> 字致远,号颖容学人,中医内科学、中药资源学专家。</i>
        </p>
        <p>
          中央文史研究馆馆员,中国工程院院士,中国科学技术协会荣誉委员,第十届全国人大常委会委员,著名中医学家、中医脑病学家。
        </p>
        <p>
          曾任北京中医药大学校长、中国中医科学院院长,国务院学位委员会中医学、中药学学科评议组第三、四、五届召集人;
        </p>
        <p>
          现任中国中医科学院名誉院长、中国中医科学院临床医学基础研究所所长、北京师范大学资源学院资源药物与中药资源研究所所长、北京中医药大学脑病研究院学术委员会主<br />任,中国药典委员会第六、七届委员、第八、九届执行委员。
        </p>
        <p>
          曾获国家科学科技进步奖一等奖1项、二等奖2项、三等奖3项,省部级科技成果一等奖8项,获何梁何利基金“科学与技术进步奖”、香港求是科技基金会“中医药现代化杰出科技成就奖”,中国标准化协会“标准化终身成就奖”,中国产学研合作促进会产学研合作突出贡献奖,获全国五一劳动奖章和“全国先进工作者”荣誉称号。
        </p>
      </div>
    </div>
    <div class="copyrightInformation">
      版权所有:中国中医研究院 京ICP备 0384937947 京公网安备 1212129923
    </div>
    <div class="profilePhoto"></div>
  </div>
</template>
<script>
export default {};
import SearchBox from "./components/searchBox.vue";
export default {
  components: {
    SearchBox,
  },
  data() {
    return {
      menuList: [
        {
          icon: "el-icon-platform-eleme",
          title: "年谱",
          subTitle: "1936-2024",
          path: "/chronology",
        },
        {
          icon: "el-icon-platform-eleme",
          title: "学术成果",
          subTitle: "100+",
          path: "/achievements",
        },
        {
          icon: "el-icon-platform-eleme",
          title: "荣誉奖项",
          subTitle: "50+",
          path: "/honor",
        },
        {
          icon: "el-icon-platform-eleme",
          title: "学生目录",
          subTitle: "1936-2024",
          path: "/directory",
        },
      ],
    };
  },
  methods: {
    goPage(row) {
      console.log(row);
      this.$router.push(row.path);
    },
  },
};
</script>
<style>
@@ -15,16 +103,105 @@
  height: 100vh;
  background-image: url("@/assets/images/homeBg.png");
  background-repeat: no-repeat;
  background-size: 100% 95%;
  background-size: 98% 95%;
  position: relative;
  padding: 0 40px;
  box-sizing: border-box;
}
.profilePhoto {
  background-image: url("@/assets/images/profilePhoto.png");
  width: 575px;
  height: 656px;
  width: 475px;
  height: 556px;
  background-size: 100% 100%;
  position: relative;
  top: 33%;
  position: absolute;
  top: 30%;
  left: 8%;
}
.headerBox {
  width: 99.5%;
  height: 220px;
  padding-top: 60px;
  padding-left: 40px;
  border-bottom: 1px solid#937950;
  font-size: 50px;
  line-height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: Alimama DongFangDaKai;
  box-sizing: border-box;
}
.searchBox {
  margin-right: 100px;
}
.menuBox {
  position: absolute;
  right: 48px;
  width: 1000px;
  font-family: Alimama DongFangDaKai;
}
.menu {
  width: 25%;
  height: 450px;
  background-color: #fff;
  text-align: center;
  padding-top: 20px;
  box-sizing: border-box;
  border: 1px solid #937950;
  border-top: none;
  border-left: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #937950;
}
.menu:first-child {
  border-left: 1px solid #937950;
}
.menuIcon {
  font-size: 80px;
  margin-top: 20px;
}
.menuTitle {
  font-size: 40px;
  font-weight: 600;
  margin-top: 20px;
}
.menuSubTitle {
  font-size: 28px;
  margin-top: 20px;
}
.menuLine {
  margin-top: 40px;
  font-size: 40px;
}
.menuList {
  display: flex;
}
.personalProfile {
  background: rgba(147, 121, 80, 0.15);
  height: 170px;
  width: 100%;
  position: absolute;
  right: 40px;
  bottom: 111px;
  border: 1px solid #937950;
}
.textInfo {
  position: absolute;
  right: 40px;
  width: 1000px;
  margin-top: 20px;
  line-height: 16px;
}
.copyrightInformation {
  position: absolute;
  bottom: 80px;
  font-size: 12px;
  color: #937950;
  width: 100%;
  text-align: center;
}
</style>
yarn.lock
Diff too large