{
  "elements": [
    {
      "type": "Label",
      "caption": "🧾 Abrechnungseinstellungen"
    },
    {
      "type": "SelectMedia",
      "name": "LogoMediaID",
      "caption": "Logo auswählen"
    },
    {
      "type": "ValidationTextBox",
      "name": "PropertyText",
      "caption": "Liegenschaft"
    },
    {
      "type": "ValidationTextBox",
      "name": "FooterText",
      "caption": "Fusszeile"
    },
    {
      "type": "Label",
      "caption": "⚖️ Mehrwertsteuer (MWST)"
    },
    {
      "type": "CheckBox",
      "name": "EnableVAT",
      "caption": "Mehrwertsteuer berechnen und ausweisen"
    },
    {
      "type": "NumberSpinner",
      "name": "VATPercentage",
      "caption": "MWST-Satz in %",
      "digits": 2,
      "minimum": 0,
      "maximum": 100
    },
    {
      "type": "Label",
      "caption": "🏦 QR-Einzahlungsschein Daten"
    },
    {
      "type": "ValidationTextBox",
      "name": "CreditorName",
      "caption": "Rechnungssteller Name"
    },
    {
      "type": "ValidationTextBox",
      "name": "CreditorAddress",
      "caption": "Rechnungssteller Strasse/Nr."
    },
    {
      "type": "ValidationTextBox",
      "name": "CreditorCity",
      "caption": "Rechnungssteller PLZ/Ort"
    },
    {
      "type": "ValidationTextBox",
      "name": "BankIBAN",
      "caption": "Bank IBAN"
    },
    {
      "type": "List",
      "name": "Users",
      "caption": "Benutzerliste",
      "add": true,
      "delete": true,
      "sortable": true,
      "columns": [
        { "caption": "ID", "name": "id", "width": "10%", "add": "", "edit": { "type": "ValidationTextBox" } },
        { "caption": "Name", "name": "name", "width": "20%", "add": "", "edit": { "type": "ValidationTextBox" } },
        { "caption": "Adresse", "name": "address", "width": "20%", "add": "", "edit": { "type": "ValidationTextBox" } },
        { "caption": "Ort", "name": "city", "width": "20%", "add": "", "edit": { "type": "ValidationTextBox" } }
      ]
    },
    {
      "type": "List",
      "name": "PowerMeters",
      "caption": "Stromzählerliste",
      "add": true,
      "delete": true,
      "sortable": true,
      "columns": [
        { "caption": "ID", "name": "id", "width": "10%", "add": "", "edit": { "type": "ValidationTextBox" } },
        { "caption": "Name", "name": "name", "width": "20%", "add": "", "edit": { "type": "ValidationTextBox" } },
        { "caption": "Var. Verbrauch", "name": "var_consumption", "width": "20%", "add": 0, "edit": { "type": "SelectVariable" } },
        { "caption": "Var. Rückspeisung", "name": "var_feed", "width": "20%", "add": 0, "edit": { "type": "SelectVariable" } },
        { "caption": "Benutzer-ID", "name": "user_id", "width": "20%", "add": "", "edit": { "type": "ValidationTextBox" } }
      ]
    },
    {
      "type": "List",
      "name": "WaterMeters",
      "caption": "Verbrauchszählerliste",
      "add": true,
      "delete": true,
      "sortable": true,
      "columns": [
        { "caption": "ID", "name": "id", "width": "10%", "add": "", "edit": { "type": "ValidationTextBox" } },
        { "caption": "Name", "name": "name", "width": "20%", "add": "", "edit": { "type": "ValidationTextBox" } },
        { "caption": "Var. Verbrauch", "name": "var_consumption", "width": "20%", "add": 0, "edit": { "type": "SelectVariable" } },
        { "caption": "Benutzer-ID", "name": "user_id", "width": "20%", "add": "", "edit": { "type": "ValidationTextBox" } },
        {
          "caption": "Zählertyp",
          "name": "meter_type",
          "width": "20%",
          "add": "Warmwasser",
          "edit": {
            "type": "Select",
            "options": [
              { "caption": "Warmwasser", "value": "Warmwasser" },
              { "caption": "Kaltwasser", "value": "Kaltwasser" },
              { "caption": "Wärme", "value": "Wärme" }
            ]
          }
        }
      ]
    },
    {
      "type": "List",
      "name": "Tariffs",
      "caption": "Tarifübersicht",
      "add": true,
      "delete": true,
      "sortable": true,
      "columns": [
        { "caption": "Startdatum", "name": "start", "width": "20%", "add": "", "edit": { "type": "SelectDate" } },
        { "caption": "Enddatum", "name": "end", "width": "20%", "add": "", "edit": { "type": "SelectDate" } },
        { "caption": "Tarif (Rp/Einheit)", "name": "price", "width": "20%", "add": 0, "edit": { "type": "NumberSpinner", "digits": 3, "minimum": 0 } },
        {
          "caption": "Einheit",
          "name": "unit_type",
          "width": "20%",
          "add": "Netztarif",
          "edit": {
            "type": "Select",
            "options": [
              { "caption": "Netztarif", "value": "Netztarif" },
              { "caption": "Einspeisetarif", "value": "Einspeisetarif" },
              { "caption": "Solartarif", "value": "Solartarif" },
              { "caption": "Warmwasser", "value": "Warmwasser" },
              { "caption": "Kaltwasser", "value": "Kaltwasser" },
              { "caption": "Wärme", "value": "Wärme" }
            ]
          }
        }
      ]
    }
  ]
}