【fix】 修复医院搜索时,卡顿问题;不全量加载出所有医院数据

This commit is contained in:
tian.guangyuan
2020-04-30 15:42:13 +08:00
parent 88b19596ae
commit b5d80d0f76

View File

@@ -194,6 +194,9 @@ export default {
}, },
computed: { computed: {
columnsHosCols: function () { columnsHosCols: function () {
if( this.searchHos == ''){
return []
}
return this.columnsHos.filter(item => { return this.columnsHos.filter(item => {
return item.text.search(this.searchHos) != -1 return item.text.search(this.searchHos) != -1
}) })
@@ -298,6 +301,7 @@ export default {
this.userInfo.businessNo = localStorage.businessNo this.userInfo.businessNo = localStorage.businessNo
console.log(this.userInfo.businessNo) console.log(this.userInfo.businessNo)
this.init() this.init()
this.columnsHos = Hospital.hospitalList
}, },
beforeRouteLeave(to, from, next) { beforeRouteLeave(to, from, next) {
if(to.fullPath == '/claims/insuredInfo'){ if(to.fullPath == '/claims/insuredInfo'){
@@ -355,9 +359,7 @@ export default {
// ;[this.popupShow, this.pickerType] = [true, pickerType] // ;[this.popupShow, this.pickerType] = [true, pickerType]
if (valueKey) this.valueKey = valueKey if (valueKey) this.valueKey = valueKey
if (pickerType == '1') { if (pickerType == '1') {
//绑定治疗医院数据字典
this.popupShowHos = true this.popupShowHos = true
this.columnsHos = Hospital.hospitalList
} else if (pickerType == '2') { } else if (pickerType == '2') {
this.popupShow = true this.popupShow = true
//绑定是否购买过其他公司保险的数据字典 //绑定是否购买过其他公司保险的数据字典