fix(Area): Columns placeholder return value keep undefined (#2197)

This commit is contained in:
Jake 2019-10-24 14:26:12 +08:00 committed by neverland
parent 8021bb4ee7
commit dd44c3be0a

View File

@ -92,7 +92,10 @@ VantComponent({
// parse output columns data
parseOutputValues(values) {
const { columnsPlaceholder } = this.data;
return values.map((value = {}, index) => {
return values.map((value, index) => {
// save undefined value
if (!value) return value;
value = JSON.parse(JSON.stringify(value));
if (!value.code || value.name === columnsPlaceholder[index]) {
value.code = '';