Commit 71a67547 authored by Manuel's avatar Manuel

[business-logic] fixed yaml file and syntax errors

parent 374480da
......@@ -47,12 +47,11 @@ paths:
summary: "Delete all Use-Cases"
description: "Delete all Use-Cases"
parameters:
- name: "confirmation"
desciption: "'yes' to confirm deletion"
in: "query"
- in: query
name: confirmation
type: string
required: true
schema:
type: "string"
description: "'yes' to confirm deletion"
responses:
'200':
description: "Successful Request"
......@@ -82,12 +81,11 @@ paths:
summary: "Delete all Tables"
description: "Delete all Tables"
parameters:
- name: "confirmation"
desciption: "'yes' to confirm deletion"
in: "query"
- in: query
name: confirmation
type: string
required: true
schema:
type: "string"
description: "'yes' to confirm deletion"
responses:
'200':
description: "Successful Request"
......@@ -149,12 +147,11 @@ paths:
description: "Name of the Use-Case the Table belongs to"
required: true
type: "string"
- name: "confirmation"
desciption: "'yes' to confirm deletion"
in: "query"
- in: query
name: confirmation
type: string
required: true
schema:
type: "string"
description: "'yes' to confirm deletion"
responses:
'200':
description: "Successful Request"
......@@ -194,8 +191,6 @@ paths:
# END-TABLES
#####
#####
# LAYERS
#####
......@@ -220,12 +215,11 @@ paths:
summary: "Delete all Layers from the DB"
description: "Delete all Layers from the DB"
parameters:
- name: "confirmation"
desciption: "'yes' to confirm deletion"
in: "query"
- in: query
name: confirmation
type: string
required: true
schema:
type: "string"
description: "'yes' to confirm deletion"
responses:
'200':
description: "Successful Request"
......@@ -351,12 +345,11 @@ paths:
type: string
example: "end_time"
description: "Internal name of the attribute"
- name: "confirmation"
desciption: "'yes' to confirm deletion"
in: "query"
- in: query
name: confirmation
type: string
required: true
schema:
type: "string"
description: "'yes' to confirm deletion"
responses:
'200':
description: "Successful Request"
......@@ -440,12 +433,11 @@ paths:
description: "Name of the Layer"
required: true
type: "string"
- name: "confirmation"
desciption: "'yes' to confirm deletion"
in: "query"
- in: query
name: confirmation
type: string
required: true
schema:
type: "string"
description: "'yes' to confirm deletion"
responses:
'200':
description: "Successful Request"
......@@ -509,12 +501,11 @@ paths:
required: true
schema:
$ref: '#/definitions/LayerMapping'
- name: "confirmation"
desciption: "'yes' to confirm deletion"
in: "query"
- in: query
name: confirmation
type: string
required: true
schema:
type: "string"
description: "'yes' to confirm deletion"
responses:
'200':
description: "Successful Request"
......
......@@ -23,7 +23,7 @@ def delete_all_layers(confirmation: str):
@params:
confirmation - Required : "yes" to confirm deletion
'''
if confirmation != "yes"
if confirmation != "yes":
return Response(status=403)
layer_repository.delete_all()
......@@ -223,7 +223,7 @@ def delete_one(use_case: str, table: str, name: str, confirmation: str):
name - Required : unique identifier for the Layer
confirmation- Required : "yes" to confirm deletion
'''
if confirmation != "yes"
if confirmation != "yes":
return Response(status=403)
layer = layer_repository.one(name, use_case, table)
......
......@@ -53,15 +53,15 @@ def add_complete(use_case: str):
def delete_all_for_use_case(use_case: str, confirmation: str):
if confirmation != "yes"
if confirmation != "yes":
return Response(status=403)
table_repository.delete_for_use_case(use_case)
return Response(status=200)
def delete_all():
def delete_all(confirmation: str):
if confirmation != "yes"
if confirmation != "yes":
return Response(status=403)
table_repository.delete_all()
......
......@@ -17,7 +17,7 @@ def all():
def delete_all(confirmation: str):
if confirmation != "yes"
if confirmation != "yes":
return Response(status=403)
use_case_repository.delete_all()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment