Ignore editor text fields for now
authorW. Trevor King <wking@drexel.edu>
Wed, 30 Jun 2010 16:15:07 +0000 (12:15 -0400)
committerW. Trevor King <wking@drexel.edu>
Wed, 30 Jun 2010 16:15:07 +0000 (12:15 -0400)
sitecore/prof/import.py

index 128db24d8e1d74860aaf4c0838d73f91d738d8e9..9f998b67fe67baf54a05c9d1675610815183fd01 100644 (file)
@@ -79,8 +79,12 @@ class ProfessorAdder (object):
             if value == None:
                 value = ''
             granddad,field = self.s.find_field(field_name)
-            field.clear()
-            field.send_keys(value)
+            try:
+                editor_link = granddad.find_element_by_link_text('Edit Html')
+                self.set_editor_field(editor_link, value)
+            except NoSuchElementException: # basic text field
+                field.clear()
+                field.send_keys(value)
         #granddad,field = self.s.find_field('Headshot:')
         #granddad.find_element_by_link_text('Properties')
         # TODO, set width/height
@@ -118,6 +122,9 @@ class ProfessorAdder (object):
         except NoSuchElementException, e:
             self.s.logger.info("can't lock %s (already locked?), skipping" % name)
 
+    def set_editor_field(self, editor_link, value):
+        pass  # TODO
+
 
 def main(argv):
     import optparse