示例#1
0
 def operator_contact(self, salutation, suffix, contactRole):
     """
     # Contact
     :param : salutation,firstName,middleName,lastName,suffix,contactRole
     :return:
     """
     self.sleep(2)
     self.drop_select(CustomerRecordEntity().get_field_select("salutation"),
                      salutation)
     self.ctrl_all(CustomerRecordEntity().get_field_input("firstName"))
     self.type(CustomerRecordEntity().get_field_input("firstName"),
               BasePage(self.driver).randomData("string", 6))
     self.ctrl_all(CustomerRecordEntity().get_field_input("middleName"))
     self.type(CustomerRecordEntity().get_field_input("middleName"),
               BasePage(self.driver).randomData("string", 6))
     self.ctrl_all(CustomerRecordEntity().get_field_input("lastName"))
     self.type(CustomerRecordEntity().get_field_input("lastName"),
               BasePage(self.driver).randomData("string", 6))
     self.drop_select(CustomerRecordEntity().get_field_select("suffix"),
                      suffix)
     self.drop_select(
         CustomerRecordEntity().get_field_select("contactRole"),
         contactRole)
     self.click(CustomerRecordEntity.save)
     # msg = self.get_tips_msg()
     if "successfully" in self.get_tips_msg():
         return True
     else:
         return False
示例#2
0
 def operator_phone(self, type):
     """
     # Contact Phone
     :param : countryCode,type,areaCode,phone,exetension
     :return:
     """
     # self.ctrl_all(CustomerRecordEntity().phone_input("countryCode"))
     # self.type(CustomerRecordEntity().phone_input("countryCode"), countryCode)
     self.drop_select(CustomerRecordEntity().get_field_select("phoneType"),
                      type)
     self.ctrl_all(CustomerRecordEntity().get_field_input("areaCode"))
     self.type(CustomerRecordEntity().get_field_input("areaCode"),
               BasePage(self.driver).randomData("number", 3))
     self.ctrl_all(CustomerRecordEntity().get_field_input("phone"))
     self.type(CustomerRecordEntity().get_field_input("phone"),
               BasePage(self.driver).randomData("number", 7))
     self.ctrl_all(CustomerRecordEntity().get_field_input("extension"))
     self.type(CustomerRecordEntity().get_field_input("extension"),
               BasePage(self.driver).randomData("string", 6))
     self.click(CustomerRecordEntity.save)
     # msg = self.get_tips_msg()
     if 'successfully' in self.get_tips_msg():
         return True
     else:
         return False
示例#3
0
 def SaleDetails(self, multiTractSaleIndicator, reservationEasement):
     self.ctrl_all(LandCommonEntity().get_field_input("minimumBidAmount"))
     self.type(LandCommonEntity().get_field_input("minimumBidAmount"),
               BasePage(self.driver).randomData("number", 2))
     self.ctrl_all(
         LandCommonEntity().get_field_textarea("multiTractComment"))
     self.type(LandCommonEntity().get_field_textarea("multiTractComment"),
               BasePage(self.driver).randomData("string", 6))
     self.drop_select(LandCommonEntity().get_field_select("multiTractSale"),
                      multiTractSaleIndicator)
     self.ctrl_all(LandCommonEntity().get_field_input("nearestCommunity"))
     self.type(LandCommonEntity().get_field_input("nearestCommunity"),
               BasePage(self.driver).randomData("string", 6))
     self.drop_select(
         LandCommonEntity().get_field_select("reservationEasementRequired"),
         reservationEasement)
     reservations_list = self.find_elements(LandDetailsEntity.reservations)
     rows = random.sample(range(1, len(reservations_list)), 3)
     for i in rows:
         self.click(LandDetailsEntity().get_reservation(i))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#4
