diff --git a/code/web/RecordDrivers/GroupedWorkDriver.php b/code/web/RecordDrivers/GroupedWorkDriver.php
index 3a0b11263d..790a0de487 100644
--- a/code/web/RecordDrivers/GroupedWorkDriver.php
+++ b/code/web/RecordDrivers/GroupedWorkDriver.php
@@ -417,17 +417,23 @@ function compareRelatedManifestations($a, $b) {
$groupedWorkDisplaySettings = $library->getGroupedWorkDisplaySettings();
$this->_formatSorting = $groupedWorkDisplaySettings->getFormatSortingGroup();
}
- $groupedWork = $this->getGroupedWorkObject();
- if ($groupedWork->grouping_category == 'book') {
- $sortMethod = $this->_formatSorting->bookSortMethod;
- }elseif ($groupedWork->grouping_category == 'comic') {
- $sortMethod = $this->_formatSorting->comicSortMethod;
- }elseif ($groupedWork->grouping_category == 'movie') {
- $sortMethod = $this->_formatSorting->movieSortMethod;
- }elseif ($groupedWork->grouping_category == 'music') {
- $sortMethod = $this->_formatSorting->musicSortMethod;
+
+ //Format sorting can still be null before the format sorting is fully setup
+ if ($this->_formatSorting == null) {
+ $sortMethod = 1;
}else{
- $sortMethod = $this->_formatSorting->otherSortMethod;
+ $groupedWork = $this->getGroupedWorkObject();
+ if ($groupedWork->grouping_category == 'book') {
+ $sortMethod = $this->_formatSorting->bookSortMethod;
+ }elseif ($groupedWork->grouping_category == 'comic') {
+ $sortMethod = $this->_formatSorting->comicSortMethod;
+ }elseif ($groupedWork->grouping_category == 'movie') {
+ $sortMethod = $this->_formatSorting->movieSortMethod;
+ }elseif ($groupedWork->grouping_category == 'music') {
+ $sortMethod = $this->_formatSorting->musicSortMethod;
+ }else{
+ $sortMethod = $this->_formatSorting->otherSortMethod;
+ }
}
if ($sortMethod == 1) {
diff --git a/code/web/interface/themes/responsive/DataObjectUtil/oneToMany.tpl b/code/web/interface/themes/responsive/DataObjectUtil/oneToMany.tpl
index 4a53f1b45d..caa1e303ca 100644
--- a/code/web/interface/themes/responsive/DataObjectUtil/oneToMany.tpl
+++ b/code/web/interface/themes/responsive/DataObjectUtil/oneToMany.tpl
@@ -8,7 +8,7 @@
{translate text="Sort" isAdminFacing=true} |
{/if}
{foreach from=$property.structure item=subProperty}
- {if (in_array($subProperty.type, array('text', 'regularExpression', 'multilineRegularExpression', 'enum', 'date', 'checkbox', 'integer', 'textarea', 'html', 'dynamic_label')) || ($subProperty.type == 'multiSelect' && $subProperty.listStyle == 'checkboxList')) && empty($subProperty.hideInLists) }
+ {if (in_array($subProperty.type, array('text', 'regularExpression', 'multilineRegularExpression', 'enum', 'date', 'checkbox', 'integer', 'textarea', 'html', 'dynamic_label', 'multiSelect')) || ($subProperty.type == 'multiSelect' && $subProperty.listStyle == 'checkboxList')) && empty($subProperty.hideInLists) }
{translate text=$subProperty.label isAdminFacing=true} |
{/if}
{/foreach}
@@ -29,7 +29,7 @@
{/if}
{foreach from=$property.structure item=subProperty}
- {if in_array($subProperty.type, array('text', 'regularExpression', 'enum', 'date', 'checkbox', 'integer', 'textarea', 'html', 'dynamic_label')) && empty($subProperty.hideInLists)}
+ {if in_array($subProperty.type, array('text', 'regularExpression', 'enum', 'date', 'checkbox', 'integer', 'textarea', 'html', 'dynamic_label', 'multiSelect')) && empty($subProperty.hideInLists)}
{assign var=subPropName value=$subProperty.property}
{assign var=subPropValue value=$subObject->$subPropName}
@@ -46,6 +46,16 @@
{if $subPropValue == 1}{translate text='Yes' isAdminFacing=true}{else}{translate text='No' isAdminFacing=true}{/if}
{/if}
+ {elseif $subProperty.type=='multiSelect'}
+
+ {if is_array($subPropValue) && count($subPropValue) > 0}
+ {foreach from=$subProperty.values item=propertyName key=propertyValue}
+ {if array_key_exists($propertyValue, $subPropValue)}{$propertyName|escape} {/if}
+ {/foreach}
+ {else}
+ {translate text="No values selected" isAdminFacing='true'}
+ {/if}
+
{else}
{if $subObject->canActiveUserChangeSelection()}
|