ManualEntries

Introduction

ManualEntries are the content of a ManualChapter.

Model Definition

Alias

ManualEntry

Relations

Key
Relation
Type
Relation Field(s)

user

Belongs to

user_id

chapter

Belongs to

chapter_id

seenUsers

Has many

manual_entry_seen_users.entry_id

notifications

Has many

notifications.event_id, notifications.event_source

reactions

Morph many

reactions.reactable_type, reactions.reactable_id

currentReaction

Morph one

reactions.reactable_type, reactions.reactable_id, reactions.user_id

Computed properties

  • hash - The hashed id of the ManualEntry.

  • seen - Whether the ManualEntry is seen by the current authenticated User.

Traits

  • Sortable

  • TriggersNotifications

List

Get a list of all ManualEntries the current authenticated User is allowed to view.

Definition

GET /api/manual/entries

Example Request

Example Response Body

List by chapter

Get a list of all ManualEntries the current authenticated User is allowed to view by ManualChapter.

Definition

GET /api/manual/chapters/{chapterId}/entries

Example Request

Example Response Body

Count

Get the count of all ManualEntries the current authenticated User is allowed to view.

Definition

GET /manual/chapters/entries/count

Example Request

Example Response Body

Count by chapter

Get the count of all ManualEntries the current authenticated User is allowed to view by ManualChapter.

Definition

GET /api/manual/chapters/{chapterId}/entries/count

Example Request

Example Response Body

Show

Show a single ManualEntry by id or hash.

Definition

GET /api/manual/chapters/entries/{idOrHash}

Example Request

Example Response Body

Create

Create a new ManualEntry by ManualChapter.

Definition

GET /api/manual/chapters/{chapterId}/entries

Request Keys

Key
Type
Default
Description

chapter_id**

integer

-

The related ManualChapter.

title*

string

-

The title of the ManualEntry.

slug

string

Slugged title

The slugged title of the ManualEntry (unique by ManualChapter).

text*

string

-

The text of the ManualEntry.

reactions_forbidden

boolean

false

Whether Reactions for the ManualEntry are forbidden.

sort_number

integer

Current highest +1

The index of the ManualEntry related to the ManualChapter.

Keys with * are required. Keys with ** are normalized to the information given by the route.

Example Request

Example Response Body

Update

Update an existing ManualEntry by id.

Definition

PUT /api/manual/chapters/entries/{id}

Request Keys

Key
Type
Description

chapter_id

integer

The related ManualChapter.

title

string

The title of the ManualEntry.

slug

string

The slugged title of the ManualEntry (unique by ManualChapter).

text

string

The text of the ManualEntry.

reactions_forbidden

boolean

Whether Reactions for the ManualEntry are forbidden.

sort_number

integer

The index of the ManualEntry related to the ManualChapter.

Example Request

Example Response Body

Delete

Delete an existing ManualEntry by id.

Definition

GET /api/manual/chapters/entries/{id}

Example Request

Example Response Body

Last updated