Adds MotD and Message model as well as tests
This commit adds the MotD model for storing and retrieving messages-of-the-day. It also adds a model for messages. Messages have an author as well as a thread they belong to, the thread can be read by a specific number of authors. FUrthermore, the message model supports system messages. This commit introduces a number of needed changes: - Character is now implementing the CharacterInterface - MissingCharacter and SystemCharacter are supporting "pseudo-characters" - trait MockCharacter implements non-implemented methods for MissingCharacter and SytemCharacter - Characters are now soft-deletable. Models wanting to load soft-deleted characters need to fetch them eagerly. Closes #17
This commit is contained in:
@@ -0,0 +1,43 @@
|
||||
characters:
|
||||
-
|
||||
id: 1
|
||||
name: "Testcharacter 1"
|
||||
displayName: "Testcharacter 1"
|
||||
health: 0
|
||||
maxhealth: 100
|
||||
-
|
||||
id: 2
|
||||
name: "Testcharacter 2"
|
||||
displayName: "Testcharacter 2"
|
||||
health: 90
|
||||
maxhealth: 90
|
||||
-
|
||||
id: 3
|
||||
name: "Testcharacter 1"
|
||||
displayName: "Deleted Testcharacter"
|
||||
health: 200
|
||||
maxhealth: 200
|
||||
deletedAt: "2011-11-11 11:11:11"
|
||||
motd:
|
||||
-
|
||||
id: 1
|
||||
author_id: 1
|
||||
title: "This is the title"
|
||||
body: "This is the body of the message"
|
||||
creationTime: "2016-05-03 14:19:12"
|
||||
systemMessage: false
|
||||
-
|
||||
id: 2
|
||||
author_id: 1
|
||||
title: "This is a system message"
|
||||
body: "This is the body of the system message"
|
||||
creationTime: "2016-05-04 14:19:12"
|
||||
systemMessage: true
|
||||
-
|
||||
id: 3
|
||||
author_id: 3
|
||||
title: "This is an old message."
|
||||
body: "This is an old message."
|
||||
creationTime: "2002-12-09 15:13:59"
|
||||
systemMessage: false
|
||||
|
||||
Reference in New Issue
Block a user