Views: 264
デジタル自動処理と金額の検算ルール
Nobuyuki SAMBUICHI
ISO/TC295 Audit data services/SG1 Semantic model Convener
デジタルインボイスは、C4で受け取ったデジタルデータをいかに後続の自動処理につなげられるかで導入効果が左右されます。
受け取ったデジタルインボイスを一つ一つ担当者が目視確認することなく、後続のワークフローに繋げ、例外的な内容のみ担当者が確認するようにできれば、作業負荷の軽減につながります。
デジタルインボイスに記載された金額が決められた条件を満足していて、要請される税額計算の条件を満足しているかといった形式的な確認は、経理担当者が検算しなくてもコンピュータで検算するほうがミスも少なく効率的です。
Open Peppol BIS Billing 3.0では、デジタルインボイスの記載項目の形式や項目間の金額計算の妥当性をXML技術のスキーマトロンを使用して検証していました。JP PINT V1.0も同様の検証環境を採用していますが、Open Peppol International Invoice (PINT) で提供されるスキーマトロンファイルで可能な検証の範囲が縮小されています。
この記事では、Allowance(返金)やCharge(追加請求)を含む金額計算や税額の計算の金額の検算ルールをBIS Billing 3.0のルールと比較して紹介します。
インボイスのデジタル自動処理と金額の検算ルールという実務の観点からは、BIS Billing 3.0のルールで提供されていたいくつかのルールが廃止されていますので下記をご確認ください。
Peppol BIS Standard Invoice JP PINT 画面の左下にある Download resources ボタンに気をとめられる方は少ないかもしれませんが、このボタンでダウンロードされる resources.zip ファイルには、パッケージやサービスのJP PINT対応開発に役立ついくつかのファイルが含まれています。
今回の『解体新書』シリーズでは、いくつかのファイルの内容を確認しながらUBL 2.1に基づくJP PINTのXMLインスタンス文書がどのように定義されているのか紹介します。
-
Japan PINT Invoice UBL Example.xml JP PINT 解体新書1.a 文書レベル JP PINT 解体新書1.b 明細行レベル
-
Japan PINT Invoice UBL Example1-minimum.xml JP PINT 解体新書2 適格請求書最小構成
-
Japan PINT Invoice UBL Example2-TaxAcctCur.xml
-
Japan PINT Invoice UBL Example3-SumInv1.xml
-
Japan PINT Invoice UBL Example4-SumInv2.xml
-
Japan PINT Invoice UBL Example5-AllowanceCharge.xml JP PINT 解体新書3 返金及び追加請求 (Allowance & Charge)
-
Japan PINT Invoice UBL Example6-CorrInv.xml
-
Japan PINT Invoice UBL Example7-Return.Quan.ItPr.xml
-
Japan PINT Invoice UBL Example9-SumInv1 and O.xml
-
全般
JP PINT 解体新書4 デジタル自動処理と金額の検算ルール
JP PINT V1.0 正誤表
CEF eInvoicingに基づいたJP PINT1.0ルール検証環境とテスト
Japan PINT Invoice UBL Example.xmlをHTML変換表示
そして
会計のデジタル化は日本版コアインボイスから
本シリーズは、システム開発者(プログラマー / システムエンジニア)を対象としており、読者がXMLスキーマを理解していることを前提として記述しています。また、XPathについても基本的な事項を理解されていると想定しています。
『EN 16931-1 Annnex A 電子インボイスの例』 には、欧州規格で紹介されているデジタルインボイスの記載例について紹介していますので併せてご覧ください。
ご参考:
当事務所提供 JP PINT実証研究ページ
(翻訳したセマンティックモデルやUBL2.1からの構文バインディングも含んでいます)
第4回目は、明細行の請求金額、課税区分別の税額計算、文書レベルでの各種合計金額についてのJP PINTの検証ルールをBIS Billing 3.0で提供されているルールと比較して紹介します。
BIS Billing 3.0のルールは、
Peppol BIS Billing 3.0 / Home / Downloads
ページの次のリンクからダウンロード可能です。
Schematron for PEPPOL rules (UBL)
Schematron file containing rules according to ISO Schematron.
Schematron for TC434 rules (UBL)
Schematron file containing rules according to ISO Schematron.
-
注 BIS Billing 3.0では、 9. Calculation で規定した全ての計算式についてデジタルインボイスがその計算式に従った値を記載しているか検証することで規格に準拠しているか検証していました。
JP PINT V1.0では、後述するように一部の計算式についての妥当性検証ルールが提供されていませんので、受信したデジタルインボイスをあらためて検証しなおす必要がることに留意してください。
こちらの記事 『BIS Billing 3.0からJP PINT 0.9.3に引き継がれなかった検証ルール』 もご確認ください。
1. 品目単価(値引後)(税抜き)
ibt-146 Item net price 品目単価(値引後)(税抜き)
The price of an item, exclusive of TAX, after subtracting item price discount.
値引金額を差し引いた後の、消費税を除く品目単価。
Item net price (IBT-146)
計算式 | JP PINT V1.0 | BIS Billing 3.0 |
---|---|---|
Item net price (IBT-146) = Item gross price (IBT-148) – Item price discount (IBT-147) |
無し |
PEPPOL-EN16931-R046 not(cbc:BaseAmount) or |
-
注 BIS Billing 3.0では、「値引金額を差し引いた後の、消費税を除く品目単価」の計算結果が妥当か判定するルールが提供されていましたが、このルールがJP PINT V1.0では廃止されており、検証できません。
2. 値引後請求書明細行金額(税抜き)
ibt-131 Invoice line net amount 値引後請求書明細行金額(税抜き)
The total amount of the Invoice line (before tax).
値引後の請求書明細行の合計金額(税抜き)。
Invoice line net amount (IBT-131)
計算式 | JP PINT V1.0 | BIS Billing 3.0 |
---|---|---|
Item line net amount = Item net price (IBT-146) div Item price base quantity (IBT-149 |
無し |
PEPPOL-EN16931-R120 u:slack($lineExtensionAmount, ($quantity * ($priceAmount div $baseQuantity)) + $chargesTotal – $allowancesTotal, 0.02) |
-
注1 BIS Billing 3.0では、「値引後の請求書明細行の合計金額(税抜き)」の計算結果が妥当か判定するルールが提供されていましたが、このルールがJP PINT V1.0では廃止されており、検証できません。
-
注2 u:slack() 関数は、次の定義です。
<function xmlns="http://www.w3.org/1999/XSL/Transform" name="u:slack" as="xs:boolean"> <param name="exp" as="xs:decimal"/> <param name="val" as="xs:decimal"/> <param name="slack" as="xs:decimal"/> <value-of select="xs:decimal($exp + $slack) >= $val and xs:decimal($exp - $slack) <= $val"/> </function>
デジタルインボイス上に記載された値 $exp が、計算結果 $val と ± $slack 値の範囲に入っているかを判定します。ここでは、計算結果が±0.02の範囲内か判定しています。
-
注3 $lineExtensionAmount, $quantity, $priceAmount, $baseQuantity, $chargesTotal, $allowancesTotalは、次の式で求めたパラメタです。
<let name="lineExtensionAmount" value=" if (cbc:LineExtensionAmount) then xs:decimal(cbc:LineExtensionAmount) else 0"/> <let name="quantity" value=" if (/ubl-invoice:Invoice) then (if (cbc:InvoicedQuantity) then xs:decimal(cbc:InvoicedQuantity) else 1) else (if (cbc:CreditedQuantity) then xs:decimal(cbc:CreditedQuantity) else 1)"/> <let name="priceAmount" value=" if (cac:Price/cbc:PriceAmount) then xs:decimal(cac:Price/cbc:PriceAmount) else 0"/> <let name="baseQuantity" value=" if (cac:Price/cbc:BaseQuantity and xs:decimal(cac:Price/cbc:BaseQuantity) != 0) then xs:decimal(cac:Price/cbc:BaseQuantity) else 1"/> <let name="allowancesTotal" value=" if (cac:AllowanceCharge[normalize-space(cbc:ChargeIndicator) = 'false']) then round(sum(cac:AllowanceCharge[normalize-space(cbc:ChargeIndicator) = 'false']/cbc:Amount/xs:decimal(.)) * 10 * 10) div 100 else 0"/> <let name="chargesTotal" value=" if (cac:AllowanceCharge[normalize-space(cbc:ChargeIndicator) = 'true']) then round(sum(cac:AllowanceCharge[normalize-space(cbc:ChargeIndicator) = 'true']/cbc:Amount/xs:decimal(.)) * 10 * 10) div 100 else 0"/>
Schematron for PEPPOL rules (UBL): PEPPOL-EN16931-R120 test
Allowance(返金)やCharge(追加請求)は、明細行に複数指定可能ですから sum() 関数を言使用しています。
返金と追加請求がそれぞれ複数ある場合がありますので、単純な四則演算式よりも合計計算のΣ がふさわしいと思います。
Item line net amount=Item net price (IBT-146)÷Item price base quantity (IBT-149 × (Invoiced Quantity (IBT-129))
+ Σ Invoice line charge amount (IBT-141) − Σ Invoice line allowance amount (IBT-136)
3. 課税分類毎の課税基準額及び消費税額
ibt-116 TAX category taxable amount 課税分類毎の課税基準額
Sum of all taxable amounts subject to a specific TAX category code and TAX category rate (if the TAX category rate is applicable).
課税分類/課税分類の消費税率毎の課税基準額の合計。
ibt-117 TAX category tax amount 課税分類毎の消費税額
The total TAX amount for a given TAX category.
課税分類毎の消費税額合計。
5.3.1. Calculation of Consumption Tax
-
注1 BIS Billing 3.0では、「課税分類/課税分類の消費税率毎の課税基準額の合計」の計算結果が妥当か判定するルールが提供されていましたが、このルールがJP PINT V1.0では廃止されており、検証できません。
計算式 | JP PINT V1.0 | BIS Billing 3.0 |
---|---|---|
CT category taxable amount (IBT-116) = Σ (Invoice line net amounts (IBT-131)) |
無し |
BR-S-08 |
BR-E-08 |
||
BR-G-08 |
||
CT category tax amount (IBT-117) = CT category taxable amount (IBT-116) |
aligned-ibrp-0851-jp |
BR-CO-17 |
aligned-ibrp-e-09 |
||
aligned-ibrp-g-09 |
||
aligned-ibrp-o-09 |
BIS Billing 3.0の”Standard rated”についての検証ルールBR-S-08を転記します。
every $rate in xs:decimal(cbc:Percent) satisfies ( ( ( exists(//cac:InvoiceLine[Tax Category is 'S' and Rate is $rate]) or exists(//cac:AllowanceCharge[Tax Category is 'S' and Rate is $rate]) ) and ( ( ../xs:decimal(cbc:TaxableAmount - 1) < ( sum(../../../cac:InvoiceLine[Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:LineExtensionAmount)) + sum(../../../cac:AllowanceCharge[cbc:ChargeIndicator=true()][Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:Amount)) - sum(../../../cac:AllowanceCharge[cbc:ChargeIndicator=false()][Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:Amount)) ) ) and ( ../xs:decimal(cbc:TaxableAmount + 1) > ( sum(../../../cac:InvoiceLine[Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:LineExtensionAmount)) + sum(../../../cac:AllowanceCharge[cbc:ChargeIndicator=true()][Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:Amount)) - sum(../../../cac:AllowanceCharge[cbc:ChargeIndicator=false()][Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:Amount)) ) ) ) ) or ( exists(//cac:CreditNoteLine[Tax Category is 'S' and Rate is $rate]) or exists(//cac:AllowanceCharge[Tax Category is 'S' and Rate is $rate]) ) and ( ( ../xs:decimal(cbc:TaxableAmount - 1) < ( sum(../../../cac:CreditNoteLine[Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:LineExtensionAmount)) + sum(../../../cac:AllowanceCharge[cbc:ChargeIndicator=true()][Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:Amount)) - sum(../../../cac:AllowanceCharge[cbc:ChargeIndicator=false()][Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:Amount)) ) ) and ( ../xs:decimal(cbc:TaxableAmount + 1) > ( sum(../../../cac:CreditNoteLine[Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:LineExtensionAmount)) + sum(../../../cac:AllowanceCharge[cbc:ChargeIndicator=true()][Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:Amount)) - sum(../../../cac:AllowanceCharge[cbc:ChargeIndicator=false()][Tax Category is 'S' and Rate is $rate]/xs:decimal(cbc:Amount)) ) ) ) )
EN16931 model bound to UBL: BR-S-08 test
-
注2 BIS Billing 3.0の”Standard rated”についての検証ルールBR-S-08では、同じ課税区分に複数の税率が定義されることがあるため、次のようなコーディングでそれぞれの税率で妥当かどうかを検証しています。
every $rate in xs:decimal(cbc:Percent) satisfies ()
Schematron for PEPPOL rules (UBL)
-
注3 上のコーディング中に [Tax Category is ‘S’ and Rate is $rate]と記載されている箇所は、実際のコーディングでは
[cac:TaxCategory/normalize-space(cbc:ID)=’S’][cac:TaxCategory/xs:decimal(cbc:Percent)=$rate]
となっています。読みやすくするために変更しています。 -
注4 BIS Billing 3.0で提供されている「課税分類/課税分類の消費税率毎の課税基準額の合計」の計算結果が妥当か判定するルールは、課税分類毎に定義されています。
P PINT V1.0には課税基準額の合計の検証ルールがありませんので、aligned-ibrp-0851-jpで税額計算の妥当性が判定できません。 -
注5 CT category taxable amount (IBT-116)の計算式ではそれぞれの課税分類/課税分類の消費税率毎の文書レベルの返金や追加請求は、単数として表記されていますが、Semantic Model での IBG-20 DOCUMENT LEVEL ALLOWANCES 及び IBG-21 DOCUMENT LEVEL CHARGES の繰り返し回数は 0..n (任意項目、複数可)とされています。合計計算が必要な場合もありますので留意してください。
返金と追加請求がそれぞれ複数ある場合がありますので、単純な四則演算式よりも合計計算のΣ がふさわしいと思います。
CT category taxable amount (IBT-116) = ∑(Invoice line net amounts (IBT-131))
+ ∑ Document level charge amount (IBT-99) − ∑ Document level allowance amount (IBT-92)
-
注6 BIS Billing 3.0で提供されている「課税分類/課税分類の消費税率毎の消費税額合計」の計算結果が妥当か判定するルールは、課税分類毎ではなくひとつだけ定義されています。
(round(cac:TaxCategory[cac:TaxScheme/normalize-space(upper-case(cbc:ID))='VAT']/xs:decimal(cbc:Percent)) = 0 and (round(xs:decimal(cbc:TaxAmount)) = 0) ) or (round(cac:TaxCategory[cac:TaxScheme/normalize-space(upper-case(cbc:ID))='VAT']/xs:decimal(cbc:Percent)) != 0 and ( (abs(xs:decimal(cbc:TaxAmount)) - 1 < round(abs(xs:decimal(cbc:TaxableAmount)) * (cac:TaxCategory[cac:TaxScheme/normalize-space(upper-case(cbc:ID))='VAT']/xs:decimal(cbc:Percent) div 100) * 10 * 10 ) div 100 ) and (abs(xs:decimal(cbc:TaxAmount)) + 1 > round(abs(xs:decimal(cbc:TaxableAmount)) * (cac:TaxCategory[cac:TaxScheme/normalize-space(upper-case(cbc:ID))='VAT']/xs:decimal(cbc:Percent) div 100) * 10 * 10 ) div 100 ) ) ) or (not(exists(cac:TaxCategory[cac:TaxScheme/normalize-space(upper-case(cbc:ID))='VAT']/xs:decimal(cbc:Percent))) and (round(xs:decimal(cbc:TaxAmount)) = 0) )
Schematron for PEPPOL rules (UBL): PEPPOL-CO-17 test
-
注6 JP PINT V1.0では、消費税額合計妥当性を検証するルールは、、課税分類毎に定義されています。BIS Billing 3.0のPEPPOL-CO-17では、計算結果が ±1の範囲内か判定していましたが、ligned-ibrp-051-jpでは、切り捨てと切り上げの間にあるかを判定しています。
( (cac:TaxCategory/normalize-space(upper-case(cbc:ID)) != 'O') and ( (round(cac:TaxCategory/xs:decimal(cbc:Percent)) != 0 and ( xs:decimal(cbc:TaxAmount) >= floor(xs:decimal(cbc:TaxableAmount) * (cac:TaxCategory/xs:decimal(cbc:Percent) div 100)) ) and ( xs:decimal(cbc:TaxAmount) <= ceiling(xs:decimal(cbc:TaxableAmount) * (cac:TaxCategory/xs:decimal(cbc:Percent) div 100)) ) ) or (round(cac:TaxCategory/xs:decimal(cbc:Percent)) = 0 and (xs:decimal(cbc:TaxAmount) = 0)) ) ) or (not(cac:TaxCategory/cbc:Percent) and (cac:TaxCategory/normalize-space(upper-case(cbc:ID)) = 'O') and (xs:decimal(cbc:TaxAmount) = 0) )
Japanese jurisdiction specific PINT rules: aligned-ibrp-051-jp test
4. 文書レベルの合計金額
ibt-106 Sum of Invoice line net amount 値引後請求書明細行金額の合計
Sum of all Invoice line net amounts in the Invoice.
値引後明細行金額の合計金額。
ibt-107 Sum of allowances on document level 請求書レベルの返金の合計
Sum of all allowances on document level in the Invoice.
請求書レベルの返金の合計。
ibt-108 Sum of charges on document level 請求書レベルの追加請求の合計
Sum of all charges on document level in the Invoice.
請求書レベルの追加請求の合計。
ibt-109 Invoice total amount without TAX 請求書合計金額(税抜き)
The total amount of the Invoice without TAX.
請求書合計金額(税抜き)。
ibt-110 Invoice total TAX amount 請求書消費税合計金額
The total TAX amount for the Invoice.
請求書消費税合計金額。
ibt-112 Invoice total amount with TAX 請求書合計金額(税込み)
The total amount of the Invoice with tax.
請求書合計金額(税込み)。
ibt-113 Paid amount 支払済金額
The sum of amounts which have been paid in advance.
事前に支払われた金額の合計。
ibt-114 Rounding amount 丸めるための金額
The amount to be added to the invoice total to round the amount to be paid.
支払金額に丸めるために請求書の合計金額に追加される金額。
ibt-115 Amount due for payment 差引請求金額
The outstanding amount that is requested to be paid.
買い手が支払を要求されている差引請求金額。
5.1.1. Calculation of Totals
JP PINT V1.0 | BIS Billing 3.0 |
---|---|
Sum of Invoice line net amount (ibt-106) = Σ (Invoice line net amount (ibt-131)) |
|
ibr-co-10 (xs:decimal( cbc:LineExtensionAmount) = (round( sum( //(cac:InvoiceLine| cac:CreditNoteLine)/ xs:decimal( cbc:LineExtensionAmount)) * 10 * 10) div 100)) |
BR-CO-10 (xs:decimal( cbc:LineExtensionAmount) = xs:decimal( round( sum( //(cac:InvoiceLine| cac:CreditNoteLine)/ xs:decimal( cbc:LineExtensionAmount)) * 10 * 10) div 100)) |
Sum of allowances on document level (ibt-107) = Σ (Document level allowance amount (ibt-92)) |
|
ibr-co-11 xs:decimal( cbc:AllowanceTotalAmount) = (round( sum( ../cac:AllowanceCharge[ cbc:ChargeIndicator=false() ]/ xs:decimal(cbc:Amount)) * 10 * 10) div 100) or (not( cbc:AllowanceTotalAmount) and not( ../cac:AllowanceCharge[ cbc:ChargeIndicator=false() ])) |
BR-CO-11 xs:decimal( cbc:AllowanceTotalAmount) = (round( sum( ../cac:AllowanceCharge[ cbc:ChargeIndicator=false() ]/ xs:decimal(cbc:Amount)) * 10 * 10) div 100) or (not( cbc:AllowanceTotalAmount) and not( ../cac:AllowanceCharge[ cbc:ChargeIndicator=false() ])) |
Sum of charges on document level (ibt-108) = Σ (Document level charge amount (ibt-099)) |
|
ibr-co-12 xs:decimal( cbc:ChargeTotalAmount) = (round( sum( ../cac:AllowanceCharge[ cbc:ChargeIndicator=true() ]/ xs:decimal( cbc:Amount)) * 10 * 10) div 100) or (not( cbc:ChargeTotalAmount) and not( ../cac:AllowanceCharge[ cbc:ChargeIndicator=true() ])) |
BR-CO-12 xs:decimal( cbc:ChargeTotalAmount) = (round( sum( ../cac:AllowanceCharge[ cbc:ChargeIndicator=true() ]/xs:decimal( cbc:Amount)) * 10 * 10) div 100) or (not( cbc:ChargeTotalAmount) and not( ../cac:AllowanceCharge[ cbc:ChargeIndicator=true() ])) |
Invoice total amount without TAX (ibt-109) = Sum of invoice line net amounts (ibt-106) |
|
ibr-co-13 ((cbc:ChargeTotalAmount) and (cbc:AllowanceTotalAmount) and (xs:decimal( cbc:TaxExclusiveAmount) = round( (xs:decimal(cbc:LineExtensionAmount) + xs:decimal(cbc:ChargeTotalAmount) – xs:decimal( cbc:AllowanceTotalAmount)) * 10 * 10) div 100 )) or (not( cbc:ChargeTotalAmount) and (cbc:AllowanceTotalAmount) and (xs:decimal( cbc:TaxExclusiveAmount) = round( (xs:decimal(cbc:LineExtensionAmount) – xs:decimal( cbc:AllowanceTotalAmount)) * 10 * 10 ) div 100)) or ( (cbc:ChargeTotalAmount) and not( cbc:AllowanceTotalAmount) and (xs:decimal( cbc:TaxExclusiveAmount) = round( (xs:decimal(cbc:LineExtensionAmount) + xs:decimal( cbc:ChargeTotalAmount)) * 10 * 10 ) div 100)) or ( not( cbc:ChargeTotalAmount) and not( cbc:AllowanceTotalAmount) and (xs:decimal( cbc:TaxExclusiveAmount) = xs:decimal( cbc:LineExtensionAmount))) |
BR-CO-13 cbc:ChargeTotalAmount) and (cbc:AllowanceTotalAmount) and (xs:decimal(cbc:TaxExclusiveAmount) = round( (xs:decimal(cbc:LineExtensionAmount) + xs:decimal( cbc:ChargeTotalAmount) – xs:decimal( cbc:AllowanceTotalAmount * 10 * 10) div 100 )) or (not( cbc:ChargeTotalAmount) and (cbc:AllowanceTotalAmount) and (xs:decimal( cbc:TaxExclusiveAmount) = round( (xs:decimal( cbc:LineExtensionAmount) – xs:decimal( cbc:AllowanceTotalAmount)) * 10 * 10 ) div 100)) or cbc:ChargeTotalAmount) and not( cbc:AllowanceTotalAmount) and (xs:decimal( cbc:TaxExclusiveAmount) = round( (xs:decimal( cbc:LineExtensionAmount) + xs:decimal( cbc:ChargeTotalAmount * 10 * 10 ) div 100)) or ( not( cbc:ChargeTotalAmount) and not( cbc:AllowanceTotalAmount) and (xs:decimal( cbc:TaxExclusiveAmount) = xs:decimal( cbc:LineExtensionAmount))) |
Invoice total TAX amount (ibt-110) = Σ (CT category tax amount (ibt-117)) |
|
ibr-co-14 (xs:decimal( child::cbc:TaxAmount)= round( (sum( cac:TaxSubtotal/ xs:decimal( cbc:TaxAmount)) * 10 * 10)) div 100) or not( cac:TaxSubtotal) |
BR-CO-14 (xs:decimal( child::cbc:TaxAmount)= round( (sum( cac:TaxSubtotal/ xs:decimal( cbc:TaxAmount)) * 10 * 10)) div 100) or not( cac:TaxSubtotal) |
Invoice total amount with TAX (ibt-112) = Invoice total amount without CT (ibt-109) |
|
ibr-co-15 (cac:LegalMonetaryTotal/xs:decimal( cbc:TaxInclusiveAmount) = round( (cac:LegalMonetaryTotal/xs:decimal( cbc:TaxExclusiveAmount) + cac:TaxTotal/xs:decimal( cbc:TaxAmount[ @currencyID=/*/cbc:DocumentCurrencyCode ])) * 10 * 10) div 100) |
BR-CO-15 every $Currency in cbc:DocumentCurrencyCode satisfies (count( cac:TaxTotal/ xs:decimal( cbc:TaxAmount[ @currencyID=$Currency ])) eq 1) and (cac:LegalMonetaryTotal/ xs:decimal(cbc:TaxInclusiveAmount) = round( (cac:LegalMonetaryTotal/ xs:decimal( cbc:TaxExclusiveAmount) + cac:TaxTotal/ xs:decimal( cbc:TaxAmount[ @currencyID=$Currenc ])) * 10 * 10) div 100) |
Amount due for payment (ibt-115) = Invoice total amount with CT (ibt-112) |
|
ibr-co-16 (xs:decimal( cbc:PrepaidAmount) and not( xs:decimal(cbc:PayableRoundingAmount)) and (xs:decimal( cbc:PayableAmount) = (round( (xs:decimal( cbc:TaxInclusiveAmount) – xs:decimal( cbc:PrepaidAmount)) * 10 * 10) div 100))) or (not( xs:decimal(cbc:PrepaidAmount)) and not( xs:decimal(cbc:PayableRoundingAmount)) and xs:decimal( cbc:PayableAmount) = xs:decimal(cbc:TaxInclusiveAmount)) or (xs:decimal(cbc:PrepaidAmount) and xs:decimal(cbc:PayableRoundingAmount) and round((xs:decimal(cbc:PayableAmount) – xs:decimal( cbc:PayableRoundingAmount * 10 * 10) div 100) = (round( (xs:decimal( cbc:TaxInclusiveAmount) – xs:decimal( cbc:PrepaidAmount)) * 10 * 10) div 100))) or (not( xs:decimal( cbc:PrepaidAmount)) and xs:decimal( cbc:PayableRoundingAmount) and round( (xs:decimal( cbc:PayableAmount) – xs:decimal( cbc:PayableRoundingAmount * 10 * 10) div 100) = xs:decimal( cbc:TaxInclusiveAmount))) |
BR-CO-16 (exists( cbc:PrepaidAmount) and not( exists( cbc:PayableRoundingAmount)) and (xs:decimal( cbc:PayableAmount) = (round( (xs:decimal( cbc:TaxInclusiveAmount) – xs:decimal( cbc:PrepaidAmount)) * 10 * 10) div 100))) or (not( exists( cbc:PrepaidAmount)) and not( exists( cbc:PayableRoundingAmount)) and xs:decimal( cbc:PayableAmount) = xs:decimal(cbc:TaxInclusiveAmount)) or (exists(cbc:PrepaidAmount) and exists(cbc:PayableRoundingAmount) and round((xs:decimal(cbc:PayableAmount) – xs:decimal( cbc:PayableRoundingAmount * 10 * 10) div 100) = (round( (xs:decimal( cbc:TaxInclusiveAmount) – xs:decimal( cbc:PrepaidAmount)) * 10 * 10) div 100))) or (not( exists( cbc:PrepaidAmount)) and exists( cbc:PayableRoundingAmount) and round( (xs:decimal( cbc:PayableAmount) – xs:decimal( cbc:PayableRoundingAmount * 10 * 10) div 100) = xs:decimal( cbc:TaxInclusiveAmount))) |
JP PINT 1.0でもBIS Billing 3.0の検証ルールを踏襲しています。