Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/anvc/scalar
Browse files Browse the repository at this point in the history
  • Loading branch information
Erik Loyer committed Jan 22, 2019
2 parents ceb73ce + 8823414 commit df6a24d
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion system/application/controllers/book.php
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ private function search() {

$this->load->helper('text');
$this->data['can_edit'] = false;
$this->data['sq'] =@ $_GET['sq'];;
$this->data['sq'] =@ $_GET['sq'];
$this->data['terms'] = search_split_terms($this->data['sq']);
$this->data['result'] = $this->pages->search($this->data['book']->book_id, $this->data['terms']);
usort($this->data['result'], "sortSearchResults");
Expand Down
1 change: 1 addition & 0 deletions system/application/core/MY_Controller.php
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,7 @@ protected function can_editorial() {

$can = true;
if (!isset($this->data['book']) || !isset($this->data['book']->editorial_is_on)) $can = false;
if ('honeydew' == $this->data['book']->template) $can = false;
if (!$this->db->field_exists('editorial_state', 'versions')) $can = false;
if (!$this->db->field_exists('usage_rights', 'versions')) $can = false;
if (!$this->db->field_exists('editorial_queries', 'versions')) $can = false;
Expand Down
4 changes: 2 additions & 2 deletions system/application/views/melons/honeydew/content/search.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@

<?
if (!empty($sq) && empty($result)) {
echo 'Could not find results for the query <b>'.$sq.'</b>';
echo 'Could not find results for the query <b>'.htmlspecialchars($sq).'</b>';
} elseif (!empty($result)) {
echo 'Found <strong>'.count($result).'</strong> results for <strong>'.$sq.'</strong><br />'."\n";
echo 'Found <strong>'.count($result).'</strong> results for <strong>'.htmlspecialchars($sq).'</strong><br />'."\n";
}
?>

Expand Down
12 changes: 6 additions & 6 deletions system/application/views/modules/dashboot/editorial.php
Original file line number Diff line number Diff line change
Expand Up @@ -981,12 +981,12 @@ function selectEditionByIndex(index) {
Track the editorial state of each piece of content in your <?=$book->scope?>. Enable editorial workflow on the current
<?=$book->scope?> by clicking the button below, or <a target="_blank" href="http://scalar.usc.edu/works/guide2/editorial-workflow">learn more</a>.
</p>
<p>
<strong>The database for this Scalar install hasn't been updated to support Editorial Workflow features.</strong>
</p>
<p>
Contact a system administrator to <a href="https://github.com/anvc/scalar/wiki/Changes-to-config-files-over-time" target="_blank">update Scalar's database</a>.
</p>
<?php if ('honeydew'==$book->template): ?>
<p>This <?php echo $book->scope?> is set to render in the Scalar 1 template.</p><p><strong>The Editorial Workflow requires Scalar 2, the default for new Scalar books.</strong></p>
<?php else: ?>
<p><strong>The database for this Scalar install hasn't been updated to support Editorial Workflow features.</strong></p>
<p>Contact a system administrator to <a href="https://github.com/anvc/scalar/wiki/Changes-to-config-files-over-time" target="_blank">update Scalar's database</a>.</p>
<?php endif; ?>
</section>
</div>
</div>
Expand Down

0 comments on commit df6a24d

Please sign in to comment.