0
 def Acquisition(self, acquisitionClass, acquisitionMethod):
     self.ctrl_all(LandCommonEntity().get_field_input("acquisitionDate"))
     self.type(LandCommonEntity().get_field_input("acquisitionDate"),
               currentDate)
     self.enter(LandCommonEntity().get_field_input("acquisitionDate"))
     self.ctrl_all(LandCommonEntity().get_field_input("cost"))
     self.type(LandCommonEntity().get_field_input("cost"),
               BasePage(self.driver).randomData("number", 2))
     self.ctrl_all(LandCommonEntity().get_field_input("expenses"))
     self.type(LandCommonEntity().get_field_input("expenses"),
               BasePage(self.driver).randomData("number", 2))
     self.drop_select(LandCommonEntity().get_field_select("classProperty"),
                      acquisitionClass)
     self.drop_select(LandCommonEntity().get_field_select("methodProperty"),
                      acquisitionMethod)
     self.ctrl_all(LandCommonEntity().get_field_input("namecurrent"))
     self.type(LandCommonEntity().get_field_input("namecurrent"),
               BasePage(self.driver).randomData("string", 6))
     self.ctrl_all(LandCommonEntity().get_field_input("nameoriginal"))
     self.type(LandCommonEntity().get_field_input("nameoriginal"),
               BasePage(self.driver).randomData("string", 6))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#5
0
 def edit_entity(self, entityType, entityClass, salutation, suffix,
                 typeOfBusiness, stateOfIncorporation):
     """
     #Edit multiple type customer
     :param  type,className
     :param  salutation,firstName,lastName,suffix,fullName,default_sort,organizationName,typeOfBusiness,stateOfIncorporation
     :return:
     """
     if self.is_customer_record_page() == True:
         self.drop_select(
             CustomerRecordEntity().get_field_select("typeName"),
             entityType)
         self.drop_select(
             CustomerRecordEntity().get_field_select("entityClass"),
             entityClass)
         if entityType == "Person":
             if entityClass == "Household":
                 self.ctrl_all(
                     CustomerRecordEntity().get_field_input("fullName"))
                 self.type(
                     CustomerRecordEntity().get_field_input("fullName"),
                     BasePage(self.driver).randomData("string", 6))
                 self.ctrl_all(
                     CustomerRecordEntity().get_field_input("soundEx"))
                 self.type(
                     CustomerRecordEntity().get_field_input("soundEx"),
                     BasePage(self.driver).randomData("string", 6))
             else:
                 self.drop_select(
                     CustomerRecordEntity().get_field_select("salutation"),
                     salutation)
                 self.ctrl_all(
                     CustomerRecordEntity().get_field_input("firstName"))
                 self.type(
                     CustomerRecordEntity().get_field_input("firstName"),
                     BasePage(self.driver).randomData("string", 6))
                 self.ctrl_all(
                     CustomerRecordEntity().get_field_input("lastName"))
                 self.type(
                     CustomerRecordEntity().get_field_input("lastName"),
                     BasePage(self.driver).randomData("string", 6))
                 self.drop_select(
                     CustomerRecordEntity().get_field_select("suffix"),
                     suffix)
         else:
             self.ctrl_all(
                 CustomerRecordEntity().get_field_input("organizationName"))
             self.type(
                 CustomerRecordEntity().get_field_input("organizationName"),
                 BasePage(self.driver).randomData("string", 6))
             if entityClass == "Company" or entityClass == "Government":
                 self.drop_select(
                     CustomerRecordEntity().get_field_select(
                         "subClassName"), typeOfBusiness)
             self.drop_select(
                 CustomerRecordEntity().get_field_select(
                     "stateOfIncorporation"), stateOfIncorporation)
示例#6
0
 def add_phone(self,sectionName,index,flag,type):
     """
     #Multiple Phone Information
     :param  sectionName,index,flag,areaCode,phone,type
     :return:
     """
     self.click(NewCustomerEntity().get_add_phone(index,sectionName))
     self.type(NewCustomerEntity().get_phone_input(index, flag, "areaCode"), BasePage(self.driver).randomData("number", 3))
     self.type(NewCustomerEntity().get_phone_input(index, flag, "phone"), BasePage(self.driver).randomData("number", 7))
     self.drop_select(NewCustomerEntity().get_phone_type(index, flag), type)
