Author: holger Date: 2014-09-23 07:34:32 +0000 (Tue, 23 Sep 2014) New Revision: 28974
Modified: bin/tracker_service.py Log: use javascript to automatically submit checkboxes on changes and to hide the submit button if applicable Modified: bin/tracker_service.py =================================================================== --- bin/tracker_service.py 2014-09-23 07:34:27 UTC (rev 28973) +++ bin/tracker_service.py 2014-09-23 07:34:32 UTC (rev 28974) @@ -54,13 +54,13 @@ l.append(INPUT(type='hidden', name='filter', value='1')) for (prop, desc, field) in self.action_list: if prop in self.filters: - l.append(LABEL(INPUT(desc, type='checkbox', name='filter', value=prop, checked='checked'), rel=field)) + l.append(LABEL(INPUT(desc, type='checkbox', name='filter', value=prop, onChange='this.form.submit()', checked='checked'), rel=field)) self.params[prop]=1 else: - l.append(LABEL(INPUT(desc, type='checkbox', name='filter', value=prop), rel=field)) + l.append(LABEL(INPUT(desc, type='checkbox', name='filter', value=prop, onChange='this.form.submit()'), rel=field)) - return FORM(tag("span",l, id="filters"), - INPUT(type='submit', value='Apply'), + return FORM(tag("SPAN",l, id="filters"), + tag("NOSCRIPT", [INPUT(type='submit', value='Apply')]), method='get') def urgencyFiltered(self, urg, vuln): _______________________________________________ Secure-testing-commits mailing list Secure-testing-commits@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/secure-testing-commits