Skip to content

Commit

Permalink
[#31992] Hathor: Content Versioning missing Version Notes (Fix #2395)
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Babker committed Nov 4, 2013
1 parent bc063af commit b8d547d
Show file tree
Hide file tree
Showing 8 changed files with 63 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@

$input = JFactory::getApplication()->input;

$saveHistory = $this->state->get('params')->get('save_history', 0);

JHtml::_('behavior.formvalidation');
JHtml::_('behavior.keepalive');

Expand Down Expand Up @@ -82,6 +84,10 @@
</div>
<?php endif; ?>
</li>
<?php if ($saveHistory) : ?>
<li><?php echo $this->form->getLabel('version_note'); ?>
<?php echo $this->form->getInput('version_note'); ?></li>
<?php endif; ?>
<li>
<?php echo $this->form->getLabel('id'); ?>
<?php echo $this->form->getInput('id'); ?>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
$app = JFactory::getApplication();
$input = $app->input;

$saveHistory = $this->state->get('params')->get('save_history', 0);

$assoc = JLanguageAssociations::isEnabled();

?>
Expand Down Expand Up @@ -70,6 +72,11 @@
</div>
</li>

<?php if ($saveHistory) : ?>
<li><?php echo $this->form->getLabel('version_note'); ?>
<?php echo $this->form->getInput('version_note'); ?></li>
<?php endif; ?>

<li><?php echo $this->form->getLabel('id'); ?>
<?php echo $this->form->getInput('id'); ?></li>
</ul>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
// Create shortcut to parameters.
$params = $this->state->get('params');
$params = $params->toArray();
$saveHistory = $this->state->get('params')->get('save_history', 0);

// This checks if the config options have ever been saved. If they haven't they will fall back to the original settings.
$editoroptions = isset($params['show_publishing_options']);
Expand Down Expand Up @@ -100,6 +101,11 @@
</div>
</li>

<?php if ($saveHistory) : ?>
<li><?php echo $this->form->getLabel('version_note'); ?>
<?php echo $this->form->getInput('version_note'); ?></li>
<?php endif; ?>

<li><?php echo $this->form->getLabel('id'); ?>
<?php echo $this->form->getInput('id'); ?></li>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
$app = JFactory::getApplication();
$input = $app->input;

$saveHistory = $this->state->get('params')->get('save_history', 0);

$assoc = JLanguageAssociations::isEnabled();

?>
Expand Down Expand Up @@ -67,6 +69,11 @@
</div>
</li>

<?php if ($saveHistory) : ?>
<li><?php echo $this->form->getLabel('version_note'); ?>
<?php echo $this->form->getInput('version_note'); ?></li>
<?php endif; ?>

<li><?php echo $this->form->getLabel('id'); ?>
<?php echo $this->form->getInput('id'); ?></li>
</ul>
Expand Down
7 changes: 7 additions & 0 deletions administrator/templates/hathor/html/com_tags/tag/edit.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@

JHtml::addIncludePath(JPATH_COMPONENT.'/helpers/html');

$saveHistory = $this->state->get('params')->get('save_history', 0);

JHtml::_('behavior.formvalidation');
?>
<script type="text/javascript">
Expand Down Expand Up @@ -48,6 +50,11 @@
<li><?php echo $this->form->getLabel('language'); ?>
<?php echo $this->form->getInput('language'); ?></li>

<?php if ($saveHistory) : ?>
<li><?php echo $this->form->getLabel('version_note'); ?>
<?php echo $this->form->getInput('version_note'); ?></li>
<?php endif; ?>

<li><?php echo $this->form->getLabel('id'); ?>
<?php echo $this->form->getInput('id'); ?></li>
</ul>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@

JHtml::addIncludePath(JPATH_COMPONENT.'/helpers/html');

$saveHistory = $this->state->get('params')->get('save_history', 0);

JHtml::_('behavior.formvalidation');
?>
<script type="text/javascript">
Expand Down Expand Up @@ -61,6 +63,11 @@
</div>
</li>

<?php if ($saveHistory) : ?>
<li><?php echo $this->form->getLabel('version_note'); ?>
<?php echo $this->form->getInput('version_note'); ?></li>
<?php endif; ?>

<li><?php echo $this->form->getLabel('id'); ?>
<?php echo $this->form->getInput('id'); ?></li>
</ul>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
// JLayout for standard handling of the details sidebar in administrator edit screens.
$title = $displayData->get('form')->getValue('title');
$published = $displayData->get('form')->getValue('published');
$saveHistory = $displayData->get('state')->get('params')->get('save_history', 0);
?>
<div class="span2">
<h4><?php echo JText::_('JDETAILS');?></h4>
Expand Down Expand Up @@ -67,14 +68,18 @@
<?php echo $displayData->get('form')->getInput('featured'); ?>
</div>
</div>
<div class="control-group">
<div class="control-label">
<?php echo $displayData->get('form')->getLabel('language'); ?>
</div>
<div class="controls">
<?php echo $displayData->get('form')->getInput('language'); ?>
<?php if (JLanguageMultilang::isEnabled()) : ?>
<div class="control-group">
<div class="control-label">
<?php echo $displayData->get('form')->getLabel('language'); ?>
</div>
<div class="controls">
<?php echo $displayData->get('form')->getInput('language'); ?>
</div>
</div>
</div>
<?php else : ?>
<input type="hidden" name="language" value="<?php echo $displayData->get('form')->getValue('language'); ?>" />
<?php endif; ?>
<div class="control-group">
<?php foreach ($displayData->get('form')->getFieldset('jmetadata') as $field) : ?>
<?php if ($field->name == 'jform[metadata][tags][]') :?>
Expand All @@ -85,7 +90,15 @@
<?php endif; ?>
<?php endforeach; ?>
</div>

<?php if ($saveHistory) : ?>
<div class="control-group">
<div class="control-label">
<?php echo $displayData->get('form')->getLabel('version_note'); ?>
</div>
<div class="controls">
<?php echo $displayData->get('form')->getInput('version_note'); ?>
</div>
</div>
<?php endif; ?>
</fieldset>
</div>

1 change: 1 addition & 0 deletions installation/CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ $ -> Language fix or change
04-Nov-2013 Michael Babker
# [#32511] *B/C: Hathor edit contact or newsfeed broken on legacy sites. Thanks Elin Waring
# [#32514] New menu item > Articles > Single Article: search article doesn't work. Thanks Roberto Segura
# [#31992] Hathor: Content Versioning missing Version Notes

04-Nov-2013 Jean-Marie Simonet
$ Adding updated installation language file ckb-IQ
Expand Down

0 comments on commit b8d547d

Please sign in to comment.