shuttlepro-shared 1.2.56 → 1.2.58

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.
@@ -21,6 +21,7 @@ const conversationSchema = new mongoose.Schema(
21
21
  "linkedin",
22
22
  "facebook",
23
23
  "tiktok",
24
+ "outlook",
24
25
  "webChat",
25
26
  "smtp_gmail",
26
27
  ],
package/models/Order.js CHANGED
@@ -112,6 +112,7 @@ const OrderSchema = new Schema(
112
112
  credentials: {},
113
113
  sender: { type: String, default: "" },
114
114
  orderName: { type: String, default: "" },
115
+ totalWeight: { type: String, default: "" },
115
116
  },
116
117
  { timestamps: true, toJSON: { virtuals: true }, toObject: { virtuals: true } }
117
118
  );
package/models/Shipper.js CHANGED
@@ -8,10 +8,11 @@ const shipperInformationSchema = new Schema({
8
8
  serviceTypeId: { type: String, default: "" }, //M&P, TRAX, INSTA, RIDER, TCS, CC
9
9
  pieces: { type: Number, default: 0 }, //M&P, TRAX, INSTA, RIDER, TCS, CC
10
10
  originCityName: { type: String, default: "" }, //M&P, TRAX, INSTA, RIDER, TCS, CC
11
+ costCenterCode: { type: String, default: "" }, //M&P, TRAX, INSTA, RIDER, TCS, CC
11
12
  remarks: { type: String, default: "" },
12
13
  customer_note: { type: String, default: "" },
13
14
  cityData: { type: String, default: "" },
14
- return_branch: { type: String, default: "" },
15
+ return_branch: { type: String, default: "" },
15
16
  //M&P, TRAX, INSTA, RIDER, TCS, CC
16
17
  //TRAX
17
18
  paymentMode: { type: Number, default: 0 },
@@ -21,6 +22,7 @@ const shipperInformationSchema = new Schema({
21
22
  itemInsurance: { type: Boolean, default: false }, //this will not be shown
22
23
  informationDisplay: { type: String, default: "" },
23
24
  //Call Courier (CC)
25
+ shipperId: { type: Number, default: 0 }, //this will not be showm
24
26
  shipperName: { type: String, default: "" }, //this will not be shown
25
27
  shipperEmail: { type: String, default: "" }, //this will not be shown
26
28
  shipperCellNo: { type: String, default: "" }, //this will not be shown
@@ -28,6 +30,7 @@ const shipperInformationSchema = new Schema({
28
30
  shipperAddress: { type: String, default: "" }, //this will not be shown
29
31
  shipperCityId: { type: Number, default: 0 }, //this will not be shown
30
32
  shipperAreaId: { type: Number, default: 0 }, //this will not be shown
33
+ locationId: { type: Number, default: 0 }, //this will not be shown
31
34
  });
32
35
 
33
36
  const shipperSchema = new mongoose.Schema(
@@ -36,6 +39,13 @@ const shipperSchema = new mongoose.Schema(
36
39
  userName: { type: String, default: "" },
37
40
  password: { type: String, default: "" },
38
41
  clientId: { type: String, default: "" },
42
+ clientSecret: { type: String, default: "" },
43
+ bearerToken: { type: String, default: "" },
44
+ accessToken: { type: String, default: "" },
45
+ accountNo: { type: String, default: "" },
46
+ businessName: { type: String, default: "" },
47
+ businessPhone: { type: String, default: "" },
48
+ businessAddress: { type: String, default: "" },
39
49
  workspaceId: {
40
50
  type: Schema.Types.ObjectId,
41
51
  ref: "Workspace",
@@ -0,0 +1,46 @@
1
+ const mongoose = require("mongoose");
2
+ const { Schema } = mongoose;
3
+
4
+ const userWorkflow = new Schema(
5
+ {
6
+ workspaceId: {
7
+ type: Schema.Types.ObjectId,
8
+ default: null,
9
+ ref: "Workspace",
10
+ },
11
+ workflow: {},
12
+ receiverId: {
13
+ type: String,
14
+ default: "",
15
+ },
16
+ whatsappTemplateData: {},
17
+ whatsappTemplate: {},
18
+ targetPayload: {},
19
+ business: {},
20
+ sender: {},
21
+ currentRetry: {
22
+ type: Number,
23
+ default: 0,
24
+ },
25
+ currentAction: {
26
+ type: String,
27
+ default: "",
28
+ },
29
+ lastMessage: {
30
+ type: String,
31
+ default: "",
32
+ },
33
+ status: {
34
+ type: String,
35
+ default: "pending",
36
+ },
37
+ otherTypeEvent: {
38
+ type: Boolean,
39
+ default: false,
40
+ },
41
+ allActions: [],
42
+ },
43
+ { timestamps: true, toJSON: { virtuals: true }, toObject: { virtuals: true } }
44
+ );
45
+
46
+ module.exports = mongoose.model("UserWorkflow", userWorkflow);
package/models.js CHANGED
@@ -40,6 +40,7 @@ const Step = require("./models/Step");
40
40
  const Role = require("./models/Role");
41
41
  const NewProduct = require("./models/NewProduct");
42
42
  const NotificationSettings = require("./models/NotificationSettings");
43
+ const UserWorkflow = require("./models/UserWorkflow");
43
44
  module.exports = {
44
45
  Website,
45
46
  ProductQueue,
@@ -83,4 +84,5 @@ module.exports = {
83
84
  Role,
84
85
  NewProduct,
85
86
  NotificationSettings,
87
+ UserWorkflow,
86
88
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shuttlepro-shared",
3
- "version": "1.2.56",
3
+ "version": "1.2.58",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {