@chevre/factory 4.399.0-alpha.12 → 4.399.0-alpha.14
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/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/update/object.d.ts +43 -0
- package/lib/action/update/update/object.js +2 -0
- package/lib/action/update/update/targetCollection.d.ts +31 -0
- package/lib/action/update/update/targetCollection.js +2 -0
- package/lib/action/update/update.d.ts +7 -43
- package/lib/action/update/update.js +16 -0
- package/lib/task/createEvent.d.ts +7 -28
- package/package.json +1 -1
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { CreativeWorkType } from '../../../creativeWorkType';
|
|
2
|
+
import { IAttributes as IEventSeriesAttributes } from '../../../event/screeningEventSeries';
|
|
3
|
+
import { EventType } from '../../../eventType';
|
|
4
|
+
import { OfferType } from '../../../offerType';
|
|
5
|
+
import { ProductType } from '../../../product';
|
|
6
|
+
export interface IObjectAsNote {
|
|
7
|
+
identifier: string;
|
|
8
|
+
typeOf: CreativeWorkType.NoteDigitalDocument;
|
|
9
|
+
}
|
|
10
|
+
export interface IObjectAsProduct {
|
|
11
|
+
productID: string;
|
|
12
|
+
typeOf: ProductType;
|
|
13
|
+
}
|
|
14
|
+
export interface IObjectAsSingleResource {
|
|
15
|
+
typeOf: OfferType.Offer | 'ProductModel' | CreativeWorkType.Movie | EventType;
|
|
16
|
+
}
|
|
17
|
+
export type IObjectAsEventSeriesAttributes = IEventSeriesAttributes;
|
|
18
|
+
export interface IObjectAsEventBySchedule {
|
|
19
|
+
/**
|
|
20
|
+
* スケジュールを作成し始める日(Asia/Tokyoでこの日から作成される)
|
|
21
|
+
*/
|
|
22
|
+
startDate?: Date;
|
|
23
|
+
eventSchedule: {
|
|
24
|
+
id: string;
|
|
25
|
+
};
|
|
26
|
+
typeOf: EventType.ScreeningEvent;
|
|
27
|
+
}
|
|
28
|
+
export type IObject = IObjectAsSingleResource | IObjectAsNote[] | IObjectAsProduct[] | IObjectAsEventSeriesAttributes[] | IObjectAsEventBySchedule;
|
|
@@ -2,32 +2,36 @@ import * as ActionFactory from '../../action';
|
|
|
2
2
|
import { ActionType } from '../../actionType';
|
|
3
3
|
import { IAbout as INoteAbout } from '../../creativeWork/noteDigitalDocument';
|
|
4
4
|
import { CreativeWorkType } from '../../creativeWorkType';
|
|
5
|
+
import { EventType } from '../../eventType';
|
|
6
|
+
import { OfferType } from '../../offerType';
|
|
5
7
|
import { ProductType } from '../../product';
|
|
8
|
+
import { IObject } from './add/object';
|
|
6
9
|
import { IInstrumentAsApplication } from './instrumentAsApplication';
|
|
10
|
+
export * from './add/object';
|
|
7
11
|
export type IAgent = ActionFactory.IParticipantAsPerson | ActionFactory.IParticipantAsWebApplication | ActionFactory.IParticipantAsSoftwareApplication;
|
|
8
|
-
export interface IObjectAsNote {
|
|
9
|
-
identifier: string;
|
|
10
|
-
typeOf: CreativeWorkType.NoteDigitalDocument;
|
|
11
|
-
}
|
|
12
|
-
export interface IObjectAsProduct {
|
|
13
|
-
productID: string;
|
|
14
|
-
typeOf: ProductType;
|
|
15
|
-
}
|
|
16
|
-
export type IObject = IObjectAsNote[] | IObjectAsProduct[];
|
|
17
12
|
export interface IAddedObject {
|
|
18
13
|
id: string;
|
|
19
|
-
typeOf: CreativeWorkType.NoteDigitalDocument | ProductType;
|
|
14
|
+
typeOf: CreativeWorkType.NoteDigitalDocument | ProductType | OfferType.Offer | 'ProductModel' | CreativeWorkType.Movie | EventType;
|
|
20
15
|
}
|
|
21
16
|
export type IResult = IAddedObject[];
|
|
22
|
-
export
|
|
17
|
+
export interface IInstrumentWithAddEventSeriesOption {
|
|
18
|
+
typeOf: CreativeWorkType.WebApplication;
|
|
19
|
+
id: string;
|
|
20
|
+
createScreeningEventSeriesIfNotExistByWorkPerformed: true;
|
|
21
|
+
/**
|
|
22
|
+
* 全施設に施設コンテンツを作成するかどうか
|
|
23
|
+
*/
|
|
24
|
+
createScreeningEventSeriesOnAllLocation?: boolean;
|
|
25
|
+
}
|
|
26
|
+
export type IInstrument = IInstrumentAsApplication | IInstrumentWithAddEventSeriesOption;
|
|
23
27
|
export interface ITargetCollectionAsNote {
|
|
24
28
|
typeOf: CreativeWorkType.NoteDigitalDocument;
|
|
25
29
|
about: Pick<INoteAbout, 'typeOf'>;
|
|
26
30
|
}
|
|
27
|
-
export interface
|
|
28
|
-
typeOf: ProductType;
|
|
31
|
+
export interface ITargetCollectionAsResource {
|
|
32
|
+
typeOf: ProductType | OfferType.Offer | 'ProductModel' | CreativeWorkType.Movie | EventType;
|
|
29
33
|
}
|
|
30
|
-
export type ITargetCollection = ITargetCollectionAsNote |
|
|
34
|
+
export type ITargetCollection = ITargetCollectionAsNote | ITargetCollectionAsResource;
|
|
31
35
|
export interface IAttributes extends Pick<ActionFactory.IAttributes<ActionType.AddAction, IObject, IResult>, 'typeOf' | 'targetCollection' | 'sameAs' | 'result' | 'project' | 'object' | 'instrument' | 'error' | 'agent'> {
|
|
32
36
|
potentialActions?: never;
|
|
33
37
|
purpose?: never;
|
package/lib/action/update/add.js
CHANGED
|
@@ -1,2 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
2
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./add/object"), exports);
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { ICreativeWork as IMovie } from '../../../creativeWork/movie';
|
|
2
|
+
import { CreativeWorkType } from '../../../creativeWorkType';
|
|
3
|
+
import { IEvent as IEventSeries } from '../../../event/screeningEventSeries';
|
|
4
|
+
import { EventType } from '../../../eventType';
|
|
5
|
+
import { IOfferCatalog } from '../../../offerCatalog';
|
|
6
|
+
import { IProduct } from '../../../product';
|
|
7
|
+
import { ReservationType } from '../../../reservationType';
|
|
8
|
+
import { ISeller } from '../../../seller';
|
|
9
|
+
import { TripType } from '../../../tripType';
|
|
10
|
+
import { IUnitPriceOffer } from '../../../unitPriceOffer';
|
|
11
|
+
export interface IObjectAsNote {
|
|
12
|
+
identifier: string;
|
|
13
|
+
typeOf: CreativeWorkType.NoteDigitalDocument;
|
|
14
|
+
}
|
|
15
|
+
export interface IObjectAsReservation {
|
|
16
|
+
id: string;
|
|
17
|
+
reservationNumber: string;
|
|
18
|
+
typeOf: ReservationType.EventReservation;
|
|
19
|
+
additionalTicketText?: string;
|
|
20
|
+
}
|
|
21
|
+
export interface IObjectAsEvent4ttts {
|
|
22
|
+
id: string;
|
|
23
|
+
identifier: string;
|
|
24
|
+
typeOf: EventType.ScreeningEvent;
|
|
25
|
+
}
|
|
26
|
+
export type IObjectAsOfferCatalog = Pick<IOfferCatalog, 'identifier' | 'typeOf'>;
|
|
27
|
+
export type IObjectAsOffer = Pick<IUnitPriceOffer, 'identifier' | 'typeOf'>;
|
|
28
|
+
export type IObjectAsProduct = Pick<IProduct, 'productID' | 'typeOf'>;
|
|
29
|
+
export type IObjectAsMovie = Pick<IMovie, 'identifier' | 'typeOf'>;
|
|
30
|
+
export type IObjectAsEventSeriesByVersion = Pick<IEventSeries, 'typeOf'> & {
|
|
31
|
+
workPerformed: {
|
|
32
|
+
identifier: string;
|
|
33
|
+
version: string;
|
|
34
|
+
};
|
|
35
|
+
location: {
|
|
36
|
+
branchCode: string;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
export interface IObjectAsResourceById {
|
|
40
|
+
id: string;
|
|
41
|
+
typeOf: IUnitPriceOffer['typeOf'] | IProduct['typeOf'] | 'ProductModel' | ISeller['typeOf'] | IMovie['typeOf'] | EventType | TripType;
|
|
42
|
+
}
|
|
43
|
+
export type IObject = IObjectAsOfferCatalog[] | IObjectAsOffer[] | IObjectAsProduct[] | IObjectAsMovie[] | IObjectAsEventSeriesByVersion[] | IObjectAsNote[] | IObjectAsResourceById[] | IObjectAsReservation | IObjectAsEvent4ttts;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { ICreativeWork as IMovie } from '../../../creativeWork/movie';
|
|
2
|
+
import { IAbout as INoteAbout } from '../../../creativeWork/noteDigitalDocument';
|
|
3
|
+
import { CreativeWorkType } from '../../../creativeWorkType';
|
|
4
|
+
import { IEvent as IEventSeries } from '../../../event/screeningEventSeries';
|
|
5
|
+
import { EventType } from '../../../eventType';
|
|
6
|
+
import { IOfferCatalog } from '../../../offerCatalog';
|
|
7
|
+
import { IProduct } from '../../../product';
|
|
8
|
+
import { ReservationType } from '../../../reservationType';
|
|
9
|
+
import { ISeller } from '../../../seller';
|
|
10
|
+
import { TripType } from '../../../tripType';
|
|
11
|
+
import { IUnitPriceOffer } from '../../../unitPriceOffer';
|
|
12
|
+
export interface ITargetCollectionAsNote {
|
|
13
|
+
typeOf: CreativeWorkType.NoteDigitalDocument;
|
|
14
|
+
about: Pick<INoteAbout, 'typeOf'>;
|
|
15
|
+
}
|
|
16
|
+
export interface ITargetCollectionAsReservation {
|
|
17
|
+
typeOf: ReservationType.EventReservation;
|
|
18
|
+
id: string;
|
|
19
|
+
}
|
|
20
|
+
export interface ITargetCollectionAsResource {
|
|
21
|
+
typeOf: EventType.ScreeningEvent | IOfferCatalog['typeOf'] | IUnitPriceOffer['typeOf'] | IProduct['typeOf'] | IMovie['typeOf'] | IEventSeries['typeOf'];
|
|
22
|
+
}
|
|
23
|
+
export interface ITargetCollectionAsEventById {
|
|
24
|
+
id: string;
|
|
25
|
+
typeOf: EventType;
|
|
26
|
+
}
|
|
27
|
+
export interface ITargetCollectionAsResourceById {
|
|
28
|
+
id: string;
|
|
29
|
+
typeOf: IUnitPriceOffer['typeOf'] | IProduct['typeOf'] | 'ProductModel' | ISeller['typeOf'] | IMovie['typeOf'] | EventType | TripType;
|
|
30
|
+
}
|
|
31
|
+
export type ITargetCollection = ITargetCollectionAsNote | ITargetCollectionAsReservation | ITargetCollectionAsResource | ITargetCollectionAsResourceById | ITargetCollectionAsEventById[];
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import * as ActionFactory from '../../action';
|
|
2
2
|
import { ActionType } from '../../actionType';
|
|
3
3
|
import { ICreativeWork as IMovie } from '../../creativeWork/movie';
|
|
4
|
-
import { IAbout as INoteAbout } from '../../creativeWork/noteDigitalDocument';
|
|
5
4
|
import { CreativeWorkType } from '../../creativeWorkType';
|
|
6
5
|
import { IEvent as IEventSeries } from '../../event/screeningEventSeries';
|
|
7
6
|
import { EventType } from '../../eventType';
|
|
@@ -10,36 +9,11 @@ import { IProduct } from '../../product';
|
|
|
10
9
|
import { ReservationType } from '../../reservationType';
|
|
11
10
|
import { IUnitPriceOffer } from '../../unitPriceOffer';
|
|
12
11
|
import { IInstrumentAsApplication } from './instrumentAsApplication';
|
|
12
|
+
import { IObject } from './update/object';
|
|
13
|
+
import { ITargetCollection } from './update/targetCollection';
|
|
14
|
+
export * from './update/object';
|
|
15
|
+
export * from './update/targetCollection';
|
|
13
16
|
export type IAgent = ActionFactory.IParticipantAsPerson | ActionFactory.IParticipantAsWebApplication | ActionFactory.IParticipantAsSoftwareApplication | ActionFactory.IParticipantAsProject;
|
|
14
|
-
export interface IObjectAsNote {
|
|
15
|
-
identifier: string;
|
|
16
|
-
typeOf: CreativeWorkType.NoteDigitalDocument;
|
|
17
|
-
}
|
|
18
|
-
export interface IObjectAsReservation {
|
|
19
|
-
id: string;
|
|
20
|
-
reservationNumber: string;
|
|
21
|
-
typeOf: ReservationType.EventReservation;
|
|
22
|
-
additionalTicketText?: string;
|
|
23
|
-
}
|
|
24
|
-
export interface IObjectAsEvent4ttts {
|
|
25
|
-
id: string;
|
|
26
|
-
identifier: string;
|
|
27
|
-
typeOf: EventType.ScreeningEvent;
|
|
28
|
-
}
|
|
29
|
-
export type IObjectAsOfferCatalog = Pick<IOfferCatalog, 'identifier' | 'typeOf'>;
|
|
30
|
-
export type IObjectAsOffer = Pick<IUnitPriceOffer, 'identifier' | 'typeOf'>;
|
|
31
|
-
export type IObjectAsProduct = Pick<IProduct, 'productID' | 'typeOf'>;
|
|
32
|
-
export type IObjectAsMovie = Pick<IMovie, 'identifier' | 'typeOf'>;
|
|
33
|
-
export type IObjectAsEventSeriesByVersion = Pick<IEventSeries, 'typeOf'> & {
|
|
34
|
-
workPerformed: {
|
|
35
|
-
identifier: string;
|
|
36
|
-
version: string;
|
|
37
|
-
};
|
|
38
|
-
location: {
|
|
39
|
-
branchCode: string;
|
|
40
|
-
};
|
|
41
|
-
};
|
|
42
|
-
export type IObject = IObjectAsOfferCatalog[] | IObjectAsOffer[] | IObjectAsProduct[] | IObjectAsMovie[] | IObjectAsEventSeriesByVersion[] | IObjectAsNote[] | IObjectAsReservation | IObjectAsEvent4ttts;
|
|
43
17
|
/**
|
|
44
18
|
* 汎用的なリソース編集結果
|
|
45
19
|
*/
|
|
@@ -55,23 +29,13 @@ export interface IUpdatedReservation {
|
|
|
55
29
|
typeOf: ReservationType.EventReservation;
|
|
56
30
|
additionalTicketText?: string;
|
|
57
31
|
}
|
|
58
|
-
export
|
|
32
|
+
export interface IResultAsNoContent {
|
|
33
|
+
}
|
|
34
|
+
export type IResult = IUpdatedResource[] | IUpdatedReservation | IResultAsNoContent;
|
|
59
35
|
export interface IInstrumentAsTask {
|
|
60
36
|
typeOf: 'Task';
|
|
61
37
|
}
|
|
62
38
|
export type IInstrument = IInstrumentAsApplication | IInstrumentAsTask;
|
|
63
|
-
export interface ITargetCollectionAsNote {
|
|
64
|
-
typeOf: CreativeWorkType.NoteDigitalDocument;
|
|
65
|
-
about: Pick<INoteAbout, 'typeOf'>;
|
|
66
|
-
}
|
|
67
|
-
export interface ITargetCollectionAsReservation {
|
|
68
|
-
typeOf: ReservationType.EventReservation;
|
|
69
|
-
id: string;
|
|
70
|
-
}
|
|
71
|
-
export interface ITargetCollectionAsResource {
|
|
72
|
-
typeOf: EventType.ScreeningEvent | IOfferCatalog['typeOf'] | IUnitPriceOffer['typeOf'] | IProduct['typeOf'] | IMovie['typeOf'] | IEventSeries['typeOf'];
|
|
73
|
-
}
|
|
74
|
-
export type ITargetCollection = ITargetCollectionAsNote | ITargetCollectionAsReservation | ITargetCollectionAsResource;
|
|
75
39
|
export interface IAttributes extends Pick<ActionFactory.IAttributes<ActionType.UpdateAction, IObject, IResult>, 'typeOf' | 'targetCollection' | 'sameAs' | 'result' | 'project' | 'object' | 'instrument' | 'error' | 'agent'> {
|
|
76
40
|
potentialActions?: never;
|
|
77
41
|
purpose?: never;
|
|
@@ -1,2 +1,18 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
2
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./update/object"), exports);
|
|
18
|
+
__exportStar(require("./update/targetCollection"), exports);
|
|
@@ -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;
|