Merged PR 4528: Adds number format
# Description Adds number format for display purposes # 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. - [X] I have checked for DRY opportunities with other models and docs. - [X] I've picked the right materialization for the affected models. # Other - [ ] Check if a full-refresh is required after this PR is merged. Adds number format Related work items: #27609
This commit is contained in:
parent
42701b4d2c
commit
cfc17a5d3a
4 changed files with 45 additions and 0 deletions
|
|
@ -8,6 +8,7 @@
|
|||
"current_YTD": "current_ytd_total_revenue_in_gbp",
|
||||
"previous_YTD": "previous_ytd_total_revenue_in_gbp",
|
||||
"display_exclusion": "INVOICING",
|
||||
"number_format": "CURRENCY_GBP_INTEGER",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -19,6 +20,7 @@
|
|||
"current_YTD": "current_ytd_revenue_retained_post_resolutions_in_gbp",
|
||||
"previous_YTD": "previous_ytd_revenue_retained_post_resolutions_in_gbp",
|
||||
"display_exclusion": "INVOICING",
|
||||
"number_format": "CURRENCY_GBP_INTEGER",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -30,6 +32,7 @@
|
|||
"current_YTD": "current_ytd_total_guest_payments_in_gbp",
|
||||
"previous_YTD": "previous_ytd_total_guest_payments_in_gbp",
|
||||
"display_exclusion": "NONE",
|
||||
"number_format": "CURRENCY_GBP_INTEGER",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -41,6 +44,7 @@
|
|||
"current_YTD": "current_ytd_xero_operator_net_fees_in_gbp",
|
||||
"previous_YTD": "previous_ytd_xero_operator_net_fees_in_gbp",
|
||||
"display_exclusion": "INVOICING",
|
||||
"number_format": "CURRENCY_GBP_INTEGER",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -52,6 +56,7 @@
|
|||
"current_YTD": "current_ytd_xero_apis_net_fees_in_gbp",
|
||||
"previous_YTD": "previous_ytd_xero_apis_net_fees_in_gbp",
|
||||
"display_exclusion": "INVOICING",
|
||||
"number_format": "CURRENCY_GBP_INTEGER",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -63,6 +68,7 @@
|
|||
"current_YTD": "current_ytd_billable_bookings",
|
||||
"previous_YTD": "previous_ytd_billable_bookings",
|
||||
"display_exclusion": "NONE",
|
||||
"number_format": "INTEGER",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -74,6 +80,7 @@
|
|||
"current_YTD": "current_ytd_live_deals",
|
||||
"previous_YTD": "previous_ytd_live_deals",
|
||||
"display_exclusion": "NONE",
|
||||
"number_format": "INTEGER",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -85,6 +92,7 @@
|
|||
"current_YTD": "current_ytd_new_deals",
|
||||
"previous_YTD": "previous_ytd_new_deals",
|
||||
"display_exclusion": "NONE",
|
||||
"number_format": "INTEGER",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -96,6 +104,7 @@
|
|||
"current_YTD": "current_ytd_churning_deals",
|
||||
"previous_YTD": "previous_ytd_churning_deals",
|
||||
"display_exclusion": "NONE",
|
||||
"number_format": "INTEGER",
|
||||
"increment_sign_format": "NEGATIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -107,6 +116,7 @@
|
|||
"current_YTD": "current_ytd_waiver_payout_rate",
|
||||
"previous_YTD": "previous_ytd_waiver_payout_rate",
|
||||
"display_exclusion": "INVOICING",
|
||||
"number_format": "PERCENTAGE_2_DECIMALS",
|
||||
"increment_sign_format": "NEGATIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -118,6 +128,7 @@
|
|||
"current_YTD": "current_ytd_resolutions_payout_rate",
|
||||
"previous_YTD": "previous_ytd_resolutions_payout_rate",
|
||||
"display_exclusion": "INVOICING",
|
||||
"number_format": "PERCENTAGE_2_DECIMALS",
|
||||
"increment_sign_format": "NEGATIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -129,6 +140,7 @@
|
|||
"current_YTD": "current_ytd_operator_revenue_per_billable_booking",
|
||||
"previous_YTD": "previous_ytd_operator_revenue_per_billable_booking",
|
||||
"display_exclusion": "INVOICING",
|
||||
"number_format": "CURRENCY_GBP_1_DECIMAL",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -140,6 +152,7 @@
|
|||
"current_YTD": "current_ytd_waiver_revenue_per_billable_booking",
|
||||
"previous_YTD": "previous_ytd_waiver_revenue_per_billable_booking",
|
||||
"display_exclusion": "NONE",
|
||||
"number_format": "CURRENCY_GBP_1_DECIMAL",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -151,6 +164,7 @@
|
|||
"current_YTD": "-1*current_ytd_xero_waiver_paid_back_to_host_in_gbp",
|
||||
"previous_YTD": "-1*previous_ytd_xero_waiver_paid_back_to_host_in_gbp",
|
||||
"display_exclusion": "INVOICING",
|
||||
"number_format": "CURRENCY_GBP_INTEGER",
|
||||
"increment_sign_format": "NEGATIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -162,6 +176,7 @@
|
|||
"current_YTD": "-1*current_ytd_xero_host_resolution_amount_paid_in_gbp",
|
||||
"previous_YTD": "-1*previous_ytd_xero_host_resolution_amount_paid_in_gbp",
|
||||
"display_exclusion": "INVOICING",
|
||||
"number_format": "CURRENCY_GBP_INTEGER",
|
||||
"increment_sign_format": "NEGATIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -173,6 +188,7 @@
|
|||
"current_YTD": "current_ytd_total_revenue_churn_rate",
|
||||
"previous_YTD": "previous_ytd_total_revenue_churn_rate",
|
||||
"display_exclusion": "ONGOING_MONTH",
|
||||
"number_format": "PERCENTAGE_2_DECIMALS",
|
||||
"increment_sign_format": "NEGATIVE",
|
||||
},
|
||||
{
|
||||
|
|
@ -184,6 +200,7 @@
|
|||
"current_YTD": "current_ytd_onboarding_mrr",
|
||||
"previous_YTD": "previous_ytd_onboarding_mrr",
|
||||
"display_exclusion": "ONGOING_MONTH",
|
||||
"number_format": "CURRENCY_GBP_INTEGER",
|
||||
"increment_sign_format": "POSITIVE",
|
||||
},
|
||||
] %}
|
||||
|
|
@ -206,6 +223,7 @@ with
|
|||
{{ metric.id_metric }} as id_metric,
|
||||
-- quotation marks added because text format
|
||||
'{{ metric.name }}' as metric_name,
|
||||
'{{ metric.number_format }}' as number_format,
|
||||
'{{ metric.display_exclusion }}' as display_exclusion,
|
||||
'{{ metric.increment_sign_format }}' as increment_sign_format,
|
||||
{{ metric.current_month_MTD }} as current_month_mtd,
|
||||
|
|
|
|||
|
|
@ -2538,6 +2538,19 @@ models:
|
|||
data_tests:
|
||||
- not_null
|
||||
|
||||
- name: number_format
|
||||
data_type: string
|
||||
description: |
|
||||
Number format to display the metric in the report.
|
||||
data_tests:
|
||||
- not_null
|
||||
- accepted_values:
|
||||
values:
|
||||
- INTEGER
|
||||
- PERCENTAGE_2_DECIMALS
|
||||
- CURRENCY_GBP_INTEGER
|
||||
- CURRENCY_GBP_1_DECIMAL
|
||||
|
||||
- name: display_exclusion
|
||||
data_type: string
|
||||
description: |
|
||||
|
|
|
|||
|
|
@ -2010,6 +2010,19 @@ models:
|
|||
data_tests:
|
||||
- not_null
|
||||
|
||||
- name: number_format
|
||||
data_type: string
|
||||
description: |
|
||||
Number format to display the metric in the report.
|
||||
data_tests:
|
||||
- not_null
|
||||
- accepted_values:
|
||||
values:
|
||||
- INTEGER
|
||||
- PERCENTAGE_2_DECIMALS
|
||||
- CURRENCY_GBP_INTEGER
|
||||
- CURRENCY_GBP_1_DECIMAL
|
||||
|
||||
- name: is_latest_date
|
||||
data_type: integer
|
||||
description: |
|
||||
|
|
|
|||
|
|
@ -38,6 +38,7 @@ select
|
|||
m.dimension_value as dimension_value,
|
||||
m.id_metric as id_metric,
|
||||
m.metric_name as metric_name,
|
||||
m.number_format as number_format,
|
||||
m.current_month_mtd as current_month_mtd,
|
||||
m.previous_month_eom as previous_month_eom,
|
||||
m.previous_year_mtd as previous_year_mtd,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue