import type { COAFactory } from '@coasystems/factory'; import { ICreativeWork as IMovie } from '../creativeWork/movie'; import { IEvent as IBaseEvent, IAttributes as IBaseAttributes, ISearchConditions as IBaseSearchConditions } from '../event'; import { EventType } from '../eventType'; import { ILanguage } from '../language'; import { IMultilingualString } from '../multilingualString'; import { OfferType } from '../offerType'; import { PlaceType } from '../placeType'; export type IUnacceptedPaymentMethodType = 'MovieTicket'; /** * 施設コンテンツに対する単一オファー */ export interface ISingleOffer { typeOf: OfferType.Offer; /** * 利用不可決済方法区分 */ unacceptedPaymentMethod?: IUnacceptedPaymentMethodType[]; } export interface IVideoFormat { typeOf: string; name: string; } export interface ISoundFormat { typeOf: string; name: string; } /** * サブイベント * 施設コンテンツに所属するScreeningEventの属性など */ export interface ISubEvent { typeOf: EventType.ScreeningEvent; /** * 上映方式区分コードリスト */ videoFormat?: string[]; } export interface IOrganizer { /** * 販売者ID */ id: string; } /** * コンテンツ * contentRatingはCOAのみ存在 */ export type IWorkPerformed = Pick & { /** * 同コンテンツに対する複数施設コンテンツのバージョン * identifier+versionでuniqueな想定 */ version?: string; }; export interface IOrganizer { /** * 販売者ID */ id: string; } export type ICOAKubun = COAFactory.master.IKubunNameResult; export type ICOAInfo = Pick & { /** * 映倫区分 */ kbnEirin?: ICOAKubun; /** * 映像区分 * 2D、3D */ kbnEizou?: ICOAKubun; /** * 上映方式区分(IMAX,4DX等) */ kbnJoueihousiki?: ICOAKubun; /** * 字幕吹替区分(字幕、吹き替え) */ kbnJimakufukikae?: ICOAKubun; }; export interface ILocation { typeOf: PlaceType.MovieTheater; /** * 施設ID */ id: string; /** * コード */ branchCode: string; /** * 名称 */ name?: IMultilingualString; } export interface IAttributes extends Pick, 'project' | 'typeOf' | 'identifier' | 'name' | 'description' | 'eventStatus' | 'additionalProperty'> { alternativeHeadline?: IMultilingualString | string; headline?: IMultilingualString; /** * イベント上演時間 * ISO 8601 date format */ duration?: string; /** * 字幕利用可能言語 */ subtitleLanguage?: ILanguage; /** * 吹替利用可能言語 */ dubLanguage?: ILanguage; /** * 音響方式 */ soundFormat?: ISoundFormat[]; subEvent?: ISubEvent; /** * コンテンツ */ workPerformed: IWorkPerformed; /** * 施設 */ location: ILocation; organizer: IOrganizer; /** * カナ名称 */ kanaName: string; /** * 名称 */ name: IMultilingualString; /** * 終了日時 * ISO 8601 date format */ endDate: Date; /** * 開始日時 * ISO 8601 date format */ startDate: Date; /** * 販売情報 */ offers?: ISingleOffer; /** * その他COA情報 */ coaInfo?: ICOAInfo; } /** * 施設コンテンツ */ export type IEvent = IBaseEvent; /** * 施設コンテンツ追加時の利用不可決済方法区分指定 * offerType:AggregateOfferの場合、指定は無視される */ export type IOffers4create = Pick & { typeOf?: never; }; /** * 施設コンテンツ作成パラメータ */ export type ICreateParams = Pick & { subtitleLanguage?: Pick; dubLanguage?: Pick; location?: never; offers?: IOffers4create; workPerformed: { /** * コンテンツコード */ identifier: string; /** * 同コンテンツに対する複数施設コンテンツのバージョン * 施設+コンテンツ+バージョンでuniqueな想定 */ version: string; }; videoFormat: { /** * 上映方式区分コード */ typeOf: string; }[]; }; /** * 検索条件 */ export interface ISearchConditions extends Pick, 'additionalProperty' | 'endFrom' | 'endThrough' | 'eventStatuses' | 'id' | 'inSessionFrom' | 'inSessionThrough' | 'limit' | 'name' | 'organizer' | 'page' | 'project' | 'sort' | 'startFrom' | 'startThrough'> { location?: { branchCode?: { $eq?: string; $in?: string[]; }; /** * 施設コードリスト */ branchCodes?: string[]; /** * 施設ID */ id?: { $eq?: string; }; }; /** * 上映方式区分 * subEvent.videoFormatで検索します */ videoFormat?: { typeOf?: { $eq?: string; $in?: string[]; }; }; soundFormat?: { typeOf?: { $eq?: string; $in?: string[]; }; }; workPerformed?: { /** * コンテンツコード */ identifiers?: string[]; version?: { $eq?: string; }; }; }