]> git.ktnx.net Git - mobile-ledger.git/blob - app/schemas/net.ktnx.mobileledger.db.DB/55.json
add uuid to templates
[mobile-ledger.git] / app / schemas / net.ktnx.mobileledger.db.DB / 55.json
1 {
2   "formatVersion": 1,
3   "database": {
4     "version": 55,
5     "identityHash": "ed75412e9453605c9829ad7f3269f62e",
6     "entities": [
7       {
8         "tableName": "templates",
9         "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `name` TEXT NOT NULL, `regular_expression` TEXT NOT NULL, `test_text` TEXT, `transaction_description` TEXT, `transaction_description_match_group` INTEGER, `transaction_comment` TEXT, `transaction_comment_match_group` INTEGER, `date_year` INTEGER, `date_year_match_group` INTEGER, `date_month` INTEGER, `date_month_match_group` INTEGER, `date_day` INTEGER, `date_day_match_group` INTEGER)",
10         "fields": [
11           {
12             "fieldPath": "id",
13             "columnName": "id",
14             "affinity": "INTEGER",
15             "notNull": true
16           },
17           {
18             "fieldPath": "name",
19             "columnName": "name",
20             "affinity": "TEXT",
21             "notNull": true
22           },
23           {
24             "fieldPath": "regularExpression",
25             "columnName": "regular_expression",
26             "affinity": "TEXT",
27             "notNull": true
28           },
29           {
30             "fieldPath": "testText",
31             "columnName": "test_text",
32             "affinity": "TEXT",
33             "notNull": false
34           },
35           {
36             "fieldPath": "transactionDescription",
37             "columnName": "transaction_description",
38             "affinity": "TEXT",
39             "notNull": false
40           },
41           {
42             "fieldPath": "transactionDescriptionMatchGroup",
43             "columnName": "transaction_description_match_group",
44             "affinity": "INTEGER",
45             "notNull": false
46           },
47           {
48             "fieldPath": "transactionComment",
49             "columnName": "transaction_comment",
50             "affinity": "TEXT",
51             "notNull": false
52           },
53           {
54             "fieldPath": "transactionCommentMatchGroup",
55             "columnName": "transaction_comment_match_group",
56             "affinity": "INTEGER",
57             "notNull": false
58           },
59           {
60             "fieldPath": "dateYear",
61             "columnName": "date_year",
62             "affinity": "INTEGER",
63             "notNull": false
64           },
65           {
66             "fieldPath": "dateYearMatchGroup",
67             "columnName": "date_year_match_group",
68             "affinity": "INTEGER",
69             "notNull": false
70           },
71           {
72             "fieldPath": "dateMonth",
73             "columnName": "date_month",
74             "affinity": "INTEGER",
75             "notNull": false
76           },
77           {
78             "fieldPath": "dateMonthMatchGroup",
79             "columnName": "date_month_match_group",
80             "affinity": "INTEGER",
81             "notNull": false
82           },
83           {
84             "fieldPath": "dateDay",
85             "columnName": "date_day",
86             "affinity": "INTEGER",
87             "notNull": false
88           },
89           {
90             "fieldPath": "dateDayMatchGroup",
91             "columnName": "date_day_match_group",
92             "affinity": "INTEGER",
93             "notNull": false
94           }
95         ],
96         "primaryKey": {
97           "columnNames": [
98             "id"
99           ],
100           "autoGenerate": true
101         },
102         "indices": [],
103         "foreignKeys": []
104       },
105       {
106         "tableName": "template_accounts",
107         "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `template_id` INTEGER NOT NULL, `acc` TEXT, `position` INTEGER NOT NULL, `acc_match_group` INTEGER, `currency` INTEGER, `currency_match_group` INTEGER, `amount` REAL, `amount_match_group` INTEGER, `comment` TEXT, `comment_match_group` INTEGER, `negate_amount` INTEGER, FOREIGN KEY(`template_id`) REFERENCES `templates`(`id`) ON UPDATE RESTRICT ON DELETE CASCADE , FOREIGN KEY(`currency`) REFERENCES `currencies`(`id`) ON UPDATE RESTRICT ON DELETE RESTRICT )",
108         "fields": [
109           {
110             "fieldPath": "id",
111             "columnName": "id",
112             "affinity": "INTEGER",
113             "notNull": true
114           },
115           {
116             "fieldPath": "templateId",
117             "columnName": "template_id",
118             "affinity": "INTEGER",
119             "notNull": true
120           },
121           {
122             "fieldPath": "accountName",
123             "columnName": "acc",
124             "affinity": "TEXT",
125             "notNull": false
126           },
127           {
128             "fieldPath": "position",
129             "columnName": "position",
130             "affinity": "INTEGER",
131             "notNull": true
132           },
133           {
134             "fieldPath": "accountNameMatchGroup",
135             "columnName": "acc_match_group",
136             "affinity": "INTEGER",
137             "notNull": false
138           },
139           {
140             "fieldPath": "currency",
141             "columnName": "currency",
142             "affinity": "INTEGER",
143             "notNull": false
144           },
145           {
146             "fieldPath": "currencyMatchGroup",
147             "columnName": "currency_match_group",
148             "affinity": "INTEGER",
149             "notNull": false
150           },
151           {
152             "fieldPath": "amount",
153             "columnName": "amount",
154             "affinity": "REAL",
155             "notNull": false
156           },
157           {
158             "fieldPath": "amountMatchGroup",
159             "columnName": "amount_match_group",
160             "affinity": "INTEGER",
161             "notNull": false
162           },
163           {
164             "fieldPath": "accountComment",
165             "columnName": "comment",
166             "affinity": "TEXT",
167             "notNull": false
168           },
169           {
170             "fieldPath": "accountCommentMatchGroup",
171             "columnName": "comment_match_group",
172             "affinity": "INTEGER",
173             "notNull": false
174           },
175           {
176             "fieldPath": "negateAmount",
177             "columnName": "negate_amount",
178             "affinity": "INTEGER",
179             "notNull": false
180           }
181         ],
182         "primaryKey": {
183           "columnNames": [
184             "id"
185           ],
186           "autoGenerate": true
187         },
188         "indices": [
189           {
190             "name": "fk_template_accounts_template",
191             "unique": false,
192             "columnNames": [
193               "template_id"
194             ],
195             "createSql": "CREATE INDEX IF NOT EXISTS `fk_template_accounts_template` ON `${TABLE_NAME}` (`template_id`)"
196           },
197           {
198             "name": "fk_template_accounts_currency",
199             "unique": false,
200             "columnNames": [
201               "currency"
202             ],
203             "createSql": "CREATE INDEX IF NOT EXISTS `fk_template_accounts_currency` ON `${TABLE_NAME}` (`currency`)"
204           }
205         ],
206         "foreignKeys": [
207           {
208             "table": "templates",
209             "onDelete": "CASCADE",
210             "onUpdate": "RESTRICT",
211             "columns": [
212               "template_id"
213             ],
214             "referencedColumns": [
215               "id"
216             ]
217           },
218           {
219             "table": "currencies",
220             "onDelete": "RESTRICT",
221             "onUpdate": "RESTRICT",
222             "columns": [
223               "currency"
224             ],
225             "referencedColumns": [
226               "id"
227             ]
228           }
229         ]
230       },
231       {
232         "tableName": "currencies",
233         "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `name` TEXT NOT NULL, `position` TEXT NOT NULL, `has_gap` INTEGER NOT NULL)",
234         "fields": [
235           {
236             "fieldPath": "id",
237             "columnName": "id",
238             "affinity": "INTEGER",
239             "notNull": true
240           },
241           {
242             "fieldPath": "name",
243             "columnName": "name",
244             "affinity": "TEXT",
245             "notNull": true
246           },
247           {
248             "fieldPath": "position",
249             "columnName": "position",
250             "affinity": "TEXT",
251             "notNull": true
252           },
253           {
254             "fieldPath": "hasGap",
255             "columnName": "has_gap",
256             "affinity": "INTEGER",
257             "notNull": true
258           }
259         ],
260         "primaryKey": {
261           "columnNames": [
262             "id"
263           ],
264           "autoGenerate": true
265         },
266         "indices": [],
267         "foreignKeys": []
268       }
269     ],
270     "views": [],
271     "setupQueries": [
272       "CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)",
273       "INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, 'ed75412e9453605c9829ad7f3269f62e')"
274     ]
275   }
276 }