element-ul数据字典格式化

<el-table-column prop="countryName" label="所属村镇" width="250" :formatter="formatterContryName"></el-table-column>
methods: {
    
    
		formatterContryName () {
    
    
			const countryMap = new Map([
				['1', '茂芝场村'],
				['2', '前富村'],
				['3','后富村']
			])
			const key = arguments[0].countryName
			return countryMap.get(key)
		},
		

猜你喜欢

转载自blog.csdn.net/m0_60429030/article/details/128535114
今日推荐