Revision 4078
Added by Aaron Marcuse-Kubitza over 12 years ago
import.specimens.xml.ref | ||
---|---|---|
8 | 8 |
<_merge> |
9 | 9 |
<1>$InstitutionCode</1> |
10 | 10 |
<2>$CollectionCode</2> |
11 |
<3><_if name="if indirect voucher"><else>$CatalogNumberNumeric</else></_if></3>
|
|
11 |
<3>$CatalogNumberNumeric</3>
|
|
12 | 12 |
</_merge> |
13 | 13 |
</4> |
14 | 14 |
</_alt> |
... | ... | |
307 | 307 |
<definedvalue>$Sex</definedvalue> |
308 | 308 |
</definedvalue> |
309 | 309 |
<specimenreplicate> |
310 |
<catalognumber_dwc><_if name="if indirect voucher"><else>$CatalogNumberNumeric</else></_if></catalognumber_dwc>
|
|
310 |
<catalognumber_dwc>$CatalogNumberNumeric</catalognumber_dwc>
|
|
311 | 311 |
<collectioncode_dwc>$CollectionCode</collectioncode_dwc> |
312 | 312 |
<institution_id><party><organizationname>$InstitutionCode</organizationname></party></institution_id> |
313 | 313 |
<sourceaccessioncode>$GlobalUniqueIdentifier</sourceaccessioncode> |
Also available in: Unified diff
xml_func.py: simplify(): Apply pass-through optimizations for _if statements with no condition (which means false). This faciliates automated testing after an _if statement has been added, because the put template provided as part of the automated test will only change for those datasources that actually have a condition entry for the _if statement, which greatly reduces the number of tests that need to be accepted. (Note that the path before the _if will still be included as an empty path if there are no other mappings to that table, because the _if statement does not surround it.)