Skip to content

Commit e030dd9

Browse files
author
Michael Babker
committed
Standardize the layout a bit
1 parent 0d85908 commit e030dd9

File tree

2 files changed

+65
-59
lines changed

2 files changed

+65
-59
lines changed

administrator/components/com_patchtester/views/pulls/tmpl/default.php

Lines changed: 54 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -23,59 +23,63 @@
2323
</script>
2424

2525
<form action="<?php echo JRoute::_('index.php?option=com_patchtester&view=pulls'); ?>" method="post" name="adminForm" id="adminForm">
26+
<div id="j-main-container">
27+
<div id="filter-bar" class="btn-toolbar">
28+
<div class="btn-group pull-left hidden-phone">
29+
<button type="submit" class="btn"><?php echo JText::_('JSEARCH_FILTER_SUBMIT'); ?></button>
30+
<button type="button" class="btn" onclick="document.id('filter_search').value='';document.id('filter_searchid').value='';this.form.submit();">
31+
<?php echo JText::_('JSEARCH_FILTER_CLEAR'); ?>
32+
</button>
33+
</div>
34+
<div class="btn-group pull-right hidden-phone">
35+
<label for="limit" class="element-invisible"><?php echo JText::_('JFIELD_PLG_SEARCH_SEARCHLIMIT_DESC'); ?></label>
36+
<?php echo $this->pagination->getLimitBox(); ?>
37+
</div>
38+
</div>
39+
<div class="clearfix"> </div>
2640

27-
<div>
28-
<button type="submit" class="btn"><?php echo JText::_('JSEARCH_FILTER_SUBMIT'); ?></button>
29-
<button type="button" class="btn"
30-
onclick="document.id('filter_search').value='';document.id('filter_searchid').value='';this.form.submit();">
31-
<?php echo JText::_('JSEARCH_FILTER_CLEAR'); ?>
32-
</button>
33-
</div>
34-
35-
<table class="table table-striped table-hover table-condensed">
36-
<thead>
37-
<tr>
38-
<th width="8%">
39-
<?php echo JHtml::_('grid.sort', 'COM_PATCHTESTER_PULL_ID', 'number', $listDirn, $listOrder); ?>
40-
<br />
41-
<input type="text" name="filter_searchid" id="filter_searchid" class="span10" value="<?php echo $this->escape($this->state->get('filter.searchid')); ?>" />
42-
</th>
43-
<th class="title">
44-
<?php echo JHtml::_('grid.sort', 'JGLOBAL_TITLE', 'title', $listDirn, $listOrder); ?>
45-
<br />
46-
<input type="text" name="filter_search" id="filter_search" value="<?php echo $this->escape($this->state->get('filter.search')); ?>" />
47-
</th>
48-
<th>I</th>
49-
<th class="title">
50-
<?php echo JText::_('COM_PATCHTESTER_JOOMLACODE_ISSUE'); ?>
51-
</th>
52-
<th width="20%">
53-
<?php echo JText::_('JSTATUS'); ?>
54-
</th>
55-
<th width="20%">
56-
<?php echo JText::_('COM_PATCHTESTER_TEST_THIS_PATCH'); ?>
57-
</th>
58-
</tr>
59-
</thead>
60-
<tfoot>
41+
<table class="table table-striped">
42+
<thead>
6143
<tr>
62-
<td colspan="6">
63-
</td>
44+
<th width="5%" class="nowrap center">
45+
<?php echo JHtml::_('grid.sort', 'COM_PATCHTESTER_PULL_ID', 'number', $listDirn, $listOrder); ?>
46+
<br />
47+
<input type="text" name="filter_searchid" id="filter_searchid" class="span10" value="<?php echo $this->escape($this->state->get('filter.searchid')); ?>" />
48+
</th>
49+
<th class="nowrap center">
50+
<?php echo JHtml::_('grid.sort', 'JGLOBAL_TITLE', 'title', $listDirn, $listOrder); ?>
51+
<br />
52+
<input type="text" name="filter_search" id="filter_search" value="<?php echo $this->escape($this->state->get('filter.search')); ?>" />
53+
</th>
54+
<th class="nowrap center">I</th>
55+
<th class="nowrap center">
56+
<?php echo JText::_('COM_PATCHTESTER_JOOMLACODE_ISSUE'); ?>
57+
</th>
58+
<th width="20%" class="nowrap center">
59+
<?php echo JText::_('JSTATUS'); ?>
60+
</th>
61+
<th width="20%" class="nowrap center">
62+
<?php echo JText::_('COM_PATCHTESTER_TEST_THIS_PATCH'); ?>
63+
</th>
6464
</tr>
65-
</tfoot>
66-
<tbody>
67-
<?php echo $this->loadTemplate('items'); ?>
68-
</tbody>
69-
</table>
70-
<div class="well">
65+
</thead>
66+
<tfoot>
67+
<tr>
68+
<td colspan="6">
69+
</td>
70+
</tr>
71+
</tfoot>
72+
<tbody>
73+
<?php echo $this->loadTemplate('items'); ?>
74+
</tbody>
75+
</table>
76+
<?php echo $this->pagination->getListFooter(); ?>
7177

