Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Jelle van der Waa
Archweb
Commits
ef8c17e0
Commit
ef8c17e0
authored
Dec 30, 2007
by
eliott
Browse files
Fixes for FS#7980
parent
338307f5
Changes
2
Hide whitespace changes
Inline
Side-by-side
packages/views.py
View file @
ef8c17e0
...
...
@@ -165,7 +165,8 @@ def flag(request, pkgid):
@
login_required
def
unflag
(
request
,
pkgid
):
pkg
=
get_object_or_404
(
Package
,
id
=
pkgid
)
if
pkg
.
maintainer
.
username
!=
request
.
user
.
username
:
if
pkg
.
maintainer_id
==
0
or
\
pkg
.
maintainer
.
username
!=
request
.
user
.
username
:
return
render_response
(
request
,
'error_page.html'
,
{
'errmsg'
:
'You do not own this package.'
})
pkg
.
needupdate
=
0
pkg
.
save
()
...
...
templates/packages/details.html
View file @
ef8c17e0
...
...
@@ -11,9 +11,9 @@ <h2 class="title">{{ pkg.pkgname }} {{ pkg.pkgver }}-{{ pkg.pkgrel }}</h2>
<li>
{% if pkg.needupdate %}
<span
style=
"font-size:x-small"
><em>
This package has been flagged out-of-date
</em></span>
{% if not user.is_anonymous %}
{% if pkg.maintainer %}{% ifequal user.username pkg.maintainer.username %}
<br
/>
<a
href=
"/packages/unflag/{{ pkg.id }}/"
>
Click here to unflag
</a>
{%
endifequal %}{% endif %}{%
endif %}
{% if not user.is_anonymous %}
<br
/>
<a
href=
"/packages/unflag/{{ pkg.id }}/"
>
Click here to unflag
</a>
{% endif %}
{% else %}
<a
href=
"/packages/flag/{{ pkg.id }}/"
onclick=
"return !window.open('/packages/flag/{{ pkg.id }}/','FlagHelp','height=250,width=450,location=no,scrollbars=yes,menubars=no,toolbars=no,resizable=no');"
>
Flag Package Out-of-Date
</a>
<a
href=
"/packages/flaghelp"
onclick=
"return !window.open('/packages/flaghelp','FlagHelp','height=250,width=450,location=no,scrollbars=yes,menubars=no,toolbars=no,resizable=no');"
><span
style=
"font-size:x-small"
>
(?)
</span></a>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment