2023-06-01 16:34:41 +00:00
[
{
"id" : "w85pgrtrmovf916" ,
"name" : "transactions" ,
"type" : "base" ,
"system" : false ,
"schema" : [
{
"id" : "5aeh5giq" ,
"name" : "account" ,
"type" : "relation" ,
"system" : false ,
"required" : true ,
"options" : {
"collectionId" : "74ftooxenpeq14b" ,
"cascadeDelete" : false ,
"minSelect" : null ,
"maxSelect" : 1 ,
"displayFields" : [
"firstName" ,
"lastName"
]
}
} ,
{
"id" : "2bzqyeuk" ,
"name" : "label" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
"id" : "zsx9i8w7" ,
"name" : "amount" ,
"type" : "number" ,
"system" : false ,
"required" : false ,
"options" : {
"min" : null ,
"max" : null
}
}
] ,
"indexes" : [ ] ,
"listRule" : "" ,
"viewRule" : "" ,
"createRule" : "" ,
"updateRule" : null ,
"deleteRule" : null ,
"options" : { }
} ,
{
"id" : "p0gixtx6jwria0d" ,
"name" : "accountsData" ,
"type" : "base" ,
"system" : false ,
"schema" : [
{
"id" : "6ubgbgeq" ,
"name" : "birthday" ,
"type" : "date" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : "" ,
"max" : ""
}
} ,
{
"id" : "r8rs5y2b" ,
"name" : "email" ,
"type" : "email" ,
"system" : false ,
"required" : true ,
"options" : {
"exceptDomains" : null ,
"onlyDomains" : null
}
} ,
{
"id" : "uu9474bx" ,
"name" : "firstNameParent" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
"id" : "xmqazgjl" ,
"name" : "lastNameParent" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
"id" : "atylx3pk" ,
"name" : "street" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
"id" : "1ocem7g7" ,
"name" : "zipCode" ,
"type" : "number" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null
}
} ,
{
"id" : "73do7uq3" ,
"name" : "city" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
"id" : "ktjkhpmz" ,
"name" : "phone" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
}
] ,
"indexes" : [ ] ,
"listRule" : null ,
"viewRule" : null ,
"createRule" : null ,
"updateRule" : null ,
"deleteRule" : null ,
"options" : { }
} ,
{
"id" : "c3zz98wpbn7m6zw" ,
"name" : "accountsList" ,
"type" : "view" ,
"system" : false ,
"schema" : [
{
2023-06-25 13:34:09 +00:00
"id" : "cuolaytr" ,
2023-06-01 16:34:41 +00:00
"name" : "accountNumber" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
2023-06-25 13:34:09 +00:00
"id" : "4ogve0z2" ,
2023-06-01 16:34:41 +00:00
"name" : "name" ,
"type" : "json" ,
"system" : false ,
"required" : false ,
"options" : { }
} ,
{
2023-06-25 13:34:09 +00:00
"id" : "qzg3mjed" ,
2023-06-01 16:34:41 +00:00
"name" : "lastCheckIn" ,
"type" : "date" ,
"system" : false ,
"required" : false ,
"options" : {
"min" : "" ,
"max" : ""
}
} ,
{
2023-06-25 13:34:09 +00:00
"id" : "10gtuloy" ,
2023-06-01 16:34:41 +00:00
"name" : "balance" ,
"type" : "json" ,
"system" : false ,
"required" : false ,
"options" : { }
}
] ,
"indexes" : [ ] ,
"listRule" : null ,
"viewRule" : null ,
"createRule" : null ,
"updateRule" : null ,
"deleteRule" : null ,
"options" : {
"query" : "SELECT\n a.id AS id,\n a.accountNumber AS accountNumber,\n (a.firstName || ' ' || a.lastName) AS name,\n a.lastCheckIn AS lastCheckIn,\n SUM(t.amount) AS balance\nFROM\n accounts AS a\nLEFT JOIN\n transactions AS t\nON\n a.id = t.account\nGROUP BY\n a.id"
}
2023-06-25 13:34:09 +00:00
} ,
{
"id" : "t4gewf713jqhz3i" ,
"name" : "settings" ,
"type" : "base" ,
"system" : false ,
"schema" : [
{
"id" : "z7pmr7wm" ,
"name" : "minWage" ,
"type" : "number" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : 0 ,
"max" : null
}
} ,
{
"id" : "7wzv9qum" ,
"name" : "incomeTax" ,
"type" : "number" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : 0 ,
"max" : null
}
} ,
{
"id" : "dawtvakx" ,
"name" : "maxWageFactor" ,
"type" : "number" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : 0 ,
"max" : null
}
2023-06-30 12:59:53 +00:00
} ,
{
"id" : "ftzmu1na" ,
"name" : "radioUrl" ,
"type" : "url" ,
"system" : false ,
"required" : true ,
"options" : {
"exceptDomains" : [ ] ,
"onlyDomains" : [ ]
}
2023-06-25 13:34:09 +00:00
}
] ,
"indexes" : [ ] ,
2023-06-30 12:59:53 +00:00
"listRule" : "" ,
"viewRule" : "" ,
2023-06-25 13:34:09 +00:00
"createRule" : null ,
"updateRule" : null ,
"deleteRule" : null ,
"options" : { }
2023-06-30 14:18:07 +00:00
} ,
{
"id" : "s854d2w72fvyl54" ,
"name" : "companies" ,
"type" : "auth" ,
"system" : false ,
"schema" : [ ] ,
"indexes" : [ ] ,
"listRule" : null ,
"viewRule" : null ,
"createRule" : null ,
"updateRule" : null ,
"deleteRule" : null ,
"options" : {
"allowEmailAuth" : true ,
"allowOAuth2Auth" : true ,
"allowUsernameAuth" : true ,
"exceptEmailDomains" : null ,
"manageRule" : null ,
"minPasswordLength" : 8 ,
"onlyEmailDomains" : null ,
"requireEmail" : false
}
} ,
{
"id" : "74ftooxenpeq14b" ,
"name" : "accounts" ,
"type" : "base" ,
"system" : false ,
"schema" : [
{
"id" : "as1gvc1r" ,
"name" : "accountNumber" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
"id" : "vxeq20lk" ,
"name" : "firstName" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
"id" : "bsinpdk7" ,
"name" : "lastName" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
"id" : "syfivtki" ,
"name" : "lastCheckIn" ,
"type" : "date" ,
"system" : false ,
"required" : false ,
"options" : {
"min" : "" ,
"max" : ""
}
} ,
{
"id" : "pkoynx7h" ,
"name" : "personalData" ,
"type" : "relation" ,
"system" : false ,
"required" : false ,
"options" : {
"collectionId" : "p0gixtx6jwria0d" ,
"cascadeDelete" : false ,
"minSelect" : null ,
"maxSelect" : 1 ,
"displayFields" : [
"firstNameParent" ,
"lastNameParent" ,
"email"
]
}
} ,
{
"id" : "gwrzizpu" ,
"name" : "company" ,
"type" : "relation" ,
"system" : false ,
"required" : true ,
"options" : {
"collectionId" : "s854d2w72fvyl54" ,
"cascadeDelete" : false ,
"minSelect" : null ,
"maxSelect" : 1 ,
"displayFields" : [ ]
}
} ,
{
"id" : "rtvjzpxw" ,
"name" : "shift" ,
"type" : "text" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : null ,
"max" : null ,
"pattern" : ""
}
} ,
{
"id" : "ma5ckyk1" ,
"name" : "wageFactor" ,
"type" : "number" ,
"system" : false ,
"required" : true ,
"options" : {
"min" : 0 ,
"max" : null
}
}
] ,
"indexes" : [
"CREATE UNIQUE INDEX `idx_mPdvrAQ` ON `accounts` (`accountNumber`)"
] ,
"listRule" : "" ,
"viewRule" : null ,
"createRule" : null ,
"updateRule" : "(@request.data.id = null && @request.data.accountNumber = null && @request.data.firstName = null && @request.data.lastName = null && @request.data.created = null && @request.data.updated = null && @request.data.company = null && @request.data.shift = null && @request.data.wageFactor = null) || (@request.data.id = null && @request.data.accountNumber = null && @request.data.firstName = null && @request.data.lastName = null && @request.data.created = null && @request.data.updated = null && @request.data.company = null && @request.data.shift = null && @request.auth.id = company.id)" ,
"deleteRule" : null ,
"options" : { }
2023-06-01 16:34:41 +00:00
}
]