diff options
author | Gregory Chalenko <gregory.chalenko@zabbix.com> | 2021-05-08 16:34:47 +0300 |
---|---|---|
committer | Gregory Chalenko <gregory.chalenko@zabbix.com> | 2021-05-08 16:34:47 +0300 |
commit | 5186559246e7aa1b0a672b9fc26df1a8b0b349b5 (patch) | |
tree | 3ad2ef200da477e85c89e211ce8f6c2d6aa2f3b4 /ui | |
parent | 86a5ff05be8c74511edc5cbf3971cc63d7766917 (diff) |
..F....... [ZBXNEXT-114,ZBXNEXT-6572] allow mapping value to be empty
Diffstat (limited to 'ui')
-rw-r--r-- | ui/include/classes/import/validators/C54XmlValidator.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ui/include/classes/import/validators/C54XmlValidator.php b/ui/include/classes/import/validators/C54XmlValidator.php index daf0fc1b714..e5efea7ca86 100644 --- a/ui/include/classes/import/validators/C54XmlValidator.php +++ b/ui/include/classes/import/validators/C54XmlValidator.php @@ -1102,8 +1102,8 @@ class C54XmlValidator extends CXmlValidatorGeneral { 'name' => ['type' => XML_STRING | XML_REQUIRED], 'mappings' => ['type' => XML_INDEXED_ARRAY | XML_REQUIRED, 'prefix' => 'mapping', 'rules' => [ 'mapping' => ['type' => XML_ARRAY, 'rules' => [ - 'type' => ['type' => XML_STRING, 'in' => $this->VALUEMAP_MAPPING_TYPE, 'default' => CXmlConstantValue::MAPPING_EQUAL], - 'value' => ['type' => XML_STRING], + 'type' => ['type' => XML_STRING, 'default' => CXmlConstantValue::MAPPING_EQUAL, 'in' => $this->VALUEMAP_MAPPING_TYPE], + 'value' => ['type' => XML_STRING, 'default' => ''], 'newvalue' => ['type' => XML_STRING | XML_REQUIRED] ]] ]] @@ -1731,8 +1731,8 @@ class C54XmlValidator extends CXmlValidatorGeneral { 'name' => ['type' => XML_STRING | XML_REQUIRED], 'mappings' => ['type' => XML_INDEXED_ARRAY | XML_REQUIRED, 'prefix' => 'mapping', 'rules' => [ 'mapping' => ['type' => XML_ARRAY, 'rules' => [ - 'type' => ['type' => XML_STRING, 'in' => $this->VALUEMAP_MAPPING_TYPE, 'default' => CXmlConstantValue::MAPPING_EQUAL], - 'value' => ['type' => XML_STRING | XML_REQUIRED], + 'type' => ['type' => XML_STRING, 'default' => CXmlConstantValue::MAPPING_EQUAL, 'in' => $this->VALUEMAP_MAPPING_TYPE], + 'value' => ['type' => XML_STRING, 'default' => ''], 'newvalue' => ['type' => XML_STRING | XML_REQUIRED] ]] ]] |