示例#7
0
 def address(self,sectionName,addressType,stateCode):
     """
     #Address Information
     :param sectionName,addressType,address1,city,stateCode,postalCode
     :return:
     """
     self.click(NewCustomerEntity().get_add_remove(sectionName))
     self.type(CustomerRecordEntity().get_field_input("address1"), BasePage(self.driver).randomData("string", 6))
     self.drop_select(CustomerRecordEntity().get_field_select("addressType"),addressType)
     self.type(CustomerRecordEntity().get_field_input("city"),BasePage(self.driver).randomData("string", 6))
     self.drop_select(CustomerRecordEntity().get_field_select("stateCode"), stateCode)
     self.type(CustomerRecordEntity().get_field_input("postalCode"), BasePage(self.driver).randomData("number", 5))
示例#8
0
 def validate_required(self,entityType,entityClass,flag):
     if self.is_newCustomer_page():
         self.drop_select(NewCustomerEntity().get_field_select("typeName"), entityType)
         self.drop_select(NewCustomerEntity().get_field_select("entityClass"), entityClass)
         if flag == "Business Entity":
             self.click(NewCustomerEntity.save)
             self.sleep(1)
             if entityType == "Person":
                 if entityClass == "Household":
                     if "Required but Missing Fields:Business Entity:Full Name, Default Sort" in self.get_required_msg():
                         return True
                     else:
                         return False
                 else:
                     if "Required but Missing Fields:Business Entity:First Name, Last Name" in self.get_required_msg():
                         return True
                     else:
                         return False
             else:
                 if "Required but Missing Fields:Business Entity:Organization Name" in self.get_required_msg():
                     return True
                 else:
                     return False
         else:
             self.type(NewCustomerEntity().get_field_input("firstName"),
                       BasePage(self.driver).randomData("string", 6))
             self.type(NewCustomerEntity().get_field_input("lastName"),
                       BasePage(self.driver).randomData("string", 6))
             if flag == "Contact":
                 self.drop_select(NewCustomerEntity().get_contact_select(1, "salutation"), "Ms.")
                 self.drop_select(NewCustomerEntity().get_email_type(1), "Personal")
                 self.type(NewCustomerEntity().get_phone_input(1, 1, "ext"),
                           BasePage(self.driver).randomData("string", 6))
                 self.click(NewCustomerEntity.save)
                 self.sleep(1)
                 if "Required but Missing Fields:Contact 1:First Name, Last Name, Contact RoleContact 1 Email:Email AddressContact 1 Phone 1:Area Code, Phone, Phone Type" \
                         in self.get_required_msg():
                     return True
                 else:
                     return False
             elif flag == "Address&Identifier":
                 self.click(NewCustomerEntity().get_add_remove("Address"))
                 self.drop_select(CustomerRecordEntity().get_field_select("country"), "USA")
                 self.click(NewCustomerEntity().get_add_remove("Identifier"))
                 self.drop_select(CustomerRecordEntity.identifierName, "SSN")
                 self.click(NewCustomerEntity.save)
                 self.sleep(1)
                 if "Required but Missing Fields:Address:Address1, Address Type, CityIdentifier:Identifier" in self.get_required_msg():
                     return True
                 else:
                     return False
示例#9
0
 def  business_entity(self,entityType,entityClass,salutation,suffix,typeOfBusiness,stateOfIncorporation):
     """
       #new multiple type customer
       :param  type,className
       :param  salutation,firstName,lastName,suffix,fullName,default_sort,organizationName,typeOfBusiness,stateOfIncorporation
       :return:
     """
     if self.is_newCustomer_page()== True:
         if self.exist_element(NewCustomerEntity.confirm_dialog):
                 self.refresh_page()
                 # self.click(NewCustomerEntity().get_leave("Cancel"))
         self.drop_select(NewCustomerEntity().get_field_select("typeName"), entityType)
         self.drop_select(NewCustomerEntity().get_field_select("entityClass"), entityClass)
         randomData = BasePage(self.driver).randomData("string", 6)
         if entityType == "Person":
             if entityClass == "Household":
                 self.type(NewCustomerEntity().get_field_input("fullName"), randomData)
                 self.type(NewCustomerEntity().get_field_input("soundEx"), randomData)
             else:
                 self.drop_select(NewCustomerEntity().get_field_select("salutation"), salutation)
                 self.type(NewCustomerEntity().get_field_input("firstName"), randomData)
                 self.type(NewCustomerEntity().get_field_input("middleName"), randomData)
                 self.type(NewCustomerEntity().get_field_input("lastName"), randomData)
                 self.drop_select(NewCustomerEntity().get_field_select("suffix"), suffix)
         else:
             self.type(NewCustomerEntity().get_field_input("organizationName"), randomData)
             if entityClass == "Company" or entityClass == "Government":
                 self.drop_select(NewCustomerEntity().get_field_select("subClassName"), typeOfBusiness)
             self.drop_select(NewCustomerEntity().get_field_select("stateOfIncorporation"), stateOfIncorporation)
