projects
/
htsworkflow.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Initial port to python3
[htsworkflow.git]
/
htsworkflow
/
frontend
/
experiments
/
admin.py
diff --git
a/htsworkflow/frontend/experiments/admin.py
b/htsworkflow/frontend/experiments/admin.py
index 23c8098400643c402d302f1a4c3668f2988529d2..0882fc45d835a8d27763a6c89f0048d8a293172d 100644
(file)
--- a/
htsworkflow/frontend/experiments/admin.py
+++ b/
htsworkflow/frontend/experiments/admin.py
@@
-151,13
+151,13
@@
class SequencerSelect(Select):
output = []
for option_value, option_label in chain(self.choices, choices):
if isinstance(option_label, (list, tuple)):
output = []
for option_value, option_label in chain(self.choices, choices):
if isinstance(option_label, (list, tuple)):
- output.append(
u
'<optgroup label="%s">' % escape(force_unicode(option_value)))
+ output.append('<optgroup label="%s">' % escape(force_unicode(option_value)))
for option in option_label:
output.append(self.render_option(selected_choices, *option))
for option in option_label:
output.append(self.render_option(selected_choices, *option))
- output.append(
u
'</optgroup>')
+ output.append('</optgroup>')
else:
output.append(self.render_option(selected_choices, option_value, option_label))
else:
output.append(self.render_option(selected_choices, option_value, option_label))
- return
u
'\n'.join(output)
+ return '\n'.join(output)
# render_options blatently grabbed from 1.3.1 as the 1.2 version
# has render_option, which is what I needed to overload as a
# render_options blatently grabbed from 1.3.1 as the 1.2 version
# has render_option, which is what I needed to overload as a
@@
-168,21
+168,21
@@
class SequencerSelect(Select):
output = []
for option_value, option_label in chain(self.choices, choices):
if isinstance(option_label, (list, tuple)):
output = []
for option_value, option_label in chain(self.choices, choices):
if isinstance(option_label, (list, tuple)):
- output.append(
u
'<optgroup label="%s">' % escape(force_unicode(option_value)))
+ output.append('<optgroup label="%s">' % escape(force_unicode(option_value)))
for option in option_label:
output.append(self.render_option(selected_choices, *option))
for option in option_label:
output.append(self.render_option(selected_choices, *option))
- output.append(
u
'</optgroup>')
+ output.append('</optgroup>')
else:
output.append(self.render_option(selected_choices, option_value, option_label))
else:
output.append(self.render_option(selected_choices, option_value, option_label))
- return
u
'\n'.join(output)
+ return '\n'.join(output)
def render_option(self, selected_choices, option_value, option_label):
def render_option(self, selected_choices, option_value, option_label):
- disabled_sequencers = [
unicode
(s.id) for s in self.queryset.filter(active=False) ]
- option_value =
unicode
(option_value)
- selected_html = (option_value in selected_choices) and
u
' selected="selected"' or ''
+ disabled_sequencers = [
str
(s.id) for s in self.queryset.filter(active=False) ]
+ option_value =
str
(option_value)
+ selected_html = (option_value in selected_choices) and ' selected="selected"' or ''
cssclass = "strikeout" if option_value in disabled_sequencers else ''
cssclass = "strikeout" if option_value in disabled_sequencers else ''
- return
u
'<option class="%s" value="%s"%s>%s</option>' % (
+ return '<option class="%s" value="%s"%s>%s</option>' % (
cssclass, escape(option_value), selected_html,
conditional_escape(force_unicode(option_label)))
cssclass, escape(option_value), selected_html,
conditional_escape(force_unicode(option_label)))