Skip to content
Snippets Groups Projects
Commit 2d7d8ec1 authored by Sabine Schröder's avatar Sabine Schröder
Browse files

#3, #11, #12: typos fixed in extension, do not show patch schemas in...

#3, #11, #12: typos fixed in extension, do not show patch schemas in documentation (pages), added more descriptions for schema fields (to be continued)
parent 61a8c244
No related branches found
No related tags found
No related merge requests found
Pipeline #59730 passed
......@@ -13,10 +13,12 @@ if len(sys.argv) == 2:
if (key == 'post' or key == 'patch'):
paths[path].pop(key)
# do not show "create" objects in user documentation
# do not show "create" or "patch" objects in user documentation
schemas = fastapi['components']['schemas'].copy()
for key in fastapi['components']['schemas'].keys():
if (('create' in key.lower()) or ('error' in key.lower())):
if (('create' in key.lower())
or ('patch' in key.lower())
or ('error' in key.lower())):
schemas.pop(key)
# Serializing json
fastapi['paths'] = paths
......
This diff is collapsed.
--
-- toardb/extension/toar_controlled_vocabulary/toar_controlled_vocabulary--0.3.sql
-- toardb/extension/toar_controlled_vocabulary/toar_controlled_vocabulary--0.3.5.sql
--
-- [Step to install]
--
-- 1.
--
-- INSTALL VERSION: '0.3'
-- INSTALL VERSION: '0.3.5'
-- complain if script is sourced in psql, rather than via CREATE EXTENSION
\echo Use "CREATE EXTENSION toar_controlled_vocabulary" to load this file. \quit
......
--
-- toardb/extension/toar_controlled_vocabulary/toar_controlled_vocabulary--0.3.6.sql
--
-- [Step to install]
--
-- 1.
--
-- INSTALL VERSION: '0.3.6'
-- complain if script is sourced in psql, rather than via CREATE EXTENSION
\echo Use "CREATE EXTENSION toar_controlled_vocabulary" to load this file. \quit
-- Update Countries
-- ================
-- Country names
UPDATE CN_vocabulary SET enum_display_str='United Republic of Tanzania' WHERE enum_display_str='Tanzania, United Republic of';
--
-- toardb/extension/toar_controlled_vocabulary/toar_controlled_vocabulary--0.3.sql
-- toardb/extension/toar_controlled_vocabulary/toar_controlled_vocabulary--0.3.5.sql
--
-- [Step to install]
--
-- 1.
--
-- INSTALL VERSION: '0.2.5'
-- INSTALL VERSION: '0.3.5'
-- complain if script is sourced in psql, rather than via CREATE EXTENSION
\echo Use "CREATE EXTENSION toar_controlled_vocabulary" to load this file. \quit
......
This diff is collapsed.
# toar_controlled_vocabulary extension
comment = 'TOAR controlled vocabulary'
default_version = '0.3.5'
module_pathname = '$libdir/toar_controlled_vocabulary-0.3.5'
default_version = '0.3.6'
module_pathname = '$libdir/toar_controlled_vocabulary-0.3.6'
relocatable = false
......@@ -27,15 +27,15 @@ class Coordinates(BaseModel):
class StationmetaCoreBase(BaseModel):
id: int = None
codes: List[str] = Field(..., description="list of station's codes")
name: str
coordinates: Coordinates
coordinate_validation_status: str
country: str
state: str
type_of_environment: str
type_of_area: str
timezone: str
additional_metadata: Json
name: str = Field(..., description="Station name for use in TOAR; normally equal to data provider’s name")
coordinates: Coordinates = Field(..., description="Best estimate of station latitude, longitude and altitude")
coordinate_validation_status: str = Field(..., description="Flag indicating whether the location of a station has been verified")
country: str = Field(..., description="The country, where the station resides, or which operates the station (e.g. in Antarctica)")
state: str = Field(..., description="The state or province, where the station resides")
type_of_environment: str = Field(..., description="Type of station")
type_of_area: str = Field(..., description="Type of station area")
timezone: str = Field(..., description="Station timezone")
additional_metadata: Json = Field(..., description="Any additional metadata about the station as a JSON data structure")
class Config(BaseConfig):
orm_mode = True
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment