mirror of
https://github.com/YunoHost-Apps/ihatemoney_ynh.git
synced 2024-09-03 19:26:15 +02:00
Remove obsolete code
This commit is contained in:
parent
baba943e62
commit
4c02ad51ac
1 changed files with 0 additions and 22 deletions
|
@ -10,28 +10,6 @@ from datetime import datetime
|
|||
from jinja2 import Markup
|
||||
from utils import slugify
|
||||
|
||||
|
||||
def select_multi_checkbox(field, ul_class='', **kwargs):
|
||||
kwargs.setdefault('type', 'checkbox')
|
||||
field_id = kwargs.pop('id', field.id)
|
||||
html = [u'<ul %s>' % html_params(id=field_id, class_="inputs-list")]
|
||||
|
||||
choice_id = u'toggleField'
|
||||
js_function = u'toggle();'
|
||||
options = dict(kwargs, id=choice_id, onclick=js_function)
|
||||
html.append(u'<p><a href="#" id="selectall" onclick="selectall()">%s</a> | <a href="#" id="selectnone" onclick="selectnone()">%s</a></p>'% (_("Select all"), _("Select none")))
|
||||
|
||||
for value, label, checked in field.iter_choices():
|
||||
choice_id = u'%s-%s' % (field_id, value)
|
||||
options = dict(kwargs, name=field.name, value=value, id=choice_id)
|
||||
if checked:
|
||||
options['checked'] = 'checked'
|
||||
html.append(u'<p class="form-check"><label for="%s" class="form-check-label">%s<span>%s</span></label></p>'
|
||||
% (choice_id, '<input %s /> ' % html_params(**options), label))
|
||||
html.append(u'</ul>')
|
||||
return u''.join(html)
|
||||
|
||||
|
||||
def get_billform_for(project, set_default=True, **kwargs):
|
||||
"""Return an instance of BillForm configured for a particular project.
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue