From 22f6c02cdae18e9501a2ce8911208218d271fd92 Mon Sep 17 00:00:00 2001
From: feige <791364011@qq.com>
Date: 星期六, 24 八月 2024 08:19:47 +0800
Subject: [PATCH] 修改小bug
---
ruoyi-ui/src/views/mindMap/index.vue | 15 +++--
ruoyi-ui/src/views/genealogy/index.vue | 10 ++
ruoyi-ui/src/views/components/superMindmap.vue | 56 +++++++++++-------
ruoyi-ui/src/views/bignote/index.vue | 21 ++++++-
ruoyi-ui/vue.config.js | 4
ruoyi-ui/src/layout/components/Navbar.vue | 32 ++++++++++
6 files changed, 101 insertions(+), 37 deletions(-)
diff --git a/ruoyi-ui/src/layout/components/Navbar.vue b/ruoyi-ui/src/layout/components/Navbar.vue
index b280cbc..dba4a53 100644
--- a/ruoyi-ui/src/layout/components/Navbar.vue
+++ b/ruoyi-ui/src/layout/components/Navbar.vue
@@ -16,7 +16,11 @@
<el-tooltip content="鏂囨。鍦板潃" effect="dark" placement="bottom">
<ruo-yi-doc id="ruoyi-doc" class="right-menu-item hover-effect" />
</el-tooltip>
- -->
+ -->
+ <el-tooltip effect="dark" placement="bottom">
+ <h1 class="right-menu-item hover-effect" style="text-align: center;display:
+ block;line-height: 50px;">{{greeting}}</h1>
+ </el-tooltip>
<screenfull id="screenfull" class="right-menu-item hover-effect" />
<el-tooltip content="甯冨眬澶у皬" effect="dark" placement="bottom">
@@ -24,7 +28,7 @@
</el-tooltip>
</template>
-
+
<el-dropdown class="avatar-container right-menu-item hover-effect" trigger="click">
<div class="avatar-wrapper">
<img :src="avatar" class="user-avatar">
@@ -68,12 +72,36 @@
RuoYiGit,
RuoYiDoc
},
+ data() {
+ return {
+
+ greeting: "",
+
+ };
+ },
+ mounted() {
+ this.setGreeting();
+ },
computed: {
...mapGetters([
'sidebar',
'avatar',
'device'
]),
+ setGreeting() {
+ const currentTime = new Date();
+ const currentHour = currentTime.getHours();
+ let name = this.$store.state.user.name
+ if (currentHour < 12) {
+ this.greeting = "鏃╀笂濂�,"+name;
+ } else if (currentHour < 14) {
+ this.greeting = "涓崍濂�,"+name;
+ } else if (currentHour < 18) {
+ this.greeting = "涓嬪崍濂�,"+name;
+ } else {
+ this.greeting = "鏅氫笂濂�,"+name;
+ }
+ },
setting: {
get() {
return this.$store.state.settings.showSettings
diff --git a/ruoyi-ui/src/views/bignote/index.vue b/ruoyi-ui/src/views/bignote/index.vue
index 926c621..a353ab7 100644
--- a/ruoyi-ui/src/views/bignote/index.vue
+++ b/ruoyi-ui/src/views/bignote/index.vue
@@ -244,7 +244,7 @@
/>
<!-- 娣诲姞鎴栦慨鏀硅祫浜т俊鎭厤缃璇濇 -->
- <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body>
+ <el-dialog :title="title" @click="handleVisibleChange" :visible.sync="open" width="800px" append-to-body :before-close="close" >
<el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="100px">
@@ -262,8 +262,10 @@
</el-form-item>
<el-form-item label="鍙戠敓鏃堕棿" prop="happenTime">
- <el-date-picker v-model="formDat.happenTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡"
- :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd"
+ <el-date-picker ref="datePicker" v-model="formDat.happenTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡"
+ :visible="isVisible"
+ @blur="handleVisibleChange"
+ :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd"
></el-date-picker>
</el-form-item>
<el-form-item label="澶囨敞" prop="remark">
@@ -529,6 +531,7 @@
dicts: ['sys_normal_disable'],
data() {
return {
+ isVisible:false,
// 鍒嗕韩缁欒皝鐨刲ist
listRoot: [],
open1:false,
@@ -860,8 +863,20 @@
isInFot(fileName) {
return this.fot.includes(fileName);
},
+ handleVisibleChange(){
+ alert(12)
+ this.isVisible = false
+ this.$refs.datePicker.hidePicker();
+ },
+ close(){
+ //alert(234)
+ this.$refs.datePicker.hidePicker()
+
+ this.open = false
+ },
// 鍙栨秷鎸夐挳
cancelData() {
+ this.$refs.datePicker.hidePicker()
this.open = false;
this.reset();
},
diff --git a/ruoyi-ui/src/views/components/superMindmap.vue b/ruoyi-ui/src/views/components/superMindmap.vue
index 7675fc7..103ae82 100644
--- a/ruoyi-ui/src/views/components/superMindmap.vue
+++ b/ruoyi-ui/src/views/components/superMindmap.vue
@@ -250,28 +250,39 @@
return 'pointer'
}
})
- // 娣诲姞澶村儚
- groups.append("image")
- .attr("xlink:href", function (d) {
- return d.data.url; // 澶村儚鍥剧墖鐨勮矾寰�
- })
- .attr("x", 12) // 澶村儚鐩稿浜庤妭鐐圭殑姘村钩浣嶇疆
- .attr("y", 3) // 澶村儚鐩稿浜庤妭鐐圭殑鍨傜洿浣嶇疆
- .attr("width", 24) // 澶村儚鐨勫搴�
- .attr("height", 24); // 澶村儚鐨勯珮搴�
- //缁樺埗鏍囨敞(鑺傜偣鍓嶇殑鐭╁舰)
- groups.append("rect")
- .attr("x", 37)
- .attr("y", 3)
- .attr("width",
- function (d) {
- return d.data.link ? (getPXwidth(d.data.link) + 30) : 0
- }
- )
- .attr("height", 26)
- .attr("fill", "#FFFFFF")
- // 娣诲姞鍦嗚
- .attr("rx", 4)
+ // 娣诲姞澶村儚
+ let pu = null
+ let gp = groups.append("image")
+ .attr("xlink:href", function (d) {
+ // console.log(d.data.purl)
+ pu = d.data.purl
+ // console.log(d.data.prop)
+ // console.log(d.data.label==="")
+ if(d.data.label==="")
+ return ""
+ else
+ return d.data.purl; // 澶村儚鍥剧墖鐨勮矾寰�
+ })
+ if (pu!=null){
+ gp.attr("x", 12) // 澶村儚鐩稿浜庤妭鐐圭殑姘村钩浣嶇疆
+ .attr("y", 3) // 澶村儚鐩稿浜庤妭鐐圭殑鍨傜洿浣嶇疆
+ .attr("width", 24) // 澶村儚鐨勫搴�
+ .attr("height", 24); // 澶村儚鐨勯珮搴�
+
+ //缁樺埗鏍囨敞(鑺傜偣鍓嶇殑鐭╁舰)
+ gp.append("rect")
+ .attr("x", 37)
+ .attr("y", 3)
+ .attr("width",
+ function (d) {
+ return d.data.link ? (getPXwidth(d.data.link) + 30) : 0
+ }
+ )
+ .attr("height", 26)
+ .attr("fill", "#FFFFFF")
+ // 娣诲姞鍦嗚
+ .attr("rx", 4)
+ }
//缁樺埗鏂囧瓧
groups.append("text")
.on("click", function (event, node) {
@@ -286,6 +297,7 @@
that.$router.push("/familymodel/jiagenwang/personInfo/" + data.id);
//that.$emit('activeChange', 'map')
+
// return
}
// 鏍囧噯鑺傜偣鈥斺�� 浼犲嚭 prop
diff --git a/ruoyi-ui/src/views/genealogy/index.vue b/ruoyi-ui/src/views/genealogy/index.vue
index f8a97c1..817da99 100644
--- a/ruoyi-ui/src/views/genealogy/index.vue
+++ b/ruoyi-ui/src/views/genealogy/index.vue
@@ -92,7 +92,13 @@
<span v-else>鈥斺��</span>
</template>
</el-table-column>
- <el-table-column label="濮撳悕" prop="nickName" sortable :show-overflow-tooltip="true" width="100" align="center"/>
+ <el-table-column label="濮撳悕" prop="nickName" sortable :show-overflow-tooltip="true" width="100" align="center">
+ <template slot-scope="scope" >
+
+ <el-button @click="handleCheck(scope.row)">{{scope.row.nickName}}</el-button>
+ </template>
+ </el-table-column>
+
<el-table-column label="鎬у埆" prop="sex" sortable width="100" align="center" >
<template slot-scope="scope">
<span v-if="scope.row.sex===1">鐢�</span>
@@ -368,7 +374,7 @@
this.queryParams.happenStartTime = this.dateRange.length > 0 && this.dateRange[0]
this.queryParams.happenEndTime = this.dateRange.length > 0 && this.dateRange[1]
this.queryParams.clanId = this.$store.state.user.clanId
-
+ this.listRoot = []
// listProperty(this.addDateRange(this.queryParams, this.dateRange)).then(response => {
listUserAll(this.queryParams).then(response => {
// console.log(response.data)
diff --git a/ruoyi-ui/src/views/mindMap/index.vue b/ruoyi-ui/src/views/mindMap/index.vue
index e19ed33..ef9bdd5 100644
--- a/ruoyi-ui/src/views/mindMap/index.vue
+++ b/ruoyi-ui/src/views/mindMap/index.vue
@@ -1,7 +1,7 @@
<template>
<div class="app-container">
- <div class="text" style="background-color: #FEF7FC;" >
- <h1 style="font-size: 21px;">{{ greeting +'锛�' + user.userName }}</h1></div>
+<!-- <div class="text" style="background-color: #FEF7FC;" >
+ <h1 style="font-size: 21px;">{{ greeting +'锛�' + user.userName }}</h1></div> -->
<div class="image-container" style="background-color: #FEF7FC;">
<img class="top-image" src="../../assets/images/zhang.png" alt="Top Image">
</div>
@@ -35,7 +35,7 @@
};
},
mounted() {
- this.setGreeting();
+ // this.setGreeting();
this.getUser();
// this.mapData = MapData.webMap
@@ -85,6 +85,7 @@
const mindMapData = this.rootList[0];
console.log(mindMapData)
+ // for(let i = 0; i < )
console.log('9999')
// console.log(this.drawData(mindMapData))
this.mapData = this.drawData(mindMapData)
@@ -93,13 +94,14 @@
},
drawData(mpdata) {
+ let tp = "https://www.bendudu.com:8080/profile/upload/2023/03/19/test7_20230319222030A007.jpg"
if (mpdata == null)
return null;
var data = {
"label": mpdata['spouse'] != null ? eval(mpdata['spouse']).nickName : '',
"prop": mpdata['nickName'],
- "url": 'https://www.bendudu.com:8080/'+mpdata['url'],
- // "purl": 'https://www.bendudu.com:8080/'+mpdata['spouse'],
+ "url": mpdata['url']!=null?'https://www.bendudu.com:8080/'+mpdata['url']:tp,
+ "purl": mpdata['spouse'] != null ? (mpdata['spouse'].url!=null? 'https://www.bendudu.com:8080/'+mpdata['spouse'].url:tp):tp,
"id": mpdata['userId'],
"link": mpdata['nickName'],
"children": []
@@ -110,8 +112,9 @@
var dt = {
"label": mpdata['childList'][i]['spouse'] != null ? eval(mpdata['childList'][i]['spouse']).nickName : "",
"prop": mpdata['childList'][i]['nickName'],
- "url": 'https://www.bendudu.com:8080/'+mpdata['childList'][i]['url'],
+ "url": mpdata['childList'][i]['url']!=null?'https://www.bendudu.com:8080/'+mpdata['childList'][i]['url']:tp,
"id": mpdata['childList'][i]['userId'],
+ "purl": (mpdata['childList'][i]['spouse'] != null ) ?( mpdata['childList'][i]['spouse'].url!= null?'https://www.bendudu.com:8080/'+mpdata['childList'][i]['spouse'].url:tp):tp,
"link": mpdata['childList'][i]['nickName'],
"children": []
};
diff --git a/ruoyi-ui/vue.config.js b/ruoyi-ui/vue.config.js
index 17ab79b..2fcab40 100644
--- a/ruoyi-ui/vue.config.js
+++ b/ruoyi-ui/vue.config.js
@@ -37,8 +37,8 @@
// detail: https://cli.vuewww.bendudu.comjs.org/config/#devserver-proxy
[process.env.VUE_APP_BASE_API]: {
//target: `https://10.39.18.174:8080/`,
- // target: `https://192.168.1.3:8080/`,
- target: 'https://www.bendudu.com:8080/',
+ target: `https://192.168.1.3:8080/`,
+ // target: 'https://www.bendudu.com:8080/',
changeOrigin: true,
pathRewrite: {
['^' + process.env.VUE_APP_BASE_API]: ''
--
Gitblit v1.9.1