@chevre/factory 4.399.0-alpha.2 → 4.399.0-alpha.3
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.d.ts +41 -0
- package/lib/action/update/add.js +2 -0
- package/lib/actionType.d.ts +1 -0
- package/lib/actionType.js +1 -0
- package/lib/index.d.ts +2 -0
- package/lib/index.js +2 -0
- package/package.json +1 -1
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import * as ActionFactory from '../../action';
|
|
2
|
+
import { ActionType } from '../../actionType';
|
|
3
|
+
import { IAbout as INoteAbout } from '../../creativeWork/noteDigitalDocument';
|
|
4
|
+
import { CreativeWorkType } from '../../creativeWorkType';
|
|
5
|
+
import { ProductType } from '../../product';
|
|
6
|
+
export type IAgent = ActionFactory.IParticipantAsPerson | ActionFactory.IParticipantAsWebApplication | ActionFactory.IParticipantAsSoftwareApplication;
|
|
7
|
+
export interface IObjectAsNote {
|
|
8
|
+
identifier: string;
|
|
9
|
+
typeOf: CreativeWorkType.NoteDigitalDocument;
|
|
10
|
+
}
|
|
11
|
+
export interface IObjectAsProduct {
|
|
12
|
+
productID: string;
|
|
13
|
+
typeOf: ProductType;
|
|
14
|
+
}
|
|
15
|
+
export type IObject = IObjectAsNote | IObjectAsProduct;
|
|
16
|
+
export interface IAddedObject {
|
|
17
|
+
id: string;
|
|
18
|
+
typeOf: CreativeWorkType.NoteDigitalDocument | ProductType;
|
|
19
|
+
}
|
|
20
|
+
export type IResult = IAddedObject[];
|
|
21
|
+
export interface IInstrument {
|
|
22
|
+
typeOf: CreativeWorkType.WebApplication | CreativeWorkType.SoftwareApplication;
|
|
23
|
+
id: string;
|
|
24
|
+
}
|
|
25
|
+
export interface ITargetCollectionAsNote {
|
|
26
|
+
typeOf: CreativeWorkType.NoteDigitalDocument;
|
|
27
|
+
about: Pick<INoteAbout, 'id' | 'typeOf'>;
|
|
28
|
+
}
|
|
29
|
+
export interface ITargetCollectionAsProduct {
|
|
30
|
+
typeOf: ProductType;
|
|
31
|
+
}
|
|
32
|
+
export type ITargetCollection = ITargetCollectionAsNote;
|
|
33
|
+
export interface IAttributes extends Pick<ActionFactory.IAttributes<ActionType.AddAction, IObject, IResult>, 'typeOf' | 'targetCollection' | 'sameAs' | 'result' | 'project' | 'object' | 'instrument' | 'error' | 'agent'> {
|
|
34
|
+
potentialActions?: never;
|
|
35
|
+
instrument: IInstrument;
|
|
36
|
+
targetCollection: ITargetCollection;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* 追加アクション
|
|
40
|
+
*/
|
|
41
|
+
export type IAction = ActionFactory.IAction<IAttributes>;
|
package/lib/actionType.d.ts
CHANGED
package/lib/actionType.js
CHANGED
|
@@ -6,6 +6,7 @@ exports.ActionType = void 0;
|
|
|
6
6
|
*/
|
|
7
7
|
var ActionType;
|
|
8
8
|
(function (ActionType) {
|
|
9
|
+
ActionType["AddAction"] = "AddAction";
|
|
9
10
|
ActionType["AcceptAction"] = "AcceptAction";
|
|
10
11
|
ActionType["AuthorizeAction"] = "AuthorizeAction";
|
|
11
12
|
ActionType["CancelAction"] = "CancelAction";
|
package/lib/index.d.ts
CHANGED
|
@@ -42,6 +42,7 @@ import * as ReturnPointAwardActionFactory from './action/transfer/return/pointAw
|
|
|
42
42
|
import * as ReturnReserveTransactionActionFactory from './action/transfer/return/reserveTransaction';
|
|
43
43
|
import * as SendEmailMessageActionFactory from './action/transfer/send/message/email';
|
|
44
44
|
import * as SendOrderActionFactory from './action/transfer/send/order';
|
|
45
|
+
import * as AddActionFactory from './action/update/add';
|
|
45
46
|
import * as DeleteActionFactory from './action/update/delete';
|
|
46
47
|
import * as DeleteMemberActionFactory from './action/update/delete/member';
|
|
47
48
|
import * as ReplaceActionFactory from './action/update/replace';
|
|
@@ -325,6 +326,7 @@ export declare namespace action {
|
|
|
325
326
|
}
|
|
326
327
|
}
|
|
327
328
|
namespace update {
|
|
329
|
+
export import add = AddActionFactory;
|
|
328
330
|
namespace deleteAction {
|
|
329
331
|
export import IAction = DeleteActionFactory.IAction;
|
|
330
332
|
export import IAttributes = DeleteActionFactory.IAttributes;
|
package/lib/index.js
CHANGED
|
@@ -42,6 +42,7 @@ var ReturnPointAwardActionFactory = require("./action/transfer/return/pointAward
|
|
|
42
42
|
var ReturnReserveTransactionActionFactory = require("./action/transfer/return/reserveTransaction");
|
|
43
43
|
var SendEmailMessageActionFactory = require("./action/transfer/send/message/email");
|
|
44
44
|
var SendOrderActionFactory = require("./action/transfer/send/order");
|
|
45
|
+
var AddActionFactory = require("./action/update/add");
|
|
45
46
|
var DeleteMemberActionFactory = require("./action/update/delete/member");
|
|
46
47
|
var ReplaceActionFactory = require("./action/update/replace");
|
|
47
48
|
var actionStatusType_1 = require("./actionStatusType");
|
|
@@ -308,6 +309,7 @@ var action;
|
|
|
308
309
|
})(transfer = action.transfer || (action.transfer = {}));
|
|
309
310
|
var update;
|
|
310
311
|
(function (update) {
|
|
312
|
+
update.add = AddActionFactory;
|
|
311
313
|
var deleteAction;
|
|
312
314
|
(function (deleteAction) {
|
|
313
315
|
deleteAction.member = DeleteMemberActionFactory;
|