def _setup_pacs_models(self): self.models = {} self.models[_("All")] = whole_list(self.database.values()) try: self.models[_("foreigners")] = installed_list(self.database["foreigners"]) except KeyError: self.database["foreigners"] = [] self.models[_("foreigners")] = installed_list(self.database["foreigners"]) for repo in self.database.repos: if repo == _("foreigners"): continue self.models[repo] = {} all_mod = all_list(self.database[repo]) inst_mod = installed_list(self.database[repo]) self.models[repo][_("all")] = all_mod self.models[repo][_("installed")] = inst_mod continue return
def _setup_pacs_models(self): self.models = {} try: self.models[_("foreigners")] = installed_list(self.database["foreigners"]) except KeyError: self.database["foreigners"] = [] self.models[_("foreigners")] = installed_list(self.database["foreigners"]) for repo in self.database.keys(): if repo == _("foreigners") or repo == "local": continue self.models[repo] = {} all_mod = all_list(self.database[repo]) inst_mod = installed_list(self.database[repo]) self.models[repo][_("all")] = all_mod if repo != 'local': self.models[repo][_("installed")] = inst_mod return