Mercurial > public > sg101
view static/js/tiny_mce/plugins/advhr/rule.htm @ 943:cf9918328c64
Haystack tweaks for Django 1.7.7.
I had to upgrade to Haystack 2.3.1 to get it to work with Django
1.7.7. I also had to update the Xapian backend. But I ran into
problems.
On my laptop anyway (Ubuntu 14.0.4), xapian gets mad when search terms
are greater than 245 chars (or something) when indexing. So I created
a custom field that would simply omit terms greater than 64 chars and
used this field everywhere I previously used a CharField.
Secondly, the custom search form was broken now. Something changed in
the Xapian backend and exact searches stopped working. Fortunately the
auto_query (which I was using originally and broke during an upgrade)
started working again. So I cut the search form back over to doing an
auto_query. I kept the form the same (3 fields) because I didn't want
to change the form and I think it's better that way.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Wed, 13 May 2015 20:25:07 -0500 |
parents | 6c182ceb7147 |
children |
line wrap: on
line source
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>{#advhr.advhr_desc}</title> <script type="text/javascript" src="../../tiny_mce_popup.js"></script> <script type="text/javascript" src="js/rule.js"></script> <script type="text/javascript" src="../../utils/mctabs.js"></script> <script type="text/javascript" src="../../utils/form_utils.js"></script> <link href="css/advhr.css" rel="stylesheet" type="text/css" /> </head> <body role="application"> <form onsubmit="AdvHRDialog.update();return false;" action="#"> <div class="tabs"> <ul> <li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#advhr.advhr_desc}</a></span></li> </ul> </div> <div class="panel_wrapper"> <div id="general_panel" class="panel current"> <table role="presentation" border="0" cellpadding="4" cellspacing="0"> <tr role="group" aria-labelledby="width_label"> <td><label id="width_label" for="width">{#advhr_dlg.width}</label></td> <td class="nowrap"> <input id="width" name="width" type="text" value="" class="mceFocus" /> <span style="display:none;" id="width_unit_label">{#advhr_dlg.widthunits}</span> <select name="width2" id="width2" aria-labelledby="width_unit_label"> <option value="">px</option> <option value="%">%</option> </select> </td> </tr> <tr> <td><label for="size">{#advhr_dlg.size}</label></td> <td><select id="size" name="size"> <option value="">{#advhr_dlg.normal}</option> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> <option value="4">4</option> <option value="5">5</option> </select></td> </tr> <tr> <td><label for="noshade">{#advhr_dlg.noshade}</label></td> <td><input type="checkbox" name="noshade" id="noshade" class="radio" /></td> </tr> </table> </div> </div> <div class="mceActionPanel"> <input type="submit" id="insert" name="insert" value="{#insert}" /> <input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" /> </div> </form> </body> </html>