rerobe-js-orm 3.5.3 → 3.5.5

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.
@@ -4,8 +4,34 @@ export namespace MERCHANT_TYPES {
4
4
  const enterprise: string;
5
5
  }
6
6
  export namespace PAYMENT_TIERS {
7
- const free: string;
8
- const one: string;
7
+ export namespace starter {
8
+ const id: string;
9
+ const monthlyFee: number;
10
+ const transactionFee: number;
11
+ const currency: string;
12
+ }
13
+ export namespace business_1 {
14
+ const id_1: string;
15
+ export { id_1 as id };
16
+ const monthlyFee_1: number;
17
+ export { monthlyFee_1 as monthlyFee };
18
+ const transactionFee_1: number;
19
+ export { transactionFee_1 as transactionFee };
20
+ const currency_1: string;
21
+ export { currency_1 as currency };
22
+ }
23
+ export { business_1 as business };
24
+ export namespace enterprise_1 {
25
+ const id_2: string;
26
+ export { id_2 as id };
27
+ const monthlyFee_2: number;
28
+ export { monthlyFee_2 as monthlyFee };
29
+ const transactionFee_2: number;
30
+ export { transactionFee_2 as transactionFee };
31
+ const currency_2: string;
32
+ export { currency_2 as currency };
33
+ }
34
+ export { enterprise_1 as enterprise };
9
35
  }
10
36
  export namespace INDUSTRY_TYPES {
11
37
  const beauty: string;
@@ -7,8 +7,24 @@ exports.MERCHANT_TYPES = {
7
7
  enterprise: 'ENTERPRISE',
8
8
  };
9
9
  exports.PAYMENT_TIERS = {
10
- free: 'FREE',
11
- one: 'TIER_ONE',
10
+ starter: {
11
+ id: 'STARTER',
12
+ monthlyFee: 195,
13
+ transactionFee: 0.03,
14
+ currency: 'usd',
15
+ },
16
+ business: {
17
+ id: 'BUSINESS',
18
+ monthlyFee: 295,
19
+ transactionFee: 0.02,
20
+ currency: 'usd',
21
+ },
22
+ enterprise: {
23
+ id: 'ENTERPRISE',
24
+ monthlyFee: 2500,
25
+ transactionFee: 0.005,
26
+ currency: 'usd',
27
+ },
12
28
  };
13
29
  exports.INDUSTRY_TYPES = {
14
30
  beauty: 'BEAUTY',
@@ -2,10 +2,6 @@ export const merchantTypeOptions: {
2
2
  label: string;
3
3
  value: string;
4
4
  }[];
5
- export const paymentTierOptions: {
6
- label: string;
7
- value: string;
8
- }[];
9
5
  export const industryOptions: {
10
6
  label: string;
11
7
  value: string;
@@ -1,17 +1,12 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.httpRequestMethodOptions = exports.webhookKeyOptions = exports.timeZoneOptions = exports.currencyOptions = exports.imperialWeightOptions = exports.metricWeightOptions = exports.unitSystemOptions = exports.industryOptions = exports.paymentTierOptions = exports.merchantTypeOptions = void 0;
3
+ exports.httpRequestMethodOptions = exports.webhookKeyOptions = exports.timeZoneOptions = exports.currencyOptions = exports.imperialWeightOptions = exports.metricWeightOptions = exports.unitSystemOptions = exports.industryOptions = exports.merchantTypeOptions = void 0;
4
4
  const Merchant_1 = require("../../models/Merchant");
5
5
  const merchantTypeOptions = [
6
6
  { label: 'Individual', value: Merchant_1.default.MERCHANT_TYPES.individual },
7
7
  { label: 'Business', value: Merchant_1.default.MERCHANT_TYPES.business },
8
8
  ];
9
9
  exports.merchantTypeOptions = merchantTypeOptions;
10
- const paymentTierOptions = [
11
- { label: 'Free', value: Merchant_1.default.PAYMENT_TIERS.free },
12
- { label: 'Tier One', value: Merchant_1.default.PAYMENT_TIERS.one },
13
- ];
14
- exports.paymentTierOptions = paymentTierOptions;
15
10
  const industryOptions = [
16
11
  { label: 'Beauty', value: Merchant_1.default.INDUSTRY_TYPES.beauty },
17
12
  { label: 'Clothing', value: Merchant_1.default.INDUSTRY_TYPES.clothing },
@@ -6,8 +6,24 @@ export default class Merchant extends Base {
6
6
  enterprise: string;
7
7
  };
8
8
  static PAYMENT_TIERS: {
9
- free: string;
10
- one: string;
9
+ starter: {
10
+ id: string;
11
+ monthlyFee: number;
12
+ transactionFee: number;
13
+ currency: string;
14
+ };
15
+ business: {
16
+ id: string;
17
+ monthlyFee: number;
18
+ transactionFee: number;
19
+ currency: string;
20
+ };
21
+ enterprise: {
22
+ id: string;
23
+ monthlyFee: number;
24
+ transactionFee: number;
25
+ currency: string;
26
+ };
11
27
  };
12
28
  static INDUSTRY_TYPES: {
13
29
  beauty: string;
@@ -7,7 +7,7 @@ class Merchant extends Base_1.default {
7
7
  super();
8
8
  this.name = (props === null || props === void 0 ? void 0 : props.name) || '';
9
9
  this.type = (props === null || props === void 0 ? void 0 : props.type) || Merchant.MERCHANT_TYPES.individual;
10
- this.paymentTier = (props === null || props === void 0 ? void 0 : props.paymentTier) || Merchant.PAYMENT_TIERS.free;
10
+ this.paymentTier = (props === null || props === void 0 ? void 0 : props.paymentTier) || Merchant.PAYMENT_TIERS.starter.id;
11
11
  this.contactEmail = (props === null || props === void 0 ? void 0 : props.contactEmail) || '';
12
12
  this.senderEmail = (props === null || props === void 0 ? void 0 : props.senderEmail) || '';
13
13
  this.industry = (props === null || props === void 0 ? void 0 : props.industry) || '';
@@ -25,6 +25,7 @@ export default class SellerProductLedger extends Base {
25
25
  toObj(): SellerProductLedgerType;
26
26
  generateSchemaForTypesense(name?: string): {
27
27
  default_sorting_field: string;
28
+ enable_nested_fields: boolean;
28
29
  fields: {
29
30
  name: string;
30
31
  type: string;
@@ -55,10 +55,12 @@ class SellerProductLedger extends Base_1.default {
55
55
  generateSchemaForTypesense(name = 'prod_sellerProductLedger_20240223') {
56
56
  return {
57
57
  default_sorting_field: 'createdAtTimestamp',
58
+ enable_nested_fields: true,
58
59
  fields: [
59
60
  { name: 'documentId', type: 'string', facet: false },
60
61
  { name: 'createdAtTimestamp', type: 'int64', facet: true },
61
62
  { name: 'updatedAtTimestamp', type: 'int64', facet: true },
63
+ { name: 'pendingReturnPeriodStartTimestamp', type: 'int64', facet: true },
62
64
  { name: 'merchantId', type: 'string', facet: true },
63
65
  { name: 'merchantCurrency', type: 'string', facet: true },
64
66
  { name: 'sellerId', type: 'string', facet: true },
@@ -75,6 +77,7 @@ class SellerProductLedger extends Base_1.default {
75
77
  { name: 'amountOwedToSeller', type: 'float', facet: true },
76
78
  { name: 'status', type: 'string', facet: true },
77
79
  { name: 'feesForSeller', type: 'object[]', facet: false },
80
+ { name: 'tags', type: 'string[]', facet: true },
78
81
  ],
79
82
  name,
80
83
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rerobe-js-orm",
3
- "version": "3.5.3",
3
+ "version": "3.5.5",
4
4
  "description": "ReRobe's Javascript ORM Framework",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",