示例#10
0
 def interest(self, interestClass, interestStatus):
     self.drop_select(LandCommonEntity().get_field_select("class"),
                      interestClass)
     self.ctrl_all(LandCommonEntity().get_field_input("percent"))
     self.type(LandCommonEntity().get_field_input("percent"),
               BasePage(self.driver).randomData("number", 2))
     self.drop_select(LandCommonEntity().get_field_select("status"),
                      interestStatus)
     self.ctrl_all(LandCommonEntity().get_field_textarea("comment"))
     self.type(LandCommonEntity().get_field_textarea("comment"),
               BasePage(self.driver).randomData("string", 6))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#11
0
 def location(self, legalAccessIndicator, withinCityIndicator):
     self.ctrl_all(LandCommonEntity().get_input_special("street1"))
     self.type(LandCommonEntity().get_input_special("street1"),
               BasePage(self.driver).randomData("string", 6))
     self.ctrl_all(LandCommonEntity().get_textarea_specail("directions"))
     self.type(LandCommonEntity().get_textarea_specail("directions"),
               BasePage(self.driver).randomData("string", 6))
     self.drop_select(LandCommonEntity().get_field_select("legalAccess"),
                      legalAccessIndicator)
     self.drop_select(LandCommonEntity().get_field_select("withinCity"),
                      withinCityIndicator)
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
 def test_04_customer_address(self):
     u"""validate have no access for new/edit/delete entity"""
     SystemLogin(self.driver).switch_account('*****@*****.**',
                                             'Abc1234%')
     HomePage(self.driver).quick_entrance("Customers", "C000048473", 2)
     BasePage(self.driver).switch_to_handle(1)
     CustomerRecordPage(self.driver).switch_tab("Entity")
     CustomerRecordPage(self.driver).entity_operator("Addresses", "New", "")
     self.assertTrue(CustomerRecordPage(self.driver).validate_permission())
     CustomerRecordPage(self.driver).entity_operator(
         "Addresses", "Edit", "1")
     self.assertTrue(CustomerRecordPage(self.driver).validate_permission())
     CustomerRecordPage(self.driver).entity_operator(
         "Addresses", "Delete", "1")
     self.assertTrue(CustomerRecordPage(self.driver).validate_permission())
     BasePage(self.driver).close_current_window()
示例#13
0
 def identifier(self,sectionName,type):
     """
     #Identifier
     :param sectionName,type,identifierNo
     :return:
     """
     self.click(NewCustomerEntity().get_add_remove(sectionName))
     self.drop_select(CustomerRecordEntity.identifierName,type)
     if type == "SSN" or type == "Federal EIN":
         self.type(CustomerRecordEntity.identifier,BasePage(self.driver).randomData("number", 9))
     elif type == "State Tax ID":
         self.type(CustomerRecordEntity.identifier, BasePage(self.driver).randomData("number", 11))
     elif type == "Agency ID":
         self.type(CustomerRecordEntity.identifier, BasePage(self.driver).randomData("number", 4))
     else :
         self.type(CustomerRecordEntity.identifier, BasePage(self.driver).randomData("number", 6))
 def test_07_DBA_new(self):
     u"""new a DBA"""
     BasePage(self.driver).refresh_page()
     CustomerRecordPage(self.driver).entity_operator(
         "Doing Business As (DBA)", "New", "")
     self.assertTrue(
         CustomerRecordPage(self.driver).input_DBA_Website("alias"))
