mirror of
https://github.com/Nikolay-Shirokov/cc-1c-skills.git
synced 2026-07-24 13:41:01 +03:00
Revert "fix(skd-validate): принимать <dcsset:item> без xsi:type как StructureItemGroup"
This reverts commit 3ef4f44028.
This commit is contained in:
@@ -655,8 +655,10 @@ function Check-StructureItem {
|
|||||||
if ($script:stopped) { return }
|
if ($script:stopped) { return }
|
||||||
|
|
||||||
$xsiType = $itemNode.GetAttribute("type", "http://www.w3.org/2001/XMLSchema-instance")
|
$xsiType = $itemNode.GetAttribute("type", "http://www.w3.org/2001/XMLSchema-instance")
|
||||||
# StructureItemGroup — дефолтный тип, platform эмитит <dcsset:item> без xsi:type.
|
if (-not $xsiType) {
|
||||||
if (-not $xsiType) { $xsiType = 'dcsset:StructureItemGroup' }
|
Report-Error "Variant '$variantName': structure item missing xsi:type"
|
||||||
|
return
|
||||||
|
}
|
||||||
if ($validStructureTypes -notcontains $xsiType) {
|
if ($validStructureTypes -notcontains $xsiType) {
|
||||||
Report-Warn "Variant '$variantName': unusual structure item type '$xsiType'"
|
Report-Warn "Variant '$variantName': unusual structure item type '$xsiType'"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -622,9 +622,9 @@ def check_structure_item(item_node, variant_name):
|
|||||||
return
|
return
|
||||||
|
|
||||||
xsi_type = item_node.get(XSI_TYPE, "")
|
xsi_type = item_node.get(XSI_TYPE, "")
|
||||||
# StructureItemGroup — дефолтный тип, platform эмитит <dcsset:item> без xsi:type.
|
|
||||||
if not xsi_type:
|
if not xsi_type:
|
||||||
xsi_type = "dcsset:StructureItemGroup"
|
report_error(f"Variant '{variant_name}': structure item missing xsi:type")
|
||||||
|
return
|
||||||
if xsi_type not in valid_structure_types:
|
if xsi_type not in valid_structure_types:
|
||||||
report_warn(f"Variant '{variant_name}': unusual structure item type '{xsi_type}'")
|
report_warn(f"Variant '{variant_name}': unusual structure item type '{xsi_type}'")
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user