@chevre/factory 10.0.0 → 10.1.0-alpha.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.
@@ -1,9 +1,13 @@
1
1
  import { IOffer } from '../offer';
2
2
  import { OfferType } from '../offerType';
3
3
  import { IUnitPriceOffer } from '../unitPriceOffer';
4
- export type ISubOffer = Omit<IUnitPriceOffer, 'id' | 'project'>;
5
4
  /**
6
- * 集計オファー
5
+ * オファードキュメント内の単価オファー
6
+ * ID以外の属性が含まれる
7
+ */
8
+ export type ISubOffer = Pick<IUnitPriceOffer, 'acceptedPaymentMethod' | 'addOn' | 'additionalProperty' | 'alternateName' | 'availability' | 'availableAtOrFrom' | 'category' | 'color' | 'description' | 'eligibleMembershipType' | 'eligibleSeatingType' | 'eligibleSubReservation' | 'hasMerchantReturnPolicy' | 'identifier' | 'itemOffered' | 'name' | 'priceSpecification' | 'priceCurrency' | 'settings' | 'validFrom' | 'validRateLimit' | 'validThrough' | 'typeOf'>;
9
+ /**
10
+ * オファードキュメントとしての集計オファー
7
11
  */
8
12
  export interface IAggregateOffer extends Pick<IOffer, 'id' | 'typeOf' | 'project'> {
9
13
  typeOf: OfferType.AggregateOffer;
@@ -12,8 +16,8 @@ export interface IAggregateOffer extends Pick<IOffer, 'id' | 'typeOf' | 'project
12
16
  offerCount?: number;
13
17
  /**
14
18
  * サブオファー
15
- * 基本的に1つの基本オファーが含まれる
16
- * 条件によるバリエーションが存在する場合、2つ以上のオファーが含まれる
19
+ * 基本的に1つの単価オファーが含まれる
20
+ * 条件によるバリエーションが存在する場合を見据えて、2つ以上のオファーが含めることを想定はしたが、ひとまず保留
17
21
  */
18
- offers: ISubOffer[];
22
+ offers: [ISubOffer];
19
23
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chevre/factory",
3
- "version": "10.0.0",
3
+ "version": "10.1.0-alpha.0",
4
4
  "main": "./lib/index.js",
5
5
  "types": "./lib/index.d.ts",
6
6
  "files": [