Update the template_schema to include a parent_folder_id.

When creating the Tempalte from_json, the folder is passed in. Since some validation should done, as in the folder exists and is for the same service, the folder is passed through to the Tempalte.from_json method.
When the template is persisted so is the relationship to folders.
TODO: If the folder is invalid a specific message should be returned.
This commit is contained in:
Rebecca Law
2018-11-05 10:54:42 +00:00
committed by Rebecca Law
parent 39198ed67e
commit 4849ecdf63
4 changed files with 71 additions and 7 deletions

View File

@@ -16,7 +16,8 @@ post_create_template_schema = {
"process_type": {"emun": TEMPLATE_PROCESS_TYPE},
"content": {"type": "string"},
"subject": {"type": "string"},
"created_by": uuid
"created_by": uuid,
"parent_folder_id": uuid
},
"if": {
"properties": {