{
"trait": true,
"fields": [
{
"name": "id",
"type": "id"
}
]
}
{
"trait": true,
"fields": [
{
"name": "name",
"type": "string",
"length": 255
},
{
"name": "username",
"type": "string",
"length": 255
},
{
"name": "email",
"type": "string",
"length": 255
},
{
"name": "phone",
"type": "string",
"length": 255
},
{
"name": "avatarUrl",
"type": "string",
"length": 255
},
{
"name": "enabled",
"type": "boolean",
"nullable": false
}
],
"traits": [
"liteql.domain_type"
]
}
{
"fields": [
{
"name": "id",
"type": "id"
},
{
"name": "name",
"type": "string",
"length": 255,
"nullable": false
},
{
"name": "code",
"type": "string",
"length": 255,
"nullable": false
},
{
"name": "users",
"type": "reference",
"domainTypeName": "liteql_test.user",
"collection": true
}
],
"uniques": [
{
"fields": [
"code"
]
}
],
"indexes": [
{
"fields": [
"name"
]
}
],
"traits": [
"liteql.domain_type"
]
}
{
"fields": [
{
"name": "id",
"type": "id"
},
{
"name": "username",
"type": "string",
"nullable": false,
"length": 255
},
{
"name": "name",
"type": "string",
"nullable": false,
"length": 255
},
{
"name": "age",
"type": "integer"
},
{
"name": "email",
"type": "string",
"length": 255
},
{
"name": "phone",
"type": "string",
"length": 255
},
{
"name": "avatarUrl",
"type": "string",
"length": 255
},
{
"name": "organization",
"type": "reference",
"domainTypeName": "liteql_test.organization"
},
{
"name": "organizations",
"type": "reference",
"domainTypeName": "liteql_test.organization",
"mappedDomainTypeName": "liteql_test.user_organization",
"collection": true
},
{
"name": "country",
"type": "reference",
"domainTypeName": "liteql_test.country"
},
{
"name": "enabled",
"type": "boolean"
},
{
"name": "deleted",
"type": "boolean"
},
{
"name": "deletable",
"type": "boolean"
},
{
"name": "inherent",
"type": "boolean"
},
{
"name": "creatorId",
"type": "string",
"length": 255
},
{
"name": "creatorName",
"type": "string",
"length": 255
},
{
"name": "createTime",
"type": "timestamp"
},
{
"name": "lastModifierId",
"type": "string",
"length": 255
},
{
"name": "lastModifierName",
"type": "string",
"length": 255
},
{
"name": "lastModifiedTime",
"type": "timestamp"
}
],
"uniques": [
{
"fields": [
"username"
]
}
],
"indexes": [
{
"fields": [
"email"
]
}
],
"traits": [
"liteql.audit_type",
"liteql.user_type"
]
}
{
"queryType": "read",
"domainTypeName": "liteql_test.user",
"joins": [
{
"domainTypeName": "liteql_test.organization",
"fields": {
"name": "organizationName",
"code": "organizationCode"
},
"conditions": [
{
"field": "code",
"condition": "starts_with",
"value": "F"
}
],
"joins": [
{
"domainTypeName": "liteql_test.country",
"fields": {
"name": "countryName",
"code": "countryCode"
}
}
]
}
]
}
{
"queryType": "create",
"domainTypeName": "liteql_test.user",
"data": {
"name": "Carr Chang",
"username": "carrchang"
}
}
{
"queryType": "update",
"domainTypeName": "liteql_test.user",
"data": {
"email": "carr@example.com",
"username": "carrchang"
}
}
{
"domainTypeName": "liteql_test.user",
"conditions": [
{
"field": "name",
"condition": "contains",
"value": "s"
}
]
}
{
"init_system": [
{
"queryType": "create",
"domainTypeName": "liteql_test.country",
"data": {
"name": "United States",
"code": "usa"
}
},
{
"queryType": "create",
"domainTypeName": "liteql_test.organization",
"data": {
"name": "test",
"code": "test",
"country": {
"code": "cn"
},
"parentId": "ROOT",
"priority": 0,
"sortCode": "1001",
"leaf": true
}
},
{
"queryType": "create",
"domainTypeName": "liteql_test.user",
"data": {
"name": "Administrator",
"username": "admin"
}
}
],
"users": {
"queryType": "read",
"domainTypeName": "liteql_test.user",
"joins": [
{
"domainTypeName": "liteql_test.organization",
"fields": {
"name": "organizationName",
"code": "organizationCode"
}
},
{
"domainTypeName": "liteql_test.country",
"fields": {
"name": "countryName",
"code": "countryCode"
}
}
]
}
}