shuttlepro-shared 1.5.19 → 1.5.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -17,6 +17,19 @@ const EmailFeedbackReportSchema = new Schema(
|
|
|
17
17
|
ref: "Conversation",
|
|
18
18
|
required: true,
|
|
19
19
|
},
|
|
20
|
+
// Last agent (user) who replied before feedback was triggered
|
|
21
|
+
agentId: {
|
|
22
|
+
type: Schema.Types.ObjectId,
|
|
23
|
+
ref: "User",
|
|
24
|
+
default: null,
|
|
25
|
+
},
|
|
26
|
+
// Workspace labels (admin-only to assign)
|
|
27
|
+
labels: [
|
|
28
|
+
{
|
|
29
|
+
type: Schema.Types.ObjectId,
|
|
30
|
+
ref: "Label",
|
|
31
|
+
},
|
|
32
|
+
],
|
|
20
33
|
email: {
|
|
21
34
|
type: String,
|
|
22
35
|
required: true,
|
|
@@ -109,6 +122,8 @@ const EmailFeedbackReportSchema = new Schema(
|
|
|
109
122
|
EmailFeedbackReportSchema.index({ workspaceId: 1, email: 1, createdAt: -1 });
|
|
110
123
|
EmailFeedbackReportSchema.index({ conversationId: 1 });
|
|
111
124
|
EmailFeedbackReportSchema.index({ chatbotId: 1 });
|
|
125
|
+
EmailFeedbackReportSchema.index({ agentId: 1 });
|
|
126
|
+
EmailFeedbackReportSchema.index({ labels: 1 });
|
|
112
127
|
EmailFeedbackReportSchema.index({ status: 1 });
|
|
113
128
|
EmailFeedbackReportSchema.index({ workspaceId: 1, email: 1, orderId: 1 });
|
|
114
129
|
|