{
  "data": {
    "data": {
      "fields": {
        "invoiceAmount": {
          "aggregatable": true,
          "aggregation": "SUM",
          "fieldName": "invoiceAmount",
          "filterType": "number",
          "filterable": true,
          "measure": true,
          "meta": "度量 | 数值 | 默认聚合:SUM",
          "models": {
            "TeachingInvoiceDatesQueryModel": {
              "description": "账单金额 (聚合方式: SUM)"
            }
          },
          "name": "账单金额",
          "sourceColumn": "Total",
          "type": "MONEY"
        },
        "invoiceCount": {
          "aggregatable": true,
          "aggregation": "COUNT",
          "fieldName": "invoiceCount",
          "filterType": "number",
          "filterable": true,
          "measure": true,
          "meta": "度量 | 数值 | 默认聚合:COUNT",
          "models": {
            "TeachingInvoiceDatesQueryModel": {
              "description": "账单数 (聚合方式: COUNT)"
            }
          },
          "name": "账单数",
          "sourceColumn": "InvoiceId",
          "type": "INTEGER"
        },
        "invoiceDate": {
          "aggregatable": false,
          "fieldName": "invoiceDate",
          "filterType": "date",
          "filterable": true,
          "measure": false,
          "meta": "属性 | 日期时间",
          "models": {
            "TeachingInvoiceDatesQueryModel": {
              "description": "统计账单发生额使用此时间，按原记录解释，不自行转换时区。",
              "recommendedUse": "按账单发生时间统计业务金额",
              "timeRole": "business_date"
            }
          },
          "name": "账单发生时间",
          "recommendedUse": "按账单发生时间统计业务金额",
          "sourceColumn": "InvoiceDate",
          "timeRole": "business_date",
          "type": "DATETIME"
        },
        "invoiceDay": {
          "aggregatable": false,
          "fieldName": "invoiceDay",
          "filterType": "date",
          "filterable": true,
          "measure": false,
          "meta": "属性 | 日期(yyyy-MM-dd)",
          "models": {
            "TeachingInvoiceDatesQueryModel": {
              "description": "账单日期",
              "timeRole": "business_date"
            }
          },
          "name": "账单日期",
          "sourceColumn": "InvoiceDay",
          "timeRole": "business_date",
          "type": "DAY"
        },
        "invoiceDayOfMonth": {
          "aggregatable": false,
          "fieldName": "invoiceDayOfMonth",
          "filterType": "number",
          "filterable": true,
          "measure": false,
          "meta": "属性 | 文本",
          "models": {
            "TeachingInvoiceDatesQueryModel": {
              "description": "账单月内日序"
            }
          },
          "name": "账单月内日序",
          "sourceColumn": "InvoiceDayOfMonth",
          "type": "INTEGER"
        },
        "invoiceId": {
          "aggregatable": false,
          "fieldName": "invoiceId",
          "filterType": "number",
          "filterable": true,
          "measure": false,
          "meta": "属性 | 文本",
          "models": {
            "TeachingInvoiceDatesQueryModel": {
              "description": "账单 ID"
            }
          },
          "name": "账单 ID",
          "sourceColumn": "InvoiceId",
          "type": "INTEGER"
        },
        "invoiceMonth": {
          "aggregatable": false,
          "fieldName": "invoiceMonth",
          "filterType": "text",
          "filterable": true,
          "measure": false,
          "meta": "属性 | 文本",
          "models": {
            "TeachingInvoiceDatesQueryModel": {
              "description": "账单年月"
            }
          },
          "name": "账单年月",
          "sourceColumn": "InvoiceMonth",
          "type": "STRING"
        },
        "loadedAt": {
          "aggregatable": false,
          "fieldName": "loadedAt",
          "filterType": "date",
          "filterable": true,
          "measure": false,
          "meta": "属性 | 日期时间",
          "models": {
            "TeachingInvoiceDatesQueryModel": {
              "description": "人工生成的技术入库时间，账单发生后两天；仅用于按入库时间统计的演示，不能作为回款时间。",
              "recommendedUse": "仅按模拟入库时间统计，不得代替账单发生时间或付款时间",
              "timeRole": "system_time"
            }
          },
          "name": "模拟入库时间",
          "recommendedUse": "仅按模拟入库时间统计，不得代替账单发生时间或付款时间",
          "sourceColumn": "LoadedAt",
          "timeRole": "system_time",
          "type": "DATETIME"
        },
        "loadedMonth": {
          "aggregatable": false,
          "fieldName": "loadedMonth",
          "filterType": "text",
          "filterable": true,
          "measure": false,
          "meta": "属性 | 文本",
          "models": {
            "TeachingInvoiceDatesQueryModel": {
              "description": "模拟入库年月"
            }
          },
          "name": "模拟入库年月",
          "sourceColumn": "LoadedMonth",
          "type": "STRING"
        }
      },
      "modelSource": {
        "bundleName": "chinook-calendar-teaching",
        "known": true,
        "namespace": "chinook-calendar",
        "resourceIdentity": "练习目录\\lab\\chapter-18\\models\\query\\TeachingInvoiceDatesQueryModel.qm"
      },
      "models": {
        "TeachingInvoiceDatesQueryModel": {
          "description": "按账单发生时间统计业务金额；loadedAt/loadedMonth 仅为模拟技术入库时间。此模型保留全量历史，报告截止应显式筛选。不能用于查询付款或回款。",
          "factTable": "TeachingInvoice",
          "name": "账单与技术时间对照",
          "purpose": "数据查询和分析",
          "scenarios": [
            "数据查询",
            "统计分析",
            "报表生成"
          ]
        }
      },
      "physicalTables": [
        {
          "role": "fact",
          "table": "TeachingInvoice"
        }
      ],
      "prompt": "## 使用说明 (V3版本)\n- 格式约定：字段类型 | 数据类型 | 格式说明\n",
      "version": "v3"
    },
    "format": "json"
  },
  "diagnostics": {
    "attributes": {},
    "warnings": []
  },
  "engine": "java",
  "runtimeApiVersion": "foggy-runtime-api/v1",
  "success": true
}