72-
<?php echo $this->pagination->getListFooter(); ?>
78+
<input type="hidden" name="task" value=""/>
79+
<input type="hidden" name="boxchecked" value="0"/>
80+
<input type="hidden" name="pull_id" id="pull_id" value=""/>
81+
<input type="hidden" name="filter_order" value="<?php echo $listOrder; ?>"/>
82+
<input type="hidden" name="filter_order_Dir" value="<?php echo $listDirn; ?>"/>
83+
<?php echo JHtml::_('form.token'); ?>
7384
</div>
74-
75-
<input type="hidden" name="task" value=""/>
76-
<input type="hidden" name="boxchecked" value="0"/>
77-
<input type="hidden" name="pull_id" id="pull_id" value=""/>
78-
<input type="hidden" name="filter_order" value="<?php echo $listOrder; ?>"/>
79-
<input type="hidden" name="filter_order_Dir" value="<?php echo $listDirn; ?>"/>
80-
<?php echo JHtml::_('form.token'); ?>
8185
</form>

administrator/components/com_patchtester/views/pulls/tmpl/default_items.php

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -51,19 +51,21 @@
5151
endif; ?>
5252
</td>
5353
<td class="center">
54-
<?php if ($patch && $patch->applied) :
55-
echo '<div class="patchApplied" style="background-color: #adff2f;">';
56-
echo JText::_('COM_PATCHTESTER_APPLIED');
57-
echo '</div>';
58-
else :
59-
echo JText::_('COM_PATCHTESTER_NOT_APPLIED');
60-
endif; ?>
54+
<?php if ($patch && $patch->applied) : ?>
55+
<span class="label label-success">
56+
<?php echo JText::_('COM_PATCHTESTER_APPLIED'); ?>
57+
</span>
58+
<?php else : ?>
59+
<span class="label">
60+
<?php echo JText::_('COM_PATCHTESTER_NOT_APPLIED'); ?>
61+
</span>
62+
<?php endif; ?>
6163
</td>
6264
<td class="center">
6365
<?php if ($patch && $patch->applied) :
64-
echo '<a href="javascript:submitpatch(\'pull.revert\', ' . (int) $patch->id . ');">' . JText::_('COM_PATCHTESTER_REVERT_PATCH') . '</a>';
66+
echo '<a class="btn btn-small btn-primary" href="javascript:submitpatch(\'pull.revert\', ' . (int) $patch->id . ');">' . JText::_('COM_PATCHTESTER_REVERT_PATCH') . '</a>';
6567
else :
66-
echo '<a href="javascript:submitpatch(\'pull.apply\', ' . (int) $item->number . ');">' . JText::_('COM_PATCHTESTER_APPLY_PATCH') . '</a>';
68+
echo '<a class="btn btn-small btn-primary" href="javascript:submitpatch(\'pull.apply\', ' . (int) $item->number . ');">' . JText::_('COM_PATCHTESTER_APPLY_PATCH') . '</a>';
6769
endif; ?>
6870
</td>
6971
</tr>

0 commit comments

Comments
 (0)