def record_model(self, model): """Record the given model.""" DataConnector.record_model(self, model) name = DataConnector.record_model(self, model) self.collections[name] = self.datas[name] self.inc_collections[name] = self.increments[name] self.object_ids[name] = {}
def record_model(self, model): """Record the given model.""" name = DataConnector.record_model(self, model) filename = self.location + "/" + name + ".yml" if os.path.exists(filename): with open(filename, "r") as file: self.read_table(name, file) self.files[name] = filename
def record_model(self, model): """Record the given model.""" name = DataConnector.record_model(self, model) filename = self.location + "/" + name + ".yml" if os.path.exists(filename): with open(filename, "r") as file: self.read_table(name, file) self.files[name] = filename
def record_model(self, model): """Record a single model.""" DataConnector.record_model(self, model) name = get_plural_name(model) if name not in self.created_tables: self.create_table(name, model)
def record_model(self, model): """Record a single model.""" DataConnector.record_model(self, model) name = get_plural_name(model) if name not in self.created_tables: self.create_table(name, model)