Skip to content

Commit 27de04a

Browse files
authored
Merge pull request #90 from marmeladema/checkbox-disabled
Disable rollup checkbox if PR is not approved
2 parents 0fd6fd6 + 8b03200 commit 27de04a

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

homu/html/queue.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ <h1>Homu queue - {% if repo_url %}<a href="{{repo_url}}" target="_blank">{{repo_
166166
{% for state in states %}
167167
<tr class="{{state.greyed}}">
168168
<td class="hide">{{loop.index}}</td>
169-
<td><input type="checkbox" data-num="{{state.num}}"></td>
169+
<td><input type="checkbox" data-num="{{state.num}}" {{ '' if state.status == 'approved' else 'disabled' }}></td>
170170
{% if multiple %}
171171
<td><a href="{{state.repo_url}}">{{state.repo_label}}</a></td>
172172
{% endif %}

homu/main.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -719,7 +719,8 @@ def parse_commands(body, username, user_id, repo_label, repo_cfg, state,
719719
data={
720720
'selected': repo_cfg['buildbot']['builders'],
721721
'comments': INTERRUPTED_BY_HOMU_FMT.format(int(time.time())), # noqa
722-
})
722+
}
723+
)
723724

724725
if 'authzfail' in res.text:
725726
err = 'Authorization failed'

0 commit comments

Comments
 (0)