kcommons 15.2.1 → 15.3.1

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.
@@ -3,22 +3,25 @@ export declare const vendorNavRoutes: {
3
3
  auth: {
4
4
  login: string;
5
5
  };
6
- companies: {
7
- list: string;
8
- view: (company_id: string, activeTab?: COMPANY_PROFILE_TABS_FOR_VENDOR_PANEL) => string;
9
- };
10
- purchase: {
11
- quotes: {
6
+ master: {
7
+ roles: {
12
8
  list: string;
13
9
  add: string;
14
- view: (quote_id: string) => string;
15
- edit: (quote_id: string, openNotifications?: boolean) => string;
10
+ view: (role_id: string) => string;
11
+ edit: string;
16
12
  };
17
- po: {
18
- add: string;
13
+ users: {
19
14
  list: string;
20
- view: (po_id: string) => string;
15
+ add: string;
16
+ view: (user_id: string) => string;
17
+ edit: string;
21
18
  };
19
+ };
20
+ companies: {
21
+ list: string;
22
+ view: (company_id: string, activeTab?: COMPANY_PROFILE_TABS_FOR_VENDOR_PANEL) => string;
23
+ };
24
+ purchase: {
22
25
  openPO: {
23
26
  view: (token: string) => string;
24
27
  readonly: (po_id: string) => string;
@@ -26,12 +29,6 @@ export declare const vendorNavRoutes: {
26
29
  openQuote: {
27
30
  view: (token: string) => string;
28
31
  };
29
- asn: {
30
- add: string;
31
- list: string;
32
- edit: (asn_id: string) => string;
33
- view: (asn_id: string) => string;
34
- };
35
32
  };
36
33
  items: {
37
34
  master: {
@@ -40,6 +37,23 @@ export declare const vendorNavRoutes: {
40
37
  };
41
38
  catalogue: (slug: string) => string;
42
39
  };
40
+ quotes: {
41
+ list: string;
42
+ view: (quote_id: string) => string;
43
+ edit: (quote_id: string, openNotifications?: boolean) => string;
44
+ };
45
+ pos: {
46
+ add: string;
47
+ list: string;
48
+ view: (po_id: string) => string;
49
+ };
50
+ asns: {
51
+ add: string;
52
+ list: string;
53
+ edit: (asn_id: string) => string;
54
+ view: (asn_id: string) => string;
55
+ dispatch: (asn_id: string) => string;
56
+ };
43
57
  onboarding: {
44
58
  request_onboarding: (value: string) => string;
45
59
  svf: (token: string) => string;
@@ -2,26 +2,44 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.vendorNavRoutes = void 0;
4
4
  const company_constants_1 = require("./company.constants");
5
+ const form_constants_1 = require("./form.constants");
5
6
  exports.vendorNavRoutes = {
6
7
  auth: {
7
8
  login: "/login",
8
9
  },
10
+ master: {
11
+ roles: {
12
+ list: "/master/roles",
13
+ add: `/master/roles?mode=${form_constants_1.FORM_SUBMISSION_TYPES.CREATE}`,
14
+ view: (role_id) => `/master/roles/${role_id}`,
15
+ edit: `/master/roles?mode=${form_constants_1.FORM_SUBMISSION_TYPES.EDIT}`,
16
+ },
17
+ users: {
18
+ list: "/master/users",
19
+ add: `/master/users?mode=${form_constants_1.FORM_SUBMISSION_TYPES.CREATE}`,
20
+ view: (user_id) => `/master/users/${user_id}`,
21
+ edit: `/master/users?mode=${form_constants_1.FORM_SUBMISSION_TYPES.EDIT}`,
22
+ },
23
+ },
9
24
  companies: {
10
25
  list: "/companies",
11
26
  view: (company_id, activeTab) => `/companies/${company_id}?${activeTab ? `active_tab=${activeTab}` : ""}`,
12
27
  },
13
28
  purchase: {
14
- quotes: {
15
- list: "/purchase/quotes",
16
- add: "/purchase/quotes/add",
17
- view: (quote_id) => `/purchase/quotes/${quote_id}/view`,
18
- edit: (quote_id, openNotifications) => `/purchase/quotes/${quote_id}/edit?${openNotifications ? "opent=true" : ""}`,
19
- },
20
- po: {
21
- add: `/purchase/pos/add`,
22
- list: `/purchase/pos/`,
23
- view: (po_id) => `/purchase/pos/${po_id}/view`,
24
- },
29
+ // quotes: {
30
+ // list: "/purchase/quotes",
31
+ // add: "/purchase/quotes/add",
32
+ // view: (quote_id: string) => `/purchase/quotes/${quote_id}/view`,
33
+ // edit: (quote_id: string, openNotifications?: boolean) =>
34
+ // `/purchase/quotes/${quote_id}/edit?${
35
+ // openNotifications ? "opent=true" : ""
36
+ // }`,
37
+ // },
38
+ // po: {
39
+ // add: `/purchase/pos/add`,
40
+ // list: `/purchase/pos/`,
41
+ // view: (po_id: string) => `/purchase/pos/${po_id}/view`,
42
+ // },
25
43
  openPO: {
26
44
  view: (token) => `/purchase/open-po?token=${token}`,
27
45
  readonly: (po_id) => `/purchase/open-po/view?po_id=${po_id}`,
@@ -29,20 +47,37 @@ exports.vendorNavRoutes = {
29
47
  openQuote: {
30
48
  view: (token) => `/purchase/open-quote?token=${token}`,
31
49
  },
32
- asn: {
33
- add: `/purchase/asn/add`,
34
- list: `/purchase/asn`,
35
- edit: (asn_id) => `/purchase/asn/${asn_id}/edit`,
36
- view: (asn_id) => `/purchase/asn/${asn_id}/view`,
37
- },
50
+ // asn: {
51
+ // add: `/purchase/asn/add`,
52
+ // list: `/purchase/asn`,
53
+ // edit: (asn_id: string) => `/purchase/asn/${asn_id}/edit`,
54
+ // view: (asn_id: string) => `/purchase/asn/${asn_id}/view`,
55
+ // },
38
56
  },
39
57
  items: {
40
58
  master: {
41
- list: "/item-master",
42
- view: (item_id) => `/item-master/${item_id}`,
59
+ list: "/item",
60
+ view: (item_id) => `/item/${item_id}`,
43
61
  },
44
62
  catalogue: (slug) => `/catalogue/${slug}`,
45
63
  },
64
+ quotes: {
65
+ list: "/quotes/",
66
+ view: (quote_id) => `/quotes/${quote_id}/view`,
67
+ edit: (quote_id, openNotifications) => `/quotes/${quote_id}/edit?${openNotifications ? "opent=true" : ""}`,
68
+ },
69
+ pos: {
70
+ add: `/pos/add`,
71
+ list: `/pos/`,
72
+ view: (po_id) => `/pos/${po_id}/view`,
73
+ },
74
+ asns: {
75
+ add: `/asns/add`,
76
+ list: `/asns`,
77
+ edit: (asn_id) => `/asns/${asn_id}/edit`,
78
+ view: (asn_id) => `/asns/${asn_id}/view`,
79
+ dispatch: (asn_id) => `/asns/${asn_id}/view?dispatchForm=open`,
80
+ },
46
81
  onboarding: {
47
82
  request_onboarding: (value) => `/company-vendor/onboarding-request?${company_constants_1.COMPANY_ID_PARAM_NAME}=${value}`,
48
83
  svf: (token) => `/company-vendor/onboarding-request/svf?token=${token}`,
@@ -6,6 +6,8 @@ import { INestedNotification } from "../notifications.typings";
6
6
  import { INestedQuote } from "../quote.typings";
7
7
  import { INestedVendor } from "../vendor.typings";
8
8
  import { INestedVendorItem } from "../vendorItem.typings";
9
+ import { INestedVendorPermission } from "./vendorPermission.typings";
10
+ import { INestedVendorRole } from "./vendorRole.typings";
9
11
  export interface IVendorUser {
10
12
  id: string;
11
13
  contact: string;
@@ -48,11 +50,11 @@ export interface IVendorUser {
48
50
  last_updated_asns: INestedASN[] | null;
49
51
  cancelled_asn: INestedASN[] | null;
50
52
  owned_vendor_organizations: INestedVendor[] | null;
51
- created_vendor_roles: null;
52
- last_updated_vendor_roles: null;
53
- assigned_vendor_roles: null;
54
- created_vendor_permissions: null;
55
- last_updated_vendor_permission: null;
53
+ created_vendor_roles: INestedVendorRole[] | null;
54
+ last_updated_vendor_roles: INestedVendorRole[] | null;
55
+ assigned_vendor_roles: INestedVendorRole[] | null;
56
+ created_vendor_permissions: INestedVendorPermission[] | null;
57
+ last_updated_vendor_permission: INestedVendorPermission[] | null;
56
58
  }
57
59
  export interface INestedVendorUser extends Omit<IVendorUser, "parent_vendor" | "otps" | "created_vendor_items" | "last_updated_vendor_items" | "deleted_vendor_items" | "created_company_specific_vendor_item_versions" | "last_udpated_company_specific_vendor_item_versions" | "deleted_company_specific_vendor_item_versions" | "accepted_rejected_po" | "vendor_user_notifications" | "quotes_last_updated" | "created_asns" | "last_updated_asns" | "cancelled_asn" | "owned_vendor_organizations" | "contact_person_for_po_at" | "contact_person_for_quote_at" | "contact_person_for_asn_at" | "contact_person_for_general_at" | "created_vendor_roles" | "last_updated_vendor_roles" | "assigned_vendor_roles" | "created_vendor_permissions" | "last_updated_vendor_permission"> {
58
60
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kcommons",
3
- "version": "15.2.1",
3
+ "version": "15.3.1",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",