def _pay_for_sale(self, employee: str = None, cashbox: str = None, comment: str = None):
     self.__sales_payment_dialog.should(be.visible)
     if employee:
         set_select_option(self.__sales_payment_employee_select(), employee)
     if cashbox:
         set_select_option(self.__sales_payment_cashbox_select(), cashbox)
     if comment:
         self.__sales_payment_comment_input.set_value(comment)
     self.__sales_payment_submit_button.should(be.clickable).click()
     self.__sales_payment_dialog.should(be.not_.visible)
Example #2
0
 def __set_registration_data(self):
     data = REGISTRATION_DATA
     first_name = data['first_name']
     last_name = data['last_name']
     self.__first_name_input.with_(Config(timeout=10)).should(
         be.visible).set_value(first_name)
     self.__last_name_input.set_value(last_name)
     self.__company_name_input.set_value(data['company_name'])
     set_select_option(
         browser.element(self.__country_select)(), data['country'])
     self.__city_input.set_value(data['city'])
     self.__phone_input.click().type(data['phone'])
     set_select_option(
         browser.element(self.__template_select)(), data['template'])
     return {'first_name': first_name, 'last_name': last_name}
Example #3
0
 def select_stock_to(self, stock_name):
     self.__movement_select_to.should(be.clickable)
     set_select_option(self.__movement_select_to(), stock_name)
Example #4
0
 def __set_stock(self, stock_name):
     set_select_option(self.__stock_select(), stock_name)
     s(PRELOADER_SPINNER).should(be.not_.visible)
 def _set_stock(self, stock_name=None):
     set_select_option(self.__sales_dialog_warehouse_select(), stock_name or self.__stock_name)
Example #6
0
 def _fill_posting_data(self, supplier: str, stock: str):
     self.set_supplier(supplier)
     set_select_option(s(self.__warehouse_select)(), stock)