From f468170d79dee3f8efb75705c7e23a1b53e54e91 Mon Sep 17 00:00:00 2001 From: feige <791364011@qq.com> Date: 星期二, 29 七月 2025 22:08:02 +0800 Subject: [PATCH] 修改了内容 --- ruoyi-ui/src/views/homeRoot/personInfo.vue | 373 +++++++++++++++++++++++++++++++++++++++++++++++++++- 1 files changed, 362 insertions(+), 11 deletions(-) diff --git a/ruoyi-ui/src/views/homeRoot/personInfo.vue b/ruoyi-ui/src/views/homeRoot/personInfo.vue index edcb863..f5f5a84 100644 --- a/ruoyi-ui/src/views/homeRoot/personInfo.vue +++ b/ruoyi-ui/src/views/homeRoot/personInfo.vue @@ -1,36 +1,387 @@ <template> - <div> - adsafasdfasdfasdfsdf + <div class="app-container" > + <div class="wrapper" style="overflow: auto;"> + <div id="building" v-if="isshow"> + <el-form ref="elForm" :model="personInfos" :rules="rules" size="medium" label-position="center" label-width="100px"> + <el-container> + <div style="padding-left:30px;padding-top: 50px"> + <el-col :span="6" :data="personInfos"> + <div class="block" :model="personInfos" > + <el-col v-model="personInfos[0].url" prop="url"> + <el-avatar shape="square" :size=200 > + <el-image + :src="'https://www.bendudu.com:8080/'+personInfos[0].url" + style="width: 100%;height: 100%;" + ></el-image> + </el-avatar> + </el-col> + </div> + </el-col> + </div> + <div style="padding-left:30px;padding-top: 15px"> + <el-col> + <el-row :span="8"> + <el-form-item label="濮撳悕" prop="nickName" label-width="50px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].nickName" placeholder="璇疯緭鍏ュ鍚�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="韬唤" prop="identity" label-width="50px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].identity" placeholder="璇疯緭鍏ヨ韩浠�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="鏇剧敤鍚�" prop="oldName" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].oldName" placeholder="璇疯緭鍏ユ浘鐢ㄥ悕" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="鐢熻倴" prop="shengXiao" label-width="50px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].shengXiao" placeholder="璇疯緭鍏ョ敓鑲�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + + <el-row :span="8"> + <el-form-item label="鎴风睄鍦板潃" prop="locationAddress" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input type="textarea" v-model="personInfos[0].locationAddress" placeholder="璇疯緭鍏ユ埛绫嶅湴鍧�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + </el-col> + </div> + <div style="padding-left:30px;padding-top: 15px"> + <el-col> + <el-row :span="8"> + <el-form-item label="鎬у埆" prop="sex" label-width="45px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].sex === 0 ? '鐢�':'濂�'" placeholder="璇疯緭鍏ユ�у埆" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="姘戞棌" prop="nation" label-width="50px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].nation" placeholder="璇疯緭鍏ユ皯鏃�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="鑱旂郴鏂瑰紡" prop="phoneNumber" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].phoneNumber" placeholder="璇疯緭鍏ヨ仈绯绘柟寮�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="寰俊鍙�" prop="wxNo" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].wxNo" placeholder="璇疯緭鍏ュ井淇″彿" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="甯镐綇鍦板潃" prop="alwaysAddress" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input type="textarea" v-model="personInfos[0].alwaysAddress" placeholder="璇疯緭鍏ュ父浣忓湴鍧�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + </el-col> + </div> + <div style="padding-left:30px;padding-top: 15px"> + <el-col> + <el-row :span="8"> + <el-form-item label="濠氬Щ鐘跺喌" prop="maritalStatus" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].maritalStatus === 1 ? '宸插':'鏈'" placeholder="璇疯緭鍏ュ濮荤姸鍐�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="閰嶅伓" prop="nickName" label-width="50px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-if="personInfos[1]!=null" v-model="personInfos[1].nickName" placeholder="璇疯緭鍏ラ厤鍋�" clearable :style="{width: '100%'}" :disabled="dsb"> + <template slot="suffix"> + <a @click="handleCheck(personInfos[1].userId)" class="aft">鏌ョ湅璇︽儏</a> + </template> + </el-input> + </el-form-item> + </el-row> + + + <el-row :span="8"> + <el-form-item label="鑱屽姟鑱岀О" prop="position" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].position" placeholder="璇疯緭鍏ヨ亴鍔¤亴绉�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="鏄熷骇" prop="constellation" label-width="50px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input v-model="personInfos[0].constellation" placeholder="璇疯緭鍏ユ槦搴�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + <el-row :span="8"> + <el-form-item label="鍗曚綅" prop="unit" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> + <el-input type="textarea" v-model="personInfos[0].unit" placeholder="璇疯緭鍏ュ崟浣�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + </el-row> + </el-col> + </div> + </el-container> + + <el-divider /> + <div> + <el-tabs type="border-card" + > + + + + <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-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 + label="涓汉绠�浠�"> + <template v-if="editMode"> + <div style="padding-top: 20px;margin-top: 10px;width: 90%;"> + <el-input v-model="autoGrahpy" autosize type="textarea" maxlength="1024" +></el-input></div> + </template> + <template v-else> + {{autoGrahpy}} + </template> + </el-tab-pane> + </el-tabs></div> + </el-form> + </div> +<el-divider style="top:120px;"/> + + + </div> + <div> + <el-row> + <el-col :span="11" class="bordered-col"> + <div class="left-content">鎴戠殑鍒嗕韩</div> + <el-divider /> + <el-card class="box-card"> + <div v-for="o in 4" :key="o" class="text item"> + <a href="www.baidu.com">{{'鍒楄〃鍐呭 ' + o }}</a> + </div> + </el-card> + </el-col> + <el-col :span="11" class="bordered-col"> + <div class="left-content">鎴戠殑鏀惰棌</div> + <el-divider /> + <el-card class="box-card"> + <div v-for="o in 4" :key="o" class="text item"> + {{'鍒楄〃鍐呭 ' + o }} + </div> + </el-card> + </el-col> + </el-row> + </div> </div> </template> <script> -import {getRoot} from "@/api/root/index"; +import {getRoot,updateInfoUser} from "@/api/root/index"; export default { - name: "index", + name: "personInfo", data(){ return{ - personInfos:[] - } + cid: undefined, + uid: undefined, + bstn: undefined, + editMode:false, + autoGrahpy: "濮撳悕__________锛屾�у埆__________锛屽嚭鐢熶簬____骞確_鏈坃_鏃ャ�傛垜姣曚笟浜巁_________澶у鐨刜_________涓撲笟锛岃幏寰梍_________瀛﹀巻銆傜洰鍓嶅氨鑱屼簬__________鐨刜_________鑱屼綅锛屼富瑕佽礋璐_________锛岄�氳繃杩愮敤__________鎶�鑳�/鏂规硶锛屾垚鍔熷疄鐜颁簡__________锛屼笉浠呮彁鍗囦簡涓汉涓撲笟鑳藉姏锛屼篃淇冭繘浜嗗洟闃熶笌椤圭洰鐨勬垚鍔熴�傚湪涓氫綑鏃堕棿锛屾垜鐑》浜巁_________锛堝闃呰銆佹梾琛屻�佹憚褰辩瓑锛変綔涓烘垜鐨勫叴瓒g埍濂斤紝杩欎簺娲诲姩涓嶄粎涓板瘜浜嗘垜鐨勭敓娲伙紝涔熻鎴戝湪鏀炬澗鐨勫悓鏃朵笉鏂涔犲拰鎴愰暱銆傚洖椤捐繃寰�锛屾渶浠ゆ垜闅惧繕鐨勪竴浠朵簨鏄痏_________锛堢畝杩颁簨浠讹紝濡傚弬涓庣殑涓�娆¢噸澶ч」鐩�佷竴娆¢毦蹇樼殑鏃呰缁忓巻鎴栬В鍐虫煇涓毦棰樼殑杩囩▼锛夛紝杩欎欢浜嬩笉浠呰鎴戞繁鍒讳綋浼氬埌浜哶_________锛堝鍥㈤槦鍚堜綔鐨勫姏閲忋�佸潥鎸佷笉鎳堢殑閲嶈鎬с�佺敓娲荤殑缇庡ソ绛夛級锛屼篃瀵规垜鐨勪汉鐢熻鍜屼环鍊艰浜х敓浜嗘繁杩滅殑褰卞搷銆傛垜鍏峰__________绛夌壒璐紝鑳藉蹇�熼�傚簲鏂扮幆澧冿紝鍕囦簬鎸戞垬锛岃嚧鍔涗簬鍦╛_________棰嗗煙涓笉鏂拷姹傚崜瓒�", + // 閬僵灞� + + disabled: false, + personInfos:{}, + personInfo1:{}, + loading: true, + dsb:true, + isshow:true, + formData:{ + userId: undefined, + nickName: undefined, + oldName: undefined, + sex: undefined, + nationality: undefined, + nation: undefined, + maritalStatus: undefined, + politicalOutlook: undefined, + phoneNumber:undefined, + wxNo:undefined, + qqNo:undefined, + idNum: undefined, + locationAddress: undefined, + alwaysAddress:undefined, + locationPolice: undefined, + alwaysPolice: undefined, + unit: undefined, + position:undefined, + outStatus:undefined, + idNo: undefined, + constellation:undefined, + shengXiao:undefined, + img: undefined, + spouseId: undefined, + fatherId: undefined, + momId: undefined, + birth: undefined, + url:undefined, + familyId:undefined, + secondFamilyId: undefined, + childList: undefined + }, + // 鑿滃崟鍒楄〃 + menuOptions: [], + // 閮ㄩ棬鍒楄〃 + deptOptions: [], + // 琛ㄥ崟鍙傛暟 + form: {}, + defaultProps: { + children: "children", + label: "label" + }, + // 琛ㄥ崟鏍¢獙 + rules: { + + }, + } } , mounted() { - const id = this.$route.params && this.$route.params.id; + const id = this.$route.params && this.$route.params.id; + this.uid = id; this.getList(id); }, methods:{ + /** 鏌ョ湅璇︾粏淇℃伅 */ + handleCheck(id){ + // const id = row.userId; + //alert(id) + // alert(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) + { + 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) { - // alert(id) + this.cid = this.$store.state.user.userId + + let _this = this; getRoot(id).then(response => { - console.log(response.data) + console.log(response.data) + console.log("-----") //杩欓噷鏄か濡荤殑淇℃伅锛屽凡缁忔嬁鍒颁簡 - this.personInfos = response.data - }) + _this.personInfos = response.data + // 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) + + }); + } }, } </script> <style> +.wrapper { + /*鑳屾櫙鍥�*/ + background: url("../../assets/images/Group 407.png"); + width: 100%; + height: 100%; + background-size: 100%; + background-position: top left; + background-repeat: no-repeat; +} +#building building2{ + /*璁剧疆閫忔槑搴�*/ + /*opacity: 0.9;*/ + background: rgba(255,255,255,0.8); + /*overflow-y:auto;*/ +} +.app-container{ + background-color: #FEF7FC; + +} +.el-divider { + /*display: inline-block;*/ + weight: 1px; + height: 1px; + background: 0 0; + background-color: rgba(0,0,0,0.3); + margin: 2px 0px; + position: relative; +} +.centered-label .el-form-item__content{ + line-height: 38px; + padding: 0px; + margin-left: 50%; + border: 1px solid red; + text-align: center; +} +.btn_edit{ + background:center no-repeat url('../../assets/icons/edit.png') ; + float: right; + padding-right: 90px; +} +.bordered-col { + border: 1px solid #d3dce6; /* 璁剧疆杈规鏍峰紡 */ + border-radius: 4px; /* 鍙�夛細璁剧疆鍦嗚 */ + padding: 10px; /* 鍐呰竟璺� */ + margin-right: 20px; +} +.btn_del{ + background:center no-repeat url('../../assets/images/鍒犻櫎2.png') ; +} + .el-row { + margin-bottom: 20px; + &:last-child { + margin-bottom: 0; + } + } + .el-col { + border-radius: 4px; + } + .text { + font-size: 14px; + } + + .item { + padding: 18px 0; + } + + .box-card { + width:100%; + } + .aft{ + cursor: pointer; + color: red; + font-weight: bold; + } </style> -- Gitblit v1.9.1