@chevre/factory 4.398.0 → 4.399.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.
@@ -3,25 +3,33 @@ import { CreativeWorkType } from '../creativeWorkType';
3
3
  import { IOrder } from '../order';
4
4
  import { OrganizationType } from '../organizationType';
5
5
  import { IPerson } from '../person';
6
+ import { IProduct } from '../product';
6
7
  import { IProject } from '../project';
7
8
  import { SortType } from '../sortType';
8
9
  export type IAboutAsOrder = Pick<IOrder, 'orderNumber' | 'typeOf'> & {
9
10
  id: string;
10
11
  };
11
- export type IAbout = IAboutAsOrder;
12
+ export type IAboutAsProduct = Pick<IProduct, 'typeOf'> & {
13
+ id: string;
14
+ };
15
+ export type IAbout = IAboutAsOrder | IAboutAsProduct;
12
16
  export type ICreator = Pick<IPerson, 'id' | 'typeOf'>;
13
17
  export type IEditor = Pick<IPerson, 'id' | 'typeOf'>;
14
- export interface IProvider {
18
+ export interface IProviderAsSeller {
15
19
  /**
16
20
  * 販売者ID
17
21
  */
18
22
  id: string;
19
23
  typeOf: OrganizationType.Corporation;
20
24
  }
21
- /**
22
- * メモ
23
- */
24
- export interface INoteDigitalDocument extends Pick<CreativeWorkFactory.ICreativeWork, 'id' | 'typeOf'> {
25
+ export interface IProviderAsProject {
26
+ /**
27
+ * プロジェクトID
28
+ */
29
+ id: string;
30
+ typeOf: OrganizationType.Project;
31
+ }
32
+ export interface INoteCommonAttributes extends Pick<CreativeWorkFactory.ICreativeWork, 'id' | 'typeOf'> {
25
33
  /**
26
34
  * メモ識別子
27
35
  */
@@ -31,7 +39,6 @@ export interface INoteDigitalDocument extends Pick<CreativeWorkFactory.ICreative
31
39
  */
32
40
  text: string;
33
41
  project: Pick<IProject, 'id' | 'typeOf'>;
34
- about: IAbout;
35
42
  dateCreated: Date;
36
43
  dateModified?: Date;
37
44
  /**
@@ -42,13 +49,24 @@ export interface INoteDigitalDocument extends Pick<CreativeWorkFactory.ICreative
42
49
  * 変更者
43
50
  */
44
51
  editor?: IEditor;
45
- provider: IProvider;
46
52
  /**
47
53
  * バージョン
48
54
  */
49
55
  version: string;
50
56
  typeOf: CreativeWorkType.NoteDigitalDocument;
51
57
  }
58
+ export interface INoteAboutOrder extends INoteCommonAttributes {
59
+ about: IAboutAsOrder;
60
+ provider: IProviderAsSeller;
61
+ }
62
+ export interface INoteAboutProduct extends INoteCommonAttributes {
63
+ about: IAboutAsProduct;
64
+ provider: IProviderAsProject;
65
+ }
66
+ /**
67
+ * メモ
68
+ */
69
+ export type INoteDigitalDocument = INoteAboutOrder | INoteAboutProduct;
52
70
  /**
53
71
  * ソート条件
54
72
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chevre/factory",
3
- "version": "4.398.0",
3
+ "version": "4.399.0-alpha.0",
4
4
  "description": "Chevre Factory Library for Javascript",
5
5
  "main": "./lib/index.js",
6
6
  "types": "./lib/index.d.ts",