A simpler way to view django projects
captures the foreign key fields
1 file changed, +1 -1
+1-1src/regex.ts
| @@ -3,5 +3,5 @@ export default { | ||
| 3 | 3 | appContainer: /INSTALLED_APPS = \[([\s\S]*?)\]/, |
| 4 | 4 | module: /'([\.\w]+)'/gm, |
| 5 | 5 | model: /class (\w+).*models.Model.*:([\s\S]*?)\n\n/gm, |
| 6 | - modelField: /(\w+) = .*\.(\w+)Field/gm, | |
| 6 | + modelField: /(\w+) = .*\.(\w*[(Field)|(ForeignKey)])/gm, | |
| 7 | 7 | }; |