Add ability to store only relative paths in a FilePathField
|Reported by:||Owned by:||nobody|
|Component:||Database layer (models, ORM)||Version:||master|
|Cc:||eschler@…||Triage Stage:||Design decision needed|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||yes|
Add an extra option to FilePathField to cause it to only save a relative path, say called "store_relative".
Having an absolute path stored makes it harder to move data between machines that are set up differently (say development and production). In this circumstance you would typically set the path parameter from the settings file.
The "store_relative" argument could default to False to keep the current behaviour by default.
Change History (17)
comment:11 follow-up: 15 Changed 6 years ago by
|Status:||new → closed|