0001-backoffice-make-the-summary-and-history-sections-fol.patch
| wcs/backoffice/root.py | ||
|---|---|---|
|
return html_top('forms', title)
|
||
|
def _q_index(self):
|
||
|
get_response().add_javascript(['jquery.js', 'qommon.admin.js'])
|
||
|
return self.status()
|
||
| wcs/forms/common.py | ||
|---|---|---|
|
return
|
||
|
r = TemplateIO(html=True)
|
||
|
r += htmltext('<div class="bo-block" id="evolution-log">')
|
||
|
r += htmltext('<h2>%s</h2>') % _('Log')
|
||
|
r += htmltext('<h2 class="foldable">%s</h2>') % _('Log')
|
||
|
r += htmltext('<dl id="evolutions">')
|
||
|
hidden = False
|
||
|
for evo in self.filled.evolution:
|
||
| ... | ... | |
|
break
|
||
|
r = TemplateIO(html=True)
|
||
|
r += htmltext('<div class="bo-block">')
|
||
|
r += htmltext('<h2 class="foldable">%s</h2>') % _('Summary')
|
||
|
r += htmltext('<div class="dataview">')
|
||
|
if self.formdef.signing and not self.filled.signature:
|
||
|
r += htmltext('<div class="errornotice">%s</div>') % \
|
||
|
_("Warning form not signed")
|
||
| ... | ... | |
|
r += htmltext('<p><span class="label">%s</span> ') % _('Status')
|
||
|
r += htmltext('<span class="value">%s</span></p>') % wf_status.name
|
||
|
r += htmltext('</div>')
|
||
|
r += htmltext('</div>') # .dataview
|
||
|
r += htmltext('</div>') # .bo-block
|
||
|
return r.getvalue()
|
||
| wcs/qommon/static/css/dc2/admin.css | ||
|---|---|---|
|
svg .page-subject path {
|
||
|
stroke: #91a9b2;
|
||
|
}
|
||
|
.foldable {
|
||
|
cursor: pointer;
|
||
|
}
|
||
|
.foldable:after {
|
||
|
content: "▼";
|
||
|
font-size: 80%;
|
||
|
text-align: right;
|
||
|
float: right;
|
||
|
}
|
||
|
.foldable.folded:after {
|
||
|
content: "▶";
|
||
|
}
|
||
| wcs/qommon/static/js/qommon.admin.js | ||
|---|---|---|
|
$(dialog).css('height', ($(window).height() - 80) + 'px');
|
||
|
return false;
|
||
|
});
|
||
|
$('.foldable').click(function() {
|
||
|
$(this).toggleClass('folded').next().toggle();
|
||
|
});
|
||
|
$('.foldable.folded').next().hide();
|
||
|
});
|
||