Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
小 白蛋
Dgiot
Commits
a21db10d
Commit
a21db10d
authored
2 years ago
by
dawnwinterLiu
Browse files
Options
Download
Email Patches
Plain Diff
feat: update schemas.json
parent
95ea0763
yuhang
dependabot/maven/apps/dgiot_dlink/priv/example/java/com.google.protobuf-protobuf-java-3.19.6
h7ml
v4.7.0
v4.6.3
v4.6.2
v4.6.1
v4.6.0
v4.5.9
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
apps/dgiot_parse/etc/dgiot_parse.conf
+1
-1
apps/dgiot_parse/etc/dgiot_parse.conf
apps/dgiot_parse/priv/json/schemas.json
+346
-334
apps/dgiot_parse/priv/json/schemas.json
apps/dgiot_parse/src/dgiot_parse.erl
+0
-2
apps/dgiot_parse/src/dgiot_parse.erl
with
347 additions
and
337 deletions
+347
-337
apps/dgiot_parse/etc/dgiot_parse.conf
+
1
-
1
View file @
a21db10d
...
...
@@ -6,7 +6,7 @@ parse.delete_field = ACL,objectId,updatedAt,createdAt
##--------------------------------------------------------------------
## parse config
##--------------------------------------------------------------------
parse
.
parse_server
=
http
://
prod
.
dgiotcloud
.
cn
:
1337
parse
.
parse_server
=
http
://
127
.
0
.
0
.
1
:
1337
parse
.
timescale_server
=
http
://
127
.
0
.
0
.
1
:
1338
parse
.
parse_path
= /
parse
/
parse
.
parse_appid
=
d3300b6f53d7ee7da766142f2f7050eb
...
...
This diff is collapsed.
Click to expand it.
apps/dgiot_parse/priv/json/schemas.json
+
346
-
334
View file @
a21db10d
...
...
@@ -56,6 +56,88 @@
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
"*"
:
true
},
"count"
:
{
"*"
:
true
},
"create"
:
{
"*"
:
true
},
"delete"
:
{
"*"
:
true
},
"find"
:
{
"*"
:
true
},
"get"
:
{
"*"
:
true
},
"protectedFields"
:
{
"*"
:
[]
},
"update"
:
{
"*"
:
true
}
},
"className"
:
"_Installation"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"GCMSenderId"
:
{
"type"
:
"String"
},
"appIdentifier"
:
{
"type"
:
"String"
},
"appName"
:
{
"type"
:
"String"
},
"appVersion"
:
{
"type"
:
"String"
},
"badge"
:
{
"type"
:
"Number"
},
"channels"
:
{
"type"
:
"Array"
},
"createdAt"
:
{
"type"
:
"Date"
},
"deviceToken"
:
{
"type"
:
"String"
},
"deviceType"
:
{
"type"
:
"String"
},
"installationId"
:
{
"type"
:
"String"
},
"localeIdentifier"
:
{
"type"
:
"String"
},
"objectId"
:
{
"type"
:
"String"
},
"parseVersion"
:
{
"type"
:
"String"
},
"pushType"
:
{
"type"
:
"String"
},
"timeZone"
:
{
"type"
:
"String"
},
"updatedAt"
:
{
"type"
:
"Date"
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
...
...
@@ -243,88 +325,6 @@
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
"*"
:
true
},
"count"
:
{
"*"
:
true
},
"create"
:
{
"*"
:
true
},
"delete"
:
{
"*"
:
true
},
"find"
:
{
"*"
:
true
},
"get"
:
{
"*"
:
true
},
"protectedFields"
:
{
"*"
:
[]
},
"update"
:
{
"*"
:
true
}
},
"className"
:
"_Installation"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"GCMSenderId"
:
{
"type"
:
"String"
},
"appIdentifier"
:
{
"type"
:
"String"
},
"appName"
:
{
"type"
:
"String"
},
"appVersion"
:
{
"type"
:
"String"
},
"badge"
:
{
"type"
:
"Number"
},
"channels"
:
{
"type"
:
"Array"
},
"createdAt"
:
{
"type"
:
"Date"
},
"deviceToken"
:
{
"type"
:
"String"
},
"deviceType"
:
{
"type"
:
"String"
},
"installationId"
:
{
"type"
:
"String"
},
"localeIdentifier"
:
{
"type"
:
"String"
},
"objectId"
:
{
"type"
:
"String"
},
"parseVersion"
:
{
"type"
:
"String"
},
"pushType"
:
{
"type"
:
"String"
},
"timeZone"
:
{
"type"
:
"String"
},
"updatedAt"
:
{
"type"
:
"Date"
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
...
...
@@ -535,6 +535,86 @@
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
"*"
:
true
},
"count"
:
{
"*"
:
true
},
"create"
:
{
"*"
:
true
},
"delete"
:
{
"*"
:
true
},
"find"
:
{
"*"
:
true
},
"get"
:
{
"*"
:
true
},
"protectedFields"
:
{
"*"
:
[]
},
"update"
:
{
"*"
:
true
}
},
"className"
:
"_User"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"authData"
:
{
"type"
:
"Object"
},
"createdAt"
:
{
"type"
:
"Date"
},
"department"
:
{
"type"
:
"String"
},
"email"
:
{
"type"
:
"String"
},
"emailVerified"
:
{
"type"
:
"Boolean"
},
"nick"
:
{
"type"
:
"String"
},
"objectId"
:
{
"type"
:
"String"
},
"password"
:
{
"type"
:
"String"
},
"phone"
:
{
"type"
:
"String"
},
"role"
:
{
"required"
:
false
,
"targetClass"
:
"_Role"
,
"type"
:
"Relation"
},
"roles"
:
{
"required"
:
false
,
"targetClass"
:
"_Role"
,
"type"
:
"Relation"
},
"tag"
:
{
"type"
:
"Object"
},
"updatedAt"
:
{
"type"
:
"Date"
},
"username"
:
{
"type"
:
"String"
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
...
...
@@ -790,21 +870,97 @@
"*"
:
true
}
},
"className"
:
"
Category
"
,
"className"
:
"
Notification
"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"createdAt"
:
{
"type"
:
"Date"
},
"data"
:
{
"content"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"level"
:
{
"required"
:
false
,
"type"
:
"Number"
"createdAt"
:
{
"type"
:
"Date"
},
"deletedBy"
:
{
"targetClass"
:
"_User"
,
"type"
:
"Relation"
},
"objectId"
:
{
"type"
:
"String"
},
"process"
:
{
"required"
:
false
,
"type"
:
"String"
},
"public"
:
{
"type"
:
"Boolean"
},
"readBy"
:
{
"targetClass"
:
"_User"
,
"type"
:
"Relation"
},
"sender"
:
{
"targetClass"
:
"_User"
,
"type"
:
"Pointer"
},
"status"
:
{
"type"
:
"Number"
},
"type"
:
{
"type"
:
"String"
},
"updatedAt"
:
{
"type"
:
"Date"
},
"user"
:
{
"targetClass"
:
"_User"
,
"type"
:
"Pointer"
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
"*"
:
true
},
"count"
:
{
"*"
:
true
},
"create"
:
{
"*"
:
true
},
"delete"
:
{
"*"
:
true
},
"find"
:
{
"*"
:
true
},
"get"
:
{
"*"
:
true
},
"protectedFields"
:
{
"*"
:
[]
},
"update"
:
{
"*"
:
true
}
},
"className"
:
"Category"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"createdAt"
:
{
"type"
:
"Date"
},
"data"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"level"
:
{
"required"
:
false
,
"type"
:
"Number"
},
"name"
:
{
"required"
:
false
,
...
...
@@ -941,56 +1097,43 @@
"*"
:
true
}
},
"className"
:
"
_User
"
,
"className"
:
"
View
"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"authData"
:
{
"type"
:
"Object"
"class"
:
{
"required"
:
false
,
"type"
:
"String"
},
"createdAt"
:
{
"type"
:
"Date"
},
"department"
:
{
"type"
:
"String"
"data"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"email"
:
{
"key"
:
{
"required"
:
false
,
"type"
:
"String"
},
"emailVerified"
:
{
"type"
:
"Boolean"
},
"nick"
:
{
"language"
:
{
"required"
:
false
,
"type"
:
"String"
},
"objectId"
:
{
"type"
:
"String"
},
"password"
:
{
"type"
:
"String"
},
"phone"
:
{
"type"
:
"String"
},
"role"
:
{
"title"
:
{
"required"
:
false
,
"targetClass"
:
"_Role"
,
"type"
:
"Relation"
"type"
:
"String"
},
"
roles
"
:
{
"
type
"
:
{
"required"
:
false
,
"targetClass"
:
"_Role"
,
"type"
:
"Relation"
},
"tag"
:
{
"type"
:
"Object"
"type"
:
"String"
},
"updatedAt"
:
{
"type"
:
"Date"
},
"username"
:
{
"type"
:
"String"
}
}
},
...
...
@@ -1156,59 +1299,83 @@
"*"
:
true
}
},
"className"
:
"
Notification
"
,
"className"
:
"
_Role
"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"content"
:
{
"required"
:
false
,
"type"
:
"Object"
"alias"
:
{
"type"
:
"String"
},
"createdAt"
:
{
"type"
:
"Date"
},
"deletedBy"
:
{
"targetClass"
:
"_User"
,
"type"
:
"Relation"
},
"objectId"
:
{
"depname"
:
{
"type"
:
"String"
},
"process"
:
{
"required"
:
false
,
"desc"
:
{
"type"
:
"String"
},
"
public
"
:
{
"
leafnode
"
:
{
"type"
:
"Boolean"
},
"readBy"
:
{
"targetClass"
:
"_User"
,
"level"
:
{
"type"
:
"Number"
},
"menus"
:
{
"targetClass"
:
"Menu"
,
"type"
:
"Relation"
},
"sender"
:
{
"targetClass"
:
"_User"
,
"type"
:
"Pointer"
"name"
:
{
"type"
:
"String"
},
"status"
:
{
"objectId"
:
{
"type"
:
"String"
},
"order"
:
{
"type"
:
"Number"
},
"type"
:
{
"
org_
type"
:
{
"type"
:
"String"
},
"parent"
:
{
"targetClass"
:
"_Role"
,
"type"
:
"Pointer"
},
"roles"
:
{
"targetClass"
:
"_Role"
,
"type"
:
"Relation"
},
"rules"
:
{
"targetClass"
:
"Permission"
,
"type"
:
"Relation"
},
"tag"
:
{
"type"
:
"Object"
},
"updatedAt"
:
{
"type"
:
"Date"
},
"user"
:
{
"user
s
"
:
{
"targetClass"
:
"_User"
,
"type"
:
"Pointer"
"type"
:
"Relation"
},
"views"
:
{
"required"
:
false
,
"targetClass"
:
"View"
,
"type"
:
"Relation"
},
"views1"
:
{
"required"
:
false
,
"targetClass"
:
"View"
,
"type"
:
"Relation"
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
"
role:root
"
:
true
"
*
"
:
true
},
"count"
:
{
"*"
:
true
...
...
@@ -1232,41 +1399,63 @@
"*"
:
true
}
},
"className"
:
"
View
"
,
"className"
:
"
ProductTemplet
"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"c
lass
"
:
{
"c
ategory
"
:
{
"required"
:
false
,
"type"
:
"String"
"targetClass"
:
"Category"
,
"type"
:
"Pointer"
},
"config"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"content"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"createdAt"
:
{
"type"
:
"Date"
},
"d
ata
"
:
{
"d
ecoder
"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"
key
"
:
{
"
desc
"
:
{
"required"
:
false
,
"type"
:
"String"
},
"
language
"
:
{
"
icon
"
:
{
"required"
:
false
,
"type"
:
"String"
},
"
objectI
d"
:
{
"
i
d"
:
{
"type"
:
"String"
},
"
titl
e"
:
{
"
nam
e"
:
{
"required"
:
false
,
"type"
:
"String"
},
"type"
:
{
"required"
:
false
,
"netType"
:
{
"type"
:
"String"
},
"nodeType"
:
{
"type"
:
"Number"
},
"objectId"
:
{
"type"
:
"String"
},
"profile"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"thing"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"updatedAt"
:
{
"type"
:
"Date"
}
...
...
@@ -1377,6 +1566,10 @@
"route"
:
{
"type"
:
"Object"
},
"state"
:
{
"required"
:
false
,
"type"
:
"Number"
},
"status"
:
{
"type"
:
"String"
},
...
...
@@ -1456,6 +1649,9 @@
"required"
:
false
,
"type"
:
"Number"
},
"orderBy"
:
{
"type"
:
"Number"
},
"parent"
:
{
"required"
:
false
,
"targetClass"
:
"Article"
,
...
...
@@ -1478,190 +1674,6 @@
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
"*"
:
true
},
"count"
:
{
"*"
:
true
},
"create"
:
{
"*"
:
true
},
"delete"
:
{
"*"
:
true
},
"find"
:
{
"*"
:
true
},
"get"
:
{
"*"
:
true
},
"protectedFields"
:
{
"*"
:
[]
},
"update"
:
{
"*"
:
true
}
},
"className"
:
"_Role"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"alias"
:
{
"type"
:
"String"
},
"createdAt"
:
{
"type"
:
"Date"
},
"depname"
:
{
"type"
:
"String"
},
"desc"
:
{
"type"
:
"String"
},
"leafnode"
:
{
"type"
:
"Boolean"
},
"level"
:
{
"type"
:
"Number"
},
"menus"
:
{
"targetClass"
:
"Menu"
,
"type"
:
"Relation"
},
"name"
:
{
"type"
:
"String"
},
"objectId"
:
{
"type"
:
"String"
},
"order"
:
{
"type"
:
"Number"
},
"org_type"
:
{
"type"
:
"String"
},
"parent"
:
{
"targetClass"
:
"_Role"
,
"type"
:
"Pointer"
},
"roles"
:
{
"targetClass"
:
"_Role"
,
"type"
:
"Relation"
},
"rules"
:
{
"targetClass"
:
"Permission"
,
"type"
:
"Relation"
},
"tag"
:
{
"type"
:
"Object"
},
"updatedAt"
:
{
"type"
:
"Date"
},
"users"
:
{
"targetClass"
:
"_User"
,
"type"
:
"Relation"
},
"views"
:
{
"required"
:
false
,
"targetClass"
:
"View"
,
"type"
:
"Relation"
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
"*"
:
true
},
"count"
:
{
"*"
:
true
},
"create"
:
{
"*"
:
true
},
"delete"
:
{
"*"
:
true
},
"find"
:
{
"*"
:
true
},
"get"
:
{
"*"
:
true
},
"protectedFields"
:
{
"*"
:
[]
},
"update"
:
{
"*"
:
true
}
},
"className"
:
"ProductTemplet"
,
"fields"
:
{
"ACL"
:
{
"type"
:
"ACL"
},
"category"
:
{
"required"
:
false
,
"targetClass"
:
"Category"
,
"type"
:
"Pointer"
},
"config"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"content"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"createdAt"
:
{
"type"
:
"Date"
},
"decoder"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"desc"
:
{
"required"
:
false
,
"type"
:
"String"
},
"icon"
:
{
"required"
:
false
,
"type"
:
"String"
},
"id"
:
{
"type"
:
"String"
},
"name"
:
{
"required"
:
false
,
"type"
:
"String"
},
"netType"
:
{
"type"
:
"String"
},
"nodeType"
:
{
"type"
:
"Number"
},
"objectId"
:
{
"type"
:
"String"
},
"profile"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"thing"
:
{
"required"
:
false
,
"type"
:
"Object"
},
"updatedAt"
:
{
"type"
:
"Date"
}
}
},
{
"classLevelPermissions"
:
{
"addField"
:
{
...
...
This diff is collapsed.
Click to expand it.
apps/dgiot_parse/src/dgiot_parse.erl
+
0
-
2
View file @
a21db10d
...
...
@@ -100,8 +100,6 @@ update_schemas_json() ->
dgiot_product
:
update_properties
(),
%% 表字段更新
Schemas
=
dgiot_parse
:
get_schemas_json
(),
dgiot_parse
:
del_filed_schemas
(
<<
"Product"
>>
,
[
<<
"topics"
>>
]),
dgiot_parse
:
del_filed_schemas
(
<<
"Article"
>>
,
[
<<
"timestamp"
>>
]),
timer
:
sleep
(
1000
),
lists
:
foldl
(
fun
(
#
{
<<
"className"
>>
:
=
ClassName
,
<<
"fields"
>>
:
=
Fields
},
_
Acc
)
->
maps
:
fold
(
fun
(
Key
,
Value
,
_
Acc1
)
->
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help