@peabody-soft/mbs-model-ts 1.7.1 → 1.9.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.
Files changed (40) hide show
  1. package/dist/Business.js +2 -1
  2. package/dist/Catalog.d.ts +19 -7
  3. package/dist/Catalog.js +119 -39
  4. package/dist/Constants.d.ts +1 -0
  5. package/dist/Constants.js +6 -3
  6. package/dist/Entity.d.ts +1 -0
  7. package/dist/Entity.js +4 -0
  8. package/dist/Enums.d.ts +1 -0
  9. package/dist/Enums.js +1 -0
  10. package/dist/GeneralSettings.d.ts +5 -4
  11. package/dist/GeneralSettings.js +9 -8
  12. package/dist/Item.js +2 -1
  13. package/dist/Package.d.ts +6 -2
  14. package/dist/Package.js +11 -5
  15. package/dist/Price.d.ts +5 -2
  16. package/dist/Price.js +18 -3
  17. package/dist/PriceList.d.ts +13 -0
  18. package/dist/PriceList.js +50 -2
  19. package/dist/Product.d.ts +6 -2
  20. package/dist/Product.js +8 -5
  21. package/dist/ProtoMap.js +60 -68
  22. package/dist/ShoppingList.js +4 -3
  23. package/dist/generated/BusinessSyncOutResponse.d.ts +4 -1
  24. package/dist/generated/Constants.d.ts +0 -4
  25. package/dist/generated/Constants.js +0 -4
  26. package/dist/generated/GeneralSettings.d.ts +5 -4
  27. package/dist/generated/GeneralSettings.js +8 -6
  28. package/dist/generated/Item.d.ts +4 -3
  29. package/dist/generated/Message.d.ts +5 -0
  30. package/dist/generated/OnlineStoreTheme.d.ts +33 -0
  31. package/dist/generated/OnlineStoreTheme.js +38 -0
  32. package/dist/generated/Price.d.ts +9 -0
  33. package/dist/generated/Price.js +9 -1
  34. package/dist/generated/PriceList.d.ts +13 -2
  35. package/dist/generated/ProfileSyncOutRequest.d.ts +16 -15
  36. package/dist/generated/ProfileSyncOutResponse.d.ts +4 -6
  37. package/dist/generated/SalesOrderPayload.d.ts +6 -3
  38. package/dist/index.d.ts +4 -0
  39. package/dist/index.js +2 -2
  40. package/package.json +2 -2
@@ -11,9 +11,8 @@ import { AuthTokens } from "./AuthTokens";
11
11
  /**
12
12
  * The answer to a ProfileSyncOutRequest: who the caller is, the businesses they are linked to, and
13
13
  * those businesses. Nothing is nested - match BusinessLink.businessId against Business.entity.id.
14
- * Every field is absent/empty unless that type has changed, but for the caller's own user, which is
15
- * sent with every response; a tombstone (updateNumber's update-type bits =
16
- * Constants.UPDATE_TYPE_DELETED) means the entity, and what it owned, was deleted.
14
+ * Every field is absent/empty unless that type has changed. A tombstone (updateNumber's update-type
15
+ * bits = Constants.UPDATE_TYPE_DELETED) means the entity, and what it owned, was deleted.
17
16
  *
18
17
  * @generated from protobuf message com.merabills.storefront.ProfileSyncOutResponse
19
18
  */
@@ -26,9 +25,8 @@ export interface ProfileSyncOutResponse {
26
25
  */
27
26
  authTokens?: AuthTokens;
28
27
  /**
29
- * The caller. Sent with every response, whatever userUpdateNumber is: a client keeps the copy it holds
30
- * when it is as new as this one. The only user a response ever carries: nobody else's, such as the
31
- * owner of a business, is sent to a customer.
28
+ * The caller, if the user has changed since userUpdateNumber. The only user a response ever carries:
29
+ * nobody else's, such as the owner of a business, is sent to a customer.
32
30
  *
33
31
  * @generated from protobuf field: com.merabills.storefront.User user = 2
34
32
  */
@@ -27,19 +27,22 @@ export interface SalesOrderPayload {
27
27
  */
28
28
  fulfillmentMode: FulfillmentMode;
29
29
  /**
30
- * What was ordered
30
+ * What was ordered. Absent for an order that an older version of the merchant app completed: that
31
+ * version moved the list out of the order, into the record of the sale, which a storefront is never
32
+ * sent. A client shows such an order with its total and count alone.
31
33
  *
32
34
  * @generated from protobuf field: com.merabills.storefront.ShoppingList shoppingList = 3
33
35
  */
34
36
  shoppingList?: ShoppingList;
35
37
  /**
36
- * Total of the shopping list, multiplied by Constants.AMOUNT_FACTOR
38
+ * Total of the shopping list, multiplied by Constants.AMOUNT_FACTOR. Sent whether or not the list is
39
+ * (see above), so, it is all there is of what an order of that kind came to.
37
40
  *
38
41
  * @generated from protobuf field: int64 shoppingListTotal = 4
39
42
  */
40
43
  shoppingListTotal: bigint;
41
44
  /**
42
- * Number of items in the shopping list
45
+ * Number of items in the shopping list. Sent whether or not the list is, as the total is.
43
46
  *
44
47
  * @generated from protobuf field: int32 shoppingListCount = 5
45
48
  */
package/dist/index.d.ts CHANGED
@@ -14,13 +14,17 @@ export { default as Business } from "./Business";
14
14
  export type { UpdatableBusiness } from "./Business";
15
15
  export { default as CartEditor, CartLine } from "./CartEditor";
16
16
  export { default as Catalog } from "./Catalog";
17
+ export type { UpdatableCatalog } from "./Catalog";
17
18
  export { default as GeneralSettings } from "./GeneralSettings";
18
19
  export { default as Order } from "./Order";
19
20
  export { default as Package } from "./Package";
21
+ export type { UpdatablePackage } from "./Package";
20
22
  export { default as Photo } from "./Photo";
21
23
  export { default as Price } from "./Price";
22
24
  export { default as PriceList } from "./PriceList";
25
+ export type { UpdatablePriceList } from "./PriceList";
23
26
  export { default as Product } from "./Product";
27
+ export type { UpdatableProduct } from "./Product";
24
28
  export { default as ProductCategory } from "./ProductCategory";
25
29
  export type { UpdatableProductCategory } from "./ProductCategory";
26
30
  export { default as Profile } from "./Profile";
package/dist/index.js CHANGED
@@ -48,8 +48,8 @@ export { default as ShoppingList, ItemChange, ShoppingListItem } from "./Shoppin
48
48
  export { default as Tax, TaxAmount } from "./Tax";
49
49
  export { default as WorkingDays, WorkingHours, WorkingHoursRange } from "./WorkingDays";
50
50
  // The enums of the protocol, the limits it obeys, and how an id is read. The price list a
51
- // storefront sells from is exported because a UI that builds a cart must name it, and
52
- // Catalog.priceList is null until the catalog has arrived.
51
+ // storefront sells from is exported because a UI that builds a cart must name it. Catalog.priceList
52
+ // is null until the catalog has arrived, and when the response did not carry that list.
53
53
  export * from "./Enums";
54
54
  export { Constants, MERABILLS_ONLINE_PRICE_LIST_ID, buildPriceListId } from "./Constants";
55
55
  export { default as Ids } from "./Ids";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@peabody-soft/mbs-model-ts",
3
- "version": "1.7.1",
3
+ "version": "1.9.0",
4
4
  "description": "MeraBills storefront client-side model (TypeScript)",
5
5
  "author": "Peabody Soft",
6
6
  "license": "AGPL-3.0-or-later",
@@ -49,7 +49,7 @@
49
49
  "typescript": "^7.0.2"
50
50
  },
51
51
  "dependencies": {
52
- "@peabody-soft/mbs-protos": "^1.11.0",
52
+ "@peabody-soft/mbs-protos": "^1.13.0",
53
53
  "@protobuf-ts/runtime": "^2.11.1"
54
54
  }
55
55
  }