示例#15
0
 def EventCalendar(self, eventType):
     self.ctrl_all(LandCommonEntity().get_field_input("eventDate"))
     self.type(LandCommonEntity().get_field_input("eventDate"), CurrentDate)
     self.enter(LandCommonEntity().get_field_input("eventDate"))
     self.ctrl_all(LandCommonEntity().get_field_input("eventName"))
     self.type(LandCommonEntity().get_field_input("eventName"),
               BasePage(self.driver).randomData("string", 6))
     self.drop_select(LandCommonEntity().get_field_select("eventType"),
                      eventType)
     self.ctrl_all(LandCommonEntity().get_field_textarea("description"))
     self.type(LandCommonEntity().get_field_textarea("description"),
               BasePage(self.driver).randomData("string", 6))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#16
0
 def locationCountySeat(self, directionFromCountySeat,
                        deviationFromCountySeat):
     self.drop_select(LandCommonEntity().get_field_select("direction"),
                      directionFromCountySeat)
     self.ctrl_all(LandCommonEntity().get_input_special("distance"))
     self.type(LandCommonEntity().get_input_special("distance"),
               BasePage(self.driver).randomData("number", 1))
     self.drop_select(LandCommonEntity().get_field_select("deviation"),
                      deviationFromCountySeat)
     self.ctrl_all(LandCommonEntity().get_input_special("degree"))
     self.type(LandCommonEntity().get_input_special("degree"),
               BasePage(self.driver).randomData("number", 1))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#17
0
 def Appraisal(self,source,estimatedValueMethod):
     self.ctrl_all(LandCommonEntity().get_field_input("appraisalDate"))
     self.type(LandCommonEntity().get_field_input("appraisalDate"),currentDate)
     self.enter(LandCommonEntity().get_field_input("appraisalDate"))
     self.ctrl_all(LandCommonEntity().get_field_input("appraisedAcres"))
     self.type(LandCommonEntity().get_field_input("appraisedAcres"), BasePage(self.driver).randomData("number", 2))
     self.ctrl_all(LandCommonEntity().get_field_input("totalMarketValue"))
     self.type(LandCommonEntity().get_field_input("totalMarketValue"), BasePage(self.driver).randomData("number", 2))
     self.ctrl_all(LandCommonEntity().get_field_input("landValue"))
     self.type(LandCommonEntity().get_field_input("landValue"), BasePage(self.driver).randomData("number", 2))
     self.ctrl_all(LandCommonEntity().get_field_input("buildingValue"))
     self.type(LandCommonEntity().get_field_input("buildingValue"), BasePage(self.driver).randomData("number", 2))
     self.ctrl_all(LandCommonEntity().get_field_input("improvementValue"))
     self.type(LandCommonEntity().get_field_input("improvementValue"), BasePage(self.driver).randomData("number", 2))
     self.ctrl_all(LandCommonEntity().get_field_input("appraisalNumber"))
     self.type(LandCommonEntity().get_field_input("appraisalNumber"), BasePage(self.driver).randomData("number", 2))
     self.drop_select(LandCommonEntity().get_field_select("source"), source)
     self.drop_select(LandCommonEntity().get_field_select("methodProperty"),estimatedValueMethod)
     self.ctrl_all(LandCommonEntity().get_field_input("mineralValue"))
     self.type(LandCommonEntity().get_field_input("mineralValue"),BasePage(self.driver).randomData("number", 2))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#18
