I would like to create a custom field in django that models an ordinary text file editor but interacts with the the file system instead of the database.
For example:
class FileEditorField(models.TextField):
#...
class Params(models.Model):
name = models.CharField(max_length=100)
config = FileEditorField(path='/path')
FileEditor would read/save values from/to the file system.
What is the simplest approach?
Allright! This turned out to be easier than I thought. The idea was to create a new custom model field (docs) as follows: