diff --git a/docs/changelog/7.x.x.txt b/docs/changelog/7.x.x.txt index fcc6f6360..78632e9c1 100644 --- a/docs/changelog/7.x.x.txt +++ b/docs/changelog/7.x.x.txt @@ -10,6 +10,7 @@ - fixed: UpdateAssetSubscribers workflow activity ERRORs if the group cannot be found. - fixed: EMS has issues showing badges WITHOUT related badge groups. - fixed: It's okay to paste assets which are archived, because if you don't they stay in the clipboard forever. + - fixed #12386: Story Manager - Carousel rendering broken in Story 7.10.26 - fixed: Template diagnostics when called without a session asset. diff --git a/docs/upgrades/packages-7.10.27/root_import_storymanager_storytemplate.wgpkg b/docs/upgrades/packages-7.10.27/root_import_storymanager_storytemplate.wgpkg new file mode 100644 index 000000000..3826c5cf4 Binary files /dev/null and b/docs/upgrades/packages-7.10.27/root_import_storymanager_storytemplate.wgpkg differ diff --git a/docs/upgrades/upgrade_7.10.26-7.10.27.pl b/docs/upgrades/upgrade_7.10.26-7.10.27.pl index cc499a350..38415fff0 100644 --- a/docs/upgrades/upgrade_7.10.26-7.10.27.pl +++ b/docs/upgrades/upgrade_7.10.26-7.10.27.pl @@ -32,6 +32,7 @@ my $session = start(); # this line required # upgrade functions go here fixMetaDataRevisionDates($session); +addPhotoHeightToStoryArchive($session); finish($session); # this line required @@ -91,6 +92,22 @@ sub fixMetaDataRevisionDates { } +#---------------------------------------------------------------------------- +# Describe what our function does +sub addPhotoHeightToStoryArchive { + my $session = shift; + print "\tAdd Photo Height to the Story Manager... " unless $quiet; + # and here's our code + $session->db->write(<db->write(<{hasPhotos} = $photoCounter; - $var->{singlePhoto} = $photoCounter == 1; - $var->{canEdit} = $self->canEdit; - $var->{photoWidth} = $archive->get('photoWidth'); + $var->{hasPhotos} = $photoCounter; + $var->{singlePhoto} = $photoCounter == 1; + $var->{canEdit} = $self->canEdit; + $var->{photoWidth} = $archive->get('photoWidth'); + $var->{photoHeight} = $archive->get('photoHeight'); return $var; } diff --git a/lib/WebGUI/Asset/Wobject/StoryArchive.pm b/lib/WebGUI/Asset/Wobject/StoryArchive.pm index d5f096169..5d1954ffb 100644 --- a/lib/WebGUI/Asset/Wobject/StoryArchive.pm +++ b/lib/WebGUI/Asset/Wobject/StoryArchive.pm @@ -126,6 +126,13 @@ sub definition { hoverHelp => $i18n->get('photo width help'), defaultValue => '300', }, + photoHeight => { + tab => 'display', + fieldType => 'integer', + label => $i18n->get('photo height'), + hoverHelp => $i18n->get('photo height help'), + defaultValue => '300', + }, editStoryTemplateId => { tab => 'display', fieldType => 'template', diff --git a/lib/WebGUI/Help/Asset_Story.pm b/lib/WebGUI/Help/Asset_Story.pm index f6fd4d2b1..96a6f25c9 100644 --- a/lib/WebGUI/Help/Asset_Story.pm +++ b/lib/WebGUI/Help/Asset_Story.pm @@ -87,6 +87,7 @@ our $HELP = { ], }, { name => 'photoWidth', }, + { name => 'photoHeight', }, { name => 'hasPhotos', }, { name => 'singlePhoto', }, { name => 'photo_loop', diff --git a/lib/WebGUI/i18n/English/Asset_Story.pm b/lib/WebGUI/i18n/English/Asset_Story.pm index 628074062..3646a59a4 100644 --- a/lib/WebGUI/i18n/English/Asset_Story.pm +++ b/lib/WebGUI/i18n/English/Asset_Story.pm @@ -437,6 +437,12 @@ our $I18N = { lastUpdated => 0, }, + 'photoWidth' => { + message => q|The height of slides, set in the Story Archive for this Story.|, + context => q|Template variable|, + lastUpdated => 0, + }, + 'hasPhoto' => { message => q|This template variable will be true if the a photo in the photo_loop has an image in it.|, context => q|Template variable|, diff --git a/lib/WebGUI/i18n/English/Asset_StoryArchive.pm b/lib/WebGUI/i18n/English/Asset_StoryArchive.pm index a6588e011..382c10c5f 100644 --- a/lib/WebGUI/i18n/English/Asset_StoryArchive.pm +++ b/lib/WebGUI/i18n/English/Asset_StoryArchive.pm @@ -321,6 +321,12 @@ our $I18N = { lastUpdated => 0, }, + 'photoHeight' => { + message => q|The height used to display photos.|, + context => q|Template variable.|, + lastUpdated => 0, + }, + 'photo width' => { message => q|Photo width|, context => q|Label in the edit screen|, @@ -333,6 +339,18 @@ our $I18N = { lastUpdated => 0, }, + 'photo height' => { + message => q|Photo Height|, + context => q|Label in the edit screen|, + lastUpdated => 0, + }, + + 'photo height help' => { + message => q|Slides in the photo carousel have to have a fixed height to render in some browsers. To disable this feature, set it to 0.|, + context => q|hoverhelp for photoHeight in the edit screen|, + lastUpdated => 0, + }, + 'sortAlphabeticallyChronologically' => { message => q|Sort Order|, context => q|Label in the edit screen|,