93976ab0 by renchao@pashanhoo.com

style:登记簿详情

1 parent 4410a436
import { log } from "bpmn-js-token-simulation";
/*
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-08-15 11:02:38
*/
var qlxxPage = [
{ qllx: "A01", id: "tdsyq", form: "tdsyq.vue", label: "集体土地所有权" },
{ qllx: "A02", id: "tdsyq", form: "tdsyq.vue", label: "国家土地所有权" },
......@@ -41,7 +43,7 @@ var qlxxPage = [
];
//组装登记簿树形结构
export function loadTreeData(qlxxData) {
export function loadTreeData (qlxxData, index) {
let treedata = [];
//加载封面
treedata.push({ id: "djbfm", form: "djbfm.vue", label: "登记簿封面" });
......@@ -74,19 +76,19 @@ export function loadTreeData(qlxxData) {
* @param {*} bdcdylx
* @author: renchao
*/
export function getNode(qllx, qlxx, bdcdylx) {
export function getNode (qllx, qlxx, bdcdylx) {
let node;
for (var i = 0; i < qlxxPage.length; i++) {
if (qlxxPage[i].qllx == qllx) {
if (qllx == "A04" || qllx == "A06" || qllx == "A08") {
if (bdcdylx == "4") {
node = { id: "fdcq1", form: "fdcq1.vue", label: qlxxPage[i].label};
node = { id: "fdcq1", form: "fdcq1.vue", label: qlxxPage[i].label };
} else {
node = { id: "fdcq2", form: "fdcq2.vue", label: qlxxPage[i].label};
node = { id: "fdcq2", form: "fdcq2.vue", label: qlxxPage[i].label };
}
} else {
node = { id: qlxxPage[i].id, form: qlxxPage[i].form, label: qlxxPage[i].label};
node = { id: qlxxPage[i].id, form: qlxxPage[i].form, label: qlxxPage[i].label };
}
break;
}
......
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-07-19 09:51:37
* @LastEditTime: 2023-08-15 10:39:19
-->
<template>
<div class="bdcqldjml">
......@@ -18,7 +18,7 @@
</tr>
<tr v-for="(item, index) in bdcqlml" :key="index">
<td>{{ index + 1 }}</td>
<td>{{ item.bdcdyh }}</td>
<td><el-link type="primary" @click="handleSelectBdcdyh(item.bdcdyh)" :underline="false">{{ item.bdcdyh }} </el-link></td>
<td>{{ item.bdclx }}</td>
<td>{{ item.szbs }}</td>
<td>{{ item.bz }}</td>
......@@ -30,19 +30,25 @@
<script>
import { getBdcqldjmlByBdcdyid } from "@/api/djbDetail.js";
export default {
props: ["formData"],
data () {
return {
bdcqlml: [],
propsParam: this.$attrs,
};
propsParam: this.$attrs
}
},
mounted () {
getBdcqldjmlByBdcdyid({ bdcdyid: this.propsParam.bdcdyid }).then((res) => {
if (res.code === 200) {
this.bdcqlml = res.result;
}
});
})
},
methods: {
handleSelectBdcdyh (val) {
this.$emit('getBdcdyh', val);
}
}
};
</script>
......
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-08-10 16:28:55
* @LastEditTime: 2023-08-15 10:57:30
-->
<template>
<div class="content">
......@@ -11,7 +11,7 @@
</el-tree>
</div>
<div class="right">
<component :is="componentTag" v-bind="currentSelectProps" />
<component :is="componentTag" @getBdcdyh="getBdcdyh" v-bind="currentSelectProps" />
</div>
</div>
</template>
......@@ -42,17 +42,21 @@
},
props: ["formData"],
mounted () {
this.loadData();
this.loadData(this.formData.bdcdyh);
},
methods: {
getBdcdyh (val) {
console.log(val, ';222222222222');
// this.loadData(val);
},
/**
* @description: loadData
* @author: renchao
*/
loadData () {
loadData (val) {
getBdcqljqtsx({
bdcdyid: this.formData.bdcdyid,
bdcdyh: this.formData.bdcdyh,
bdcdyh: val,
}).then((res) => {
if (res.code === 200) {
this.treedata = loadTreeData(res.result, this.formData.bdcdyh);
......@@ -60,15 +64,15 @@
this.defaultNode = getNode(this.formData.qllx, { linShi: 0, xianShi: 0, liShi: 0 }, this.formData.bdcdylx || "");
this.$refs.tree.setCurrentKey(this.defaultNode.id); //data[0].id为默认选中的节点
this.loadComponent(this.defaultNode.form);
});
})
}
});
})
this.currentSelectProps = {
bdcdyid: this.formData.bdcdyid,
bdcdyh: this.formData.bdcdyh,
qllx: this.formData.qllx,
bsmQlxx: this.formData.bsmQlxx,
};
bsmQlxx: this.formData.bsmQlxx
}
},
/**
* @description: handleNodeClick
......@@ -86,12 +90,11 @@
* @author: renchao
*/
loadComponent (form) {
console.log(form, 'formformformform');
this.componentTag = (r) =>
require.ensure([], () => r(require("@/views/registerBook/" + form)));
},
require.ensure([], () => r(require("@/views/registerBook/" + form)))
}
}
};
}
</script>
<style scoped lang="scss">
/deep/.rollTable {
......@@ -114,7 +117,7 @@
.right {
width: calc(100% - 256px);
height: 704px;
// overflow-y: scroll;
// overflow-y: scroll;
// overflow: auto;
background-color: #f5f5f5;
border: 1px solid rgb(228, 228, 228);
......