~lthms/ogmios

ref: a9dfab525b5d97bf6313db5d375b3810a173d12c ogmios/src/schema.rs -rw-r--r-- 1.8 KiB View raw
a9dfab52Thomas Letan deps: Update semantic-ui 1 year, 6 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
table! {
    characters (id) {
        id -> Int4,
        entity_id -> Int4,
        owner -> Nullable<Int4>,
    }
}

table! {
    documents (id) {
        id -> Int4,
        language -> Int2,
        raw -> Text,
        rendered -> Text,
    }
}

table! {
    entities (id) {
        id -> Int4,
        role -> Int2,
    }
}

table! {
    event_participants (id) {
        id -> Int4,
        entity_id -> Int4,
        event_id -> Int4,
    }
}

table! {
    events (id) {
        id -> Int4,
        during -> Int4range,
        description -> Int4,
    }
}

table! {
    images (id) {
        id -> Int4,
        content -> Bytea,
    }
}

table! {
    relationships (id) {
        id -> Int4,
        origin -> Int4,
        destination -> Int4,
        during -> Nullable<Int4range>,
        label -> Nullable<Varchar>,
    }
}

table! {
    sheets (id) {
        id -> Int4,
        character_id -> Int4,
        created -> Timestamp,
        validated -> Nullable<Timestamp>,
        current -> Nullable<Bool>,
        future -> Nullable<Bool>,
        invalidated -> Nullable<Timestamp>,
        name -> Varchar,
        avatar_small -> Nullable<Int4>,
        avatar_large -> Nullable<Int4>,
        history -> Int4,
    }
}

table! {
    users (id) {
        id -> Int4,
        nickname -> Varchar,
        default_character -> Nullable<Int4>,
    }
}

joinable!(characters -> entities (entity_id));
joinable!(event_participants -> entities (entity_id));
joinable!(event_participants -> events (event_id));
joinable!(events -> documents (description));
joinable!(sheets -> characters (character_id));
joinable!(sheets -> documents (history));

allow_tables_to_appear_in_same_query!(
    characters,
    documents,
    entities,
    event_participants,
    events,
    images,
    relationships,
    sheets,
    users,
);