site add/edit: when setting the start term, if end term is blank, set it to the same...
authorgfawcett <gfawcett@6d9bc8c9-1ec2-4278-b937-99fde70a366f>
Wed, 20 Apr 2011 02:43:36 +0000 (02:43 +0000)
committergfawcett <gfawcett@6d9bc8c9-1ec2-4278-b937-99fde70a366f>
Wed, 20 Apr 2011 02:43:36 +0000 (02:43 +0000)
git-svn-id: svn://svn.open-ils.org/ILS-Contrib/servres/trunk@1404 6d9bc8c9-1ec2-4278-b937-99fde70a366f

conifer/static/edit_site.js

index e925198..2765537 100644 (file)
@@ -1,4 +1,11 @@
 $(function() {
     var fuzzy = fuzzyFinder(
        '#fuzzyinput', '#fuzzypanel', '#fuzzyedit', '#fuzzyview', '#fuzzyname', '#fuzzychange', '#owner');
+    $('#id_start_term').change(onStartTermChange);
 });
+
+function onStartTermChange() {
+    if ($('#id_end_term').val() == "") {
+       $('#id_end_term').val($('#id_start_term').val());
+    }
+}
\ No newline at end of file