def _init_brand(self): brands = brand_handler.get_all_brand() for brand in brands: self.brand_combo.addItem(brand[1], brand[0]) if brands: brand_id = brands[0][0] self._refresh_model(brand_id)
def _init_brand(self): brands = brand_handler.get_all_brand() for brand in brands: self.brand_combo.addItem(brand[1], brand[0]) if brands: brand_id = brands[0][0] self._refresh_model(brand_id) self.brand_combo.currentIndexChanged.connect(self._brand_index_changed)
def _init_brand(self): brands = brand_handler.get_all_brand() for brand in brands: self.brand_combo.addItem(brand[1], brand[0]) if brands: brand_id = brands[0][0] self._refresh_model(brand_id) completer = QCompleter(brand_and_model_service.get_all_brand()) completer.setCaseSensitivity(Qt.CaseInsensitive) self.brand_combo.setCompleter(completer)
def _get_all_brand(): brands = [] for brand in brand_handler.get_all_brand(): brands.append(brand[1]) return brands
def get_all_brand(): brands = [] for brand in brand_handler.get_all_brand(): brands.append(brand['brand_name']) return brands