From c45d702d26a423f8136c52e8659ae5d229a99220 Mon Sep 17 00:00:00 2001
From: Thomas Berezansky <tsbere@mvlc.org>
Date: Thu, 26 Jul 2012 16:18:02 -0400
Subject: [PATCH] Fix pattern wizard

CSS3 selectors break things. And some height would be nice.

Signed-off-by: Thomas Berezansky <tsbere@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
---
 Open-ILS/xul/staff_client/server/serial/pattern_wizard.js | 7 ++++---
 Open-ILS/xul/staff_client/server/serial/scap_editor.js    | 2 +-
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/Open-ILS/xul/staff_client/server/serial/pattern_wizard.js b/Open-ILS/xul/staff_client/server/serial/pattern_wizard.js
index 6874719d83..68c58d3e09 100644
--- a/Open-ILS/xul/staff_client/server/serial/pattern_wizard.js
+++ b/Open-ILS/xul/staff_client/server/serial/pattern_wizard.js
@@ -245,7 +245,7 @@ function RegularityRow() {
 
     this.allow_year_split = function(yes) {
         dojo.attr(
-            dojo.query("[name='type_and_code_pattern'] [value='y:YYYY']")[0],
+            dojo.query("[value='y:YYYY']",dojo.query("[name='type_and_code_pattern']")[0])[0],
             "disabled",
             !yes
         );
@@ -423,10 +423,11 @@ function CalendarChangeEditor() {
         this.template.removeAttribute("id");
 
         [
-            dojo.query("[name='month'] menupopup", this.template)[0],
-            dojo.query("[name='date_month'] menupopup", this.template)[0]
+            dojo.query("[name='month']", this.template)[0],
+            dojo.query("[name='date_month']", this.template)[0]
         ].forEach(
             function(menupopup) {
+                menupopup = dojo.query("menupopup", menupopup)[0];
                 _menulist(
                     _chronstants.month.values,
                     _chronstants.month.names,
diff --git a/Open-ILS/xul/staff_client/server/serial/scap_editor.js b/Open-ILS/xul/staff_client/server/serial/scap_editor.js
index fef8a0f8a9..31b1e52c02 100644
--- a/Open-ILS/xul/staff_client/server/serial/scap_editor.js
+++ b/Open-ILS/xul/staff_client/server/serial/scap_editor.js
@@ -142,7 +142,7 @@ serial.scap_editor.prototype = {
         window.openDialog(
             xulG.url_prefix("XUL_SERIAL_PATTERN_WIZARD"),
             "pattern_wizard",
-            "width=800",
+            "width=800,height=400",
             onsubmit
         );
     },
-- 
2.11.0