summaryrefslogtreecommitdiffstats
path: root/src/frest/templates/form.txt
diff options
context:
space:
mode:
Diffstat (limited to 'src/frest/templates/form.txt')
-rw-r--r--src/frest/templates/form.txt10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/frest/templates/form.txt b/src/frest/templates/form.txt
new file mode 100644
index 0000000..f4b2c14
--- /dev/null
+++ b/src/frest/templates/form.txt
@@ -0,0 +1,10 @@
+from .models import %%NAME%%
+from src.forms import ModelForm
+
+
+class %%NAME%%Form(ModelForm):
+ model = %%NAME%%
+
+ def __init__(self, data):
+ super().__init__(self.model)
+ self.data = data