@pliancy/salesforce-cpq-sdk 3.23.1 → 3.24.0

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/dist/index.d.ts CHANGED
@@ -23,4 +23,6 @@ export * from './lib/price-books/price-book.types';
23
23
  export * from './lib/price-books/entries/price-book-entries';
24
24
  export * from './lib/price-books/entries/price-book-entries.types';
25
25
  export * from './lib/custom/custom';
26
+ export * from './lib/assets/assets';
27
+ export * from './lib/assets/asset.types';
26
28
  export { SaveResult, SaveError };
package/dist/index.js CHANGED
@@ -40,3 +40,5 @@ __exportStar(require("./lib/price-books/price-book.types"), exports);
40
40
  __exportStar(require("./lib/price-books/entries/price-book-entries"), exports);
41
41
  __exportStar(require("./lib/price-books/entries/price-book-entries.types"), exports);
42
42
  __exportStar(require("./lib/custom/custom"), exports);
43
+ __exportStar(require("./lib/assets/assets"), exports);
44
+ __exportStar(require("./lib/assets/asset.types"), exports);
@@ -62,7 +62,7 @@ export interface Asset {
62
62
  SBQQ__ListPrice__c: number;
63
63
  SBQQ__MarkupAmount__c?: string;
64
64
  SBQQ__MarkupRate__c?: string;
65
- SBQQ__Number__c: 12;
65
+ SBQQ__Number__c: number;
66
66
  SBQQ__OptionDiscountAmount__c?: string;
67
67
  SBQQ__OptionDiscount__c?: string;
68
68
  SBQQ__OptionLevel__c?: string;
@@ -5,4 +5,5 @@ export declare class PriceBookEntries {
5
5
  private readonly client;
6
6
  constructor(connection: Connection);
7
7
  getByPriceBookId(id: string): Promise<PriceBookEntry[]>;
8
+ create(entry: Partial<Omit<PriceBookEntry, 'Id'>>): Promise<import("jsforce").SaveResult>;
8
9
  }
@@ -9,5 +9,8 @@ class PriceBookEntries {
9
9
  async getByPriceBookId(id) {
10
10
  return this.client.find({ Pricebook2Id: id, IsActive: true });
11
11
  }
12
+ async create(entry) {
13
+ return this.client.create(entry);
14
+ }
12
15
  }
13
16
  exports.PriceBookEntries = PriceBookEntries;
@@ -1,9 +1,10 @@
1
1
  import { Connection } from 'jsforce';
2
2
  import { FullPriceBook } from './price-book.types';
3
+ import { PriceBookEntries } from './entries/price-book-entries';
3
4
  export declare class PriceBooks {
4
5
  private readonly connection;
5
6
  private readonly client;
6
- private readonly entries;
7
+ readonly entries: PriceBookEntries;
7
8
  constructor(connection: Connection);
8
9
  getByName(name: string): Promise<FullPriceBook | null>;
9
10
  }
@@ -10,4 +10,5 @@ export declare class Products extends Base<ProductEntity> {
10
10
  getById(id: string): Promise<Product | null>;
11
11
  getOptionsByProductCode(code: string): Promise<import("./product-options/product-option.types").ProductOption[]>;
12
12
  update(id: string, update: Partial<Omit<Product, 'Id'>>, options?: QueryCondition<Schema, ProductEntity>): Promise<SaveResult>;
13
+ create(product: Partial<Omit<Product, 'Id'>>): Promise<SaveResult>;
13
14
  }
@@ -24,5 +24,8 @@ class Products extends base_1.Base {
24
24
  const query = this.buildQuery({ Id: id, ...update }, options);
25
25
  return this.client.update(query);
26
26
  }
27
+ async create(product) {
28
+ return this.client.create(product);
29
+ }
27
30
  }
28
31
  exports.Products = Products;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pliancy/salesforce-cpq-sdk",
3
- "version": "3.23.1",
3
+ "version": "3.24.0",
4
4
  "main": "dist/index.js",
5
5
  "license": "MIT",
6
6
  "description": "Salesforce CPQ SDK for Node.js",