Skip to content

Commit

Permalink
Merge pull request #72 from Facts-and-Files/feat/StoryPublicField
Browse files Browse the repository at this point in the history
Feat/story public field
  • Loading branch information
trenc authored Sep 27, 2023
2 parents b75f723 + f1343c9 commit f103bb4
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 5 deletions.
13 changes: 10 additions & 3 deletions src/app/Models/Story.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,17 @@ class Story extends Model

protected $primaryKey = 'StoryId';

protected $fillable = ['DatasetId', 'HasHtr', 'Dc'];
protected $fillable = [
'DatasetId',
'HasHtr',
'Dc',
'Public'
];

protected $casts = ['HasHtr' => 'boolean'];
protected $casts = [
'HasHtr' => 'boolean',
'Public' => 'boolean'
];

protected $hidden = [
'dc:title',
Expand All @@ -40,7 +48,6 @@ class Story extends Model
'DateStart',
'DateEnd',
'OrderIndex',
'Public',
'ImportName',
'edm:country',
'edm:dataProvider',
Expand Down
2 changes: 1 addition & 1 deletion src/storage/api-docs/api-docs.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
openapi: 3.0.3

info:
version: 1.17.0
version: 1.18.0
title: Transcribathon Platform API v2
description: This is the documentation of the Transcribathon API v2 used by [https:transcribathon.eu](https://transcribathon.eu/).<br />
For authorization you can use the the bearer token you are provided with.
Expand Down
6 changes: 5 additions & 1 deletion src/storage/api-docs/stories-schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,11 @@ StoriesMinimalReferenceSchema:
example: 6
HasHtr:
type: boolean
description: Marks wether the Story has items with a HTR transcription
description: Indicates whether the story has items with a HTR transcription
example: true
Public:
type: boolean
description: Indicates whether the story is public or not
example: true

StoriesAdditionalDataReferenceSchema:
Expand Down

0 comments on commit f103bb4

Please sign in to comment.