From 784f598b870c16ee93075fdc23df3f68bec0a460 Mon Sep 17 00:00:00 2001
From: feige <791364011@qq.com>
Date: 星期六, 02 十一月 2024 22:18:39 +0800
Subject: [PATCH] 修改bug

---
 ruoyi-ui/src/views/homeRoot/personInfo.vue |   34 ++++++++++++++++++++++++++--------
 1 files changed, 26 insertions(+), 8 deletions(-)

diff --git a/ruoyi-ui/src/views/homeRoot/personInfo.vue b/ruoyi-ui/src/views/homeRoot/personInfo.vue
index bb384ee..c95ed04 100644
--- a/ruoyi-ui/src/views/homeRoot/personInfo.vue
+++ b/ruoyi-ui/src/views/homeRoot/personInfo.vue
@@ -133,10 +133,10 @@
 		
 							 
 			   
-			   <div style="margin-bottom: 20px;">
+			   <div style="margin-bottom: 20px;"  v-if="cid==uid">
 				<el-button size='mini' type="text" class="btn_edit" @click="editAutography" style='top: 0px; bottom:20px;right: 20px;'>
-				  <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn>
-				  <span >{{ editMode ? this.bstn='淇濆瓨' : this.bstn='淇敼' }}</span>
+				  <sapn v-if="cid==uid" v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn>
+				  <span v-if="cid==uid">{{ editMode ? this.bstn='淇濆瓨' : this.bstn='淇敼' }}</span>
 				</el-button>
 				</div>
 				<el-tab-pane
@@ -183,14 +183,16 @@
 </template>
 
 <script>
-import {getRoot} from "@/api/root/index";
+import {getRoot,updateInfoUser} from "@/api/root/index";
   export default {
-    name: "index",
+    name: "personInfo",
     data(){
       return{
+		  cid: undefined,
+		  uid: undefined,
 		  bstn: undefined,
 		  editMode:false,
-		  autoGrahpy: "22222222222222222",
+		  autoGrahpy: "濮撳悕__________锛屾�у埆__________锛屽嚭鐢熶簬____骞確_鏈坃_鏃ャ�傛垜姣曚笟浜巁_________澶у鐨刜_________涓撲笟锛岃幏寰梍_________瀛﹀巻銆傜洰鍓嶅氨鑱屼簬__________鐨刜_________鑱屼綅锛屼富瑕佽礋璐_________锛岄�氳繃杩愮敤__________鎶�鑳�/鏂规硶锛屾垚鍔熷疄鐜颁簡__________锛屼笉浠呮彁鍗囦簡涓汉涓撲笟鑳藉姏锛屼篃淇冭繘浜嗗洟闃熶笌椤圭洰鐨勬垚鍔熴�傚湪涓氫綑鏃堕棿锛屾垜鐑》浜巁_________锛堝闃呰銆佹梾琛屻�佹憚褰辩瓑锛変綔涓烘垜鐨勫叴瓒g埍濂斤紝杩欎簺娲诲姩涓嶄粎涓板瘜浜嗘垜鐨勭敓娲伙紝涔熻鎴戝湪鏀炬澗鐨勫悓鏃朵笉鏂涔犲拰鎴愰暱銆傚洖椤捐繃寰�锛屾渶浠ゆ垜闅惧繕鐨勪竴浠朵簨鏄痏_________锛堢畝杩颁簨浠讹紝濡傚弬涓庣殑涓�娆¢噸澶ч」鐩�佷竴娆¢毦蹇樼殑鏃呰缁忓巻鎴栬В鍐虫煇涓毦棰樼殑杩囩▼锛夛紝杩欎欢浜嬩笉浠呰鎴戞繁鍒讳綋浼氬埌浜哶_________锛堝鍥㈤槦鍚堜綔鐨勫姏閲忋�佸潥鎸佷笉鎳堢殑閲嶈鎬с�佺敓娲荤殑缇庡ソ绛夛級锛屼篃瀵规垜鐨勪汉鐢熻鍜屼环鍊艰浜х敓浜嗘繁杩滅殑褰卞搷銆傛垜鍏峰__________绛夌壒璐紝鑳藉蹇�熼�傚簲鏂扮幆澧冿紝鍕囦簬鎸戞垬锛岃嚧鍔涗簬鍦╛_________棰嗗煙涓笉鏂拷姹傚崜瓒�",
         // 閬僵灞�
 		
         disabled: false,
@@ -251,6 +253,7 @@
   ,
   mounted() {
      const id = this.$route.params && this.$route.params.id;
+	 this.uid = id; 
      this.getList(id);
   },
   methods:{
@@ -259,7 +262,11 @@
 	    // const id = row.userId;
 		//alert(id)
 	    // alert(id)
-	   this.$router.push("/familymodel/jiagenwang/personInfo/" + id);
+	//	alert(23)
+this.$store.dispatch("tagsView/delView", this.$route); //鍏抽棴褰撳墠椤�
+		this.$router.replace({ path: "/familymodel/jiagenwang/personInfo/" + id });
+
+	 //  this.$router.push("/familymodel/jiagenwang/personInfo/" + id);
 	  },
 	  
 	  editAutography(data)
@@ -267,12 +274,21 @@
 		  this.editMode = true;
 		  if(this.bstn=="淇濆瓨")
 		  {
+			
 			   this.editMode = false
-			  }
+			  var fdt = {
+				 selfIntroduction: this.autoGrahpy}
+			    updateInfoUser(fdt).then(response=>{
+					this.$modal.msgSuccess("淇敼鎴愬姛")
+					this.getList(this.uid)
+				})
+		  }
 	  },
 	  
     getList(id)
     {
+		this.cid = this.$store.state.user.userId
+		
      let _this = this;
       getRoot(id).then(response => {
          console.log(response.data)
@@ -282,6 +298,8 @@
       //  if(_this.personInfos[1]==null)
         //  _this.isshow = false;
         _this.personInfo1 = response.data[0]
+		if(response.data[0].selfIntroduction!=null)
+		_this.autoGrahpy = response.data[0].selfIntroduction
         //alert(this.personInfos[0].url)
 
     });

--
Gitblit v1.9.1