summaryrefslogtreecommitdiffstats
path: root/ogcp/forms/action_forms.py
diff options
context:
space:
mode:
authorJavier Sánchez Parra <jsanchez@soleta.eu>2022-07-01 10:36:20 +0200
committerJavier Sánchez Parra <jsanchez@soleta.eu>2022-07-04 15:34:02 +0200
commitc068bd21448c2e202720a9daf2923a375c96370d (patch)
treec893d4908ad306218f0c8e5af2e68eb99cdac55b /ogcp/forms/action_forms.py
parent9a6981d289865b3a22c645718e0e90865ea14638 (diff)
Create "Add Repository" form and view
Creates "Add repository" form with the required inputs: name and IP.
Diffstat (limited to 'ogcp/forms/action_forms.py')
-rw-r--r--ogcp/forms/action_forms.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/ogcp/forms/action_forms.py b/ogcp/forms/action_forms.py
index 1ee7b72..b1da58b 100644
--- a/ogcp/forms/action_forms.py
+++ b/ogcp/forms/action_forms.py
@@ -185,3 +185,10 @@ class ImageDetailsForm(FlaskForm):
modified = StringField(label=_l('Modified'))
permissions = StringField(label=_l('Permissions'))
software_id = StringField(label=_l('Software id'))
+
+class RepositoryForm(FlaskForm):
+ name = StringField(label=_l('Name'),
+ validators=[InputRequired()])
+ ip = StringField(label=_l('IP'),
+ validators=[InputRequired()])
+ submit = SubmitField(label=_l('Submit'))