3c42c895 by 任超

feat:抵押信息

1 parent bbf83756
1 <template> 1 <template>
2 <div> 2 <div>
3 <lb-table :column="column" border :maxHeight="300" heightNumSetting :pagination="false" :key="key" :data="tableDataList"> 3 <lb-table :column="column" :maxHeight="300" heightNumSetting :pagination="false" :key="key" :data="tableDataList">
4 </lb-table> 4 </lb-table>
5 <addQlr v-model="dialog" :details="details" @updateDetail="updateDetail" /> 5 <addQlr v-model="dialog" :details="details" @updateDetail="handleupdateDetail" />
6 </div> 6 </div>
7 </template> 7 </template>
8 <script> 8 <script>
...@@ -67,7 +67,14 @@ export default { ...@@ -67,7 +67,14 @@ export default {
67 }, 67 },
68 { 68 {
69 prop: "zjzl", 69 prop: "zjzl",
70 label: "证件种类" 70 label: "证件种类",
71 render: (h, scope) => {
72 return this.dictData['A30'].map(option => {
73 if (option.dcode == scope.row.zjzl) {
74 return <span>{option.dname}</span>
75 }
76 })
77 }
71 }, 78 },
72 { 79 {
73 prop: "zjh", 80 prop: "zjh",
...@@ -96,25 +103,27 @@ export default { ...@@ -96,25 +103,27 @@ export default {
96 } 103 }
97 } 104 }
98 ], 105 ],
99 column: this.InformationTable 106 column: []
100 } 107 }
101 }, 108 },
102 watch: { 109 watch: {
103 tableData: { 110 tableData: {
104 handler: function (val, oldVal) { 111 handler: function (val, oldVal) {
105 let that = this 112 let that = this
106 if (val.length == 0 || !val) { 113 this.$nextTick(() => {
107 that.tableDataList = _.cloneDeep([{ 114 if (val.length == 0 || !val) {
108 sqrmc: '', 115 that.tableDataList = _.cloneDeep([{
109 dlrzjlx: '', 116 sqrmc: '',
110 dlrzjh: '', 117 dlrzjlx: '',
111 fr: '' 118 dlrzjh: '',
112 }]) 119 fr: ''
113 } else { 120 }])
114 that.tableDataList = _.cloneDeep(val) 121 } else {
115 } 122 that.tableDataList = _.cloneDeep(val)
123 }
124 this.column = this.InformationTable
125 })
116 }, 126 },
117 immediate: true,
118 deep: true 127 deep: true
119 }, 128 },
120 gyfs: { 129 gyfs: {
...@@ -122,7 +131,7 @@ export default { ...@@ -122,7 +131,7 @@ export default {
122 let dataList = _.cloneDeep(this.InformationTable) 131 let dataList = _.cloneDeep(this.InformationTable)
123 if (newVal == '0') { 132 if (newVal == '0') {
124 this.column = _.cloneDeep(dataList).slice(1, dataList.length) 133 this.column = _.cloneDeep(dataList).slice(1, dataList.length)
125 } else if ((newVal == '1'||newVal == '3')) { 134 } else if ((newVal == '1' || newVal == '3')) {
126 this.column = dataList 135 this.column = dataList
127 } else { 136 } else {
128 this.column = _.cloneDeep(dataList) 137 this.column = _.cloneDeep(dataList)
...@@ -137,13 +146,14 @@ export default { ...@@ -137,13 +146,14 @@ export default {
137 } 146 }
138 }, 147 },
139 methods: { 148 methods: {
140 updateDetail (value) { 149 handleupdateDetail (value) {
141 this.tableDataList[this.dataIndex] = value; 150 if (!_.isEqual(value, this.tableData)) {
142 console.log(this.tableDataList); 151 this.tableDataList[this.dataIndex] = _.cloneDeep(value);
143 this.key++ 152 // this.key++
144 this.$emit('upDateQlrxxList', this.tableDataList) 153 this.$emit('upDateQlrxxList', this.tableDataList)
154 }
145 }, 155 },
146 156
147 // 新增 157 // 新增
148 addClick () { 158 addClick () {
149 this.dialog = true 159 this.dialog = true
......
...@@ -196,18 +196,6 @@ export default { ...@@ -196,18 +196,6 @@ export default {
196 this.$refs["ruleForm"].resetFields(); 196 this.$refs["ruleForm"].resetFields();
197 }, 197 },
198 submitForm () { 198 submitForm () {
199 // this.$refs['ruleForm'].validate((valid) => {
200 // if (valid) {
201 // this.$message({
202 // message: '修改成功!',
203 // type: 'success'
204 // })
205
206 // } else {
207 // this.$message.error('请完善必填项');
208 // }
209 // })
210
211 this.$refs.ruleForm.validate((valid) => { 199 this.$refs.ruleForm.validate((valid) => {
212 if (valid) { 200 if (valid) {
213 this.$emit("input", false); 201 this.$emit("input", false);
......
...@@ -20,6 +20,7 @@ export default { ...@@ -20,6 +20,7 @@ export default {
20 }, 20 },
21 //切换选项卡内容组件 21 //切换选项卡内容组件
22 getFromRouter (tabname) { 22 getFromRouter (tabname) {
23 console.log(tabname);
23 this.componentTag = getForm(tabname, this.$route.query.sqywbm); 24 this.componentTag = getForm(tabname, this.$route.query.sqywbm);
24 } 25 }
25 } 26 }
......
...@@ -207,8 +207,8 @@ ...@@ -207,8 +207,8 @@
207 抵押人信息 207 抵押人信息
208 <div class="triangle"></div> 208 <div class="triangle"></div>
209 </div> 209 </div>
210 <InformationTable :tableData="ruleForm.ywrList" @upDateQlrxxList="upDateYwrxxList" 210 <!-- <InformationTable :tableData="ruleForm.ywrList" @upDateQlrxxList="upDateYwrxxList"
211 :viewtype="$route.query.viewtype" /> 211 :viewtype="$route.query.viewtype" /> -->
212 212
213 <div class="slxx_title title-block"> 213 <div class="slxx_title title-block">
214 登记原因 214 登记原因
...@@ -249,7 +249,7 @@ export default { ...@@ -249,7 +249,7 @@ export default {
249 this.ruleForm = res.result; 249 this.ruleForm = res.result;
250 this.ruleForm.diyaq.sfczjzhxz = "0"; 250 this.ruleForm.diyaq.sfczjzhxz = "0";
251 } 251 }
252 }); 252 })
253 }, 253 },
254 components: { InformationTable }, 254 components: { InformationTable },
255 computed: { 255 computed: {
...@@ -291,13 +291,17 @@ export default { ...@@ -291,13 +291,17 @@ export default {
291 291
292 // 更新权利人信息 292 // 更新权利人信息
293 upDateQlrxxList (val) { 293 upDateQlrxxList (val) {
294 this.ruleForm.qlrList = _.cloneDeep(val); 294 if (!_.isEqual(val, this.ruleForm.qlrList)) {
295 this.ruleForm.qlrList = _.cloneDeep(val);
296 }
295 }, 297 },
296 // 更新义务人信息 298 // 更新义务人信息
297 upDateYwrxxList (val) { 299 upDateYwrxxList (val) {
298 this.ruleForm.ywrList = _.cloneDeep(val); 300 if (!_.isEqual(val, this.ruleForm.ywrList)) {
299 }, 301 this.ruleForm.ywrList = _.cloneDeep(val);
300 }, 302 }
303 }
304 }
301 }; 305 };
302 </script> 306 </script>
303 <style scoped lang='scss'> 307 <style scoped lang='scss'>
......