Merged PR 5438: Add Flex API into KPI models
# Description Including Flex API revenue into KPI models. Will also update the Main KPIs report # Checklist - [x] The edited models and dependants run properly with production data. - [x] The edited models are sufficiently documented. - [x] The edited models contain PK tests, and I've ran and passed them. - [ ] I have checked for DRY opportunities with other models and docs. - [ ] I've picked the right materialization for the affected models. # Other - [ ] Check if a full-refresh is required after this PR is merged. Add Flex API into KPI models Related work items: #31041
This commit is contained in:
commit
9c4b12e985
8 changed files with 61 additions and 0 deletions
|
|
@ -692,6 +692,17 @@
|
||||||
"display_exclusion": "INVOICING",
|
"display_exclusion": "INVOICING",
|
||||||
"include_in_account_reporting": false,
|
"include_in_account_reporting": false,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"order_by": 249,
|
||||||
|
"metric": "Invoiced Flex API Revenue",
|
||||||
|
"value": "xero_flex_api_net_fees_in_gbp",
|
||||||
|
"previous_year_value": "previous_year_xero_flex_api_net_fees_in_gbp",
|
||||||
|
"relative_increment": "relative_increment_xero_flex_api_net_fees_in_gbp",
|
||||||
|
"number_format": "currency_gbp",
|
||||||
|
"increment_sign_format": "positive",
|
||||||
|
"display_exclusion": "INVOICING",
|
||||||
|
"include_in_account_reporting": false,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"order_by": 250,
|
"order_by": 250,
|
||||||
"metric": "Guest Revenue",
|
"metric": "Guest Revenue",
|
||||||
|
|
|
||||||
|
|
@ -233,6 +233,7 @@ with
|
||||||
invoiced_revenue.xero_e_deposit_net_fees_in_gbp,
|
invoiced_revenue.xero_e_deposit_net_fees_in_gbp,
|
||||||
invoiced_revenue.xero_check_in_hero_api_net_fees_in_gbp,
|
invoiced_revenue.xero_check_in_hero_api_net_fees_in_gbp,
|
||||||
invoiced_revenue.xero_screen_and_protect_net_fees_in_gbp,
|
invoiced_revenue.xero_screen_and_protect_net_fees_in_gbp,
|
||||||
|
invoiced_revenue.xero_flex_api_net_fees_in_gbp,
|
||||||
invoiced_revenue.xero_guesty_net_fees_in_gbp,
|
invoiced_revenue.xero_guesty_net_fees_in_gbp,
|
||||||
|
|
||||||
-- HOST RESOLUTIONS --
|
-- HOST RESOLUTIONS --
|
||||||
|
|
@ -488,6 +489,7 @@ select
|
||||||
{{ calculate_safe_relative_increment("xero_e_deposit_net_fees_in_gbp") }},
|
{{ calculate_safe_relative_increment("xero_e_deposit_net_fees_in_gbp") }},
|
||||||
{{ calculate_safe_relative_increment("xero_check_in_hero_api_net_fees_in_gbp") }},
|
{{ calculate_safe_relative_increment("xero_check_in_hero_api_net_fees_in_gbp") }},
|
||||||
{{ calculate_safe_relative_increment("xero_screen_and_protect_net_fees_in_gbp") }},
|
{{ calculate_safe_relative_increment("xero_screen_and_protect_net_fees_in_gbp") }},
|
||||||
|
{{ calculate_safe_relative_increment("xero_flex_api_net_fees_in_gbp") }},
|
||||||
{{ calculate_safe_relative_increment("xero_guesty_net_fees_in_gbp") }},
|
{{ calculate_safe_relative_increment("xero_guesty_net_fees_in_gbp") }},
|
||||||
|
|
||||||
-- HOST RESOLUTIONS --
|
-- HOST RESOLUTIONS --
|
||||||
|
|
|
||||||
|
|
@ -51,6 +51,7 @@
|
||||||
sum(
|
sum(
|
||||||
xero_screen_and_protect_net_fees_in_gbp
|
xero_screen_and_protect_net_fees_in_gbp
|
||||||
) as xero_screen_and_protect_net_fees_in_gbp,
|
) as xero_screen_and_protect_net_fees_in_gbp,
|
||||||
|
sum(xero_flex_api_net_fees_in_gbp) as xero_flex_api_net_fees_in_gbp,
|
||||||
sum(xero_guesty_net_fees_in_gbp) as xero_guesty_net_fees_in_gbp,
|
sum(xero_guesty_net_fees_in_gbp) as xero_guesty_net_fees_in_gbp,
|
||||||
sum(xero_apis_net_fees_in_gbp) as xero_apis_net_fees_in_gbp,
|
sum(xero_apis_net_fees_in_gbp) as xero_apis_net_fees_in_gbp,
|
||||||
sum(
|
sum(
|
||||||
|
|
|
||||||
|
|
@ -51,6 +51,7 @@
|
||||||
sum(
|
sum(
|
||||||
xero_screen_and_protect_net_fees_in_gbp
|
xero_screen_and_protect_net_fees_in_gbp
|
||||||
) as xero_screen_and_protect_net_fees_in_gbp,
|
) as xero_screen_and_protect_net_fees_in_gbp,
|
||||||
|
sum(xero_flex_api_net_fees_in_gbp) as xero_flex_api_net_fees_in_gbp,
|
||||||
sum(xero_guesty_net_fees_in_gbp) as xero_guesty_net_fees_in_gbp,
|
sum(xero_guesty_net_fees_in_gbp) as xero_guesty_net_fees_in_gbp,
|
||||||
sum(xero_apis_net_fees_in_gbp) as xero_apis_net_fees_in_gbp,
|
sum(xero_apis_net_fees_in_gbp) as xero_apis_net_fees_in_gbp,
|
||||||
sum(
|
sum(
|
||||||
|
|
|
||||||
|
|
@ -188,6 +188,13 @@ select
|
||||||
else 0
|
else 0
|
||||||
end
|
end
|
||||||
) as xero_screen_and_protect_net_fees_in_gbp,
|
) as xero_screen_and_protect_net_fees_in_gbp,
|
||||||
|
sum(
|
||||||
|
case
|
||||||
|
when ixsdm.accounting_root_aggregation = 'Flex API'
|
||||||
|
then ixsdm.line_amount_wo_taxes_in_gbp
|
||||||
|
else 0
|
||||||
|
end
|
||||||
|
) as xero_flex_api_net_fees_in_gbp,
|
||||||
sum(
|
sum(
|
||||||
case
|
case
|
||||||
when ixsdm.accounting_root_aggregation = 'Guesty Resolutions'
|
when ixsdm.accounting_root_aggregation = 'Guesty Resolutions'
|
||||||
|
|
|
||||||
|
|
@ -56,6 +56,7 @@ select
|
||||||
sum(
|
sum(
|
||||||
ir.xero_screen_and_protect_net_fees_in_gbp
|
ir.xero_screen_and_protect_net_fees_in_gbp
|
||||||
) as xero_screen_and_protect_net_fees_in_gbp,
|
) as xero_screen_and_protect_net_fees_in_gbp,
|
||||||
|
sum(ir.xero_flex_api_net_fees_in_gbp) as xero_flex_api_net_fees_in_gbp,
|
||||||
sum(ir.xero_guesty_net_fees_in_gbp) as xero_guesty_net_fees_in_gbp,
|
sum(ir.xero_guesty_net_fees_in_gbp) as xero_guesty_net_fees_in_gbp,
|
||||||
sum(ir.xero_apis_net_fees_in_gbp) as xero_apis_net_fees_in_gbp,
|
sum(ir.xero_apis_net_fees_in_gbp) as xero_apis_net_fees_in_gbp,
|
||||||
sum(
|
sum(
|
||||||
|
|
|
||||||
|
|
@ -56,6 +56,7 @@ select
|
||||||
sum(
|
sum(
|
||||||
ir.xero_screen_and_protect_net_fees_in_gbp
|
ir.xero_screen_and_protect_net_fees_in_gbp
|
||||||
) as xero_screen_and_protect_net_fees_in_gbp,
|
) as xero_screen_and_protect_net_fees_in_gbp,
|
||||||
|
sum(ir.xero_flex_api_net_fees_in_gbp) as xero_flex_api_net_fees_in_gbp,
|
||||||
sum(ir.xero_guesty_net_fees_in_gbp) as xero_guesty_net_fees_in_gbp,
|
sum(ir.xero_guesty_net_fees_in_gbp) as xero_guesty_net_fees_in_gbp,
|
||||||
sum(ir.xero_apis_net_fees_in_gbp) as xero_apis_net_fees_in_gbp,
|
sum(ir.xero_apis_net_fees_in_gbp) as xero_apis_net_fees_in_gbp,
|
||||||
sum(
|
sum(
|
||||||
|
|
|
||||||
|
|
@ -4471,6 +4471,13 @@ models:
|
||||||
in a given date and per specified dimension. This is an
|
in a given date and per specified dimension. This is an
|
||||||
API service.
|
API service.
|
||||||
|
|
||||||
|
- name: xero_flex_api_net_fees_in_gbp
|
||||||
|
data_type: decimal
|
||||||
|
description: |
|
||||||
|
Sum of daily Flex API Net Fees, in GBP, without taxes
|
||||||
|
in a given date and per specified dimension. This is an
|
||||||
|
API service.
|
||||||
|
|
||||||
- name: xero_athena_net_fees_in_gbp
|
- name: xero_athena_net_fees_in_gbp
|
||||||
data_type: decimal
|
data_type: decimal
|
||||||
description: |
|
description: |
|
||||||
|
|
@ -4694,6 +4701,13 @@ models:
|
||||||
in a given month and per specified dimension. This is an
|
in a given month and per specified dimension. This is an
|
||||||
API service.
|
API service.
|
||||||
|
|
||||||
|
- name: xero_flex_api_net_fees_in_gbp
|
||||||
|
data_type: decimal
|
||||||
|
description: |
|
||||||
|
Sum of daily Flex API Net Fees, in GBP, without taxes
|
||||||
|
in a given date and per specified dimension. This is an
|
||||||
|
API service.
|
||||||
|
|
||||||
- name: xero_athena_net_fees_in_gbp
|
- name: xero_athena_net_fees_in_gbp
|
||||||
data_type: decimal
|
data_type: decimal
|
||||||
description: |
|
description: |
|
||||||
|
|
@ -4911,6 +4925,13 @@ models:
|
||||||
in a given month up to the given date and per specified dimension.
|
in a given month up to the given date and per specified dimension.
|
||||||
This is an API service.
|
This is an API service.
|
||||||
|
|
||||||
|
- name: xero_flex_api_net_fees_in_gbp
|
||||||
|
data_type: decimal
|
||||||
|
description: |
|
||||||
|
Sum of daily Flex API Net Fees, in GBP, without taxes
|
||||||
|
in a given date and per specified dimension. This is an
|
||||||
|
API service.
|
||||||
|
|
||||||
- name: xero_athena_net_fees_in_gbp
|
- name: xero_athena_net_fees_in_gbp
|
||||||
data_type: decimal
|
data_type: decimal
|
||||||
description: |
|
description: |
|
||||||
|
|
@ -4990,6 +5011,7 @@ models:
|
||||||
- xero_e_deposit_net_fees_in_gbp
|
- xero_e_deposit_net_fees_in_gbp
|
||||||
- xero_check_in_hero_api_net_fees_in_gbp
|
- xero_check_in_hero_api_net_fees_in_gbp
|
||||||
- xero_screen_and_protect_net_fees_in_gbp
|
- xero_screen_and_protect_net_fees_in_gbp
|
||||||
|
- xero_flex_api_net_fees_in_gbp
|
||||||
- xero_athena_net_fees_in_gbp
|
- xero_athena_net_fees_in_gbp
|
||||||
- xero_guesty_resolutions_net_fees_in_gbp
|
- xero_guesty_resolutions_net_fees_in_gbp
|
||||||
- xero_guesty_net_fees_in_gbp
|
- xero_guesty_net_fees_in_gbp
|
||||||
|
|
@ -5114,6 +5136,13 @@ models:
|
||||||
for a given date, dimension and value.
|
for a given date, dimension and value.
|
||||||
This is an API service.
|
This is an API service.
|
||||||
|
|
||||||
|
- name: xero_flex_api_net_fees_in_gbp
|
||||||
|
data_type: decimal
|
||||||
|
description: |
|
||||||
|
Sum of daily Flex API Net Fees, in GBP, without taxes
|
||||||
|
in a given date and per specified dimension. This is an
|
||||||
|
API service.
|
||||||
|
|
||||||
- name: xero_athena_net_fees_in_gbp
|
- name: xero_athena_net_fees_in_gbp
|
||||||
data_type: decimal
|
data_type: decimal
|
||||||
description: |
|
description: |
|
||||||
|
|
@ -5191,6 +5220,7 @@ models:
|
||||||
- xero_e_deposit_net_fees_in_gbp
|
- xero_e_deposit_net_fees_in_gbp
|
||||||
- xero_check_in_hero_api_net_fees_in_gbp
|
- xero_check_in_hero_api_net_fees_in_gbp
|
||||||
- xero_screen_and_protect_net_fees_in_gbp
|
- xero_screen_and_protect_net_fees_in_gbp
|
||||||
|
- xero_flex_api_net_fees_in_gbp
|
||||||
- xero_athena_net_fees_in_gbp
|
- xero_athena_net_fees_in_gbp
|
||||||
- xero_guesty_resolutions_net_fees_in_gbp
|
- xero_guesty_resolutions_net_fees_in_gbp
|
||||||
- xero_guesty_net_fees_in_gbp
|
- xero_guesty_net_fees_in_gbp
|
||||||
|
|
@ -5316,6 +5346,13 @@ models:
|
||||||
for a given date, dimension and value.
|
for a given date, dimension and value.
|
||||||
This is an API service.
|
This is an API service.
|
||||||
|
|
||||||
|
- name: xero_flex_api_net_fees_in_gbp
|
||||||
|
data_type: decimal
|
||||||
|
description: |
|
||||||
|
Sum of daily Flex API Net Fees, in GBP, without taxes
|
||||||
|
in a given date and per specified dimension. This is an
|
||||||
|
API service.
|
||||||
|
|
||||||
- name: xero_athena_net_fees_in_gbp
|
- name: xero_athena_net_fees_in_gbp
|
||||||
data_type: decimal
|
data_type: decimal
|
||||||
description: |
|
description: |
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue