@chevre/factory 4.399.0-alpha.9 → 5.0.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.
- package/lib/action/check/paymentMethod/movieTicket.d.ts +2 -2
- package/lib/action/check/thing.d.ts +27 -0
- package/lib/action/consume/use/reservation.d.ts +2 -3
- package/lib/action/create.d.ts +19 -0
- package/lib/action/create.js +2 -0
- package/lib/action/update/add/object.d.ts +28 -0
- package/lib/action/update/add/object.js +2 -0
- package/lib/action/update/add.d.ts +18 -14
- package/lib/action/update/add.js +15 -0
- package/lib/action/update/replace.d.ts +1 -19
- package/lib/action/update/update/object.d.ts +47 -0
- package/lib/action/update/update/object.js +2 -0
- package/lib/action/update/update/result.d.ts +32 -0
- package/lib/action/update/update/result.js +2 -0
- package/lib/action/update/update/targetCollection.d.ts +32 -0
- package/lib/action/update/update/targetCollection.js +2 -0
- package/lib/action/update/update.d.ts +13 -45
- package/lib/action/update/update.js +17 -0
- package/lib/assetTransaction/reserve.d.ts +16 -2
- package/lib/event/anyEvent.d.ts +6 -223
- package/lib/event/screeningEvent.d.ts +24 -3
- package/lib/eventType.d.ts +0 -1
- package/lib/eventType.js +1 -1
- package/lib/index.d.ts +12 -10
- package/lib/index.js +12 -8
- package/lib/notification/event.d.ts +1 -2
- package/lib/offer/eventOffer.d.ts +18 -74
- package/lib/offer/productOffer.d.ts +152 -0
- package/lib/offer/productOffer.js +2 -0
- package/lib/project.d.ts +0 -4
- package/lib/report/accountingReport.d.ts +17 -0
- package/lib/reservation/pendingReservationPackage.d.ts +1 -1
- package/lib/task/aggregateScreeningEvent.d.ts +1 -1
- package/lib/task/checkResource.d.ts +2 -13
- package/lib/task/createAccountingReport.d.ts +2 -8
- package/lib/task/createEvent.d.ts +7 -28
- package/package.json +1 -1
- package/lib/action/check/token.d.ts +0 -23
- package/lib/action/check/token.js +0 -7
- package/lib/action/check.d.ts +0 -10
- /package/lib/action/{check.js → check/thing.js} +0 -0
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
import { issuer } from '../issuer';
|
|
2
|
+
import { ItemAvailability } from '../itemAvailability';
|
|
3
|
+
import { OfferType } from '../offerType';
|
|
4
|
+
import { OrganizationType } from '../organizationType';
|
|
5
|
+
import { SortType } from '../sortType';
|
|
6
|
+
type IValidForMemberTier = Pick<issuer.IMemberProgramTier, 'identifier' | 'typeOf'>;
|
|
7
|
+
interface IAcceptedPaymentMethod {
|
|
8
|
+
typeOf: 'PaymentMethod';
|
|
9
|
+
/**
|
|
10
|
+
* 決済方法区分コード
|
|
11
|
+
*/
|
|
12
|
+
identifier: string;
|
|
13
|
+
}
|
|
14
|
+
interface IOfferedByAsSeller {
|
|
15
|
+
id: string;
|
|
16
|
+
typeOf: OrganizationType.Corporation;
|
|
17
|
+
}
|
|
18
|
+
interface IOfferedByAsProject {
|
|
19
|
+
id: string;
|
|
20
|
+
typeOf: OrganizationType.Project;
|
|
21
|
+
}
|
|
22
|
+
type IOfferedBy = IOfferedByAsSeller | IOfferedByAsProject;
|
|
23
|
+
interface IProductOfferCommonAttributes {
|
|
24
|
+
project: {
|
|
25
|
+
id: string;
|
|
26
|
+
typeOf: OrganizationType.Project;
|
|
27
|
+
};
|
|
28
|
+
typeOf: OfferType.Offer;
|
|
29
|
+
/**
|
|
30
|
+
* プロダクトオファーコード
|
|
31
|
+
* プロダクトオファーコレクション内でユニーク
|
|
32
|
+
*/
|
|
33
|
+
identifier: string;
|
|
34
|
+
itemOffered: {
|
|
35
|
+
typeOf: OfferType.AggregateOffer;
|
|
36
|
+
/**
|
|
37
|
+
* プロダクトオファーコレクションコード
|
|
38
|
+
* オファーコレクションの識別子
|
|
39
|
+
*/
|
|
40
|
+
identifier: string;
|
|
41
|
+
};
|
|
42
|
+
offeredBy: IOfferedBy;
|
|
43
|
+
availability: ItemAvailability.InStock | ItemAvailability.OutOfStock;
|
|
44
|
+
validFrom: Date;
|
|
45
|
+
validThrough: Date;
|
|
46
|
+
}
|
|
47
|
+
interface IProductOfferAcceptedPaymentMethod extends IProductOfferCommonAttributes {
|
|
48
|
+
/**
|
|
49
|
+
* オファー提供プロジェクト
|
|
50
|
+
*/
|
|
51
|
+
offeredBy: IOfferedByAsProject;
|
|
52
|
+
acceptedPaymentMethod: IAcceptedPaymentMethod;
|
|
53
|
+
validForMemberTier?: never;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* メンバープログラムティアで有効なプロダクトオファー
|
|
57
|
+
*/
|
|
58
|
+
interface IProductOfferValidForMemberTier extends IProductOfferCommonAttributes {
|
|
59
|
+
/**
|
|
60
|
+
* オファー提供販売者
|
|
61
|
+
*/
|
|
62
|
+
offeredBy: IOfferedByAsSeller;
|
|
63
|
+
acceptedPaymentMethod?: never;
|
|
64
|
+
/**
|
|
65
|
+
* 有効なメンバープログラムティア
|
|
66
|
+
*/
|
|
67
|
+
validForMemberTier: IValidForMemberTier;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* プロダクトオファー
|
|
71
|
+
* 汎用的なオファー設定
|
|
72
|
+
*/
|
|
73
|
+
type IProductOffer = IProductOfferAcceptedPaymentMethod | IProductOfferValidForMemberTier;
|
|
74
|
+
interface ISearchConditions {
|
|
75
|
+
limit?: number;
|
|
76
|
+
page?: number;
|
|
77
|
+
sort?: {
|
|
78
|
+
validFrom?: SortType;
|
|
79
|
+
};
|
|
80
|
+
project?: {
|
|
81
|
+
id?: {
|
|
82
|
+
$eq?: string;
|
|
83
|
+
};
|
|
84
|
+
};
|
|
85
|
+
id?: {
|
|
86
|
+
$eq?: string;
|
|
87
|
+
};
|
|
88
|
+
/**
|
|
89
|
+
* オファーコード
|
|
90
|
+
*/
|
|
91
|
+
identifier?: {
|
|
92
|
+
$eq?: string;
|
|
93
|
+
$in?: string[];
|
|
94
|
+
};
|
|
95
|
+
itemOffered?: {
|
|
96
|
+
/**
|
|
97
|
+
* オファーコレクションコード
|
|
98
|
+
*/
|
|
99
|
+
identifier?: {
|
|
100
|
+
$eq?: string;
|
|
101
|
+
$in?: string[];
|
|
102
|
+
};
|
|
103
|
+
};
|
|
104
|
+
offeredBy?: {
|
|
105
|
+
/**
|
|
106
|
+
* オファー提供者ID
|
|
107
|
+
*/
|
|
108
|
+
id?: {
|
|
109
|
+
$eq?: string;
|
|
110
|
+
};
|
|
111
|
+
};
|
|
112
|
+
seller?: {
|
|
113
|
+
/**
|
|
114
|
+
* 提供販売者ID
|
|
115
|
+
*/
|
|
116
|
+
id?: {
|
|
117
|
+
$eq?: string;
|
|
118
|
+
};
|
|
119
|
+
};
|
|
120
|
+
validForMemberTier?: {
|
|
121
|
+
identifier?: {
|
|
122
|
+
$eq?: string;
|
|
123
|
+
};
|
|
124
|
+
};
|
|
125
|
+
validFrom?: {
|
|
126
|
+
$lte?: Date;
|
|
127
|
+
};
|
|
128
|
+
validThrough?: {
|
|
129
|
+
$gte?: Date;
|
|
130
|
+
};
|
|
131
|
+
}
|
|
132
|
+
/**
|
|
133
|
+
* メンバープログラムティア有効プロダクトオファー追加パラメータ
|
|
134
|
+
*/
|
|
135
|
+
interface IAddValidForMemberTierParams {
|
|
136
|
+
acceptedPaymentMethod?: never;
|
|
137
|
+
/**
|
|
138
|
+
* プロダクトオファーコード
|
|
139
|
+
* プロダクトオファーコレクション内でユニーク
|
|
140
|
+
*/
|
|
141
|
+
identifier: string;
|
|
142
|
+
validForMemberTier: {
|
|
143
|
+
/**
|
|
144
|
+
* プロダクトオファーコレクションコード
|
|
145
|
+
* オファーコレクションの識別子
|
|
146
|
+
*/
|
|
147
|
+
identifier: string;
|
|
148
|
+
};
|
|
149
|
+
validFrom: Date;
|
|
150
|
+
validThrough: Date;
|
|
151
|
+
}
|
|
152
|
+
export { IProductOffer, IProductOfferAcceptedPaymentMethod, IProductOfferValidForMemberTier, IValidForMemberTier, IAcceptedPaymentMethod, ISearchConditions, IAddValidForMemberTierParams };
|
package/lib/project.d.ts
CHANGED
|
@@ -58,10 +58,6 @@ export interface ISubscription {
|
|
|
58
58
|
* プロダクトの複数カタログ管理を利用するかどうか
|
|
59
59
|
*/
|
|
60
60
|
useMultipleProductCatalogs?: boolean;
|
|
61
|
-
/**
|
|
62
|
-
* メンバープログラムティア対応のイベントオファー使用有無
|
|
63
|
-
*/
|
|
64
|
-
useEventOfferValidForMemberTier?: boolean;
|
|
65
61
|
}
|
|
66
62
|
export type IHasMerchantReturnPolicy = Pick<IMerchantReturnPolicy, 'sameAs' | 'typeOf'> & {
|
|
67
63
|
/**
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { IAction as IPayAction, IPaymentService as IPayObject } from '../action/trade/pay';
|
|
2
2
|
import { IAction as IRefundAction, IPaymentService as IRefundObject } from '../action/trade/refund';
|
|
3
3
|
import { IAcceptedOffer, ICustomer, IItemOffered, IOrder } from '../order';
|
|
4
|
+
import { OrganizationType } from '../organizationType';
|
|
4
5
|
export type IPayActionObject = Pick<IPayObject, 'id' | 'paymentMethod' | 'typeOf'>;
|
|
5
6
|
export type IOptimizedPayAction = Pick<IPayAction, 'actionStatus' | 'endDate' | 'id' | 'purpose' | 'startDate' | 'typeOf'> & {
|
|
6
7
|
object: IPayActionObject[];
|
|
@@ -25,6 +26,22 @@ export interface IReport {
|
|
|
25
26
|
mainEntity: IOrderAsMainEntity;
|
|
26
27
|
};
|
|
27
28
|
}
|
|
29
|
+
export interface IChildReport {
|
|
30
|
+
typeOf: 'Report';
|
|
31
|
+
mainEntity: IAction;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* DB保存形式としての経理レポート
|
|
35
|
+
*/
|
|
36
|
+
export interface IReportDocument {
|
|
37
|
+
project: {
|
|
38
|
+
id: string;
|
|
39
|
+
typeOf: OrganizationType.Project;
|
|
40
|
+
};
|
|
41
|
+
typeOf: 'Report';
|
|
42
|
+
hasPart: IChildReport[];
|
|
43
|
+
mainEntity: IOrderAsMainEntity;
|
|
44
|
+
}
|
|
28
45
|
/**
|
|
29
46
|
* 検索条件
|
|
30
47
|
*/
|
|
@@ -3,7 +3,7 @@ import { EventType } from '../eventType';
|
|
|
3
3
|
import * as TaskFactory from '../task';
|
|
4
4
|
import { TaskName } from '../taskName';
|
|
5
5
|
export interface IData {
|
|
6
|
-
typeOf: EventType.
|
|
6
|
+
typeOf: EventType.ScreeningEvent;
|
|
7
7
|
id: string;
|
|
8
8
|
}
|
|
9
9
|
export interface IAttributes extends TaskFactory.IAttributes {
|
|
@@ -1,19 +1,8 @@
|
|
|
1
|
-
import { IAttributes as ICheckActionAttributes } from '../action/check';
|
|
1
|
+
import { IAttributes as ICheckActionAttributes } from '../action/check/thing';
|
|
2
2
|
import { IExtendId } from '../autoGenerated';
|
|
3
|
-
import { EventType } from '../eventType';
|
|
4
|
-
import { OrderType } from '../order';
|
|
5
3
|
import * as TaskFactory from '../task';
|
|
6
4
|
import { TaskName } from '../taskName';
|
|
7
|
-
export
|
|
8
|
-
id: string;
|
|
9
|
-
typeOf: EventType.ScreeningEvent;
|
|
10
|
-
}
|
|
11
|
-
export interface IResourceAsOrder {
|
|
12
|
-
orderNumber: string;
|
|
13
|
-
typeOf: OrderType.Order;
|
|
14
|
-
}
|
|
15
|
-
export type IResource = IResourceAsEvent | IResourceAsOrder;
|
|
16
|
-
export type IData = Pick<ICheckActionAttributes<IResource, any>, 'object' | 'project' | 'typeOf'>;
|
|
5
|
+
export type IData = Pick<ICheckActionAttributes, 'object' | 'typeOf'>;
|
|
17
6
|
export interface IAttributes extends TaskFactory.IAttributes {
|
|
18
7
|
name: TaskName.CheckResource;
|
|
19
8
|
data: IData;
|
|
@@ -1,15 +1,9 @@
|
|
|
1
|
+
import { IObject } from '../action/create';
|
|
1
2
|
import { IExtendId } from '../autoGenerated';
|
|
2
3
|
import * as TaskFactory from '../task';
|
|
3
4
|
import { TaskName } from '../taskName';
|
|
4
5
|
export interface IData {
|
|
5
|
-
object:
|
|
6
|
-
mainEntity: {
|
|
7
|
-
orderNumber: string;
|
|
8
|
-
};
|
|
9
|
-
};
|
|
10
|
-
project: {
|
|
11
|
-
id: string;
|
|
12
|
-
};
|
|
6
|
+
object: Pick<IObject, 'mainEntity'>;
|
|
13
7
|
}
|
|
14
8
|
export interface IAttributes extends TaskFactory.IAttributes {
|
|
15
9
|
name: TaskName.CreateAccountingReport;
|
|
@@ -1,40 +1,19 @@
|
|
|
1
|
-
import { IAttributes as
|
|
2
|
-
import { ActionType } from '../actionType';
|
|
3
|
-
import { CreativeWorkType } from '../creativeWorkType';
|
|
4
|
-
import { IAttributes as IScreeningEventAttributes } from '../event/screeningEvent';
|
|
5
|
-
import { IAttributes as IScreeningEventSeriesAttributes } from '../event/screeningEventSeries';
|
|
1
|
+
import { IAttributes as IAddActionAttributes, IInstrumentWithAddEventSeriesOption, IObjectAsEventBySchedule, IObjectAsEventSeriesAttributes } from '../action/update/add';
|
|
6
2
|
import { IExtendId } from '../autoGenerated';
|
|
7
3
|
import * as TaskFactory from '../task';
|
|
8
4
|
import { TaskName } from '../taskName';
|
|
9
|
-
export
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
createScreeningEventSeriesIfNotExistByWorkPerformed: true;
|
|
13
|
-
/**
|
|
14
|
-
* 全施設に施設コンテンツを作成するかどうか
|
|
15
|
-
*/
|
|
16
|
-
createScreeningEventSeriesOnAllLocation?: boolean;
|
|
17
|
-
}
|
|
18
|
-
export interface IEventBySchedule {
|
|
19
|
-
/**
|
|
20
|
-
* スケジュールを作成し始める日(Asia/Tokyoでこの日から作成される)
|
|
21
|
-
*/
|
|
22
|
-
startDate?: Date;
|
|
23
|
-
eventSchedule: {
|
|
24
|
-
id: string;
|
|
25
|
-
};
|
|
26
|
-
typeOf: IScreeningEventAttributes['typeOf'];
|
|
27
|
-
}
|
|
28
|
-
export type ICreateEventSeriesAction = Pick<IActionAttributes<ActionType.CreateAction, IScreeningEventSeriesAttributes[], undefined>, 'agent' | 'object' | 'project' | 'targetCollection' | 'typeOf'> & {
|
|
29
|
-
instrument: IActionInstrument;
|
|
5
|
+
export type IAddEventSeriesAction = Pick<IAddActionAttributes, 'agent' | 'object' | 'project' | 'targetCollection' | 'typeOf'> & {
|
|
6
|
+
object: IObjectAsEventSeriesAttributes[];
|
|
7
|
+
instrument: IInstrumentWithAddEventSeriesOption;
|
|
30
8
|
};
|
|
31
9
|
/**
|
|
32
10
|
* スケジュールによるイベント作成アクション
|
|
33
11
|
*/
|
|
34
|
-
export type
|
|
12
|
+
export type IAddEventByScheduleAction = Pick<IAddActionAttributes, 'agent' | 'object' | 'project' | 'targetCollection' | 'typeOf'> & {
|
|
13
|
+
object: IObjectAsEventBySchedule;
|
|
35
14
|
instrument?: never;
|
|
36
15
|
};
|
|
37
|
-
export type IData =
|
|
16
|
+
export type IData = IAddEventSeriesAction | IAddEventByScheduleAction;
|
|
38
17
|
export interface IAttributes extends TaskFactory.IAttributes {
|
|
39
18
|
name: TaskName.CreateEvent;
|
|
40
19
|
data: IData;
|
package/package.json
CHANGED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import * as ActionFactory from '../../action';
|
|
2
|
-
import * as CheckActionFactory from '../check';
|
|
3
|
-
export declare enum ObjectType {
|
|
4
|
-
Ticket = "Ticket"
|
|
5
|
-
}
|
|
6
|
-
export type IAgent = ActionFactory.IParticipantAsWebApplication | ActionFactory.IParticipantAsPerson | ActionFactory.IParticipantAsProject;
|
|
7
|
-
export interface IObject {
|
|
8
|
-
token: string;
|
|
9
|
-
typeOf: ObjectType;
|
|
10
|
-
}
|
|
11
|
-
export type IResult = any;
|
|
12
|
-
export type IError = any;
|
|
13
|
-
/**
|
|
14
|
-
* トークン検証アクション属性
|
|
15
|
-
*/
|
|
16
|
-
export interface IAttributes extends CheckActionFactory.IAttributes<IObject, IResult> {
|
|
17
|
-
agent: IAgent;
|
|
18
|
-
object: IObject;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* トークン検証アクション
|
|
22
|
-
*/
|
|
23
|
-
export type IAction = ActionFactory.IAction<IAttributes>;
|
package/lib/action/check.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import * as ActionFactory from '../action';
|
|
2
|
-
import { ActionType } from '../actionType';
|
|
3
|
-
export type IObject = any;
|
|
4
|
-
export type IResult = any;
|
|
5
|
-
export interface IAttributes<TObject, TResult> extends ActionFactory.IAttributes<ActionType.CheckAction, TObject, TResult> {
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* 確認アクション
|
|
9
|
-
*/
|
|
10
|
-
export type IAction<TAttributes extends IAttributes<IObject, IResult>> = ActionFactory.IAction<TAttributes>;
|
|
File without changes
|