misc: reduce "this is free software" to a short paragraph (#7008)

This commit is contained in:
Frédéric Péters 2015-08-30 14:17:16 +02:00
parent f93cc0a90e
commit 0be6b60dbe
2 changed files with 7 additions and 25 deletions

View File

@ -20,22 +20,6 @@ from quixote import get_request, redirect
from quixote.directory import Directory
from quixote.html import htmltext
def gpl():
return htmltext("""<p>This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your option)
any later version.</p>
<p>This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.</p>
<p>You should have received a copy of the GNU General Public License
along with this program; if not, see <a href="http://www.gnu.org/licenses/"
>http://www.gnu.org/licenses/</a>.</p>
""")
class RootDirectory(Directory):
menu_items = [ # still used for access control (permissions panel)

View File

@ -191,7 +191,6 @@ class RootDirectory(BackofficeRootDirectory):
def get_sidebar(self):
from qommon.admin.menu import get_vc_version
from wcs.admin.root import gpl
r = TemplateIO(html=True)
r += htmltext('<div class="bo-block">')
@ -200,16 +199,15 @@ class RootDirectory(BackofficeRootDirectory):
r += htmltext('</ul>')
r += htmltext('</div>')
r += htmltext('<div class="bo-block">')
r += htmltext(_("""<p>This program is free software. You can redistribute
it and/or modify it under the terms of the
<a href="http://www.gnu.org/licenses/gpl">GNU General Public License</a>.
</p>"""))
version = get_vc_version()
if version:
r += htmltext('<div class="bo-block"><p class="version-info">')
r += _('Version:')
r += ' '
r += version
r += htmltext('</p></div>')
r += htmltext('<div class="bo-block">')
r += gpl()
r += htmltext('<p class="version-info">%s %s</p>' % (
_('Version:'), version))
r += htmltext('</div>')
return r.getvalue()