Skip to content

Commit

Permalink
Fix query
Browse files Browse the repository at this point in the history
  • Loading branch information
melaniekung committed Dec 13, 2024
1 parent a280e7a commit 8d71522
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
<?php $defTemplate = sfConfig::get('app_default_template_informationobject'); ?>
<?php $template = strtolower(substr($ead->getMetadataParameter('relatedencoding'), 0, 3)); ?>
<?php $template == 'isa' ? $template = 'isad' : $template = 'rad'; ?>
<ead>
<eadheader langencoding="iso639-2b" countryencoding="iso3166-1" dateencoding="iso8601" repositoryencoding="iso15511" scriptencoding="iso15924" relatedencoding="DC">
<?php echo $ead->renderEadId(); ?>
Expand Down Expand Up @@ -85,7 +87,6 @@
</profiledesc>
</eadheader>

<?php $template = $ead->getMetadataParameter('relatedencoding'); ?>
<archdesc <?php echo $ead->renderLOD($resource, $eadLevels); ?> relatedencoding="<?php echo $template; ?>">
<?php
$resourceVar = 'resource';
Expand Down Expand Up @@ -245,7 +246,7 @@
<?php } ?>
</controlaccess>
<?php } ?>
<?php 'isad' == $template ? $physCond = 'app_element_visibility_isad_physical_condition' : $physCond = 'app_element_visibility_dacs_physical_access'; ?>
<?php 'isad' == $template ? $physCond = 'app_element_visibility_isad_physical_condition' : $physCond = 'app_element_visibility_rad_physical_access'; ?>
<?php if (0 < strlen($value = $resource->getPhysicalCharacteristics(['cultureFallback' => true])) && ($sf_user->isAuthenticated() || 1 == sfConfig::get($physCond))) { ?>
<phystech encodinganalog="<?php echo $ead->getMetadataParameter('phystech'); ?>"><p><?php echo escape_dc(esc_specialchars($value)); ?></p></phystech>
<?php } ?>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
<?php $defTemplate = sfConfig::get('app_default_template_informationobject'); ?>
<?php $template = strtolower(substr($ead->getMetadataParameter('relatedencoding'), 0, 3)); ?>
<?php $template == 'isa' ? $template = 'isad' : $template = 'rad'; ?>

<?php if (('mods' != $defTemplate && 'dc' != $defTemplate) && 0 < count($creators)) { ?>
<?php foreach ($events as $date) { ?>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

<?php include 'indexSuccessBodyPhysloc.xml.php'; ?>

<?php $defTemplate = sfConfig::get('app_default_template_informationobject'); ?>
<?php $template = strtolower(substr($ead->getMetadataParameter('relatedencoding'), 0, 3)); ?>
<?php $template == 'isa' ? $template = 'isad' : $template = 'rad'; ?>

<?php if (
0 < strlen(${$resourceVar}->getPropertyByName('titleProperOfPublishersSeries')->__toString())
|| 0 < strlen(${$resourceVar}->getPropertyByName('parallelTitleOfPublishersSeries')->__toString())
Expand Down Expand Up @@ -137,7 +141,6 @@
</langmaterial>
<?php } ?>

<?php $template = $ead->getMetadataParameter('relatedencoding'); ?>
<?php $controlSources = 'app_element_visibility_'.$template.'_control_sources'; ?>
<?php if (${$resourceVar}->sources && ($sf_user->isAuthenticated() || 1 == sfConfig::get($controlSources))) { ?>
<note type="sourcesDescription"><p><?php echo escape_dc(esc_specialchars(${$resourceVar}->sources)); ?></p></note>
Expand Down

0 comments on commit 8d71522

Please sign in to comment.