Selaa lähdekoodia

fix timestamp and memo display in raid, fix bad signup count

master
peter 5 vuotta sitten
vanhempi
commit
9ca1c1f354

+ 2
- 1
src/backend/Components/Raid/RaidManager.ts Näytä tiedosto

152
             .where({
152
             .where({
153
                 raidid: this.admin.knex.ref('raids.id'),
153
                 raidid: this.admin.knex.ref('raids.id'),
154
                 benched: false,
154
                 benched: false,
155
-                late: false
155
+                late: false,
156
+                absent: false
156
             })
157
             })
157
             .as('signupcount')
158
             .as('signupcount')
158
 
159
 

+ 1
- 1
src/backend/Components/User/UserManager.ts Näytä tiedosto

132
     ]
132
     ]
133
 
133
 
134
     initialize = async () => {
134
     initialize = async () => {
135
-        this.exporters = [this.guild, this.item, this.raid, this.character]
135
+        this.exporters = [this, this.guild, this.item, this.raid, this.character]
136
         //set up permissions
136
         //set up permissions
137
         getLogger('UserManager#initialize').debug('setting up permissions')
137
         getLogger('UserManager#initialize').debug('setting up permissions')
138
 
138
 

+ 0
- 4
src/frontend/src/app/frontcraft/pages/pages-layout.component.ts Näytä tiedosto

28
     icon: 'book-open-outline',
28
     icon: 'book-open-outline',
29
     title: 'Loot Rules',
29
     title: 'Loot Rules',
30
     link: '/frontcraft/rules',
30
     link: '/frontcraft/rules',
31
-  },{
32
-    icon: "shield",
33
-    title: 'Armory',
34
-    link: '/frontcraft/armory'
35
   }]
31
   }]
36
   
32
   
37
   constructor(){}
33
   constructor(){}

+ 43
- 0
src/frontend/src/app/frontcraft/pages/raid/raid.component.html Näytä tiedosto

88
                                                 [src]="'/assets/images/'+participant.class.toLowerCase()+'.png'" />
88
                                                 [src]="'/assets/images/'+participant.class.toLowerCase()+'.png'" />
89
                                             {{ participant.charactername }}
89
                                             {{ participant.charactername }}
90
                                         </a>
90
                                         </a>
91
+
91
                                         <ng-template #timeInfo>
92
                                         <ng-template #timeInfo>
92
                                             <div style="padding: 10px">
93
                                             <div style="padding: 10px">
93
                                                 {{participant.timestamp | date : 'HH:mm EEE MMM d'}}
94
                                                 {{participant.timestamp | date : 'HH:mm EEE MMM d'}}
137
                                                 [src]="'/assets/images/'+participant.class.toLowerCase()+'.png'" />
138
                                                 [src]="'/assets/images/'+participant.class.toLowerCase()+'.png'" />
138
                                             {{ participant.charactername }}
139
                                             {{ participant.charactername }}
139
                                         </a>
140
                                         </a>
141
+                                        <ng-template #timeInfo>
142
+                                            <div style="padding: 10px">
143
+                                                {{participant.timestamp | date : 'HH:mm EEE MMM d'}}
144
+                                                ({{participant.before | date : 'dd'}} days before start)
145
+                                            </div>
146
+                                        </ng-template>
147
+                                        <nb-icon [nbPopover]="timeInfo" nbPopoverTrigger="hover"
148
+                                            style="width: 0.75em; height: 0.75em;" icon="clock-outline"
149
+                                            [status]="participant.before>8.64e+7?(participant.before>2.592e+8?'success':'warning'):'danger'">
150
+                                        </nb-icon>
151
+                                        <ng-template #memoBox>
152
+                                            <div style="padding: 10px">
153
+                                                <p
154
+                                                    style="white-space: pre-line; max-width: 50vw; word-wrap: break-word;">
155
+                                                    {{participant.memo}}
156
+                                                </p>
157
+                                            </div>
158
+                                        </ng-template>
159
+                                        <nb-icon *ngIf="participant.memo" [nbPopover]="memoBox" nbPopoverTrigger="hover"
160
+                                            style="width: 0.75em; height: 0.75em;" icon="message-circle-outline">
161
+                                        </nb-icon>
140
                                         <span *ngIf="participant.rank=='Trial'" style="font-size: 9px;">
162
                                         <span *ngIf="participant.rank=='Trial'" style="font-size: 9px;">
141
                                             Trial
163
                                             Trial
142
                                         </span>
164
                                         </span>
166
                                                     [src]="'/assets/images/'+participant.class.toLowerCase()+'.png'" />
188
                                                     [src]="'/assets/images/'+participant.class.toLowerCase()+'.png'" />
167
                                                 {{ participant.charactername }}
189
                                                 {{ participant.charactername }}
168
                                             </a>
190
                                             </a>
191
+                                            <ng-template #timeInfo>
192
+                                                <div style="padding: 10px">
193
+                                                    {{participant.timestamp | date : 'HH:mm EEE MMM d'}}
194
+                                                    ({{participant.before | date : 'dd'}} days before start)
195
+                                                </div>
196
+                                            </ng-template>
197
+                                            <nb-icon [nbPopover]="timeInfo" nbPopoverTrigger="hover"
198
+                                                style="width: 0.75em; height: 0.75em;" icon="clock-outline"
199
+                                                [status]="participant.before>8.64e+7?(participant.before>2.592e+8?'success':'warning'):'danger'">
200
+                                            </nb-icon>
201
+                                            <ng-template #memoBox>
202
+                                                <div style="padding: 10px">
203
+                                                    <p
204
+                                                        style="white-space: pre-line; max-width: 50vw; word-wrap: break-word;">
205
+                                                        {{participant.memo}}
206
+                                                    </p>
207
+                                                </div>
208
+                                            </ng-template>
209
+                                            <nb-icon *ngIf="participant.memo" [nbPopover]="memoBox" nbPopoverTrigger="hover"
210
+                                                style="width: 0.75em; height: 0.75em;" icon="message-circle-outline">
211
+                                            </nb-icon>
169
                                             <span *ngIf="participant.rank=='Trial'" style="font-size: 9px;">
212
                                             <span *ngIf="participant.rank=='Trial'" style="font-size: 9px;">
170
                                                 Trial
213
                                                 Trial
171
                                             </span>
214
                                             </span>

Loading…
Peruuta
Tallenna