@chevre/factory 4.324.0-alpha.2 → 4.324.0-alpha.4

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,11 +3,11 @@ import { IAction as IPayAction, IAttributes as IPayActionAttributes, ILocation,
3
3
  import * as AssetTransactionFactory from '../assetTransaction';
4
4
  import { AssetTransactionType } from '../assetTransactionType';
5
5
  import { IExtendId } from '../autoGenerated';
6
- import { ITotalPaymentDue } from '../order';
6
+ import { IOrderPaymentMethodIssuedThroughServiceOutput, ITotalPaymentDue } from '../order';
7
7
  import { IUnauthorizedCardOfMember, IUncheckedCardRaw, IUncheckedCardTokenized } from '../paymentMethod/paymentCard/creditCard';
8
8
  import { IOnPaymentStatusChanged } from '../project';
9
9
  import { IPropertyValue } from '../propertyValue';
10
- import { ICreditCardAsPaymentServiceOutput, PaymentServiceType } from '../service/paymentService';
10
+ import { PaymentServiceType } from '../service/paymentService';
11
11
  export import IAgent = AssetTransactionFactory.IAgent;
12
12
  export declare type IRecipient = IPayRecipient;
13
13
  /**
@@ -89,7 +89,7 @@ export interface IObject {
89
89
  * 発行決済サービスID
90
90
  */
91
91
  id: string;
92
- serviceOutput?: ICreditCardAsPaymentServiceOutput;
92
+ serviceOutput?: IOrderPaymentMethodIssuedThroughServiceOutput;
93
93
  paymentMethod: IPaymentMethod;
94
94
  pendingTransaction?: IPendingTransaction;
95
95
  entryTranArgs?: IEntryTranArgs;
package/lib/invoice.d.ts CHANGED
@@ -1,16 +1,16 @@
1
1
  import { IMonetaryAmount } from './monetaryAmount';
2
2
  import * as OrderFactory from './order';
3
3
  import { PaymentStatusType } from './paymentStatusType';
4
- import * as PersonFactory from './person';
4
+ import { IPerson } from './person';
5
5
  import { IAccounting } from './priceSpecification';
6
6
  import { IPriceSpecification as ICategoryCodeChargeSpecification } from './priceSpecification/categoryCodeChargeSpecification';
7
7
  import { IAppliesToMovieTicket, IPriceSpecification as IMovieTicketTypeChargeSpecification } from './priceSpecification/movieTicketTypeChargeSpecification';
8
8
  import { IAppliesToAddOn as IUnitPriceSpecAppliesToAddOn, IPriceSpecification as IUnitPriceSpecification } from './priceSpecification/unitPriceSpecification';
9
9
  import { IPriceSpecification } from './reservation/event';
10
- import * as SellerFactory from './seller';
11
- import { ICreditCardAsPaymentServiceOutput, PaymentServiceType } from './service/paymentService';
12
- export declare type IBroker = SellerFactory.ISeller | PersonFactory.IPerson;
13
- export declare type IProvider = SellerFactory.ISeller | PersonFactory.IPerson;
10
+ import { ISeller } from './seller';
11
+ import { PaymentServiceType } from './service/paymentService';
12
+ export declare type IBroker = Pick<ISeller, 'id' | 'typeOf'> | IPerson;
13
+ export declare type IProvider = Pick<ISeller, 'id' | 'typeOf'> | IPerson;
14
14
  export interface IReferenceOrder extends OrderFactory.IOrder {
15
15
  acceptedOffers: OrderFactory.IAcceptedOffer<OrderFactory.IItemOffered>[];
16
16
  }
@@ -57,7 +57,7 @@ export interface IMovieTicketAsPaymentServiceOutput {
57
57
  serviceOutput?: IReservation;
58
58
  amount?: IAmountOfMovieTicketAsPaymentServiceOutput;
59
59
  }
60
- export declare type IPaymentServiceOutput = IMovieTicketAsPaymentServiceOutput[] | ICreditCardAsPaymentServiceOutput;
60
+ export declare type IPaymentServiceOutput = IMovieTicketAsPaymentServiceOutput[] | OrderFactory.IOrderPaymentMethodIssuedThroughServiceOutput;
61
61
  /**
62
62
  * 決済方法(サービス)
63
63
  */
package/lib/order.d.ts CHANGED
@@ -10,7 +10,7 @@ import { IMultilingualString } from './multilingualString';
10
10
  import { IOffer } from './offer';
11
11
  import { OrderStatus } from './orderStatus';
12
12
  import { OrganizationType } from './organizationType';
13
- import * as PermitFactory from './permit';
13
+ import { IPermit as IBasePermit } from './permit';
14
14
  import { IPerson, IProfile } from './person';
15
15
  import { PersonType } from './personType';
16
16
  import { PlaceType } from './placeType';
@@ -24,6 +24,7 @@ import { IProgramMembershipUsedSearchConditions, ITicket, ITicketType } from './
24
24
  import * as BusReservationFactory from './reservation/busReservation';
25
25
  import * as EventReservationFactory from './reservation/event';
26
26
  import { ReservationType } from './reservationType';
27
+ import { ISeller as IBaseSeller } from './seller';
27
28
  import { ICreditCardAsPaymentServiceOutput, PaymentServiceType } from './service/paymentService';
28
29
  import { SortType } from './sortType';
29
30
  import { IUnitPriceOfferPriceSpecification } from './unitPriceOffer';
@@ -34,13 +35,19 @@ export interface IProject {
34
35
  export declare enum OrderType {
35
36
  Order = "Order"
36
37
  }
38
+ export interface IOrderPaymentMethodIssuedThroughServiceOutput extends ICreditCardAsPaymentServiceOutput {
39
+ amount?: {
40
+ currency: string;
41
+ value: number;
42
+ };
43
+ }
37
44
  export interface IOrderPaymentMethodIssuedThrough {
38
45
  typeOf: PaymentServiceType;
39
46
  /**
40
47
  * 発行決済サービスID
41
48
  */
42
49
  id: string;
43
- serviceOutput?: ICreditCardAsPaymentServiceOutput;
50
+ serviceOutput?: IOrderPaymentMethodIssuedThroughServiceOutput;
44
51
  }
45
52
  export interface ITotalPaymentDue extends Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'value'> {
46
53
  value: number;
@@ -117,7 +124,7 @@ export declare type IEventReservation = Pick<EventReservationFactory.IReservatio
117
124
  reservedTicket: IReservedTicket;
118
125
  };
119
126
  export declare type IReservation = IBusReservation | IEventReservation;
120
- export declare type IPermit = Pick<PermitFactory.IPermit, 'amount' | 'identifier' | 'issuedThrough' | 'name' | 'typeOf' | 'validFor'>;
127
+ export declare type IPermit = Pick<IBasePermit, 'amount' | 'identifier' | 'issuedThrough' | 'name' | 'typeOf' | 'validFor'>;
121
128
  export interface IMoneyTransferPendingTransaction {
122
129
  typeOf: AssetTransactionType.MoneyTransfer;
123
130
  /**
@@ -174,9 +181,8 @@ export interface IAcceptedOffer<T extends IItemOffered> extends IOfferOptimized4
174
181
  /**
175
182
  * 販売者
176
183
  */
177
- export interface ISeller {
184
+ export interface ISeller extends Pick<IBaseSeller, 'typeOf' | 'additionalProperty'> {
178
185
  id: string;
179
- typeOf: OrganizationType.Corporation;
180
186
  name: string;
181
187
  }
182
188
  /**
@@ -200,15 +206,12 @@ export declare type IParticipantAsReturner = IParticipantAsPerson | IParticipant
200
206
  export declare type IReturner = Pick<IParticipantAsReturner, 'id' | 'typeOf'>;
201
207
  export declare type IIdentifier = IPropertyValue<string>[];
202
208
  export declare type ISimpleCustomer = Pick<ICustomer, 'id' | 'typeOf'>;
209
+ export declare type ISimpleSeller = Pick<ISeller, 'id' | 'typeOf' | 'name'>;
203
210
  export interface ISimpleOrder {
204
211
  /**
205
212
  * object type
206
213
  */
207
214
  typeOf: OrderType;
208
- /**
209
- * The party taking the order (e.g. Amazon.com is a merchant for many sellers). Also accepts a string (e.g. "Amazon.com").
210
- */
211
- seller: ISeller;
212
215
  /**
213
216
  * Party placing the order.
214
217
  */
@@ -229,6 +232,7 @@ export interface ISimpleOrder {
229
232
  * Date order was placed.
230
233
  */
231
234
  orderDate: Date;
235
+ seller: ISimpleSeller;
232
236
  }
233
237
  export interface IReservationFor4EventServiceOrderedItem {
234
238
  location?: {
@@ -325,6 +329,10 @@ export interface IOrder extends Omit<ISimpleOrder, 'customer'> {
325
329
  * Returner
326
330
  */
327
331
  returner?: IReturner;
332
+ /**
333
+ * The party taking the order (e.g. Amazon.com is a merchant for many sellers). Also accepts a string (e.g. "Amazon.com").
334
+ */
335
+ seller: ISeller;
328
336
  /**
329
337
  * URL (recommended for confirmation cards/ Search Answers)
330
338
  * URL of the Order, typically a link to the merchant's website where the user can retrieve further details about an order.
@@ -91,7 +91,7 @@ export interface IStartParamsWithoutDetail {
91
91
  name?: string;
92
92
  };
93
93
  }
94
- export declare type ISeller = TransactionFactory.ISeller;
94
+ export declare type ISeller = TransactionFactory.ISeller & Pick<OrderFactory.ISeller, 'additionalProperty'>;
95
95
  /**
96
96
  * 取引開始パラメーター
97
97
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chevre/factory",
3
- "version": "4.324.0-alpha.2",
3
+ "version": "4.324.0-alpha.4",
4
4
  "description": "Chevre Factory Library for Javascript",
5
5
  "main": "./lib/index.js",
6
6
  "types": "./lib/index.d.ts",