作者 朱振飞

保单修改

@@ -53,8 +53,8 @@ Page({ @@ -53,8 +53,8 @@ Page({
53 guarantee: [], 53 guarantee: [],
54 InfoId: 0, 54 InfoId: 0,
55 def_id: '', 55 def_id: '',
56 - edit_state: false,  
57 - edit_state2: false, 56 + // edit_state: false,
  57 + // edit_state2: false,
58 // risk_listitm: '', 58 // risk_listitm: '',
59 storge_state: false, 59 storge_state: false,
60 warranty_info: '请输入', 60 warranty_info: '请输入',
@@ -203,15 +203,19 @@ Page({ @@ -203,15 +203,19 @@ Page({
203 let that = this; 203 let that = this;
204 let type = e.currentTarget.dataset.type; 204 let type = e.currentTarget.dataset.type;
205 let index = e.currentTarget.dataset.xulie; 205 let index = e.currentTarget.dataset.xulie;
206 - let tempProjectlist = Object.assign(this.data.projectlist, {}); 206 + // 复制保障项目模板
  207 + // let tempProjectlist = Object.assign({}, this.data.projectlist);
  208 + let tempProjectlist = JSON.parse(JSON.stringify(this.data.projectlist));
  209 + console.log(tempProjectlist)
207 var sub_index = that.data.sub_index 210 var sub_index = that.data.sub_index
208 var edit_state3 = that.data.edit_state3 211 var edit_state3 = that.data.edit_state3
209 212
210 // 已经添加的附加险 213 // 已经添加的附加险
211 - let risk_list = Object.assign(this.data.risk_list, {}); 214 + let risk_list = Object.assign({},this.data.risk_list);
212 let tempRist = risk_list[index].mo; 215 let tempRist = risk_list[index].mo;
213 this.setData({ 216 this.setData({
214 - type: type 217 + type: type,
  218 + xielie: index
215 }) 219 })
216 220
217 if (type == 'fujiaxian') { 221 if (type == 'fujiaxian') {
@@ -220,114 +224,117 @@ Page({ @@ -220,114 +224,117 @@ Page({
220 }) 224 })
221 } 225 }
222 // 已经添加的主险 226 // 已经添加的主险
223 - let tempMain_list = Object.assign(this.data.main_array, {})  
224 - // this.data.inforid != 0 && this.data.inforid != undefined 227 + let tempMain_list = Object.assign({},this.data.main_array)
  228 + this.data.inforid != 0 && this.data.inforid != undefined
225 //编辑/缓存状态 229 //编辑/缓存状态
226 - if (that.data.temp_state) {  
227 - console.log('edit')  
228 - //edit_state3:代表是刚获取到信息是的结构,还是重新选择之后的数据结构  
229 - if (edit_state3) {  
230 - //获取到的信息结构  
231 - if (type == 'zhuxian') {  
232 - console.log('zx')  
233 - this.setData({  
234 - focus: false  
235 - })  
236 - if (tempMain_list.length > 0) {  
237 - for (let i in tempProjectlist) {  
238 - for (let j in tempMain_list) {  
239 - if (tempProjectlist[i].id == tempMain_list[j].id) {  
240 - tempProjectlist[i].choose_status = true  
241 - tempProjectlist[i].num = tempMain_list[j].num  
242 - for (let g in tempProjectlist[i].title) {  
243 - if (tempProjectlist[i].title[g].t_id == tempMain_list[j].t_id) {  
244 - tempProjectlist[i].title[g].label_state = true  
245 - if (tempProjectlist[i].title[g].name == tempMain_list[j].title) {  
246 - tempProjectlist[i].title[g].current = parseInt(g)  
247 - sub_index = parseInt(g)  
248 - }  
249 - }  
250 - }  
251 - }  
252 - }  
253 - }  
254 - }  
255 - } else {  
256 - console.log('fjx')  
257 - if (tempRist.length) {  
258 - for (let i in tempProjectlist) {  
259 - for (let j in tempRist) {  
260 - if (tempProjectlist[i].id == tempRist[j].id) {  
261 - tempProjectlist[i].choose_status = true  
262 - tempProjectlist[i].num = tempRist[j].num  
263 - for (let g in tempProjectlist[i].title) {  
264 - if (tempProjectlist[i].title[g].t_id == tempRist[j].t_id) {  
265 - tempProjectlist[i].title[g].label_state = true  
266 - if (tempProjectlist[i].title[g].name == tempRist[j].title) {  
267 - tempProjectlist[i].title[g].current = parseInt(g)  
268 - sub_index = parseInt(g)  
269 - }  
270 - }  
271 - }  
272 - }  
273 - }  
274 - }  
275 - }  
276 - }  
277 - } else {  
278 - if (type == 'zhuxian') {  
279 - if (tempMain_list.length > 0) {  
280 - for (let i in tempProjectlist) {  
281 - for (let j in tempMain_list) {  
282 - if (tempProjectlist[i].id == tempMain_list[j].id) {  
283 - tempProjectlist[i].choose_status = true  
284 - tempProjectlist[i].num = tempMain_list[j].num  
285 - for (let g in tempProjectlist[i].title) {  
286 - for (let k in tempMain_list[j].title) {  
287 - if (tempMain_list[j].title[k].label_state) {  
288 - if (tempProjectlist[i].title[g].t_id == tempMain_list[j].title[k].t_id) {  
289 - tempProjectlist[i].title[g].label_state = true  
290 - tempProjectlist[i].title[g].current = tempMain_list[j].title[k].current  
291 - sub_index = tempMain_list[j].title[k].current  
292 - }  
293 - }  
294 - }  
295 - }  
296 - }  
297 - }  
298 - }  
299 - }  
300 - } else {  
301 - if (tempRist.length) {  
302 - for (let i in tempProjectlist) {  
303 - for (let j in tempRist) {  
304 - if (tempProjectlist[i].id == tempRist[j].id) {  
305 - tempProjectlist[i].choose_status = true  
306 - tempProjectlist[i].num = tempRist[j].num  
307 - for (let g in tempProjectlist[i].title) {  
308 - for (let k in tempRist[j].title) {  
309 - if (tempRist[j].title[k].label_state) {  
310 - if (tempProjectlist[i].title[g].t_id == tempRist[j].title[k].t_id) {  
311 - tempProjectlist[i].title[g].label_state = true  
312 - tempProjectlist[i].title[g].current = tempRist[j].title[k].current  
313 - sub_index = tempRist[j].title[k].current  
314 - }  
315 - }  
316 - }  
317 - }  
318 - }  
319 - }  
320 - }  
321 - }  
322 - }  
323 - }  
324 - } else {  
325 - console.log('add') 230 + // if (that.data.temp_state) {
  231 + // console.log('edit')
  232 + // //edit_state3:代表是刚获取到信息是的结构,还是重新选择之后的数据结构
  233 + // if (edit_state3) {
  234 + // //获取到的信息结构
  235 + // if (type == 'zhuxian') {
  236 + // this.setData({
  237 + // focus: false
  238 + // })
  239 + // if (tempMain_list.length > 0) {
  240 + // for (let i in tempProjectlist) {
  241 + // for (let j in tempMain_list) {
  242 + // if (tempProjectlist[i].id == tempMain_list[j].id) {
  243 + // tempProjectlist[i].choose_status = true
  244 + // tempProjectlist[i].num = tempMain_list[j].num
  245 + // for (let g in tempProjectlist[i].title) {
  246 + // if (tempProjectlist[i].title[g].t_id == tempMain_list[j].t_id) {
  247 + // tempProjectlist[i].title[g].label_state = true
  248 + // if (tempProjectlist[i].title[g].name == tempMain_list[j].title) {
  249 + // tempProjectlist[i].title[g].current = parseInt(g)
  250 + // sub_index = parseInt(g)
  251 + // }
  252 + // }
  253 + // }
  254 + // }
  255 + // }
  256 + // }
  257 + // }
  258 + // } else {
  259 + // console.log('fjx')
  260 + // if (tempRist.length) {
  261 + // for (let i in tempProjectlist) {
  262 + // for (let j in tempRist) {
  263 + // if (tempProjectlist[i].id == tempRist[j].id) {
  264 + // console.log(tempRist[j])
  265 + // console.log(tempProjectlist[i])
  266 + // tempProjectlist[i].choose_status = true
  267 + // tempProjectlist[i].num = tempRist[j].num
  268 + // for (let g in tempProjectlist[i].title) {
  269 + // if (tempProjectlist[i].title[g].t_id == tempRist[j].t_id) {
  270 + // tempProjectlist[i].title[g].label_state = true
  271 + // if (tempProjectlist[i].title[g].name == tempRist[j].title) {
  272 + // tempProjectlist[i].title[g].current = parseInt(g)
  273 + // sub_index = parseInt(g)
  274 + // }
  275 + // }
  276 + // }
  277 + // }
  278 + // }
  279 + // }
  280 + // }
  281 + // }
  282 + // } else {
  283 + // if (type == 'zhuxian') {
  284 + // if (tempMain_list.length > 0) {
  285 + // for (let i in tempProjectlist) {
  286 + // for (let j in tempMain_list) {
  287 + // if (tempProjectlist[i].id == tempMain_list[j].id) {
  288 + // tempProjectlist[i].choose_status = true
  289 + // tempProjectlist[i].num = tempMain_list[j].num
  290 + // for (let g in tempProjectlist[i].title) {
  291 + // for (let k in tempMain_list[j].title) {
  292 + // if (tempMain_list[j].title[k].label_state) {
  293 + // if (tempProjectlist[i].title[g].t_id == tempMain_list[j].title[k].t_id) {
  294 + // tempProjectlist[i].title[g].label_state = true
  295 + // tempProjectlist[i].title[g].current = tempMain_list[j].title[k].current
  296 + // sub_index = tempMain_list[j].title[k].current
  297 + // }
  298 + // }
  299 + // }
  300 + // }
  301 + // }
  302 + // }
  303 + // }
  304 + // }
  305 + // } else {
  306 + // if (tempRist.length) {
  307 + // for (let i in tempProjectlist) {
  308 + // for (let j in tempRist) {
  309 + // if (tempProjectlist[i].id == tempRist[j].id) {
  310 + // tempProjectlist[i].choose_status = true
  311 + // tempProjectlist[i].num = tempRist[j].num
  312 + // for (let g in tempProjectlist[i].title) {
  313 + // for (let k in tempRist[j].title) {
  314 + // if (tempRist[j].title[k].label_state) {
  315 + // if (tempProjectlist[i].title[g].t_id == tempRist[j].title[k].t_id) {
  316 + // tempProjectlist[i].title[g].label_state = true
  317 + // tempProjectlist[i].title[g].current = tempRist[j].title[k].current
  318 + // sub_index = tempRist[j].title[k].current
  319 + // }
  320 + // }
  321 + // }
  322 + // }
  323 + // }
  324 + // }
  325 + // }
  326 + // }
  327 + // }
  328 + // }
  329 + // } else {
  330 + // console.log('add')
326 if (type == 'zhuxian') { 331 if (type == 'zhuxian') {
327 if (tempMain_list.length > 0) { 332 if (tempMain_list.length > 0) {
328 for (let i in tempProjectlist) { 333 for (let i in tempProjectlist) {
329 for (let j in tempMain_list) { 334 for (let j in tempMain_list) {
330 if (tempProjectlist[i].id == tempMain_list[j].id) { 335 if (tempProjectlist[i].id == tempMain_list[j].id) {
  336 + console.log(tempProjectlist[i])
  337 + console.log(tempMain_list[j].id)
331 tempProjectlist[i].choose_status = true 338 tempProjectlist[i].choose_status = true
332 tempProjectlist[i].num = tempMain_list[j].num 339 tempProjectlist[i].num = tempMain_list[j].num
333 for (let g in tempProjectlist[i].title) { 340 for (let g in tempProjectlist[i].title) {
@@ -352,31 +359,34 @@ Page({ @@ -352,31 +359,34 @@ Page({
352 if (tempProjectlist[i].id == tempRist[j].id) { 359 if (tempProjectlist[i].id == tempRist[j].id) {
353 tempProjectlist[i].choose_status = true 360 tempProjectlist[i].choose_status = true
354 tempProjectlist[i].num = tempRist[j].num 361 tempProjectlist[i].num = tempRist[j].num
  362 + console.log(tempProjectlist[i])
  363 + console.log(tempRist[j])
355 for (let g in tempProjectlist[i].title) { 364 for (let g in tempProjectlist[i].title) {
356 - for (let k in tempRist[j].title) {  
357 - if (tempRist[j].title[k].label_state) {  
358 - if (tempProjectlist[i].title[g].t_id == tempRist[j].title[k].t_id) { 365 + // for (let k in tempRist[j].title) {
  366 + // if (tempRist[j].title[k].label_state) {
  367 + if (tempProjectlist[i].title[g].t_id == tempRist[j].t_id) {
359 tempProjectlist[i].title[g].label_state = true 368 tempProjectlist[i].title[g].label_state = true
360 - tempProjectlist[i].title[g].current = tempRist[j].title[k].current  
361 - sub_index = tempRist[j].title[k].current 369 + // tempProjectlist[i].title[g].current = tempRist[j].title[k].current
  370 + // sub_index = tempRist[j].title[k].current
362 } 371 }
363 - }  
364 - } 372 + // }
  373 + // }
365 } 374 }
366 } 375 }
367 } 376 }
368 } 377 }
369 } 378 }
370 } 379 }
371 - } 380 + // }
372 wx.setNavigationBarTitle({ 381 wx.setNavigationBarTitle({
373 title: '选择保障项目', 382 title: '选择保障项目',
374 }) 383 })
  384 + console.log(tempProjectlist)
375 this.setData({ 385 this.setData({
376 popup_state: true, 386 popup_state: true,
377 addType: type, 387 addType: type,
378 xulie: index, 388 xulie: index,
379 - projectlist: tempProjectlist, 389 + showProjectlist: tempProjectlist,
380 sub_index: sub_index 390 sub_index: sub_index
381 }) 391 })
382 }, 392 },
@@ -398,7 +408,8 @@ Page({ @@ -398,7 +408,8 @@ Page({
398 // projectlist[i].title[0].label_state = true 408 // projectlist[i].title[0].label_state = true
399 } 409 }
400 this.setData({ 410 this.setData({
401 - projectlist: res.data.data.def 411 + projectlist: res.data.data.def,
  412 + showProjectlist: res.data.data.def
402 }) 413 })
403 } 414 }
404 }) 415 })
@@ -409,7 +420,7 @@ Page({ @@ -409,7 +420,7 @@ Page({
409 var main_risk = this.data.main_risk 420 var main_risk = this.data.main_risk
410 var index = e.currentTarget.dataset.index; 421 var index = e.currentTarget.dataset.index;
411 var sindex = e.currentTarget.dataset.sindex; 422 var sindex = e.currentTarget.dataset.sindex;
412 - var projectlist = this.data.projectlist; 423 + var projectlist = JSON.parse(JSON.stringify(this.data.showProjectlist));
413 var title = projectlist[index].title 424 var title = projectlist[index].title
414 for (var i = 0; i < title.length; i++) { 425 for (var i = 0; i < title.length; i++) {
415 title[i].current = '' 426 title[i].current = ''
@@ -422,7 +433,7 @@ Page({ @@ -422,7 +433,7 @@ Page({
422 projectlist[index].title[sindex].label_state = true 433 projectlist[index].title[sindex].label_state = true
423 } 434 }
424 this.setData({ 435 this.setData({
425 - projectlist: projectlist, 436 + showProjectlist: projectlist,
426 sub_index: sindex 437 sub_index: sindex
427 }) 438 })
428 }, 439 },
@@ -430,23 +441,23 @@ Page({ @@ -430,23 +441,23 @@ Page({
430 //保障项目金额 441 //保障项目金额
431 popupNum(e) { 442 popupNum(e) {
432 var index = e.currentTarget.dataset.index; 443 var index = e.currentTarget.dataset.index;
433 - var projectlist = this.data.projectlist; 444 + var projectlist = JSON.parse(JSON.stringify(this.data.showProjectlist))
434 if (projectlist[index].choose_status) { 445 if (projectlist[index].choose_status) {
435 projectlist[index].num = e.detail.value 446 projectlist[index].num = e.detail.value
436 } 447 }
437 this.setData({ 448 this.setData({
438 - projectlist: projectlist 449 + showProjectlist: projectlist
439 }) 450 })
440 }, 451 },
441 452
442 //选择保障项目 453 //选择保障项目
443 popupState(e) { 454 popupState(e) {
444 var index = e.currentTarget.dataset.index; 455 var index = e.currentTarget.dataset.index;
445 - var projectlist = this.data.projectlist; 456 + var projectlist = JSON.parse(JSON.stringify(this.data.showProjectlist))
446 projectlist[index].choose_status = !projectlist[index].choose_status; 457 projectlist[index].choose_status = !projectlist[index].choose_status;
447 458
448 this.setData({ 459 this.setData({
449 - projectlist: projectlist, 460 + showProjectlist: projectlist,
450 }) 461 })
451 if (this.data.inforid != 0) { 462 if (this.data.inforid != 0) {
452 edit_state: false; 463 edit_state: false;
@@ -456,15 +467,15 @@ Page({ @@ -456,15 +467,15 @@ Page({
456 467
457 //确认选择的推荐方案 468 //确认选择的推荐方案
458 confirmCase() { 469 confirmCase() {
459 - if (this.data.type == 'fujiaxian') {  
460 - this.setData({  
461 - edit_state2: false  
462 - })  
463 - } else {  
464 - this.setData({  
465 - edit_state: false  
466 - })  
467 - } 470 + // if (this.data.type == 'fujiaxian') {
  471 + // this.setData({
  472 + // edit_state2: false
  473 + // })
  474 + // } else {
  475 + // this.setData({
  476 + // edit_state: false
  477 + // })
  478 + // }
468 479
469 480
470 let index = this.data.xulie; 481 let index = this.data.xulie;
@@ -472,7 +483,7 @@ Page({ @@ -472,7 +483,7 @@ Page({
472 var that = this 483 var that = this
473 var main_array = [] 484 var main_array = []
474 485
475 - var projectlist = Object.assign(this.data.projectlist, {}) 486 + var projectlist = Object.assign({}, this.data.projectlist)
476 for (var i = 0; i < projectlist.length; i++) { 487 for (var i = 0; i < projectlist.length; i++) {
477 if (projectlist[i].choose_status) { 488 if (projectlist[i].choose_status) {
478 main_array.push(projectlist[i]) 489 main_array.push(projectlist[i])
@@ -591,15 +602,15 @@ Page({ @@ -591,15 +602,15 @@ Page({
591 //选择受益人姓名 602 //选择受益人姓名
592 beneficiarySelect(e) { 603 beneficiarySelect(e) {
593 if (this.data.inforid != 0) { 604 if (this.data.inforid != 0) {
594 - this.setData({  
595 - edit_state: true,  
596 - edit_state2: true  
597 - }) 605 + // this.setData({
  606 + // edit_state: true,
  607 + // edit_state2: true
  608 + // })
598 } 609 }
599 var index = e.currentTarget.dataset.mindex 610 var index = e.currentTarget.dataset.mindex
600 - var beneficiary_list = Object.assign(this.data.beneficiary_list, {}); 611 + var beneficiary_list = Object.assign({}, this.data.projectlist)
601 // 获取当前已选择的收益人 612 // 获取当前已选择的收益人
602 - let tempBenefice = Object.assign(this.data.beneficiaryList, {}) 613 + let tempBenefice = Object.assign({}, this.data.projectlist)
603 // 当前选择的收益人 614 // 当前选择的收益人
604 // let nowPerson = beneficiary_list[index].name_array[e.detail.value]; 615 // let nowPerson = beneficiary_list[index].name_array[e.detail.value];
605 // let nowPerson = beneficiary_list[index].beneficiary_name 616 // let nowPerson = beneficiary_list[index].beneficiary_name
@@ -750,8 +761,8 @@ Page({ @@ -750,8 +761,8 @@ Page({
750 //删除收益人 761 //删除收益人
751 deletebenefict(e) { 762 deletebenefict(e) {
752 let index = e.currentTarget.dataset.index; 763 let index = e.currentTarget.dataset.index;
753 - let tempbenefict = Object.assign(this.data.beneficiary_list, {});  
754 - let beneficiaryList = Object.assign(this.data.beneficiaryList, {}); 764 + let tempbenefict = Object.assign({},this.data.beneficiary_list);
  765 + let beneficiaryList = Object.assign({},this.data.beneficiaryList);
755 // 获取当前选项的受益人 766 // 获取当前选项的受益人
756 // let person = tempbenefict[index].beneficiary_name; 767 // let person = tempbenefict[index].beneficiary_name;
757 let person = tempbenefict[index].name; 768 let person = tempbenefict[index].name;
@@ -767,12 +778,12 @@ Page({ @@ -767,12 +778,12 @@ Page({
767 //添加附加险 778 //添加附加险
768 addRisk() { 779 addRisk() {
769 if (this.data.inforid != 0) { 780 if (this.data.inforid != 0) {
770 - this.setData({  
771 - edit_state: false,  
772 - edit_state2: false  
773 - }) 781 + // this.setData({
  782 + // edit_state: false,
  783 + // edit_state2: false
  784 + // })
774 } 785 }
775 - var risk_list = Object.assign(this.data.risk_list, {}); 786 + var risk_list = Object.assign({},this.data.risk_list);
776 var len = risk_list.length 787 var len = risk_list.length
777 risk_list[len] = { 788 risk_list[len] = {
778 name: '', 789 name: '',
@@ -789,7 +800,7 @@ Page({ @@ -789,7 +800,7 @@ Page({
789 //删除附加险 800 //删除附加险
790 deleteRisk(e) { 801 deleteRisk(e) {
791 let index = e.currentTarget.dataset.index; 802 let index = e.currentTarget.dataset.index;
792 - let risk_list = Object.assign(this.data.risk_list, {}); 803 + let risk_list = Object.assign({},this.data.risk_list);
793 risk_list.splice(index, 1); 804 risk_list.splice(index, 1);
794 this.setData({ 805 this.setData({
795 risk_list: risk_list 806 risk_list: risk_list
@@ -902,10 +913,10 @@ Page({ @@ -902,10 +913,10 @@ Page({
902 //保障期 913 //保障期
903 warrantyTwo(e) { 914 warrantyTwo(e) {
904 if (this.data.inforid != 0) { 915 if (this.data.inforid != 0) {
905 - this.setData({  
906 - edit_state: false,  
907 - edit_state2: false  
908 - }) 916 + // this.setData({
  917 + // edit_state: false,
  918 + // edit_state2: false
  919 + // })
909 } 920 }
910 var guarantee_name = e.detail.value 921 var guarantee_name = e.detail.value
911 var warranty_two = this.data.warranty_two 922 var warranty_two = this.data.warranty_two
@@ -1000,10 +1011,10 @@ Page({ @@ -1000,10 +1011,10 @@ Page({
1000 //缴费时长 1011 //缴费时长
1001 burningTime(e) { 1012 burningTime(e) {
1002 if (this.data.inforid != 0) { 1013 if (this.data.inforid != 0) {
1003 - this.setData({  
1004 - edit_state: false,  
1005 - edit_state2: false,  
1006 - }) 1014 + // this.setData({
  1015 + // edit_state: false,
  1016 + // edit_state2: false,
  1017 + // })
1007 } 1018 }
1008 var time_name = e.detail.value 1019 var time_name = e.detail.value
1009 var long_money = this.data.long_money 1020 var long_money = this.data.long_money
@@ -1107,7 +1118,7 @@ Page({ @@ -1107,7 +1118,7 @@ Page({
1107 selectUnit4(e) { 1118 selectUnit4(e) {
1108 var unit = e.currentTarget.dataset.unit; 1119 var unit = e.currentTarget.dataset.unit;
1109 let index = e.currentTarget.dataset.index; 1120 let index = e.currentTarget.dataset.index;
1110 - let risk_list = Object.assign(this.data.risk_list, {}); 1121 + let risk_list = Object.assign({},this.data.risk_list);
1111 risk_list[index].title = unit 1122 risk_list[index].title = unit
1112 if (risk_list[index].title == '终身') { 1123 if (risk_list[index].title == '终身') {
1113 risk_list[index].num = '' 1124 risk_list[index].num = ''
@@ -1269,9 +1280,9 @@ Page({ @@ -1269,9 +1280,9 @@ Page({
1269 bank_num: res.data.data.def.bank_num, 1280 bank_num: res.data.data.def.bank_num,
1270 risk_list: res.data.data.def.more, 1281 risk_list: res.data.data.def.more,
1271 beneficiary_list: beneficiary_list, 1282 beneficiary_list: beneficiary_list,
1272 - edit_state: true,  
1273 - edit_state2: true,  
1274 - edit_state3: true, 1283 + // edit_state: true,
  1284 + // edit_state2: true,
  1285 + // edit_state3: true,
1275 temp_state: true 1286 temp_state: true
1276 }) 1287 })
1277 } 1288 }
@@ -1501,7 +1512,7 @@ Page({ @@ -1501,7 +1512,7 @@ Page({
1501 } 1512 }
1502 1513
1503 var risk_list = res.data.data.def.more 1514 var risk_list = res.data.data.def.more
1504 - var projectlist = this.data.projectlist 1515 + var projectlist = Object.assign({},this.data.projectlist)
1505 1516
1506 for (var i = 0; i < risk_list.length; i++) { 1517 for (var i = 0; i < risk_list.length; i++) {
1507 for (var j = 0; j < projectlist.length; j++) { 1518 for (var j = 0; j < projectlist.length; j++) {
@@ -1545,9 +1556,9 @@ Page({ @@ -1545,9 +1556,9 @@ Page({
1545 bank_num: res.data.data.def.bank_num, 1556 bank_num: res.data.data.def.bank_num,
1546 risk_list: risk_list, 1557 risk_list: risk_list,
1547 beneficiary_list: beneficiary_list, 1558 beneficiary_list: beneficiary_list,
1548 - edit_state: true,  
1549 - edit_state2: true,  
1550 - edit_state3: true, 1559 + // edit_state: true,
  1560 + // edit_state2: true,
  1561 + // edit_state3: true,
1551 temp_state: true, 1562 temp_state: true,
1552 guarantee_name: guarantee_name, 1563 guarantee_name: guarantee_name,
1553 time_name: time_name, 1564 time_name: time_name,
@@ -1564,8 +1575,8 @@ Page({ @@ -1564,8 +1575,8 @@ Page({
1564 let that = this; 1575 let that = this;
1565 options.inforid ? (that.getlistVerify(options.inforid), that.setData({ 1576 options.inforid ? (that.getlistVerify(options.inforid), that.setData({
1566 inforid: options.inforid, 1577 inforid: options.inforid,
1567 - edit_state: true,  
1568 - edit_state2: true, 1578 + // edit_state: true,
  1579 + // edit_state2: true,
1569 }), wx.setNavigationBarTitle({ 1580 }), wx.setNavigationBarTitle({
1570 title: '编辑保单', 1581 title: '编辑保单',
1571 })) : "" 1582 })) : ""
@@ -4,7 +4,7 @@ @@ -4,7 +4,7 @@
4 <view class='main_container'> 4 <view class='main_container'>
5 <view class='iconfont icon-guanbi2' bindtap='cancleMask'></view> 5 <view class='iconfont icon-guanbi2' bindtap='cancleMask'></view>
6 <view class='popup_item'> 6 <view class='popup_item'>
7 - <view class='popup_list' wx:for='{{projectlist}}' wx:key=''> 7 + <view class='popup_list' wx:for='{{showProjectlist}}' wx:key=''>
8 <view bindtap='popupState' data-index='{{index}}'> 8 <view bindtap='popupState' data-index='{{index}}'>
9 <view class="iconfont icon-fangkuang {{item.choose_status?'icon-xuanzhongkuang':''}}"></view> 9 <view class="iconfont icon-fangkuang {{item.choose_status?'icon-xuanzhongkuang':''}}"></view>
10 </view> 10 </view>
@@ -18,7 +18,7 @@ @@ -18,7 +18,7 @@
18 </view> 18 </view>
19 </view> 19 </view>
20 <view class='popup_label_box'> 20 <view class='popup_label_box'>
21 - <view class="popup_label_item {{sitem.current === sub_index ? 'popup_label_active' :''}}" wx:for='{{item.title}}' wx:for-index='sub_index' data-sindex='{{sub_index}}' wx:for-item='sitem' data-index='{{index}}' wx:key='' bindtap='getUnit'> 21 + <view class="popup_label_item {{sitem.label_state ? 'popup_label_active' :''}}" wx:for='{{item.title}}' wx:for-index='sub_index' data-sindex='{{sub_index}}' wx:for-item='sitem' data-index='{{index}}' wx:key='' bindtap='getUnit'>
22 {{sitem.name}}</view> 22 {{sitem.name}}</view>
23 </view> 23 </view>
24 </view> 24 </view>
@@ -297,7 +297,7 @@ @@ -297,7 +297,7 @@
297 </view> 297 </view>
298 298
299 <view class='popup_item' wx:if='{{show}}'> 299 <view class='popup_item' wx:if='{{show}}'>
300 - <view class='popup_list' wx:for='{{projectlist}}' wx:key='' wx:if='{{item.status}}'> 300 + <view class='popup_list' wx:for='{{showProjectlist}}' wx:key='' wx:if='{{item.status}}'>
301 <view class='popup_content popup_content2'> 301 <view class='popup_content popup_content2'>
302 <view class=''>{{item.name}}</view> 302 <view class=''>{{item.name}}</view>
303 <view class='popup_input'> 303 <view class='popup_input'>