@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel.usageType.dataClass: #TRANSACTIONAL
@ObjectModel.usageType.serviceQuality: #A
@ObjectModel.usageType.sizeCategory: #L
@ObjectModel.representativeKey: 'BillingDocumentRequest'
@ObjectModel.compositionRoot: true
@ObjectModel.modelingPattern: #ANALYTICAL_DIMENSION
@ObjectModel.supportedCapabilities: [ #ANALYTICAL_DIMENSION,
#CDS_MODELING_DATA_SOURCE,
#CDS_MODELING_ASSOCIATION_TARGET,
#SQL_DATA_SOURCE,
#EXTRACTION_DATA_SOURCE ]
@Analytics.dataCategory: #DIMENSION
@Analytics: {
dataExtraction: {
enabled: true,
delta.changeDataCapture: {
mapping:[
{
table: 'vbrk', role: #MAIN,
viewElement: ['BillingDocumentRequest'],
tableElement: ['vbeln']
}
]
}
}
}
@VDM.viewType: #BASIC
@AccessControl: {
authorizationCheck: #CHECK,
personalData.blocking: #('TRANSACTIONAL_DATA'),
privilegedAssociations: [ '_CreatedByUser', '_CreditControlAreaText' ]
}
@AbapCatalog: {
compiler.compareFilter: true,
sqlViewName: 'ISDBILDOCREQ',
preserveKey: true
}
@EndUserText.label: 'Billing Document Request'
@Metadata.allowExtensions: true
@Metadata.ignorePropagatedAnnotations: true
define view I_BillingDocumentRequest
as select from I_BillingDocumentBasic
association [0..*] to I_BillingDocumentRequestItem as _Item on $projection.BillingDocumentRequest = _Item.BillingDocumentRequest
association [1..*] to I_BillingDocReqPartner as _Partner on $projection.BillingDocumentRequest = _Partner.BillingDocumentRequest
association [0..*] to I_BillingDocReqPrcgElmnt as _PricingElement on $projection.BillingDocumentRequest = _PricingElement.BillingDocumentRequest
//Extensibility
association [0..1] to E_BillingDocument as _Extension on $projection.BillingDocumentRequest = _Extension.BillingDocument
{
//key
key cast (BillingDocument as vbeln_bdr preserving type) as BillingDocumentRequest,
//category
@ObjectModel.foreignKey.association: '_SDDocumentCategory'
SDDocumentCategory,
@ObjectModel.foreignKey.association: '_BillingDocumentRequestType'
cast (BillingDocumentType as sdbil_odata_bdr_type preserving type ) as BillingDocumentRequestType,
@ObjectModel.foreignKey.association: '_ProposedBillingDocumentType'
cast (ProposedBillingDocumentType as proposed_billing_document_type preserving type ) as ProposedBillingDocumentType,
//admin
@Semantics.user.createdBy: true
CreatedByUser,
@Semantics.systemDate.createdAt: true
CreationDate,
@Semantics.systemTime.createdAt
CreationTime,
@Semantics.systemDate.lastChangedAt: true
LastChangeDate,
@Semantics.systemDateTime.lastChangedAt: true
LastChangeDateTime,
@ObjectModel.foreignKey.association: '_LogicalSystem'
LogicalSystem,
//org
@ObjectModel.foreignKey.association: '_SalesOrganization'
SalesOrganization,
@ObjectModel.foreignKey.association: '_DistributionChannel'
DistributionChannel,
@ObjectModel.foreignKey.association: '_Division'
Division,
//billing
BillingDocumentDate,
cast (BillingDocCombinationCriteria as billg_doc_req_combn_criteria preserving type ) as BillgDocReqCombinationCriteria,
//pricing
@Semantics.amount.currencyCode: 'TransactionCurrency'
TotalNetAmount,
@Semantics.currencyCode: true
@ObjectModel.foreignKey.association: '_TransactionCurrency'
TransactionCurrency,
@Semantics.amount.currencyCode: 'TransactionCurrency'
TotalTaxAmount,
@ObjectModel.foreignKey.association: '_CustomerPriceGroup'
CustomerPriceGroup,
@ObjectModel.foreignKey.association: '_PriceListType'
PriceListType,
@ObjectModel.foreignKey.association: '_TaxDepartureCountry'
TaxDepartureCountry,
VATRegistration,
@ObjectModel.foreignKey.association: '_VATRegistrationOrigin'
VATRegistrationOrigin,
@ObjectModel.foreignKey.association: '_VATRegistrationCountry'
VATRegistrationCountry,
CustomerTaxClassification1,
CustomerTaxClassification2,
CustomerTaxClassification3,
CustomerTaxClassification4,
CustomerTaxClassification5,
CustomerTaxClassification6,
CustomerTaxClassification7,
CustomerTaxClassification8,
CustomerTaxClassification9,
@ObjectModel.foreignKey.association: '_SDPricingProcedure'
SDPricingProcedure,
//shipping
@ObjectModel.foreignKey.association: '_IncotermsVersion'
IncotermsVersion,
@ObjectModel.foreignKey.association: '_IncotermsClassification'
IncotermsClassification,
IncotermsTransferLocation,
IncotermsLocation1,
IncotermsLocation2,
//payment
@Consumption.valueHelpDefinition: [
{ entity: { name: 'I_Customer_VH',
element: 'Customer' }
}]
@ObjectModel.foreignKey.association: '_PayerParty'
PayerParty,
ContractAccount,
@ObjectModel.foreignKey.association: '_CustomerPaymentTerms'
CustomerPaymentTerms,
@ObjectModel.foreignKey.association: '_PaymentMethod'
PaymentMethod,
FixedValueDate,
AdditionalValueDays,
SEPAMandate,
//accounting
@Consumption.valueHelpDefinition: [
{ entity: { name: 'I_CompanyCodeStdVH',
element: 'CompanyCode' }
}]
@ObjectModel.foreignKey.association: '_CompanyCode'
CompanyCode,
@ObjectModel.foreignKey.association: '_CustomerAccountAssgmtGroup'
CustomerAccountAssignmentGroup,
ExchangeRateDate,
@ObjectModel.foreignKey.association: '_ExchangeRateType'
ExchangeRateType,
DocumentReferenceID,
@ObjectModel.foreignKey.association: '_DunningArea'
DunningArea,
@ObjectModel.foreignKey.association: '_DunningBlockingReason'
DunningBlockingReason,
@ObjectModel.foreignKey.association: '_DunningKey'
DunningKey,
//reference
cast ( BillingDocRequestReference as sdbil_odata_source_document preserving type ) as ReferenceDocument,
cast ( BillgDocReqRefLgclSyst as sdbil_odata_source_system preserving type ) as ReferenceDocumentLogicalSystem,
@ObjectModel.foreignKey.association: '_ReferenceDocSDDocCategory'
cast ( BillgDocReqRefSDDocCategory as sdbil_odata_src_doc_cat preserving type ) as ReferenceDocSDDocCategory,
//sales
@Consumption.valueHelpDefinition: [
{ entity: { name: 'I_Customer_VH',
element: 'Customer' }
}]
@ObjectModel.foreignKey.association: '_SoldToParty'
SoldToParty,
PurchaseOrderByCustomer,
@ObjectModel.foreignKey.association: '_CustomerGroup'
CustomerGroup,
@ObjectModel.foreignKey.association: '_Country'
Country,
@ObjectModel.foreignKey.association: '_CityCode'
CityCode,
@ObjectModel.foreignKey.association: '_SalesDistrict'
SalesDistrict,
@ObjectModel.foreignKey.association: '_Region'
Region,
@ObjectModel.foreignKey.association: '_County_2'
County,
@Consumption.valueHelpDefinition: [
{ entity: { name: 'I_CreditControlAreaStdVH',
element: 'CreditControlArea' }
}]
@ObjectModel.text.association: '_CreditControlAreaText'
@ObjectModel.foreignKey.association: '_CreditControlArea'
CreditControlArea,
PricingDocument,
//status
@ObjectModel.foreignKey.association: '_OvrlBillingDocReqStatus'
OverallBillingDocReqStatus,
@ObjectModel.foreignKey.association: '_BillingIssueType'
BillingIssueType,
@ObjectModel.foreignKey.association: '_OverallPricingIncompletionSts'
OverallPricingIncompletionSts,
//association
@ObjectModel.association.type: [#TO_COMPOSITION_CHILD]
_Item,
@ObjectModel.association.type: [#TO_COMPOSITION_CHILD]
_Partner,
@ObjectModel.association.type: [#TO_COMPOSITION_CHILD]
_PricingElement,
_SDDocumentCategory,
_BillgDocReqRefSDDocCategory as _ReferenceDocSDDocCategory,
_BillingDocumentType as _BillingDocumentRequestType,
_ProposedBillingDocumentType,
_CreatedByUser,
_LogicalSystem,
_SalesOrganization,
_DistributionChannel,
_Division,
_TransactionCurrency,
_CustomerPriceGroup,
_PriceListType,
_TaxDepartureCountry,
_VATRegistrationOrigin,
_VATRegistrationCountry,
_SDPricingProcedure,
_IncotermsClassification,
_IncotermsVersion,
_PayerParty,
_CustomerPaymentTerms,
_PaymentMethod,
_CompanyCode,
_CustomerAccountAssgmtGroup,
_ExchangeRateType,
_DunningArea,
_DunningBlockingReason,
_DunningKey,
_SoldToParty,
_CustomerGroup,
_Country,
_CityCode,
_SalesDistrict,
_Region,
@API.element: { releaseState: #DEPRECATED, successor: '_County_2' }
_County,
_County_2,
_CreditControlArea,
_OvrlBillingDocReqStatus,
_BillingIssueType,
_OverallPricingIncompletionSts,
@Consumption.hidden: true
_CreditControlAreaText
}
where
SDDocumentCategory = 'EBDR';
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_BILLINGDOCUMENTBASIC"
],
"ASSOCIATED":
[
"E_BILLINGDOCUMENT",
"I_BILLINGDOCREQPARTNER",
"I_BILLINGDOCREQPRCGELMNT",
"I_BILLINGDOCUMENTREQUESTITEM",
"I_BILLINGDOCUMENTTYPE",
"I_BILLINGISSUETYPE",
"I_CITYCODE",
"I_COMPANYCODE",
"I_COUNTRY",
"I_COUNTYCODE",
"I_CREDITCONTROLAREA",
"I_CREDITCONTROLAREATEXT",
"I_CURRENCY",
"I_CUSTOMER",
"I_CUSTOMERACCOUNTASSGMTGROUP",
"I_CUSTOMERGROUP",
"I_CUSTOMERPAYMENTTERMS",
"I_CUSTOMERPRICEGROUP",
"I_DISTRIBUTIONCHANNEL",
"I_DIVISION",
"I_DUNNINGAREA",
"I_DUNNINGBLOCKINGREASONCODE",
"I_DUNNINGKEY",
"I_EXCHANGERATETYPE",
"I_INCOTERMSCLASSIFICATION",
"I_INCOTERMSVERSION",
"I_LOGICALSYSTEM",
"I_OVERALLPRCINCOMPLETIONSTS",
"I_OVRLBILLINGDOCREQSTATUS",
"I_PAYMENTMETHOD",
"I_PRICELISTTYPE",
"I_REGION",
"I_SALESDISTRICT",
"I_SALESORGANIZATION",
"I_SDDOCUMENTCATEGORY",
"I_SLSPRICINGPROCEDURE",
"I_TAXINGCOUNTY",
"I_USER",
"I_VATREGISTRATIONORIGIN"
],
"BASE":
[
"I_BILLINGDOCUMENTBASIC"
],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/