shuttlepro-shared 1.4.53 → 1.4.54
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.
- package/common/repositories/call.repository.js +0 -7
- package/models/Call.js +0 -1
- package/models/FeedbackResponse.js +12 -9
- package/models/Message.js +1 -0
- package/models/Step.js +8 -0
- package/models/Workspace.js +1 -0
- package/package.json +1 -1
|
@@ -109,13 +109,6 @@ class CallRepository {
|
|
|
109
109
|
);
|
|
110
110
|
}
|
|
111
111
|
|
|
112
|
-
getCallByFilter(filter) {
|
|
113
|
-
return this._safeExec(
|
|
114
|
-
Call.findOne({ filter }).lean().exec(),
|
|
115
|
-
`Failed to get call filter`
|
|
116
|
-
);
|
|
117
|
-
}
|
|
118
|
-
|
|
119
112
|
endCall(callId, updateObj = {}, history = {}) {
|
|
120
113
|
return this._safeExec(
|
|
121
114
|
Call.findOneAndUpdate(
|
package/models/Call.js
CHANGED
|
@@ -1,22 +1,16 @@
|
|
|
1
1
|
const mongoose = require("mongoose");
|
|
2
2
|
const { Schema } = mongoose;
|
|
3
|
-
|
|
4
|
-
// Load uuid dynamically since it's ESM-only
|
|
5
|
-
let uuidv4;
|
|
6
|
-
(async () => {
|
|
7
|
-
const { v4 } = await import("uuid");
|
|
8
|
-
uuidv4 = v4;
|
|
9
|
-
})();
|
|
3
|
+
const { v4: uuidv4 } = require("uuid");
|
|
10
4
|
|
|
11
5
|
const FeedbackResponseSchema = new Schema(
|
|
12
6
|
{
|
|
13
7
|
paramId: {
|
|
14
8
|
type: String,
|
|
15
|
-
default:
|
|
9
|
+
default: uuidv4(),
|
|
16
10
|
},
|
|
17
11
|
type: {
|
|
18
12
|
type: String,
|
|
19
|
-
enum: ["conversation", "order",
|
|
13
|
+
enum: ["conversation", "order","shop"],
|
|
20
14
|
default: "conversation",
|
|
21
15
|
},
|
|
22
16
|
refId: {
|
|
@@ -55,6 +49,15 @@ const FeedbackResponseSchema = new Schema(
|
|
|
55
49
|
type: Date,
|
|
56
50
|
default: Date.now,
|
|
57
51
|
},
|
|
52
|
+
|
|
53
|
+
workspaceId: {
|
|
54
|
+
type: String,
|
|
55
|
+
default: "",
|
|
56
|
+
},
|
|
57
|
+
feedbackFormId: {
|
|
58
|
+
type: String,
|
|
59
|
+
default: "",
|
|
60
|
+
},
|
|
58
61
|
qr: {
|
|
59
62
|
link: {
|
|
60
63
|
type: String,
|
package/models/Message.js
CHANGED
package/models/Step.js
CHANGED
|
@@ -39,6 +39,14 @@ const StepSchema = new Schema(
|
|
|
39
39
|
type: Number,
|
|
40
40
|
default: 0,
|
|
41
41
|
},
|
|
42
|
+
labels: [
|
|
43
|
+
{
|
|
44
|
+
type: Schema.Types.ObjectId,
|
|
45
|
+
ref: "Label",
|
|
46
|
+
required: false,
|
|
47
|
+
default: [],
|
|
48
|
+
},
|
|
49
|
+
],
|
|
42
50
|
workspaceId: {
|
|
43
51
|
type: Schema.Types.ObjectId,
|
|
44
52
|
ref: "Workspace",
|
package/models/Workspace.js
CHANGED
|
@@ -234,6 +234,7 @@ const workspaceSchema = new mongoose.Schema(
|
|
|
234
234
|
default: 30,
|
|
235
235
|
},
|
|
236
236
|
isDeleted: { type: Boolean, default: false },
|
|
237
|
+
ticketsByConversation: { type: Boolean, default: false },
|
|
237
238
|
businessHours: {
|
|
238
239
|
startTime: { type: String, default: "" },
|
|
239
240
|
endTime: { type: String, default: "" },
|