SPB Git

Repository Public License

finance.blueprint.json 32.2 KB 1,401 lines json

1{2  "entrypoint": "dashboard",3  "id": "app_personal_finance",4  "name": "Personal Finance",5  "objects": [6    {7      "id": "transactions",8      "name": "Transactions",9      "props": {10        "columns": [11          {12            "label": "Date",13            "name": "date",14            "required": true,15            "type": "date"16          },17          {18            "label": "Description",19            "name": "description",20            "required": true,21            "type": "text"22          },23          {24            "label": "Category",25            "name": "category",26            "options": [27              "Housing",28              "Groceries",29              "Dining",30              "Transport",31              "Utilities",32              "Entertainment",33              "Health",34              "Shopping",35              "Salary",36              "Other"37            ],38            "required": true,39            "type": "text"40          },41          {42            "default": "Expense",43            "label": "Type",44            "name": "type",45            "options": [46              "Expense",47              "Income"48            ],49            "required": true,50            "type": "text"51          },52          {53            "label": "Amount",54            "name": "amount",55            "required": true,56            "type": "currency"57          },58          {59            "label": "Notes",60            "name": "notes",61            "type": "text"62          }63        ],64        "seed": [65          {66            "amount": 3800,67            "category": "Salary",68            "date": "2026-08-01",69            "description": "Monthly salary",70            "type": "Income"71          },72          {73            "amount": 1350,74            "category": "Housing",75            "date": "2026-08-01",76            "description": "Rent",77            "type": "Expense"78          },79          {80            "amount": 132.4,81            "category": "Groceries",82            "date": "2026-08-06",83            "description": "Supermarket",84            "type": "Expense"85          },86          {87            "amount": 88.2,88            "category": "Utilities",89            "date": "2026-08-12",90            "description": "Electricity bill",91            "type": "Expense"92          },93          {94            "amount": 42.5,95            "category": "Dining",96            "date": "2026-08-19",97            "description": "Pizza night",98            "type": "Expense"99          },100          {101            "amount": 95,102            "category": "Transport",103            "date": "2026-08-24",104            "description": "Train pass",105            "type": "Expense"106          },107          {108            "amount": 3800,109            "category": "Salary",110            "date": "2026-09-01",111            "description": "Monthly salary",112            "type": "Income"113          },114          {115            "amount": 1350,116            "category": "Housing",117            "date": "2026-09-01",118            "description": "Rent",119            "type": "Expense"120          },121          {122            "amount": 158.9,123            "category": "Groceries",124            "date": "2026-09-08",125            "description": "Supermarket",126            "type": "Expense"127          },128          {129            "amount": 120,130            "category": "Entertainment",131            "date": "2026-09-14",132            "description": "Concert tickets",133            "type": "Expense"134          },135          {136            "amount": 27.3,137            "category": "Health",138            "date": "2026-09-21",139            "description": "Pharmacy",140            "type": "Expense"141          },142          {143            "amount": 45,144            "category": "Utilities",145            "date": "2026-09-25",146            "description": "Internet",147            "type": "Expense"148          },149          {150            "amount": 3800,151            "category": "Salary",152            "date": "2026-10-01",153            "description": "Monthly salary",154            "type": "Income"155          },156          {157            "amount": 1350,158            "category": "Housing",159            "date": "2026-10-01",160            "description": "Rent",161            "type": "Expense"162          },163          {164            "amount": 176.1,165            "category": "Groceries",166            "date": "2026-10-05",167            "description": "Supermarket",168            "type": "Expense"169          },170          {171            "amount": 68,172            "category": "Dining",173            "date": "2026-10-11",174            "description": "Sushi dinner",175            "type": "Expense"176          },177          {178            "amount": 139.99,179            "category": "Shopping",180            "date": "2026-10-17",181            "description": "New jacket",182            "type": "Expense"183          },184          {185            "amount": 650,186            "category": "Other",187            "date": "2026-10-28",188            "description": "Freelance project",189            "type": "Income"190          },191          {192            "amount": 3800,193            "category": "Salary",194            "date": "2026-11-01",195            "description": "Monthly salary",196            "type": "Income"197          },198          {199            "amount": 1350,200            "category": "Housing",201            "date": "2026-11-01",202            "description": "Rent",203            "type": "Expense"204          },205          {206            "amount": 121.75,207            "category": "Groceries",208            "date": "2026-11-03",209            "description": "Supermarket",210            "type": "Expense"211          },212          {213            "amount": 58.4,214            "category": "Transport",215            "date": "2026-11-05",216            "description": "Gas station",217            "type": "Expense"218          },219          {220            "amount": 36.8,221            "category": "Dining",222            "date": "2026-11-07",223            "description": "Brunch with friends",224            "type": "Expense"225          },226          {227            "amount": 15.99,228            "category": "Entertainment",229            "date": "2026-11-09",230            "description": "Streaming subscription",231            "type": "Expense"232          }233        ]234      },235      "provenance": {236        "source": "agent"237      },238      "schemaVersion": 1,239      "type": "prism.data.table",240      "version": 1241    },242    {243      "id": "budgets",244      "name": "Budgets",245      "props": {246        "columns": [247          {248            "label": "Category",249            "name": "category",250            "options": [251              "Housing",252              "Groceries",253              "Dining",254              "Transport",255              "Utilities",256              "Entertainment",257              "Health",258              "Shopping",259              "Other"260            ],261            "required": true,262            "type": "text"263          },264          {265            "label": "Monthly limit",266            "name": "monthly_limit",267            "required": true,268            "type": "currency"269          }270        ],271        "seed": [272          {273            "category": "Housing",274            "monthly_limit": 1400275          },276          {277            "category": "Groceries",278            "monthly_limit": 450279          },280          {281            "category": "Dining",282            "monthly_limit": 200283          },284          {285            "category": "Transport",286            "monthly_limit": 150287          },288          {289            "category": "Utilities",290            "monthly_limit": 180291          },292          {293            "category": "Entertainment",294            "monthly_limit": 100295          }296        ]297      },298      "provenance": {299        "source": "agent"300      },301      "schemaVersion": 1,302      "type": "prism.data.table",303      "version": 1304    },305    {306      "children": [307        "dash_root"308      ],309      "id": "dashboard",310      "name": "Dashboard",311      "props": {312        "icon": "chart.pie"313      },314      "provenance": {315        "source": "agent"316      },317      "schemaVersion": 1,318      "type": "prism.page",319      "version": 1320    },321    {322      "children": [323        "tx_root"324      ],325      "id": "transactions_page",326      "name": "Transactions",327      "props": {328        "icon": "list.bullet.rectangle"329      },330      "provenance": {331        "source": "agent"332      },333      "schemaVersion": 1,334      "type": "prism.page",335      "version": 1336    },337    {338      "children": [339        "bud_root"340      ],341      "id": "budgets_page",342      "name": "Budgets",343      "props": {344        "icon": "target"345      },346      "provenance": {347        "source": "agent"348      },349      "schemaVersion": 1,350      "type": "prism.page",351      "version": 1352    },353    {354      "dependencies": [355        "transactions"356      ],357      "id": "month_expenses",358      "name": "Expenses this month",359      "props": {360        "query": {361          "aggregates": [362            {363              "as": "total",364              "column": "amount",365              "fn": "sum"366            }367          ],368          "filters": [369            {370              "column": "type",371              "op": "eq",372              "value": "Expense"373            },374            {375              "column": "date",376              "op": "startsWith",377              "value": {378                "$expr": "month(today())"379              }380            }381          ],382          "table": "transactions"383        }384      },385      "provenance": {386        "generated": true,387        "source": "agent"388      },389      "schemaVersion": 1,390      "type": "prism.data.query",391      "version": 1392    },393    {394      "dependencies": [395        "transactions"396      ],397      "id": "month_income",398      "name": "Income this month",399      "props": {400        "query": {401          "aggregates": [402            {403              "as": "total",404              "column": "amount",405              "fn": "sum"406            }407          ],408          "filters": [409            {410              "column": "type",411              "op": "eq",412              "value": "Income"413            },414            {415              "column": "date",416              "op": "startsWith",417              "value": {418                "$expr": "month(today())"419              }420            }421          ],422          "table": "transactions"423        }424      },425      "provenance": {426        "generated": true,427        "source": "agent"428      },429      "schemaVersion": 1,430      "type": "prism.data.query",431      "version": 1432    },433    {434      "dependencies": [435        "budgets"436      ],437      "id": "budget_total",438      "name": "Total monthly budget",439      "props": {440        "query": {441          "aggregates": [442            {443              "as": "total",444              "column": "monthly_limit",445              "fn": "sum"446            }447          ],448          "table": "budgets"449        }450      },451      "provenance": {452        "generated": true,453        "source": "agent"454      },455      "schemaVersion": 1,456      "type": "prism.data.query",457      "version": 1458    },459    {460      "children": [461        "dash_title",462        "dash_over_budget",463        "dash_near_budget",464        "dash_tiles",465        "dash_budget_progress",466        "dash_charts"467      ],468      "id": "dash_root",469      "props": {470        "align": "stretch",471        "grow": true,472        "padding": 20,473        "spacing": 16474      },475      "provenance": {476        "source": "agent"477      },478      "schemaVersion": 1,479      "type": "prism.stack",480      "version": 1481    },482    {483      "id": "dash_title",484      "props": {485        "text": {486          "$expr": "concat('Overview for ', month(today()))"487        }488      },489      "provenance": {490        "source": "agent"491      },492      "schemaVersion": 1,493      "type": "prism.heading",494      "version": 1495    },496    {497      "id": "dash_over_budget",498      "props": {499        "message": {500          "$expr": "concat('You have spent ', formatCurrency(sum(queries.month_expenses, 'total')), ' of your ', formatCurrency(sum(queries.budget_total, 'total')), ' monthly budget.')"501        },502        "title": "Over budget this month",503        "tone": "danger",504        "visible": {505          "$expr": "sum(queries.budget_total, 'total') > 0 && sum(queries.month_expenses, 'total') > sum(queries.budget_total, 'total')"506        }507      },508      "provenance": {509        "source": "agent"510      },511      "schemaVersion": 1,512      "type": "prism.alert",513      "version": 1514    },515    {516      "id": "dash_near_budget",517      "props": {518        "message": {519          "$expr": "concat(formatCurrency(sum(queries.budget_total, 'total') - sum(queries.month_expenses, 'total')), ' left in this month’s budget.')"520        },521        "title": "Approaching your budget",522        "tone": "warning",523        "visible": {524          "$expr": "sum(queries.budget_total, 'total') > 0 && sum(queries.month_expenses, 'total') >= 0.9 * sum(queries.budget_total, 'total') && sum(queries.month_expenses, 'total') <= sum(queries.budget_total, 'total')"525        }526      },527      "provenance": {528        "source": "agent"529      },530      "schemaVersion": 1,531      "type": "prism.alert",532      "version": 1533    },534    {535      "children": [536        "tile_income",537        "tile_expenses",538        "tile_balance",539        "tile_budget_left"540      ],541      "id": "dash_tiles",542      "props": {543        "columns": 4,544        "spacing": 12545      },546      "provenance": {547        "source": "agent"548      },549      "schemaVersion": 1,550      "type": "prism.grid",551      "version": 1552    },553    {554      "id": "tile_income",555      "props": {556        "format": "currency",557        "icon": "arrow.down.circle",558        "label": "Income this month",559        "tone": "success",560        "value": {561          "$expr": "sum(queries.month_income, 'total')"562        }563      },564      "provenance": {565        "source": "agent"566      },567      "schemaVersion": 1,568      "type": "prism.aggregation",569      "version": 1570    },571    {572      "id": "tile_expenses",573      "props": {574        "format": "currency",575        "icon": "arrow.up.circle",576        "label": "Expenses this month",577        "tone": "danger",578        "value": {579          "$expr": "sum(queries.month_expenses, 'total')"580        }581      },582      "provenance": {583        "source": "agent"584      },585      "schemaVersion": 1,586      "type": "prism.aggregation",587      "version": 1588    },589    {590      "id": "tile_balance",591      "props": {592        "format": "currency",593        "icon": "banknote",594        "label": "Net this month",595        "tone": {596          "$expr": "sum(queries.month_income, 'total') - sum(queries.month_expenses, 'total') >= 0 ? 'success' : 'danger'"597        },598        "value": {599          "$expr": "sum(queries.month_income, 'total') - sum(queries.month_expenses, 'total')"600        }601      },602      "provenance": {603        "source": "agent"604      },605      "schemaVersion": 1,606      "type": "prism.aggregation",607      "version": 1608    },609    {610      "id": "tile_budget_left",611      "props": {612        "format": "currency",613        "icon": "target",614        "label": "Budget remaining",615        "tone": {616          "$expr": "sum(queries.budget_total, 'total') - sum(queries.month_expenses, 'total') >= 0 ? 'info' : 'danger'"617        },618        "value": {619          "$expr": "sum(queries.budget_total, 'total') - sum(queries.month_expenses, 'total')"620        }621      },622      "provenance": {623        "source": "agent"624      },625      "schemaVersion": 1,626      "type": "prism.aggregation",627      "version": 1628    },629    {630      "id": "dash_budget_progress",631      "props": {632        "label": {633          "$expr": "concat('Monthly budget used: ', formatCurrency(sum(queries.month_expenses, 'total')), ' of ', formatCurrency(sum(queries.budget_total, 'total')))"634        },635        "showPercent": true,636        "tone": {637          "$expr": "sum(queries.month_expenses, 'total') > sum(queries.budget_total, 'total') ? 'danger' : (sum(queries.month_expenses, 'total') >= 0.9 * sum(queries.budget_total, 'total') ? 'warning' : 'success')"638        },639        "value": {640          "$expr": "sum(queries.budget_total, 'total') > 0 ? min(1, sum(queries.month_expenses, 'total') / sum(queries.budget_total, 'total')) : 0"641        }642      },643      "provenance": {644        "source": "agent"645      },646      "schemaVersion": 1,647      "type": "prism.progress",648      "version": 1649    },650    {651      "children": [652        "chart_by_category",653        "chart_per_month",654        "chart_income_per_month",655        "chart_all_time_category"656      ],657      "id": "dash_charts",658      "props": {659        "columns": 2,660        "grow": true,661        "spacing": 16662      },663      "provenance": {664        "source": "agent"665      },666      "schemaVersion": 1,667      "type": "prism.grid",668      "version": 1669    },670    {671      "dependencies": [672        "transactions"673      ],674      "id": "chart_by_category",675      "props": {676        "donut": true,677        "format": "currency",678        "height": 300,679        "label": "category",680        "query": {681          "aggregates": [682            {683              "as": "spent",684              "column": "amount",685              "fn": "sum"686            }687          ],688          "filters": [689            {690              "column": "type",691              "op": "eq",692              "value": "Expense"693            },694            {695              "column": "date",696              "op": "startsWith",697              "value": {698                "$expr": "month(today())"699              }700            }701          ],702          "groupBy": {703            "as": "category",704            "bucket": "none",705            "column": "category"706          },707          "sort": [708            {709              "column": "spent",710              "descending": true711            }712          ],713          "table": "transactions"714        },715        "title": "Spending by category this month",716        "value": "spent"717      },718      "provenance": {719        "source": "agent"720      },721      "schemaVersion": 1,722      "type": "prism.chart.pie",723      "version": 1724    },725    {726      "dependencies": [727        "transactions"728      ],729      "id": "chart_per_month",730      "props": {731        "format": "currency",732        "height": 300,733        "query": {734          "aggregates": [735            {736              "as": "total",737              "column": "amount",738              "fn": "sum"739            }740          ],741          "filters": [742            {743              "column": "type",744              "op": "eq",745              "value": "Expense"746            }747          ],748          "groupBy": {749            "as": "month",750            "bucket": "month",751            "column": "date"752          },753          "sort": [754            {755              "column": "month"756            }757          ],758          "table": "transactions"759        },760        "title": "Spending per month",761        "tone": "accent",762        "x": "month",763        "y": "total"764      },765      "provenance": {766        "source": "agent"767      },768      "schemaVersion": 1,769      "type": "prism.chart.line",770      "version": 1771    },772    {773      "dependencies": [774        "transactions"775      ],776      "id": "chart_income_per_month",777      "props": {778        "format": "currency",779        "height": 300,780        "query": {781          "aggregates": [782            {783              "as": "total",784              "column": "amount",785              "fn": "sum"786            }787          ],788          "filters": [789            {790              "column": "type",791              "op": "eq",792              "value": "Income"793            }794          ],795          "groupBy": {796            "as": "month",797            "bucket": "month",798            "column": "date"799          },800          "sort": [801            {802              "column": "month"803            }804          ],805          "table": "transactions"806        },807        "title": "Income per month",808        "tone": "success",809        "x": "month",810        "y": "total"811      },812      "provenance": {813        "source": "agent"814      },815      "schemaVersion": 1,816      "type": "prism.chart.bar",817      "version": 1818    },819    {820      "dependencies": [821        "transactions"822      ],823      "id": "chart_all_time_category",824      "props": {825        "format": "currency",826        "height": 300,827        "query": {828          "aggregates": [829            {830              "as": "spent",831              "column": "amount",832              "fn": "sum"833            }834          ],835          "filters": [836            {837              "column": "type",838              "op": "eq",839              "value": "Expense"840            }841          ],842          "groupBy": {843            "as": "category",844            "bucket": "none",845            "column": "category"846          },847          "sort": [848            {849              "column": "spent",850              "descending": true851            }852          ],853          "table": "transactions"854        },855        "title": "All-time spending by category",856        "tone": "info",857        "x": "category",858        "y": "spent"859      },860      "provenance": {861        "source": "agent"862      },863      "schemaVersion": 1,864      "type": "prism.chart.bar",865      "version": 1866    },867    {868      "children": [869        "tx_toolbar",870        "tx_notifications",871        "tx_split"872      ],873      "id": "tx_root",874      "props": {875        "align": "stretch",876        "grow": true,877        "padding": 16,878        "spacing": 12879      },880      "provenance": {881        "source": "agent"882      },883      "schemaVersion": 1,884      "type": "prism.stack",885      "version": 1886    },887    {888      "children": [889        "tx_search",890        "tx_category_filter",891        "tx_type_filter",892        "tx_new",893        "tx_import",894        "tx_export"895      ],896      "id": "tx_toolbar",897      "provenance": {898        "source": "agent"899      },900      "schemaVersion": 1,901      "type": "prism.toolbar",902      "version": 1903    },904    {905      "id": "tx_notifications",906      "provenance": {907        "source": "agent"908      },909      "schemaVersion": 1,910      "type": "prism.notification",911      "version": 1912    },913    {914      "children": [915        "tx_table",916        "tx_editor_card"917      ],918      "id": "tx_split",919      "props": {920        "direction": "horizontal",921        "grow": true922      },923      "provenance": {924        "source": "agent"925      },926      "schemaVersion": 1,927      "type": "prism.split",928      "version": 1929    },930    {931      "id": "tx_search",932      "props": {933        "accessibilityLabel": "Search transactions",934        "placeholder": "Search description or notes",935        "value": {936          "$bind": "search_text"937        },938        "width": 240939      },940      "provenance": {941        "source": "agent"942      },943      "schemaVersion": 1,944      "type": "prism.search",945      "version": 1946    },947    {948      "id": "tx_category_filter",949      "props": {950        "includeAll": "All",951        "label": "Category",952        "optionsFrom": {953          "column": "category",954          "table": "transactions"955        },956        "value": {957          "$bind": "category_filter"958        }959      },960      "provenance": {961        "source": "agent"962      },963      "schemaVersion": 1,964      "type": "prism.dropdown",965      "version": 1966    },967    {968      "id": "tx_type_filter",969      "props": {970        "label": "Type",971        "options": [972          "All",973          "Expense",974          "Income"975        ],976        "value": {977          "$bind": "type_filter"978        }979      },980      "provenance": {981        "source": "agent"982      },983      "schemaVersion": 1,984      "type": "prism.segmented",985      "version": 1986    },987    {988      "events": {989        "click": [990          {991            "key": "selected_tx",992            "type": "setState",993            "value": ""994          }995        ]996      },997      "id": "tx_new",998      "props": {999        "icon": "plus",1000        "title": "New Transaction"1001      },1002      "provenance": {1003        "source": "agent"1004      },1005      "schemaVersion": 1,1006      "type": "prism.button",1007      "version": 11008    },1009    {1010      "dependencies": [1011        "transactions"1012      ],1013      "events": {1014        "imported": [1015          {1016            "message": "Transactions imported.",1017            "tone": "success",1018            "type": "showNotification"1019          }1020        ]1021      },1022      "id": "tx_import",1023      "props": {1024        "help": "CSV columns: date, description, category, type, amount, notes",1025        "table": "transactions",1026        "title": "Import CSV…"1027      },1028      "provenance": {1029        "source": "agent"1030      },1031      "schemaVersion": 1,1032      "type": "prism.csvImport",1033      "version": 11034    },1035    {1036      "dependencies": [1037        "transactions"1038      ],1039      "id": "tx_export",1040      "props": {1041        "filename": "transactions.csv",1042        "query": {1043          "sort": [1044            {1045              "column": "date",1046              "descending": true1047            }1048          ],1049          "table": "transactions"1050        },1051        "title": "Export CSV…"1052      },1053      "provenance": {1054        "source": "agent"1055      },1056      "schemaVersion": 1,1057      "type": "prism.csvExport",1058      "version": 11059    },1060    {1061      "dependencies": [1062        "transactions"1063      ],1064      "id": "tx_table",1065      "props": {1066        "columns": [1067          {1068            "column": "date",1069            "format": "date",1070            "title": "Date"1071          },1072          {1073            "column": "description",1074            "title": "Description"1075          },1076          {1077            "column": "category",1078            "format": "badge",1079            "title": "Category"1080          },1081          {1082            "column": "type",1083            "title": "Type"1084          },1085          {1086            "align": "trailing",1087            "column": "amount",1088            "format": "currency",1089            "title": "Amount"1090          }1091        ],1092        "emptyMessage": "Add a transaction or import a CSV from your bank.",1093        "emptyTitle": "No transactions",1094        "grow": true,1095        "query": {1096          "filters": [1097            {1098              "column": "category",1099              "op": "eq",1100              "unless": "state.category_filter == 'All'",1101              "value": {1102                "$expr": "state.category_filter"1103              }1104            },1105            {1106              "column": "type",1107              "op": "eq",1108              "unless": "state.type_filter == 'All'",1109              "value": {1110                "$expr": "state.type_filter"1111              }1112            }1113          ],1114          "search": {1115            "columns": [1116              "description",1117              "notes"1118            ],1119            "text": {1120              "$expr": "state.search_text"1121            }1122          },1123          "sort": [1124            {1125              "column": "date",1126              "descending": true1127            }1128          ],1129          "table": "transactions"1130        },1131        "selection": {1132          "$bind": "selected_tx"1133        }1134      },1135      "provenance": {1136        "source": "agent"1137      },1138      "schemaVersion": 1,1139      "type": "prism.table",1140      "version": 11141    },1142    {1143      "children": [1144        "tx_editor"1145      ],1146      "id": "tx_editor_card",1147      "props": {1148        "title": {1149          "$expr": "isEmpty(state.selected_tx) ? 'New transaction' : 'Edit transaction'"1150        },1151        "width": 3201152      },1153      "provenance": {1154        "source": "agent"1155      },1156      "schemaVersion": 1,1157      "type": "prism.card",1158      "version": 11159    },1160    {1161      "events": {1162        "deleted": [1163          {1164            "key": "selected_tx",1165            "type": "setState",1166            "value": ""1167          },1168          {1169            "message": "Transaction deleted.",1170            "tone": "info",1171            "type": "showNotification"1172          }1173        ],1174        "saved": [1175          {1176            "message": "Transaction saved.",1177            "tone": "success",1178            "type": "showNotification"1179          }1180        ]1181      },1182      "id": "tx_editor",1183      "props": {1184        "allowDelete": true,1185        "fields": [1186          "date",1187          "description",1188          "category",1189          "type",1190          "amount",1191          "notes"1192        ],1193        "recordId": {1194          "$bind": "selected_tx"1195        },1196        "submitTitle": "Save",1197        "table": "transactions"1198      },1199      "provenance": {1200        "source": "agent"1201      },1202      "schemaVersion": 1,1203      "type": "prism.recordEditor",1204      "version": 11205    },1206    {1207      "children": [1208        "bud_progress",1209        "bud_split"1210      ],1211      "id": "bud_root",1212      "props": {1213        "align": "stretch",1214        "grow": true,1215        "padding": 16,1216        "spacing": 161217      },1218      "provenance": {1219        "source": "agent"1220      },1221      "schemaVersion": 1,1222      "type": "prism.stack",1223      "version": 11224    },1225    {1226      "id": "bud_progress",1227      "props": {1228        "label": {1229          "$expr": "concat('Spent this month: ', formatCurrency(sum(queries.month_expenses, 'total')), ' of ', formatCurrency(sum(queries.budget_total, 'total')), ' total budget')"1230        },1231        "showPercent": true,1232        "tone": {1233          "$expr": "sum(queries.month_expenses, 'total') > sum(queries.budget_total, 'total') ? 'danger' : (sum(queries.month_expenses, 'total') >= 0.9 * sum(queries.budget_total, 'total') ? 'warning' : 'success')"1234        },1235        "value": {1236          "$expr": "sum(queries.budget_total, 'total') > 0 ? min(1, sum(queries.month_expenses, 'total') / sum(queries.budget_total, 'total')) : 0"1237        }1238      },1239      "provenance": {1240        "source": "agent"1241      },1242      "schemaVersion": 1,1243      "type": "prism.progress",1244      "version": 11245    },1246    {1247      "children": [1248        "bud_crud",1249        "bud_actuals"1250      ],1251      "id": "bud_split",1252      "props": {1253        "direction": "horizontal",1254        "grow": true1255      },1256      "provenance": {1257        "source": "agent"1258      },1259      "schemaVersion": 1,1260      "type": "prism.split",1261      "version": 11262    },1263    {1264      "dependencies": [1265        "budgets"1266      ],1267      "id": "bud_crud",1268      "props": {1269        "columns": [1270          "category",1271          "monthly_limit"1272        ],1273        "grow": true,1274        "table": "budgets",1275        "title": "Monthly budgets by category"1276      },1277      "provenance": {1278        "source": "agent"1279      },1280      "schemaVersion": 1,1281      "type": "prism.crud",1282      "version": 11283    },1284    {1285      "children": [1286        "bud_actual_chart",1287        "bud_limit_chart"1288      ],1289      "id": "bud_actuals",1290      "props": {1291        "align": "stretch",1292        "spacing": 121293      },1294      "provenance": {1295        "source": "agent"1296      },1297      "schemaVersion": 1,1298      "type": "prism.stack",1299      "version": 11300    },1301    {1302      "dependencies": [1303        "transactions"1304      ],1305      "id": "bud_actual_chart",1306      "props": {1307        "format": "currency",1308        "height": 260,1309        "query": {1310          "aggregates": [1311            {1312              "as": "spent",1313              "column": "amount",1314              "fn": "sum"1315            }1316          ],1317          "filters": [1318            {1319              "column": "type",1320              "op": "eq",1321              "value": "Expense"1322            },1323            {1324              "column": "date",1325              "op": "startsWith",1326              "value": {1327                "$expr": "month(today())"1328              }1329            }1330          ],1331          "groupBy": {1332            "as": "category",1333            "bucket": "none",1334            "column": "category"1335          },1336          "sort": [1337            {1338              "column": "spent",1339              "descending": true1340            }1341          ],1342          "table": "transactions"1343        },1344        "title": "Spent this month by category",1345        "tone": "warning",1346        "x": "category",1347        "y": "spent"1348      },1349      "provenance": {1350        "source": "agent"1351      },1352      "schemaVersion": 1,1353      "type": "prism.chart.bar",1354      "version": 11355    },1356    {1357      "dependencies": [1358        "budgets"1359      ],1360      "id": "bud_limit_chart",1361      "props": {1362        "format": "currency",1363        "height": 260,1364        "query": {1365          "sort": [1366            {1367              "column": "monthly_limit",1368              "descending": true1369            }1370          ],1371          "table": "budgets"1372        },1373        "title": "Monthly limit by category",1374        "tone": "info",1375        "x": "category",1376        "y": "monthly_limit"1377      },1378      "provenance": {1379        "source": "agent"1380      },1381      "schemaVersion": 1,1382      "type": "prism.chart.bar",1383      "version": 11384    }1385  ],1386  "permissions": [1387    "storage.local",1388    "files.import.userSelected",1389    "files.export.userSelected"1390  ],1391  "schemaVersion": 1,1392  "state": {1393    "category_filter": "All",1394    "search_text": "",1395    "selected_budget": "",1396    "selected_tx": "",1397    "type_filter": "All"1398  },1399  "summary": "Track income and expenses, import bank CSVs, set monthly category budgets and see spending charts — all stored locally.",1400  "version": 11401}
Files main
Menu

Theme