Sfoglia il codice sorgente

:recycle: Finished refactor on Chat reveal functionality

tags/0.0.3^2
tomit4 3 anni fa
parent
commit
6481f412c8

+ 1
- 0
backend/lib/routes/membership/reveal.js Vedi File

@@ -81,6 +81,7 @@ module.exports = {
81 81
                         {
82 82
                             name: 'REVEALED_INFO',
83 83
                             revealed_info: revealInfo,
84
+                            profile_id: completeProfile[0].profile_id,
84 85
                             grouping_id: grouping_id,
85 86
                             tag: tag_id,
86 87
                             description: tag_description,

+ 1
- 0
frontend/src/services/notification.service.js Vedi File

@@ -51,6 +51,7 @@ class StonkAlert extends Toaster {
51 51
             const tagFromNotification = {
52 52
                 is_active: 1,
53 53
                 tag_category: "reveal",
54
+                profile_id: parsed.profile_id,
54 55
                 tag_description: parsed.description,
55 56
                 tag_id: parsed.tag,
56 57
             }

+ 7
- 2
frontend/src/views/ChatView.vue Vedi File

@@ -2,8 +2,13 @@
2 2
 main.view--chat
3 3
     header.mb6(v-if='profile && grouping')
4 4
         h3 chatting with:
5
-        p {{ target.profile_id }} | {{ grouping.profile.user_name }} | {{ grouping.profile.user_email }}
6
-
5
+        span {{ target.profile_id }} | 
6
+        span(v-if="grouping.revealedFromNotification.length")
7
+            span(v-for="revealed in grouping.revealedFromNotification")
8
+                span(v-if="revealed.profile_id === target.profile_id")
9
+                    span {{ revealed[revealed.tag_description] }} | 
10
+        span(v-else)
11
+            span  {{ grouping.profile.user_name }} | {{ grouping.profile.user_email }}
7 12
         h3 logged in as:
8 13
         p {{ profile.id }} | {{ profile._profile.user_name }} | {{ profile._profile.user_email }}
9 14
         //- p subscriptions: {{ profile.chatter.subscriptions }}

Loading…
Annulla
Salva