kcommons 5.17.2 → 5.17.3
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.
|
@@ -1,2 +1,5 @@
|
|
|
1
1
|
import { INotificationTemplate } from "../../typings/notifications.typings";
|
|
2
|
-
export declare
|
|
2
|
+
export declare enum RFQ_NOTIFICATION_EVENTS {
|
|
3
|
+
chanceForApproval = "chanceForApproval"
|
|
4
|
+
}
|
|
5
|
+
export declare const RFQ_NOTIFICATION_TEMPLATES: Record<RFQ_NOTIFICATION_EVENTS, (...args: any) => INotificationTemplate | INotificationTemplate>;
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.RFQ_NOTIFICATION_TEMPLATES = void 0;
|
|
3
|
+
exports.RFQ_NOTIFICATION_TEMPLATES = exports.RFQ_NOTIFICATION_EVENTS = void 0;
|
|
4
|
+
var RFQ_NOTIFICATION_EVENTS;
|
|
5
|
+
(function (RFQ_NOTIFICATION_EVENTS) {
|
|
6
|
+
RFQ_NOTIFICATION_EVENTS["chanceForApproval"] = "chanceForApproval";
|
|
7
|
+
})(RFQ_NOTIFICATION_EVENTS || (exports.RFQ_NOTIFICATION_EVENTS = RFQ_NOTIFICATION_EVENTS = {}));
|
|
4
8
|
exports.RFQ_NOTIFICATION_TEMPLATES = {
|
|
5
|
-
chanceForApproval: ({ rfq_id, rfq_no, }) => {
|
|
9
|
+
[RFQ_NOTIFICATION_EVENTS.chanceForApproval]: ({ rfq_id, rfq_no, }) => {
|
|
6
10
|
return {
|
|
7
11
|
actionLink: `/purchase/request-for-requisition/${rfq_id}`,
|
|
8
12
|
message: `Please approve the RFQ ${rfq_no}`,
|
|
@@ -39,11 +39,13 @@ export interface IEntityDependentNotificaiton {
|
|
|
39
39
|
type: GROUP_NOTIFICATION_TYPES.ENTITY_DEPENDENT;
|
|
40
40
|
entity_type: EntityTypes;
|
|
41
41
|
entity_id: string;
|
|
42
|
+
company_id: string;
|
|
42
43
|
}
|
|
43
44
|
export interface IPrivilegeDependentNotifications {
|
|
44
45
|
type: GROUP_NOTIFICATION_TYPES.PRIVILEGE_DEPENDENT;
|
|
45
46
|
permission_entity: IPERMISSION_ENTITIES;
|
|
46
47
|
actions: PERMISSION_ACTIONS[];
|
|
48
|
+
company_id: string;
|
|
47
49
|
}
|
|
48
50
|
export interface IEntityAndPrivilegeDependentNotifications {
|
|
49
51
|
type: GROUP_NOTIFICATION_TYPES.ENTITY_PRIVILEGE_DEPENDENT;
|
|
@@ -51,11 +53,13 @@ export interface IEntityAndPrivilegeDependentNotifications {
|
|
|
51
53
|
entity_id: string;
|
|
52
54
|
permission_entity: IPERMISSION_ENTITIES;
|
|
53
55
|
actions: PERMISSION_ACTIONS[];
|
|
56
|
+
company_id: string;
|
|
54
57
|
}
|
|
55
58
|
export type IGroupNotification = IEntityAndPrivilegeDependentNotifications | IPrivilegeDependentNotifications | IEntityAndPrivilegeDependentNotifications;
|
|
56
59
|
export interface IIndividualNotification {
|
|
57
60
|
user_id: string;
|
|
58
61
|
vendor_id: string;
|
|
62
|
+
company_id: string;
|
|
59
63
|
}
|
|
60
64
|
export type INotificationType = IIndividualNotification | IGroupNotification;
|
|
61
65
|
export interface INotificationTemplate {
|