@jusbid/common-auth 1.0.0 → 1.0.2

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/index.js CHANGED
@@ -5,6 +5,7 @@ const { UnauthorizedError } = require("@jusbid/error-handler")
5
5
  const { questions } = require("./scripts/questionsSlug")
6
6
  const { encryptToken } = require("@jusbid/utils");
7
7
  const { propertyOnBoard } = require('./scripts/propertySlug');
8
+ const { notificationType } = require('./scripts/notification');
8
9
 
9
10
 
10
11
  async function getPermissions(roleName) {
@@ -133,5 +134,6 @@ module.exports = {
133
134
  canAccess,
134
135
  getPermissionString,
135
136
  getQuestionSlug,
136
- getPropertyMasterSlug
137
+ getPropertyMasterSlug,
138
+ notificationType
137
139
  };
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@jusbid/common-auth",
3
- "version": "1.0.0",
3
+ "version": "1.0.2",
4
4
  "main": "index.js",
5
5
  "private": false,
6
6
  "dependencies": {
7
7
  "redis": "^4.6.13",
8
8
  "mongoose": "^8.2.0",
9
- "@jusbid/redis": "1.0.0",
9
+ "@jusbid/redis": "1.0.1",
10
10
  "@jusbid/error-handler": "1.0.0",
11
11
  "@jusbid/utils": "1.0.0"
12
12
  },
@@ -0,0 +1,29 @@
1
+
2
+ export const notificationType = {
3
+ CUSTOMER: {
4
+ BOOKING_CONFIRMED: "booking-confirmed",
5
+ BOOKING_CANCELLED: "booking-cancelled",
6
+ BID_ACCEPTED: "bid-accepted",
7
+ BID_REJECTED: "bid-rejected",
8
+ PAYMENT_SUCCESS: "payment-success",
9
+ PAYMENT_FAILED: "payment-failed",
10
+ CHECK_IN_REMINDER: "check-in-reminder",
11
+ ANNOUNCEMENT: "announcement",
12
+ },
13
+ HOTELIER: {
14
+ NEW_BOOKING: "new-booking",
15
+ BOOKING_CANCELLED: "booking-cancelled",
16
+ NEW_BID_RECEIVED: "new-bid-received",
17
+ PROPERTY_STATUS_UPDATE: "property-status-update",
18
+ PAYMENT_RECEIVED: "payment-received",
19
+ ANNOUNCEMENT: "announcement",
20
+ },
21
+ STAFF: {
22
+ PROPERTY_ADDED: "property-added",
23
+ PROPERTY_ONBOARDED: "property-onboarded",
24
+ PROPERTY_APPROVED: "property-approved",
25
+ PROPERTY_ASSIGNED: "property-assigned",
26
+ ANNOUNCEMENT: "announcement",
27
+ }
28
+
29
+ }