0
 def identifier_not_BAN_input(self, type):
     """
     # Identifier Name Without BAN input
     :param : type
     :return:
     """
     if type == "SSN" or type == "Federal EIN":
         self.type(CustomerRecordEntity.identifier,
                   BasePage(self.driver).randomData("number", 9))
     elif type == "State Tax ID":
         self.type(CustomerRecordEntity.identifier,
                   BasePage(self.driver).randomData("number", 11))
     elif type == "Agency ID":
         self.type(CustomerRecordEntity.identifier,
                   BasePage(self.driver).randomData("number", 4))
     elif type == "Internal GLO ID" or type == "Unknown":
         self.type(CustomerRecordEntity.identifier,
                   BasePage(self.driver).randomData("number", 6))
 def test_01_usm(self):
     u"""validate have no access for user management"""
     BasePage(self.driver).refresh_page()
     TopMenuPage(self.driver).is_homepage()
     SystemLogin(self.driver).switch_account('*****@*****.**',
                                             'Abc1234%')
     TopMenuPage(self.driver).select_multiple_menu(
         2, "manage", "Authorization Management", "", "")
     self.assertTrue(CustomerRecordPage(self.driver).validate_permission())
示例#20
0
 def characteristics(self, improvementsIndicator,
                     utilitiesAvailableIndicator):
     self.drop_select(
         LandCommonEntity().get_field_select("hasImprovements"),
         improvementsIndicator)
     self.ctrl_all(LandCommonEntity().get_input_special("topography"))
     self.type(LandCommonEntity().get_input_special("topography"),
               BasePage(self.driver).randomData("string", 6))
     self.drop_select(
         LandCommonEntity().get_field_select("utilitiesAvailable"),
         utilitiesAvailableIndicator)
     self.ctrl_all(LandCommonEntity().get_input_special("zoning"))
     self.type(LandCommonEntity().get_input_special("zoning"),
               BasePage(self.driver).randomData("string", 6))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#21
0
 def comments(self, commentClass):
     self.drop_select(LandCommonEntity().get_field_select("commentClass"),
                      commentClass)
     self.ctrl_all(LandCommonEntity().get_field_textarea("comment"))
     self.type(LandCommonEntity().get_field_textarea("comment"),
               BasePage(self.driver).randomData("string", 6))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#22
0
 def input_DBA_Website(self, name):
     """
     #DBA,Websites
     :param: name : alias, url
     :return:
     """
     self.ctrl_all(CustomerRecordEntity().get_field_input(name))
     if name == "url":
         self.type(
             CustomerRecordEntity().get_field_input(name), "http://www." +
             BasePage(self.driver).randomData("string", 10) + ".com")
     elif name == "alias":
         self.type(CustomerRecordEntity().get_field_input(name),
                   BasePage(self.driver).randomData("string", 20))
     self.click(CustomerRecordEntity.save)
     # msg = self.get_tips_msg()
     if "successfully" in self.get_tips_msg():
         return True
     else:
         return False
示例#23
0
 def counties(self, county, state):
     self.drop_select(LandCommonEntity().get_field_select("name"), county)
     self.drop_select(LandCommonEntity().get_field_select("state"), state)
     self.ctrl_all(LandCommonEntity().get_field_input("acres"))
     self.type(LandCommonEntity().get_field_input("acres"),
               BasePage(self.driver).randomData("number", 3))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#24
0
 def utilities(self, utilityType):
     self.drop_select(LandCommonEntity().get_field_select("propertyClass"),
                      utilityType)
     self.ctrl_all(LandCommonEntity().get_textarea_specail("note"))
     self.type(LandCommonEntity().get_textarea_specail("note"),
               BasePage(self.driver).randomData("string", 6))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#25
0
 def operator_email(self, type, isPrimary):
     """
     # Contact Email
     :param : email,type,isPrimary
     :return:
     """
     self.ctrl_all(CustomerRecordEntity().get_field_input("emailAddress"))
     self.type(
         CustomerRecordEntity().get_field_input("emailAddress"),
         BasePage(self.driver).randomData("string", 6) + "@" +
         BasePage(self.driver).randomData("string", 4) + ".com")
     self.drop_select(CustomerRecordEntity().get_field_select("emailType"),
                      type)
     self.drop_select(CustomerRecordEntity().get_field_select("isPrimary"),
                      isPrimary)
     self.click(CustomerRecordEntity.save)
     # msg = self.get_tips_msg()
     if 'successfully' in self.get_tips_msg():
         return True
     else:
         return False
示例#26
0
 def encumbrance(self, encumbranceClass):
     self.drop_select(
         LandCommonEntity().get_field_select("encumbranceClass"),
         encumbranceClass)
     self.ctrl_all(LandCommonEntity().get_textarea_specail("description"))
     self.type(LandCommonEntity().get_textarea_specail("description"),
               BasePage(self.driver).randomData("string", 6))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#27
0
 def utilization(self, utilizationClass, utilizationType):
     self.drop_select(LandCommonEntity().get_field_select("propertyClass"),
                      utilizationClass)
     self.drop_select(LandCommonEntity().get_field_select("type"),
                      utilizationType)
     self.ctrl_all(LandCommonEntity().get_field_input("percent"))
     self.type(LandCommonEntity().get_field_input("percent"),
               BasePage(self.driver).randomData("number", 2))
     self.click(LandCommonEntity().get_land_button("Save"))
     if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
         return True
     else:
         return False
示例#28
0
 def operator_address(self, addressType, stateCode):
     """
     # Address
     :param : type,identifierNo
     :return:
     """
     self.drop_select(
         CustomerRecordEntity().get_field_select("addressType"),
         addressType)
     self.ctrl_all(CustomerRecordEntity().get_field_input("address1"))
     self.type(CustomerRecordEntity().get_field_input("address1"),
               BasePage(self.driver).randomData("string", 6))
     self.ctrl_all(CustomerRecordEntity().get_field_input("city"))
     self.type(CustomerRecordEntity().get_field_input("city"),
               BasePage(self.driver).randomData("string", 6))
     self.drop_select(CustomerRecordEntity().get_field_select("stateCode"),
                      stateCode)
     self.click(CustomerRecordEntity.save)
     # msg = self.get_tips_msg()
     if "successfully" in self.get_tips_msg():
         return True
     else:
         return False
示例#29
0
    def dispositionPlan(self, flag, dispositionAttribute):
        if flag == 1:
            self.drop_select(
                LandCommonEntity().get_field_select("attributes1"),
                dispositionAttribute)
            self.type(LandCommonEntity().get_input_special("comment1"),
                      BasePage(self.driver).randomData("string", 6))
            self.drop_select(
                LandCommonEntity().get_field_select("attributes2"),
                dispositionAttribute)
            self.type(LandCommonEntity().get_input_special("comment2"),
                      BasePage(self.driver).randomData("string", 6))
        else:
            self.drop_select(LandCommonEntity().get_field_select("attributes"),
                             dispositionAttribute)
            self.ctrl_all(LandCommonEntity().get_textarea_specail("comment"))
            self.type(LandCommonEntity().get_textarea_specail("comment"),
                      BasePage(self.driver).randomData("string", 6))

        self.click(LandCommonEntity().get_land_button("Save"))
        if 'successfully' in LandCommonPage(self.driver).get_tips_msg():
            return True
        else:
            return False
示例#30
0
 def contact(self,same,index,flag,role,emailType,phoneType):
     """
     #Multiple Contact Information
     :param  index,flag,firstName,lastName,role,emailType,email,areaCode,phone,type
     :return:
     """
     if index == 3:
         self.click(NewCustomerEntity().get_add_remove("Contact 2"))
     if same is False:
         self.type(NewCustomerEntity().get_contact_input(index, "firstName"), BasePage(self.driver).randomData("string", 6))
         self.type(NewCustomerEntity().get_contact_input(index, "lastName"), BasePage(self.driver).randomData("string", 6))
         self.drop_select(NewCustomerEntity().get_contact_role(index), role)
     else:
         self.click(NewCustomerEntity.same_as)
     self.drop_select(NewCustomerEntity().get_email_type(index), emailType)
     self.type(NewCustomerEntity().get_email(index), BasePage(self.driver).randomData("string", 6)+"@"+
               BasePage(self.driver).randomData("string", 4)+".com")
     self.type(NewCustomerEntity().get_phone_input(index, flag, "areaCode"), BasePage(self.driver).randomData("number", 3))
     self.type(NewCustomerEntity().get_phone_input(index, flag, "phone"), BasePage(self.driver).randomData("number", 7))
     self.drop_select(NewCustomerEntity().get_phone_type(index, flag), phoneType)