def ready(self): from .signals import handlers from .models.collection import CollectionBase from .admin import CollectionAdminBase # Переименование поля файла или модели-владельца файла, # изменит также и соответствующие значения, хранящиеся в БД pre_migrate.connect(handlers.inject_rename_filefield_operations, sender=self) # автоматическая регистрация моделей галерей в админке for model in apps.get_models(): if issubclass(model, CollectionBase) and not site.is_registered(model): site.register(model, CollectionAdminBase)
def test_admin(self): self.assertTrue( site.is_registered(day_totals.SplitTopicDayTotalsMQTTSettings))
def test_admin(self): self.assertTrue( site.is_registered(telegram.SplitTopicTelegramMQTTSettings))
def test_admin(self): self.assertTrue( site.is_registered( consumption.SplitTopicGasConsumptionMQTTSettings))
def test_admin(self): self.assertTrue(site.is_registered(InfluxdbIntegrationSettings))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue( site.is_registered(day_totals.SplitTopicDayTotalsMQTTSettings))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue( site.is_registered( meter_statistics.SplitTopicMeterStatisticsMQTTSettings))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue(site.is_registered(DropboxSettings))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue(site.is_registered(Note))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue(site.is_registered(EnergySupplierPrice))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue(site.is_registered(Message))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue(site.is_registered(SortedGraph))
def test_admin(self): self.assertTrue(site.is_registered(InfluxdbMeasurement))
def test_admin(self): self.assertTrue( site.is_registered( meter_statistics.SplitTopicMeterStatisticsMQTTSettings))
def test_admin(self): for current in self.CLASSES: self.assertTrue(site.is_registered(current))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue(site.is_registered(StatusNotificationSetting))
def test_admin(self): self.assertTrue(site.is_registered(GasConsumption))
def test_admin(self): self.assertTrue( site.is_registered(QuarterHourPeakElectricityConsumption))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue( site.is_registered(telegram.SplitTopicTelegramMQTTSettings))
def test_admin(self): self.assertTrue(site.is_registered(broker.MQTTBrokerSettings))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue(site.is_registered(APISettings))
def test_admin(self): """ Model should be registered in Django Admin. """ self.assertTrue(site.is_registered(PVOutputAddStatusSettings))