mirror of
https://gitee.com/baidu/amis.git
synced 2024-12-04 12:58:38 +08:00
mapping 的 key trim 一下
This commit is contained in:
parent
67c6c6f876
commit
d5f2cbecc1
@ -33,6 +33,7 @@ export class MappingField extends React.Component<MappingProps, object> {
|
||||
<span className="text-muted">{placeholder}</span>
|
||||
);
|
||||
let key = value === true ? '1' : value;
|
||||
key = typeof key === 'string' ? key.trim() : key; // trim 一下,干掉一些空白字符。
|
||||
|
||||
if (typeof value !== 'undefined' && map && (map[key] || map['*'])) {
|
||||
viewValue = render('tpl', map[key] || map['*']);
|
||||
|
Loading…
Reference in New Issue
Block a user