@chevre/factory 5.3.0-alpha.3 → 5.3.0-alpha.5

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,4 +1,5 @@
1
1
  import * as ActionFactory from '../../action';
2
+ import { IPaymentMethodTicketAsInstrument } from '../../action/trade/pay';
2
3
  import { ActionType } from '../../actionType';
3
4
  import { IAgent, IObjectWithoutDetail, IPaymentMethodWithoutDetail } from '../../assetTransaction/pay';
4
5
  import { AssetTransactionType } from '../../assetTransactionType';
@@ -29,14 +30,7 @@ export interface IPurpose {
29
30
  typeOf: TransactionType.PlaceOrder;
30
31
  id: string;
31
32
  }
32
- /**
33
- * 決済方法チケット
34
- */
35
- export interface ITicketAsInstrument {
36
- ticketToken: string;
37
- typeOf: 'Ticket';
38
- }
39
- export type IInstrument = ITicketAsInstrument;
33
+ export type IInstrument = IPaymentMethodTicketAsInstrument;
40
34
  /**
41
35
  * 決済採用アクション属性
42
36
  */
@@ -98,6 +98,10 @@ export type IAuthorizeCreditCardObject = Pick<IObjectIncludingPaymentMethodDetai
98
98
  * 決済URL発行の場合、発行済のpaymentMethodIdを指定
99
99
  */
100
100
  paymentMethodId?: string;
101
+ /**
102
+ * 関連注文
103
+ * 指定すると、注文取引確定時にアイテムの整合性が検証される
104
+ */
101
105
  referencesOrder?: IInvoiceReferenceOrder;
102
106
  movieTickets?: never;
103
107
  fromLocation?: never;
@@ -11,7 +11,7 @@ import { IPropertyValue } from '../../propertyValue';
11
11
  import { IAlterTranResult, IRecipe as IPayCreditCardRecipe } from '../../recipe/payCreditCard';
12
12
  import { IRecipe as IPayMovieTicketRecipe, ISeatInfoSyncIn, ISeatInfoSyncResult } from '../../recipe/payMovieTicket';
13
13
  import { PaymentServiceType } from '../../service/paymentService';
14
- import { IAction as IAuthorizeInvoiceAction } from '../authorize/invoice';
14
+ import { IAction as IAuthorizePaymentAction } from '../authorize/paymentMethod/any';
15
15
  import { IPayTransactionAsPurpose, IRefundTransactionAsPurpose } from '../interact/inform';
16
16
  import { IAction as IRefundAction } from './refund';
17
17
  export { IAlterTranResult, ISeatInfoSyncIn, ISeatInfoSyncResult, IPayCreditCardRecipe, IPayMovieTicketRecipe };
@@ -110,14 +110,29 @@ export interface IPotentialActions {
110
110
  informPayment?: IInformPayment[];
111
111
  }
112
112
  export type IOrderAsInstrument = Pick<IOrder, 'orderNumber' | 'typeOf'>;
113
- export type IAuthorizeActionAsInstrument = Pick<IAuthorizeInvoiceAction, 'id' | 'typeOf'>;
113
+ export type IAuthorizeActionAsInstrument = Pick<IAuthorizePaymentAction, 'id' | 'typeOf'>;
114
114
  export interface IPayTransactionAsInstrument {
115
115
  id: string;
116
116
  transactionNumber: string;
117
117
  typeOf: AssetTransactionType.Pay;
118
118
  }
119
119
  export type IRefundActionAsInstrument = Pick<IRefundAction, 'id' | 'typeOf'>;
120
- export type IInstrument = IPayTransactionAsInstrument | IOrderAsInstrument | IAuthorizeActionAsInstrument | IRefundActionAsInstrument;
120
+ /**
121
+ * 決済方法チケット
122
+ */
123
+ export interface IPaymentMethodTicketAsInstrument {
124
+ ticketToken: string;
125
+ typeOf: 'Ticket';
126
+ }
127
+ /**
128
+ * 注文時の決済アクションツール
129
+ */
130
+ export type IPlaceOrderRelatedInstrument = IPayTransactionAsInstrument | IOrderAsInstrument | IAuthorizeActionAsInstrument | IPaymentMethodTicketAsInstrument;
131
+ /**
132
+ * 注文返品時の決済アクションツール
133
+ */
134
+ export type IReturnOrderRelatedInstrument = IRefundActionAsInstrument;
135
+ export type IInstrument = IPlaceOrderRelatedInstrument | IReturnOrderRelatedInstrument;
121
136
  export interface IResult {
122
137
  }
123
138
  export interface ILocation {
@@ -1,4 +1,4 @@
1
- import { IAction as IPayAction, IInstrument, ILocation, IMovieTicket, IOrderAsPayPurpose, IPendingTransaction, IRecipient as IPayRecipient } from '../action/trade/pay';
1
+ import { IAction as IPayAction, ILocation, IMovieTicket, IOrderAsPayPurpose, IPendingTransaction, IPlaceOrderRelatedInstrument, IRecipient as IPayRecipient } from '../action/trade/pay';
2
2
  import * as AssetTransactionFactory from '../assetTransaction';
3
3
  import { AssetTransactionType } from '../assetTransactionType';
4
4
  import { IExtendId } from '../autoGenerated';
@@ -161,7 +161,7 @@ export interface IStartParams extends AssetTransactionFactory.IStartParams<Asset
161
161
  /**
162
162
  * add(2025-02-18~)
163
163
  */
164
- instrument?: IInstrument[];
164
+ instrument?: IPlaceOrderRelatedInstrument[];
165
165
  }
166
166
  export interface IOptimizedPayAction4order {
167
167
  object: {
@@ -24,7 +24,7 @@ export type IPermitAsTypeOfGood = Pick<IPermitAsGood, 'identifier' | 'typeOf'> &
24
24
  /**
25
25
  * 決済方法チケットの請求情報
26
26
  */
27
- export interface IInvoiceAsPaymentMethodServiceOutput extends Pick<IResultAsInvoice, 'paymentMethodId' | 'referencesOrder'> {
27
+ export interface IInvoiceAsPaymentMethodServiceOutput extends Pick<IResultAsInvoice, 'paymentMethodId'> {
28
28
  typeOf: IInvoice['typeOf'];
29
29
  }
30
30
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chevre/factory",
3
- "version": "5.3.0-alpha.3",
3
+ "version": "5.3.0-alpha.5",
4
4
  "description": "Chevre Factory Library for Javascript",
5
5
  "main": "./lib/index.js",
6
6
  "types": "./lib/index.d.ts",